Class FontClient
Definition
- Namespace:
- Tizen.NUI
- Assembly:
- Tizen.NUI.dll
- API Level:
- 5
FontClient provides access to font information and resources.
public class FontClient : BaseHandle, INotifyPropertyChanged, IDynamicResourceHandler, IElement, INameScope, IElementController, IDisposable
- Inheritance
- Implements
Properties
View SourceInstance
Gets the singleton pattern of the FontClient object.
Declaration
public static FontClient Instance { get; }
Property Value
Type | Description |
---|---|
FontClient |
API Level: 5
Methods
View SourceAddCustomFontDirectory(String)
Adds custom fonts directory.
Declaration
public bool AddCustomFontDirectory(string path)
Parameters
Type | Name | Description |
---|---|---|
String | path | Path to the fonts directory. |
Returns
Type | Description |
---|---|
Boolean | True if the fonts can be added. |
API Level: 5
View SourceFindDefaultFont(UInt32)
Find the default font for displaying a UTF-32 character.
Declaration
public uint FindDefaultFont(uint charcode)
Parameters
Type | Name | Description |
---|---|---|
UInt32 | charcode | The character for which a font is needed. |
Returns
Type | Description |
---|---|
UInt32 | A valid font identifier. Zero if the font does not exist. |
API Level: 5
View SourceFindDefaultFont(UInt32, UInt32)
Find the default font for displaying a UTF-32 character.
Declaration
public uint FindDefaultFont(uint charcode, uint requestedPointSize)
Parameters
Type | Name | Description |
---|---|---|
UInt32 | charcode | The character for which a font is needed. |
UInt32 | requestedPointSize | The point size in 26.6 fractional points. The default point size is 12*64. |
Returns
Type | Description |
---|---|
UInt32 | A valid font identifier. Zero if the font does not exist. |
API Level: 5
View SourceFindDefaultFont(UInt32, UInt32, Boolean)
Finds the default font for displaying a UTF-32 character.
Declaration
public uint FindDefaultFont(uint charcode, uint requestedPointSize, bool preferColor)
Parameters
Type | Name | Description |
---|---|---|
UInt32 | charcode | The character for which a font is needed. |
UInt32 | requestedPointSize | The point size in 26.6 fractional points. The default point size is 12*64. |
Boolean | preferColor | True if a color font is preferred. |
Returns
Type | Description |
---|---|
UInt32 | A valid font identifier. Zero if the font does not exist. |
API Level: 5
View SourceGetFontId(String)
Retrieve the unique identifier for a font.
Declaration
public uint GetFontId(string path)
Parameters
Type | Name | Description |
---|---|---|
String | path | The path to a font file. |
Returns
Type | Description |
---|---|
UInt32 | A valid font identifier. Zero if the font does not exist. |
API Level: 5
View SourceGetFontId(String, UInt32)
Retrieve the unique identifier for a font.
Declaration
public uint GetFontId(string path, uint requestedPointSize)
Parameters
Type | Name | Description |
---|---|---|
String | path | The path to a font file. |
UInt32 | requestedPointSize | The point size in 26.6 fractional points. The default point size is 12*64. |
Returns
Type | Description |
---|---|
UInt32 | A valid font identifier. Zero if the font does not exist. |
API Level: 5
View SourceGetFontId(String, UInt32, UInt32)
Retrieve the unique identifier for a font.
Declaration
public uint GetFontId(string path, uint requestedPointSize, uint faceIndex)
Parameters
Type | Name | Description |
---|---|---|
String | path | The path to a font file. |
UInt32 | requestedPointSize | The point size in 26.6 fractional points. The default point size is 12*64. |
UInt32 | faceIndex | The index of the font face. |
Returns
Type | Description |
---|---|
UInt32 | A valid font identifier. Zero if the font does not exist. |
API Level: 5
View SourceGetPointSize(UInt32)
Retrieves the font point size of a given font id.
Declaration
public uint GetPointSize(uint id)
Parameters
Type | Name | Description |
---|---|---|
UInt32 | id | The font identifier. |
Returns
Type | Description |
---|---|
UInt32 | The point size in 26.6 fractional points. |
API Level: 5
View SourceIsCharacterSupportedByFont(UInt32, UInt32)
Whether the given character is supported by the font.
Declaration
public bool IsCharacterSupportedByFont(uint fontId, uint character)
Parameters
Type | Name | Description |
---|---|---|
UInt32 | fontId | The id of the font. |
UInt32 | character | The character in a font. |
Returns
Type | Description |
---|---|
Boolean | True if the character is supported by the font. |
API Level: 5
View SourceIsScalable(String)
Check to see if a font is scalable.
Declaration
public bool IsScalable(string path)
Parameters
Type | Name | Description |
---|---|---|
String | path | The path where the font file is located. |
Returns
Type | Description |
---|---|
Boolean | True if scalable. |
API Level: 5
View SourceResetSystemDefaults()
Called when the user changes the system defaults.
Declaration
public void ResetSystemDefaults()