[]
        
(Showing Draft Content)

GrapeCity.ActiveReports.Chart.Drawing.Font

Font Class

An immutable, GDI-like description of a font face, size, style and unit of measure. Used throughout the chart to specify the typography of titles, labels and other text without depending directly on System.Drawing.Font.

Inheritance
Font
Implements
Namespace: GrapeCity.ActiveReports.Chart.Drawing
Assembly: MESCIUS.ActiveReports.Chart.dll
Syntax
[TypeConverter(typeof())]
public sealed class Font : IDisposable, ICloneable
Remarks

Instances are immutable: all characteristics are supplied at construction time and exposed as read-only properties. The type implements ICloneable and IDisposable for interface compatibility, but because instances hold no unmanaged resources Clone() returns the same instance and Dispose() performs no work.

Constructors

Name Description
Font(string, float)

Initializes a font with the given family name and em size, using a regular style measured in points.

Font(string, float, FontStyle)

Initializes a font with the given family name, em size and style, measured in points.

Font(string, float, FontStyle, GraphicsUnit)

Initializes a font with the given family name, em size, style and unit of measure.

Font(string, float, FontStyle, GraphicsUnit, byte, bool)

Initializes a font with full control over family name, size, style, unit and GDI character-set information.

Font(string, float, GraphicsUnit)

Initializes a font with the given family name and em size, expressed in the specified unit, using a regular style.

Properties

Name Description
Bold

Gets a value indicating whether the font's style includes Bold.

GdiCharSet

Gets the GDI character set used by this font, as defined by the Windows LOGFONT structure.

GdiVerticalFont

Gets a value indicating whether this font was derived from the vertical (top-to-bottom) variant of a GDI font.

Italic

Gets a value indicating whether the font's style includes Italic.

Name

Gets the name of the font family. This is the value typically edited in the designer.

OriginalFontName

Gets the font family name exactly as it was supplied when the font was created, before any substitution.

Size

Gets the em size of the font, expressed in the unit reported by Unit.

SizeInPoints

Gets the font size converted to points, regardless of the unit the font was created with.

Strikeout

Gets a value indicating whether the font's style includes Strikeout.

Style

Gets the combination of style flags (bold, italic, underline, strikeout) applied to the font.

Underline

Gets a value indicating whether the font's style includes Underline.

Unit

Gets the unit of measure in which Size is expressed.

Methods

Name Description
Clone()

Returns this font instance. Because Font is immutable, no copy is required and the same reference can be shared safely.

Dispose()

Releases the resources used by the font. This implementation is a no-op because the type holds no unmanaged resources; it exists only to satisfy IDisposable.

Equals(object)

Determines whether the specified object is a Font that describes the same family, size, style, unit and GDI character-set information as this instance.

GetHashCode()

Returns a hash code derived from the font's style, unit and size, consistent with Equals(object).

ToString()

Returns a human-readable description of the font, including its name, size, unit and GDI character-set information.