class TDrawTextLayoutContext |
Parameters used by functions that draw text.
An object of this class is passed to CTextLayout::DrawL() and to InvertRangeL(). The draw context includes the view rectangle, the graphics context, the background colour and the margin widths.
You only need to use this class directly when you are using a CTextLayout object which is not owned by a CTextView object.
Private Member Enumerations | |
---|---|
enum | TDrawMode { EFDrawText = 0x001, EFDrawGraphics = 0x002, EFUseClippingRect = 0x004, EFUseWindowGc = 0x008, EFUseGcClear = 0x020, EFUseBackgroundColor = 0x040, EFUseOverrideTextColor = 0x080, EFParagraphFillTextOnly = 0x100, EFAllFlags = 0xfff } |
Public Attributes | |
---|---|
TLogicalRgb | iBackgroundColor |
TInt | iGutterMarginWidth |
TInt | iLabelMarginWidth |
TInt | iTextStartX |
TRect | iViewRect |
Private Attributes | |
---|---|
TUint | iDrawMode |
CGraphicsContext * | iGc |
TLogicalRgb | iOverrideTextColor |
CGraphicsContext * | iPictureGc |
IMPORT_C void | SetBitmapGc | ( | CBitmapContext * | aGc, |
CBitmapContext * | aPictureGc = NULL | |||
) |
CBitmapContext * aGc | |
CBitmapContext * aPictureGc = NULL |
IMPORT_C void | SetDrawToEveryPixel | ( | TBool | aDrawToEveryPixel | ) |
TBool aDrawToEveryPixel |
IMPORT_C void | SetGc | ( | CGraphicsContext * | aGc, |
CGraphicsContext * | aPictureGc = NULL | |||
) |
CGraphicsContext * aGc | |
CGraphicsContext * aPictureGc = NULL |
IMPORT_C void | SetParagraphFillTextOnly | ( | TBool | aFillTextOnly | ) |
TBool aFillTextOnly |
IMPORT_C void | SetTextColorOverride | ( | const TRgb * | aOverrideColor | ) |
const TRgb * aOverrideColor |
IMPORT_C void | SetWindowGc | ( | CWindowGc * | aGc, |
CWindowGc * | aPictureGc = NULL | |||
) |
IMPORT_C void | TextToWindow | ( | TPoint & | aTextAreaPos | ) | const |
TPoint & aTextAreaPos |
EFDrawText = 0x001 | |
EFDrawGraphics = 0x002 | |
EFUseClippingRect = 0x004 | |
EFUseWindowGc = 0x008 | |
EFUseGcClear = 0x020 | |
EFUseBackgroundColor = 0x040 | |
EFUseOverrideTextColor = 0x080 | |
EFParagraphFillTextOnly = 0x100 | |
EFAllFlags = 0xfff |
TLogicalRgb | iBackgroundColor |
The background colour for the view rectangle. The background colour is used to fill the parts of the view rectangle in which text cannot appear, for example, below the last line of the document and in the label, line cursor and left text margins.
TInt | iGutterMarginWidth |
The gutter margin width (also known as the line cursor margin width). By default zero.
TInt | iLabelMarginWidth |
The label margin width. By default zero. Must have the same value as the label margin width as set in the text layout object.
TInt | iTextStartX |
The horizontal offset between window coordinates and text layout coordinates.
TRect | iViewRect |
The view rectangle (specified in window coordinates). This is used to set the area in which text can be drawn. Text can only be drawn within the intersection between the text area and the aDrawRect parameter passed to CTextLayout::DrawL() or InvertRangeL().