API Reference
TextStyle
Defines fully resolved text styling shared by charts, topology, visual blocks, canvases, and image composition.
Inheritance
- Object
- TextStyle
Usage
Explore 16 API references to this type
This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.
Returned or exposed by 7
- Property LabelPlacementRequest.Style
- Property VisualFrame.LegendStyle
- Property VisualFrame.SubtitleStyle
- Property VisualFrame.TitleStyle
- Method TextStyle.Clone
- Method TextStyle.Create
- Method TextStyleOverride.Resolve
Accepted by parameters 9
- Method ImageComposition.DrawText
- Constructor LabelPlacementRequest.LabelPlacementRequest
- Method LabelPlacementService.Measure
- Constructor VisualFrame.VisualFrame
- Constructor VisualFrame.VisualFrame
- Constructor VisualFrame.VisualFrame
- Method TextLayoutEngine.Layout
- Method TextLayoutEngine.Measure
- Method TextStyleOverride.Resolve
Constructors
public TextStyle() #Methods
public static TextStyle Create(Double fontSize, ChartColor color) #TextStyleCreates a text style using the supplied size and color.
Parameters
- fontSize System.Double
- color ChartForgeX.Primitives.ChartColor
Inherited Methods
public virtual Boolean Equals(Object? obj) #BooleanParameters
- obj Object?
Properties
public FontSpec Font { get; set; } #Gets or sets the font selection.
public Double FontSize { get; set; } #Gets or sets the font size in logical pixels.
public ChartColor Color { get; set; } #Gets or sets the text color.
public TextAlignment Alignment { get; set; } #Gets or sets horizontal alignment inside the layout region.
public Double LineHeight { get; set; } #Gets or sets line height as a multiplier of the measured font height.
public Boolean Underline { get; set; } #Gets or sets a compatibility value that maps to a single solid underline.
public TextDecorationStyle UnderlineStyle { get; set; } #Gets or sets the underline pattern.
public Boolean Strikethrough { get; set; } #Gets or sets a compatibility value that maps to a single solid strikethrough.
public TextDecorationStyle StrikethroughStyle { get; set; } #Gets or sets the strikethrough pattern.
public TextBaseline Baseline { get; set; } #Gets or sets vertical baseline placement.
public TextCaseTransform TextCase { get; set; } #Gets or sets the display-time text-case transform.
public TextHinting Hinting { get; set; } #Gets or sets how raster output fits this text to the pixel grid. TextHinting.Auto (the default) snaps the baseline, x-height, and cap height of text at 12 output pixels and below to whole pixels without changing its width; TextHinting.None draws the outlines exactly. TextHinting.Full also fits and darkens narrow straight stems, retaining the same layout. SVG and HTML output leave hinting to the browser.
public String? OpenTypeLanguageTag { get; set; } #Gets or sets the OpenType language-system tag (for example, SRB or TRK). Null selects the font's default language system. Tags are case-sensitive and padded to four characters; an absent language in a font falls back to its default. This is not a culture name.
public Double EffectiveFontSize { get; } #Gets the font size used to measure and render this style.