Table of Contents

Class UniversalFont

Namespace
Utils.Common
Assembly
Utils.Common.dll

The cross-platform replacement of System.Drawing.Font in ATAS X builds: an immutable description of a font (family name, size, style, unit) that owns no native resources and needs no disposal. Indicators built for ATAS X use it in place of Font, and the font references of indicators compiled for the classic platform are retargeted to it when they are loaded on ATAS X. The classic platform build uses System.Drawing.Font instead. The family name is not checked against the installed fonts.

Added in ATAS 8.0.15.

public sealed class UniversalFont
Inheritance
object
UniversalFont
Extension Methods

Constructors

UniversalFont(string, float, FontStyle)

Creates a font with the size in points.

public UniversalFont(string fontFamily, float size, FontStyle style)

Parameters

fontFamily string

The name of the font family.

size float

The em-size, in points.

style FontStyle

The style of the font.

UniversalFont(string, float, FontStyle, GraphicsUnit)

Creates a font with the size in the given unit.

public UniversalFont(string fontFamily, float size, FontStyle style, GraphicsUnit unit)

Parameters

fontFamily string

The name of the font family.

size float

The em-size, in unit units.

style FontStyle

The style of the font.

unit GraphicsUnit

The unit of size.

UniversalFont(string, float, FontStyle, GraphicsUnit, byte)

Creates a font with the size in the given unit and the given GDI character set.

public UniversalFont(string fontFamily, float size, FontStyle style, GraphicsUnit unit, byte gdiCharSet)

Parameters

fontFamily string

The name of the font family.

size float

The em-size, in unit units.

style FontStyle

The style of the font.

unit GraphicsUnit

The unit of size.

gdiCharSet byte

The GDI character set.

UniversalFont(UniversalFontFamily, float, FontStyle, GraphicsUnit, byte)

Creates a font of the given family with the size in the given unit and the given GDI character set.

public UniversalFont(UniversalFontFamily fontFamily, float size, FontStyle style, GraphicsUnit unit, byte gdiCharSet)

Parameters

fontFamily UniversalFontFamily

The font family.

size float

The em-size, in unit units.

style FontStyle

The style of the font.

unit GraphicsUnit

The unit of size.

gdiCharSet byte

The GDI character set.

Properties

FontFamily

The font family.

public UniversalFontFamily FontFamily { get; }

Property Value

UniversalFontFamily

GdiCharSet

The GDI character set passed to the chart renderer; 0 for the constructors that do not take it.

public byte GdiCharSet { get; }

Property Value

byte

Size

The em-size of the font, in Unit units.

public float Size { get; }

Property Value

float

Style

The style of the font: bold, italic, underline, strikeout or a combination.

public FontStyle Style { get; }

Property Value

FontStyle

Unit

The unit of Size; System.Drawing.GraphicsUnit.Point for the constructors that do not take it.

public GraphicsUnit Unit { get; }

Property Value

GraphicsUnit