#include <mw/coefontprovider.h>
class CCoeFontProvider : public CBase |
Public Member Functions | |
---|---|
~CCoeFontProvider() | |
IMPORT_C const CFont & | Font(const TCoeFont &, const TZoomFactor &) |
IMPORT_C CCoeFontProvider * | NewL() |
IMPORT_C CCoeFontProvider * | NewL(const TDesC &) |
void | RefetchPixelMappingL() |
IMPORT_C void | SetTypeface(const TTypeface) |
IMPORT_C TTypeface | Typeface() |
IMPORT_C void | UseSystemTypeface() |
A helper object designed to make obtaining a font easier, taking into account zoom factors.
IMPORT_C const CFont & | Font | ( | const TCoeFont & | aFont, |
const TZoomFactor & | aZoomFactor | |||
) | const |
Returns the closest available match to the specified logical font and zoom factor. Note that all CFont objects referenced through this method are owned by the font provider. Thus do not explicitly release the font object after use!
A default font provider is made available by the CCoeEnv singleton and returned from CCoeControl::FindFontProvider() if no overriding font provider has been attached to the control tree.
For an example of how to use this function, see CCoeControl::ScreenFont().
See also: CCoeControl::ScreenFont() CCoeControl::FindFontProvider() CCoeControl::AccumulatedZoom()
Parameter | Description |
---|---|
aFont | The requested logical font. |
aZoomFactor | Zoom factor used when deriving the font height. |
Returns: The closest matching available font.
IMPORT_C CCoeFontProvider * | NewL | ( | ) | [static] |
Standard Symbian factory method. Uses a default typeface
IMPORT_C CCoeFontProvider * | NewL | ( | const TDesC & | aTypefaceName | ) | [static] |
Standard Symbian factory method. Typeface to use is provided by caller.
Parameter | Description |
---|---|
aTypefaceName | Typeface to use. |
void | RefetchPixelMappingL | ( | ) |
flushes the array & refetches the logical-to-pixel mapping. Called when global control settings are updated
IMPORT_C void | SetTypeface | ( | const TTypeface | aTypeface | ) |
Change the typeface
Parameter | Description |
---|---|
aTypeface | The typeface to use |