public static Typeface GetTypeface()
        {
            FontViewer fv = new FontViewer();

            if (fv.ShowDialog() == true)
            {
                return(new Typeface(fv.preview.FontFamily, fv.preview.FontStyle, fv.preview.FontWeight, fv.preview.FontStretch));
            }
            return(default);
        private void Ov_font_typeface_Click(object sender, RoutedEventArgs e)
        {
            Typeface tp = FontViewer.GetTypeface();

            if (tp == default)
            {
                return;
            }
            ov_title_typeface.Text =
                $"@Typeface: ({tp.FontFamily},{tp.Style},{tp.Weight},{tp.Stretch})";
            Typeface = tp;
            _dispatch.Stop();
            _dispatch.Start();
        }
Example #3
0
        private void Font_typeface_Click(object sender, RoutedEventArgs e)
        {
            var tp = FontViewer.GetTypeface();

            if (tp == default)
            {
                return;
            }

            Typeface            = tp;
            title_typeface.Text =
                $"@Typeface: ({Typeface.FontFamily},{Typeface.Style},{Typeface.Weight},{Typeface.Stretch})";


            _dispatcher.Stop();
            _dispatcher.Start();
        }