UIFont Class Reference

Font class used by UI. More...

List of all members.

Public Member Functions

 UIFont ()
 UIFont constructor (created from default UI value)
 UIFont (string filename, int size, FontStyle style)
 UIFont constructor (from filename, size, and style)
 UIFont (FontAlias alias, int size, FontStyle style)
 UIFont constructor (from separate name, size, and style)
Font GetFont ()
 Obtains Core.Imaging.Font class from UIFont.
override int GetHashCode ()
 Returns a hash code.
override bool Equals (object obj)
 Whether the target and self are equivalent.
bool Equals (UIFont uifont)
 Whether the target and self are equivalent.
override string ToString ()
 Returns a character string.

Static Public Member Functions

static void ClearCache ()
 Frees all cached objects of Core.Imaging.Font class.

Properties

string FileName [get, set]
 Font filename.
FontAlias AliasName [get, set]
 Font separate name.
int Size [get, set]
 Font size.
FontStyle Style [get, set]
 Font style.

Detailed Description

Font class used by UI.

Generates and caches an object of Core.Imaging.Font class in the system. When the pixel density is set in UISystem, the font size is also scaled according to the pixel density.


Constructor & Destructor Documentation

UIFont ( string  filename,
int  size,
FontStyle  style 
)

UIFont constructor (from filename, size, and style)

Parameters:
filenameFont filename
sizeSize
styleStyle
Exceptions:
ArgumentOutOfRangeExceptionsize is outside the range of 1 to 1024.

The argument size must be between 1 and 1024. Also, depending on the font, the font may not be generated because its size is too small.

UIFont ( FontAlias  alias,
int  size,
FontStyle  style 
)

UIFont constructor (from separate name, size, and style)

Parameters:
aliasFont separate name
sizeSize
styleStyle
Exceptions:
ArgumentOutOfRangeExceptionsize is outside the range of 1 to 1024.

The argument size must be between 1 and 1024. Also, depending on the font, the font may not be generated because its size is too small.


Member Function Documentation

override bool Equals ( object  obj)

Whether the target and self are equivalent.

Parameters:
objComparison target
Returns:
Comparison result
bool Equals ( UIFont  uifont)

Whether the target and self are equivalent.

Parameters:
uifontComparison target
Returns:
Comparison result
Font GetFont ( )

Obtains Core.Imaging.Font class from UIFont.

Returns ShallowClone of cached Core.Imaging.Font.

Returns:
Font object
override int GetHashCode ( )

Returns a hash code.

Returns:
Hash code
override string ToString ( )

Returns a character string.

Returns:
Character string of "font name, font style, font size" format

Property Documentation

FontAlias AliasName [get, set]

Font separate name.

This value is used only when FileName is null.

string FileName [get, set]

Font filename.

When null is set, the AliasName value is used. The evaluation of whether the font file is correct is performed when first rendered.

int Size [get, set]

Font size.

The argument size must be between 1 and 1024. Also, depending on the font, the font may not be generated because its size is too small.

Exceptions:
ArgumentOutOfRangeExceptionsize is outside the range of 1 to 1024.