TCursorPosition Class Reference
Cursor position.
The TMovementType enum defined in this class is used to indicate the direction of a scroll or cursor movement. The remainder of this class does not form part of the API.
Public Member Functions |
---|
| TCursorPosition() |
void | CancelHighlight() |
TTmPosInfo2 & | ChoosePosition(TTmPosInfo2 &, TTmPosInfo2 &) |
TInt
| DocPos() |
void | DontDrawOldPictureFrame() |
TBool
| DrawHighlight() |
TBool
| DrawNewPictureFrame() |
TBool
| DrawOldPictureFrame() |
TBool
| GetCursor(TTmCursorPlacement, TPoint &, TInt &, TInt &, TInt &) |
void | GetOldSelection(TCursorSelection &) |
void | GetSelection(TCursorSelection &) |
TBool
| IsNewPictureFrame() |
TBool
| IsPictureFrame() |
TBool
| IsSelection() |
TBool
| IsSelectionToDraw() |
TInt
| MoveL(TBool, TMovementType &, TBool) |
TPosHint
| PositioningHint() |
void | SetDocPos(const TTmDocPos &) |
TInt
| SetDocPosL(TBool, const TTmDocPos &) |
void | SetLayout(CTextLayout *) |
void | SetPendingSelection(const TCursorSelection &) |
void | SetPositioningHint(TPosHint) |
TInt
| SetSelectionL(const TCursorSelection &) |
void | SetToCurrentHighlight() |
void | SetToPreviousHighlight() |
TInt
| SetXyPosL(TBool, TPoint, TBool) |
void | TextMoveVertically() |
const TTmDocPos & | TmDocPos() |
void | UpdateLatentPosition() |
void | UpdateLatentX(TInt) |
const TTmDocPos & | VisualEndOfRunL(const TTmDocPos &, const TTmDocPos &, TVisualEnd) |
Public Member Enumerations |
---|
enum | TMovementType { EFNoMovement, EFLeft, EFRight, EFLineUp, EFLineDown, EFPageUp, EFPageDown, EFLineBeg, EFLineEnd } |
enum | TPosHint { EPosHintUndefined = 0, EInsertStrongL2R = 1, EInsertStrongR2L = 2, EPosHintLast } |
enum | TVisualEnd { EVisualLeft, EVisualRight } |
Constructor & Destructor Documentation
TCursorPosition()
TCursorPosition | ( | ) | [inline] |
Constructs the TCursorPosition object, initializing its members iAnchor, iOldDocPos, iOldAnchor, iFlags, iLatentX, iLatentY to zero, iLayout to NULL, and iPositioningHint to undefined.
Member Functions Documentation
CalculateCursorPos(TPoint &)
TBool
| CalculateCursorPos | ( | TPoint & | aCurPos | ) | [private, inline] |
Caculate x-y position of the cursor If ETrue is returned, places the position of the intersection of the character edge with the baseline in aPos
Parameters
TPoint & aCurPos | On return, stores the position of the intersection of the character edge with the baseline |
CancelHighlight()
void | CancelHighlight | ( | ) | [inline] |
Removes the selection, and redraws the affected part of the screen.
CheckCursorOnScreenL(TInt &)
TInt
| CheckCursorOnScreenL | ( | TInt & | aY | ) | [private] |
CheckNullSelection()
void | CheckNullSelection | ( | ) | [private] |
CheckSelection(TBool)
void | CheckSelection | ( | TBool | aSelect | ) | [private] |
ChoosePosition(TTmPosInfo2 &, TTmPosInfo2 &)
DoSetDocPosL(const TTmDocPos &)
DoSetVisibleDocPosL(const TTmDocPos &)
DoSetXyPos(TPoint &)
void | DoSetXyPos | ( | TPoint & | aXy | ) | [private] |
DocPos()
TInt
| DocPos | ( | ) | const [inline] |
Gets the edge position in the document.
DontDrawOldPictureFrame()
void | DontDrawOldPictureFrame | ( | ) | [inline] |
Sets to not draw the previous picture frame
DrawHighlight()
TBool
| DrawHighlight | ( | ) | const [inline] |
Tests whether the highlighted region needs to be drawn. The function will be called by CTextView::UpdateHighlightL() to correct the highlight after a cursor movement
DrawNewPictureFrame()
TBool
| DrawNewPictureFrame | ( | ) | const [inline] |
Tests whether there is a new picture frame that needs to be drawn. The function will be called by CTextView::UpdateHighlightL() to correct the highlight after a cursor movement
DrawOldPictureFrame()
TBool
| DrawOldPictureFrame | ( | ) | const [inline] |
Tests whether there is a previous picture frame that needs to be drawn. The function will be called by CTextView::UpdateHighlightL() to correct the highlight after a cursor movement
GetCursor(TTmCursorPlacement, TPoint &, TInt &, TInt &, TInt &)
GetOldSelection(TCursorSelection &)
GetSelection(TCursorSelection &)
IsNewPictureFrame()
TBool
| IsNewPictureFrame | ( | ) | const |
IsPictureFrame()
TBool
| IsPictureFrame | ( | ) | const |
IsSelection()
TBool
| IsSelection | ( | ) | const [inline] |
Tests whether there is currently a selected region.
IsSelectionToDraw()
TBool
| IsSelectionToDraw | ( | ) | const [inline] |
Tests whether there is currently a highlighted region being drawn.
LeftRightL(TTmPosInfo2 &, TTmLineInfo &, TMovementType &)
MoveL(TBool, TMovementType &, TBool)
PageScrollL(TMovementType &)
PositioningHint()
TPosHint
| PositioningHint | ( | ) | const [inline] |
SetDocPos(const TTmDocPos &)
void | SetDocPos | ( | const TTmDocPos & | aDocPos | ) | [inline] |
Sets the document position, the structure for holding a raw document position that can be converted to or from an x-y position and compared ordinally, which cannot be done with the more abstract TTmDocPosSpec class.
Parameters
const TTmDocPos & aDocPos | the document position |
SetDocPosL(TBool, const TTmDocPos &)
SetPendingSelection(const TCursorSelection &)
SetPictureFrame(const TTmDocPos &, TInt, const TRect &)
void | SetPictureFrame | ( | const TTmDocPos & | aDocPos, |
| TInt | aAnchor, |
| const TRect & | aPictureRect |
| ) | [private] |
SetPositioningHint(TPosHint)
void | SetPositioningHint | ( | TPosHint | aHint | ) | [inline] |
SetSelectionL(const TCursorSelection &)
SetToCurrentHighlight()
void | SetToCurrentHighlight | ( | ) | [inline] |
SetToPreviousHighlight()
void | SetToPreviousHighlight | ( | ) | [inline] |
SetXyPosL(TBool, TPoint, TBool)
StartEnd(TTmPosInfo2 &, TTmLineInfo &, TMovementType &)
TmDocPos()
Gets the document position, the structure for holding a raw document position that can be converted to or from an x-y position and compared ordinally, which cannot be done with the more abstract TTmDocPosSpec class.
UpDownL(TTmPosInfo2 &, TTmLineInfo &, TMovementType &)
UpdateLatentPosition()
void | UpdateLatentPosition | ( | ) | |
UpdateLatentX(TInt)
void | UpdateLatentX | ( | TInt | aX | ) | [inline] |
Sets the latent horizontal text cursor position. This is the horizontal coordinate to which the text cursor will be moved.
Parameters
TInt aX | The horizontal coordinate to which the text cursor should be moved |
UpdateLatentY(TInt)
void | UpdateLatentY | ( | TInt | aY | ) | [private, inline] |
Sets the latent vertical text cursor position. This is the vertical coordinate to which the text cursor will be moved.
Parameters
TInt aY | The vertical coordinate to which the text cursor should be moved |
ViewTopOfLineL(const TTmDocPos &, TInt &)
VisualEndOfRunL(const TTmDocPos &, const TTmDocPos &, TVisualEnd)
Member Enumerations Documentation
Enum anonymous
Enumerators
EFAbove = -1 | |
EFInside = 0 | |
EFBelow = 1 | |
Enum anonymous
Enumerators
EDrawHighlight = 1 | |
EDrawOldPictureFrame = 2 | |
EDrawNewPictureFrame = 4 | |
EReturnPreviousHighlight = 8 | |
ESelected = 16 | |
Enum TMovementType
Direction of cursor movement.
Enumerators
EFNoMovement |
No cursor movement
|
EFLeft |
Single character cursor movement to the left
|
EFRight |
Single character cursor movement to the right
|
EFLineUp |
Line up cursor movement
|
EFLineDown |
Line down cursor movement
|
EFPageUp |
Page up cursor movement
|
EFPageDown |
Page down cursor movement
|
EFLineBeg |
Cursor movement to line start
|
EFLineEnd |
Cursor movement to line end
|
Enum TPosHint
Enumerators
EPosHintUndefined = 0 | |
EInsertStrongL2R = 1 |
Left to right typing expected.
|
EInsertStrongR2L = 2 |
Right to left typing expected.
|
EPosHintLast | |
Enum TVisualEnd
Selection of the left end or right end of a run of text.
Enumerators
EVisualLeft |
Leftmost end.
|
EVisualRight |
Rightmost end.
|
Member Data Documentation
TPosHint
iPositioningHint
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.