ArcGIS Pro 3.8 API Reference Guide
ArcGIS.Desktop.Mapping Namespace / ISymbolFactory Interface / DefaultFont Property
Example

In This Topic
    DefaultFont Property (ISymbolFactory)
    In This Topic
    Gets the default font name and style name.
    Syntax
    ValueTuple<string,string> DefaultFont {get;}
    ReadOnly Property DefaultFont As ValueTuple(Of String,String)
    Example
    Get/Set Default Font
    {
      var def_font = SymbolFactory.Instance.DefaultFont;
      System.Diagnostics.Debug.WriteLine($"{def_font.fontName}, styles: {def_font.styleName}");
    
      //set default font - set through application options
      await QueuedTask.Run(() =>
      {
        ApplicationOptions.TextAndGraphicsElementsOptions.SetDefaultFont("tahoma");
        ApplicationOptions.TextAndGraphicsElementsOptions.SetDefaultFont("tahoma", "bold");
      });
    }
    Requirements

    Target Platforms: Windows 11 Home, Pro, Enterprise (64 bit)

    ArcGIS Pro version: 3.0 or higher.
    See Also