protected override void OnPropertyChanged(Helios.ComponentModel.PropertyNotificationEventArgs args) { if (args.PropertyName.Equals("Visual")) { _textDisplay = args.NewValue as TextDisplay; } base.OnPropertyChanged(args); }
private void TurnTextDisplayOff(object sender, RoutedEventArgs e) { TextDisplay textDisplay = Control as TextDisplay; if (textDisplay != null) { textDisplay.TextValue = "0"; } }
private void HeliosTestTextBox_TextChanged(object sender, TextChangedEventArgs e) { HeliosTextBox textBox = sender as HeliosTextBox; TextDisplay textDisplay = Control as TextDisplay; if (textDisplay != null) { textDisplay.TextValue = textBox.Text; } }
private void BottomPaddingChanged(object sender, RoutedPropertyChangedEventArgs <double> e) { Slider slider = sender as Slider; if (!System.Windows.Input.Keyboard.Modifiers.HasFlag(ModifierKeys.Shift) && slider != null && slider.IsFocused) { TextDisplay textDisplay = Control as TextDisplay; if (textDisplay != null) { textDisplay.TextFormat.PaddingTop = textDisplay.TextFormat.PaddingBottom; } } }