#include <mw/coetextdrawer.h>
class TCoeTextTypeAdaptor |
Public Member Functions | |
---|---|
TCoeTextTypeAdaptor(const TDesC &) | |
TCoeTextTypeAdaptor(const TBidiText &) | |
IMPORT_C TBool | HasRightToLeftDirectionality() |
IMPORT_C TPtrC | LineOfText(TInt, TInt &, const CFont &) |
IMPORT_C TInt | NumberOfLines() |
This class allows the XCoeTextDrawer to draw text that is in the form of a TBidiText object as well as pre-reordered new-line separated plain text descriptors. (The descriptor text is especially useful when using the XCoeTextDrawer together with the FORM component).
This removes the need to implement two versions of the DrawText() method.
IMPORT_C | TCoeTextTypeAdaptor | ( | const TDesC & | aText | ) |
Constructor taking a plain descriptor as parameter. The directionality of the text separated with '' must always be left-to-right display order.
Parameter | Description |
---|---|
aText | The text wrapped by the TCoeTextTypeAdaptor. |
IMPORT_C TBool | HasRightToLeftDirectionality | ( | ) | const |
This function checks the directionality of the text.
Returns: ETrue if the text has right-to-left directionality, EFalse if it has left-to-right directionality.
Extracts a line of text. The width (in pixels) of the line is returned in aWidthInPixels.
Parameter | Description |
---|---|
aLineNumber | Zero-based line number. |
aWidthInPixels | The width of the line of text. |
aFont | The font that will be used to draw the text. |
Returns: TPtrC line of text
IMPORT_C TInt | NumberOfLines | ( | ) | const |
Calculates the number of lines in the text.
Returns: TInt number of lines in the object