CFsAlfTextStyleManager Class Reference
class CFsAlfTextStyleManager : private CBase
|
CFsAlfTextStyleManager
This class is designed to convert
CRichText
style definitions to TAlfTextStyles. To avoid overlapping style definitions, all previously created styles are stored in a list.
Example:
manager = CFsTextStyleManager::NewL( Env().TextStyleManager() );
rText.GetChars( someText, charFormat, position ); //CRichText
TInt styleID = manager->GetStyleIDL( charFormat );
visual = CAlfTextVisual::AddNewL( *iControl, iCurveLayout );
visual->SetTextStyle( styleID );
Constructor & Destructor Documentation
CFsAlfTextStyleManager(CAlfTextStyleManager &)
CFsAlfTextStyleManager
|
(
|
CAlfTextStyleManager &
|
aAlfTextStyleManager
|
)
|
[private]
|
Parameters
CAlfTextStyleManager & aAlfTextStyleManager
|
|
~CFsAlfTextStyleManager()
~CFsAlfTextStyleManager
|
(
|
)
|
|
Member Functions Documentation
CreateNewTextStyleL(const TCharFormat &)
CreateNewTextStyleL
Creates a new text style using
TCharFormat
.
Parameters
const
TCharFormat
& aCharFormat
|
Style format from CRichText
|
FindId(const TCharFormat &)
FindId
The array of previously created styles is searched for matching
TCharFormat
. If not found KErrNotFound is returned.
Parameters
const
TCharFormat
& aCharFormat
|
Style format from CRichText
|
FindPositionOfId(TInt)
TInt
|
FindPositionOfId
|
(
|
TInt
|
aId
|
)
|
[private]
|
FindPositionOfId
The array of previously created styles is searched for matching ID. If not found KErrNotFound is returned.
GetStyleIDL(const TCharFormat &)
GetStyleIDL
This is the only public method in
CFsAlfTextStyleManager
. If there already a style that matches the given
TCharFormat
, the ID of this style is returned. If not, a new style is created.
Parameters
const
TCharFormat
& aCharFormat
|
Style format from CRichText
|
GetStyleIDWithOpositeUnderlineL(TInt)
TInt
|
GetStyleIDWithOpositeUnderlineL
|
(
|
TInt
|
aId
|
)
|
|
FindId
The array of previously created styles is searched for matching
TCharFormat
. If not found KErrNotFound is returned.
NewL(CAlfTextStyleManager &)
Parameters
CAlfTextStyleManager & aAlfTextStyleManager
|
Reference to the CAlfTextStyleManager
|
Member Data Documentation
CAlfTextStyleManager & iAlfTextStyleManager
CAlfTextStyleManager &
|
iAlfTextStyleManager
|
[private]
|
Reference to the CAlfTextStyleManager
RArray< TFsTextStyleData > iStyles
Array of previously created styles
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.