static void OnDrawLinePathPropertyChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) { TextOnAPath textOnAPath = d as TextOnAPath; if (textOnAPath == null) { return; } if (e.NewValue == e.OldValue || e.NewValue == null) { return; } textOnAPath.Update(); }
static void OnTextPathPropertyChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) { TextOnAPath textOnAPath = d as TextOnAPath; if (textOnAPath == null) { return; } if (e.NewValue == e.OldValue || e.NewValue == null) { return; } textOnAPath.TextPath.Transform = null; textOnAPath.UpdateSize(); textOnAPath.Update(); }
static void OnStringPropertyChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) { TextOnAPath textOnAPath = d as TextOnAPath; if (textOnAPath == null) { return; } if (e.NewValue == e.OldValue || e.NewValue == null) { if (textOnAPath._layoutPanel != null) { textOnAPath._layoutPanel.Children.Clear(); } return; } textOnAPath.UpdateText(); textOnAPath.Update(); }
static void OnScaleTextPathPropertyChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) { TextOnAPath textOnAPath = d as TextOnAPath; if (textOnAPath == null) { return; } if (e.NewValue == e.OldValue) { return; } bool value = (Boolean)e.NewValue; if (value == false && textOnAPath.TextPath != null) { textOnAPath.TextPath.Transform = null; } textOnAPath.UpdateSize(); textOnAPath.Update(); }