TFontSpec Class Reference
Specifies the font specification in device independent terms.
Constructor & Destructor Documentation
TFontSpec()
Default constructor.
The object's font style is set to the default: EPostureUpright, EStrokeWeightNormal, and EPrintPosNormal.
TFontSpec(const TDesC &, TInt)
IMPORT_C | TFontSpec | ( | const TDesC & | aTypefaceName, |
| TInt | aHeight |
| ) | |
Constructs a TFontSpec object with the specified typeface and height.
The object's font style is set to the default: EPostureUpright, EStrokeWeightNormal, and EPrintPosNormal.
-
panic
- GDI 6, if aTypefaceName is more than KMaxTypefaceNameLength characters long.
Parameters
const TDesC & aTypefaceName | The name of the typeface (e.g. "Roman"). It should be no longer than KMaxTypefaceNameLength characters in length. |
TInt aHeight | The height of the typeface, in twips. |
Member Functions Documentation
ExternalizeL(RWriteStream &)
Externalises the font specification to a write stream.
The presence of this function means that the standard templated operator<<() (defined in s32strm.h) is available to externalise objects of this class.
-
leave
- KErrNoMemory If the write action causes the stream's resources to be exhausted.
Parameters
RWriteStream & aStream | The stream to which the font specification is to be externalised |
InternalizeL(RReadStream &)
Internalises a font specification from a read stream.
The presence of this function means that the standard templated operator>>() (defined in s32strm.h) is available to internalise objects of this class.
-
leave
- KErrNoMemory If internalisation causes an out of memory error.
Parameters
RReadStream & aStream | The stream from which the font specification is to be internalised. |
ScriptTypeForMetrics()
IMPORT_C TInt | ScriptTypeForMetrics | ( | ) | const |
Returns the script with which font metrics calculation will be based on.
SetScriptTypeForMetrics(TLanguage)
IMPORT_C void | SetScriptTypeForMetrics | ( | TLanguage | aLanguage | ) | |
Specifies the script with which font metrics calculation will be based on.
Parameters
TLanguage aLanguage | The language used to derive the required script. |
operator==(const TFontSpec &)
Compares this font specification with another.
Parameters
const TFontSpec & aFontSpec | The font specification to be compared with this one. |
Member Data Documentation
TFontStyle
iFontStyle
The font style of the typeface.
TInt
iHeight
The height of the typeface (in twips).
Copyright ©2010 Nokia Corporation and/or its subsidiary(-ies).
All rights
reserved. Unless otherwise stated, these materials are provided under the terms of the Eclipse Public License
v1.0.