CListBoxData Class Reference

#include <mw/eiklbd.h>

Link against: mpxcommoncontainer.lib

class CListBoxData : public CBase

Inherits from

  • CListBoxData

    Detailed Description

    The CListBoxData class is the base class for list box data classes. It stores one or more instances of fonts in normal, bold and italic styles.

    Since
    ER5U

    Member Attribute Documentation

    iBoldFont

    CFontsWithStyleiBoldFont[protected]

    Bold style font

    iBoldItalicFont

    CFontsWithStyleiBoldItalicFont[protected]

    Font with normal and italic styles

    iItalicFont

    CFontsWithStyleiItalicFont[protected]

    Italic style font

    iNormalFont

    CFontsWithStyleiNormalFont[protected]

    Normal style font

    iSearchString

    HBufC *iSearchString[protected]

    String used in list box search field.

    Constructor & Destructor Documentation

    CListBoxData ( )

    IMPORT_CCListBoxData()

    C++ default constructor.

    ~CListBoxData ( )

    IMPORT_C~CListBoxData()

    Destructor

    Member Function Documentation

    Alignment ( )

    CGraphicsContext::TTextAlign Alignment()const [inline]

    Queries used text alignment.

    Returns: CGraphicsContext::TTextAlign The text alignment.

    ConstructFontL ( const CFont *, TFontStyle, CFontsWithStyle & )

    IMPORT_C voidConstructFontL(const CFont *aBaseFont,
    TFontStyleaFontStyle,
    CFontsWithStyle &aFonts
    )[protected]

    Constructs a new font based on the base font and font style given. Constructed font is added to CFontsWithStyle.

    ParameterDescription
    aBaseFontBase fontused in construction
    aFontStyleA new font's style
    aFontsNew font is added to this font container.

    ConstructL ( const CFont * )

    IMPORT_C voidConstructL(const CFont *aBaseFont)

    By default Symbian 2nd phase constructor is private. This one is public.

    ParameterDescription
    aBaseFontParameter not used in the code.

    DrawItem ( CWindowGc &, const TRect &, const TDesC &, const CFont &, const TInt, const CGraphicsContext::TTextAlign )

    IMPORT_C voidDrawItem(CWindowGc &aGc,
    const TRect &aItemTextRect,
    const TDesC &aItemText,
    const CFont &aItemFont,
    const TIntaBaseLineOffset,
    const CGraphicsContext::TTextAlignaAlign = CGraphicsContext::ELeft
    )const

    Draws list item text. Supports different drawing for the search string.

    ParameterDescription
    aGcGraphics context used.
    aItemTextRectThe item's text rectangle.
    aItemTextText of the item.
    aItemFontUsed font.
    aBaseLineOffsetItem's base line offset.
    aAlignText alignment. Default alignment is CGraphicsContext::ELeft

    Font ( const TListItemProperties & )

    IMPORT_C CFont *Font(const TListItemProperties &aItemProperties)const [virtual]

    Returns a pointer to the type of font wanted.

    ParameterDescription
    aItemPropertiesDefinition of font type wanted.

    Returns: CFont* Handle to the font or NULL.

    FontBoundValues ( )

    IMPORT_C const TListFontBoundValues &FontBoundValues()const

    Queries boundary values of font size.

    TListFontBoundValues& Reference to boundary value object.

    IsSearchString ( )

    IMPORT_C TBoolIsSearchString()const

    Query is search string set

    Returns: TBool ETrue if search string set and has non zero length. EFalse if no search string set or length is 0.

    NONSHARABLE_CLASS ( CFontsWithStyle )

    NONSHARABLE_CLASS(CFontsWithStyle)[protected, inline]

    RegenerateFonts ( CFontsWithStyle &, TInt )

    IMPORT_C TIntRegenerateFonts(CFontsWithStyle &aFonts,
    TIntaFontHeightInTwips
    )[protected]

    Changes fonts' height. Takes new height as argument and regenerates font set so that height is modified.

    ParameterDescription
    aFontsFont set to modify
    aFontHeightInTwipsNew font height

    SetAlignmentL ( CGraphicsContext::TTextAlign )

    voidSetAlignmentL(CGraphicsContext::TTextAlignaAlign)[inline]

    Sets list item's text alignment.

    ParameterDescription
    aAlignText alignment to use.

    SetFontHeight ( TInt )

    IMPORT_C TIntSetFontHeight(TIntaFontHeightInTwips)

    Sets a new height of fonts

    ParameterDescription
    aFontHeightInTwipsNew height for fonts.

    Returns: TInt Symbian error code, KErrNone if success.

    SetSearchStringL ( const TDesC * )

    IMPORT_C voidSetSearchStringL(const TDesC *aSearchString)

    Setter for a search string used for viewing search results

    ParameterDescription
    aSearchStringThe search string.

    SetSkinBackgroundControlContextL ( MAknsControlContext * )

    IMPORT_C voidSetSkinBackgroundControlContextL(MAknsControlContext *aContext)[protected]

    Sets a background skinning context. Set NULL to disable background skinning.

    Since
    Series 60 2.0
    ParameterDescription
    aContextBackground skinning context.

    SetSkinEnabledL ( TBool )

    IMPORT_C voidSetSkinEnabledL(TBoolaEnabled)[protected]

    Sets whether skins are enabled.

    ParameterDescription
    aEnabledEFalse disable skinning, ETrue enable

    SetupGc ( const TListItemProperties &, CWindowGc & )

    IMPORT_C voidSetupGc(const TListItemProperties &aItemProperties,
    CWindowGc &aGc
    )const

    Sets properties (underlining on / off, pen colorm and font) of graphical context.

    ParameterDescription
    aItemPropertiesContains properties to set.
    aGcTarget of settings.

    SkinBackgroundControlContext ( )

    IMPORT_C MAknsControlContext *SkinBackgroundControlContext()const

    Access to skin contexts from plain listboxes.

    Since
    Series 60 2.0

    Returns: MAknsControlContext* Used skin context

    UpdateFontBoundValues ( const CFont & )

    IMPORT_C voidUpdateFontBoundValues(const CFont &aFont)[protected]

    Updates width and heigh information. Used when font is changed.

    ParameterDescription
    aFontA font from which bound values are taken.