New to Telerik UI for WinFormsStart a free 30-day trial

Represents a family of related fonts.

Definition

Namespace:Telerik.WinControls.Spreadsheet.UI

Assembly:Telerik.WinControls.RadSpreadsheet.dll

Syntax:

C#
[TypeConverter(typeof(FontFamilyConverter))]
public class FontFamily

Inheritance: objectFontFamily

Constructors

Initializes a new instance of an anonymous FontFamily class.

C#
public FontFamily()

Initializes a new instance of the FontFamily class from the specified font family name.

C#
public FontFamily(string familyName)
Parameters:familyNamestring

The family name or names that comprise the new FontFamily. Multiple family names should be separated by commas.

Exceptions:

ArgumentNullException

familyName cannot be null.

Properties

Gets the font family name that is used to construct the FontFamily object.

C#
public string Source { get; }
Property Value:

The font family name of the FontFamily object.

Methods

Gets a value that indicates whether the current font family object and the specified font family object are the same.

C#
public override bool Equals(object o)
Parameters:oobject

The FontFamily object to compare.

Returns:

bool

true if o is equal to the current FontFamily object; otherwise, false. If o is not a FontFamily object, false is returned.

Overrides: object.Equals(object)

Serves as a hash function for FontFamily. It is suitable for use in hashing algorithms and data structures such as a hash table.

C#
public override int GetHashCode()
Returns:

int

An int value that represents the hash code for the current object.

Overrides: object.GetHashCode()

C#
public override string ToString()
Returns:

string

Overrides: object.ToString()

Operators

C#
public static implicit operator FontFamily(FontFamily family)
Parameters:familyFontFamilyReturns:

FontFamily