API published in: S60 3rd Ed
Link against: fontutils.lib
Required Capabilities
None
#include <aknfontspecification.h>
It contains information from the layout specification that fonts bound to the given font id should honor.
It formst the basis of the request to font provisioning to provide a suitable font
Public Types |
|
enum | TAknFontSpecificationUnits { EPixels = 0, ETwips } |
Public Member Functions |
|
IMPORT_C | TAknFontSpecification (TInt aFontId) |
Construct font specification from Font ID. |
|
IMPORT_C | TAknFontSpecification (TAknFontCategory aCategory, const TFontSpec &aFontSpec, const MGraphicsDeviceMap *aDeviceMap) |
Construct the font specifiation from Symbian OS TFontSpec and MGraphicsDeviceMap The Symbian OS TFontSpec must be set in Twips.
|
|
IMPORT_C void | SetFontCategory (TAknFontCategory aCategory) |
Sets the Series 60 font category. |
|
IMPORT_C TAknFontCategory | FontCategory () const |
Series 60 Layout Specification font category: Primary, Secondary, Title etc. |
|
IMPORT_C void | SetTextPaneHeight (TInt aNewHeight) |
The requested height for a font. |
|
IMPORT_C TInt | TextPaneHeight () const |
The requested height of the font. |
|
IMPORT_C void | SetWeight (TFontStrokeWeight aWeight) |
Set the stoke weight to request using the Symbian OS stroke weight enumeration. |
|
IMPORT_C void | SetPosture (TFontPosture aPosture) |
Sets the posture (e.g. |
|
IMPORT_C void | SetTextPaneHeightIsDesignHeight (TBool aTextPaneHeightIsDesignHeight) |
Sets the policy to use in requesting the font height. |
|
IMPORT_C TBool | TextPaneIsDesignHeight () const |
Accessor API for the height policy. |
|
IMPORT_C void | SetExactMatchRequired (TBool aRequiresExactMatch) |
Sets a flag indicating to font requests whether they should insist upon an exact match. |
|
IMPORT_C TBool | ExactMatchRequired () const |
Accessor API for whether an exact match is required for the font (See SetExactMatchRequired() ). |
|
IMPORT_C void | SetUnits (TAknFontSpecification::TAknFontSpecificationUnits aUnits) |
Sets the units for the Text Pane Height APIs. |
|
IMPORT_C TAknFontSpecification::TAknFontSpecificationUnits | Units () const |
Accessor API for the units being used. |
|
IMPORT_C TFontStrokeWeight | Weight () const |
Accessor for the requested weight. |
|
IMPORT_C TFontPosture | Posture () const |
Accessor for the requested posture. |
|
|
Construct font specification from Font ID.
|
|
Construct the font specifiation from Symbian OS TFontSpec and MGraphicsDeviceMap The Symbian OS TFontSpec must be set in Twips. The MGraphicsDeviceMap is used to convert to pixels for the text pane height. Note that the units policy during and in effect at the end of this constructor is EPixels. Note that the TTypeface part of the TFontSpec is lost in this construction
|
|
Accessor API for whether an exact match is required for the font (See SetExactMatchRequired() ).
|
|
Series 60 Layout Specification font category: Primary, Secondary, Title etc.
|
|
Accessor for the requested posture.
|
|
Sets a flag indicating to font requests whether they should insist upon an exact match. Whether a font match is treated as exact or not depends upon various things, including:
The default value upon construction is EFalse;
|
|
Sets the Series 60 font category.
|
|
Sets the posture (e.g. upright, italic) of requested font using the Symbian OS enumeration.
|
|
The requested height for a font. This represents the maximum vertical range that can be guraranteed to draw in the text pane. Note also that this value is the height requested by layout or the client, and might not correspond to the design height, ascent + descent, or max height reported by the attached font. See the APIs CAknLayoutFont::TextPaneTopToBaseline and BaselineToTextPaneBottom. If TextPaneHeightIsDesignHeight() is EFalse, then the font will be requested to fit entirely within this range. If TextPaneHeightIsDesignHeight() is set, then this value is passed to the font request as the font design height, in which case the font may not render entirely within the "text pane height".
|
|
Sets the policy to use in requesting the font height. Fonts may be requested either by "design height" (which is usually approximately the ascent + descent) or by maximum height. If false, this setting means the number set by SetTextPaneHeight is intended to match the font's maximum extent; all characters will fit within the text pane. If true, then the value passed by SetTextPaneHeight will be used to request design height. This API has no effect if called on a TAknFontSpecification that has already been bound to a font The default value upon construction is EFalse.
|
|
Sets the units for the Text Pane Height APIs. Note that calling this API does not result in the numerical value of the text pane height being recalculated. Upon construction, TAknFontSpecification objects store TextPaneHeight in pixels. If you then call SetUnits to Twips, you will also have to call SetTextPaneHeight to pass in the new (twips) value.
|
|
Set the stoke weight to request using the Symbian OS stroke weight enumeration. aWeight The stroke weight. |
|
The requested height of the font. This represents the maximum vertical range that can be guaranteed to draw in the text pane. Note also that this value is the height requested by layout or the client, and may not correspond to the design height, ascent + descent, or max height reported by the attached font. See the APIs CAknLayoutFont::TextPaneTopToBaseline and BaselineToTextPaneBottom. If TextPaneHeightIsDesignHeight() is EFalse, then the font is to be requested to fit entirely within this range. If TextPaneHeightIsDesignHeight() is set, then this value is passed to the font request as the font design height, in which case the font may not render entirely within the "text pane height". Depending upon the value of TextPaneHeightIsInTwips(), the value returned is in Pixels or Twips. Note that calling SetTextPaneHeightIsInTwips() does not perform any conversion of the text pane height; It retains its set value.
|
|
Accessor API for the height policy.
|
|
Accessor API for the units being used.
|
|
Accessor for the requested weight.
|