rvico TRichView Reference | Types

TRVTextDrawState, TRVTextDrawStates Types

Top  Previous  Next

Unit RVStyle;

type

  TRVTextDrawState = (rvtsSelected, rvtsHover, 

    rvtsItemStart, rvtsItemEnd,

    rvtsDrawItemStart, rvtsDrawItemEnd,

    rvtsControlFocused, rvtsSpecialCharacters);

  TRVTextDrawStates = set of TRVTextDrawState;

States of text, used for drawing.

See TRVStyle.OnDrawStyleText, OnDrawTextBack

State

Meaning

rvtsSelected

text is selected (for copying to the Clipboard)

rvtsHover

[hyper]text is below a mouse pointer

rvtsItemStart

this call of event draws text item from the beginning

rvtsItemEnd

this call of event finishes drawing of text item

rvtsDrawItemStart

this call of event draws part of text item from the beginning

rvtsDrawItemEnd

this call of event finishes drawing of part of text item.

rvtsControlFocused

TRichView has input focus

rvtsSpecialCharacters

rvoShowSpecialCharacters is included in TRichView.Options.

For example

CDRAW

(there are two items: 'This is an example.' and 'Selected',

and three "drawing items": 'This is an', 'example.' and 'Selected'

Calls of TRVStyle.OnDrawStyleText will be:

'This is an' with [rvtsItemStart,rvtsDrawItemStart,rvtsDrawItemEnd]

'example.' with [rvtsItemEnd, rvtsDrawItemStart, rvtsDrawItemEnd]

'Selected' with [rvtsItemStart, rvtsItemEnd, rvtsDrawItemStart, rvtsDrawItemEnd]

'lect' with [rvtsSelected]

Note 1: custom drawing of selected text is not supported for bidirected text

Note 2: this order of drawing (selected text over non-selected) is since version 1.6


RichView © Sergey Tkachenko