private void FontSelectorTitleSelectionChanged(object sender, SelectionChangedEventArgs e) { _fontFamilyTitle = (FontFamily)FontSelectorTitle.SelectedValue; TextBlockExampleTitle.FontFamily = _fontFamilyTitle; Properties.Settings.Default.Plot_Font_Name_Title = _fontFamilyTitle.Source; GraphUc.UpdateStyles(); }
private void CheckBoxKeyTransparentUnchecked(object sender, RoutedEventArgs e) { if (!_init) { return; } Properties.Settings.Default.Plot_BG_Key_Transparent = false; GraphUc.UpdateStyles(); }
private void SliderFontSizeTitleValueChanged(object sender, RoutedPropertyChangedEventArgs <double> e) { if (!_init || e.NewValue < 5) { return; } TextBlockExampleTitle.FontSize = e.NewValue; Properties.Settings.Default.Plot_Font_Size_Title = e.NewValue.ToString(CultureInfo.InvariantCulture); GraphUc.UpdateStyles(); }
private void LabelKeyBgMouseUp(object sender, MouseButtonEventArgs e) { using (var cd = new System.Windows.Forms.ColorDialog()) { cd.AllowFullOpen = true; if (cd.ShowDialog() == System.Windows.Forms.DialogResult.OK) { _bgBrushKey = new SolidColorBrush(System.Windows.Media.Color.FromRgb(cd.Color.R, cd.Color.G, cd.Color.B)); Properties.Settings.Default.Plot_BG_Key = System.Drawing.Color.FromArgb(cd.Color.R, cd.Color.G, cd.Color.B); LabelKeyBg.Background = _bgBrushKey; GraphUc.UpdateStyles(); } } }
private void LabelFgColorTitleMouseUp(object sender, MouseButtonEventArgs e) { using (var cd = new System.Windows.Forms.ColorDialog()) { cd.AllowFullOpen = true; if (cd.ShowDialog() == System.Windows.Forms.DialogResult.OK) { _fgBrushTitle = new SolidColorBrush(System.Windows.Media.Color.FromRgb(cd.Color.R, cd.Color.G, cd.Color.B)); Properties.Settings.Default.Plot_FG_Color_Title = System.Drawing.Color.FromArgb(cd.Color.R, cd.Color.G, cd.Color.B); LabelFgColorTitle.Background = _fgBrushTitle; TextBlockExampleTitle.Foreground = _fgBrushTitle; GraphUc.UpdateStyles(); } } }
private void ComboBoxStyleTitleSelectionChanged(object sender, SelectionChangedEventArgs e) { if (ComboBoxStyleTitle.SelectedValue == null) { return; } var fontStyle = (string)ComboBoxStyleTitle.SelectedValue; var fsc = new FontStyleConverter(); PlotFontStyleTitle = (FontStyle)fsc.ConvertFromString(fontStyle); TextBlockExampleTitle.FontStyle = PlotFontStyleTitle; Properties.Settings.Default.Plot_Font_Style_Title = fontStyle; GraphUc.UpdateStyles(); }
private void ComboBoxWeightSelectionChanged(object sender, SelectionChangedEventArgs e) { if (ComboBoxWeight.SelectedValue == null) { return; } var fontWeight = (string)ComboBoxWeight.SelectedValue; var fwc = new FontWeightConverter(); PlotFontWeight = (FontWeight)fwc.ConvertFromString(fontWeight); TextBlockExample.FontWeight = PlotFontWeight; Properties.Settings.Default.Plot_Font_Weight = fontWeight; GraphUc.UpdateStyles(); }
private void TextBoxTertiaryThicknessTextChanged(object sender, TextChangedEventArgs e) { if (!_init) { return; } try { var d = double.Parse(TextBoxTertiaryThickness.Text); Properties.Settings.Default.Plot_Tertiary_Thickness = d; GraphUc.UpdateStyles(); } catch { } }
private void WindowLoaded(object sender, RoutedEventArgs e) { if (RestartConfig) { TabControl1.SelectedIndex = RestartTab; } RestartConfig = false; RestartTab = 0; InitText(); InitTextTitle(); InitGraphColors(); InitSeriesStyles(); InitGraphData(); GraphUc.UpdateStyles(); InitUiControls(); _init = true; }