CCoeFontProvider Class Reference

#include <mw/coefontprovider.h>

class CCoeFontProvider : public CBase

Inherits from

  • CCoeFontProvider

    Detailed Description

    A helper object designed to make obtaining a font easier, taking into account zoom factors.

    Constructor & Destructor Documentation

    ~CCoeFontProvider ( )

    ~CCoeFontProvider()

    Member Function Documentation

    Font ( const TCoeFont &, const TZoomFactor & )

    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()

    ParameterDescription
    aFontThe requested logical font.
    aZoomFactorZoom factor used when deriving the font height.

    Returns: The closest matching available font.

    NewL ( )

    IMPORT_C CCoeFontProvider *NewL()[static]

    Standard Symbian factory method. Uses a default typeface

    NewL ( const TDesC & )

    IMPORT_C CCoeFontProvider *NewL(const TDesC &aTypefaceName)[static]

    Standard Symbian factory method. Typeface to use is provided by caller.

    ParameterDescription
    aTypefaceNameTypeface to use.

    RefetchPixelMappingL ( )

    voidRefetchPixelMappingL()

    flushes the array & refetches the logical-to-pixel mapping. Called when global control settings are updated

    SetTypeface ( const TTypeface )

    IMPORT_C voidSetTypeface(const TTypefaceaTypeface)

    Change the typeface

    ParameterDescription
    aTypefaceThe typeface to use

    Typeface ( )

    IMPORT_C TTypefaceTypeface()const

    Return the current typeface

    UseSystemTypeface ( )

    IMPORT_C voidUseSystemTypeface()

    Use the system typeface