rvico TRichView Reference | TRichView


Top  Previous  Next

Occurs when user clicks on hypertext item.


  TJumpEvent = procedure(Sender: TObject; id: Integer) of object;


property OnJump: TJumpEvent;


id is an identifier of hypertext link (the first link in the document has id=FirstJumpNo, the next link has id=FirstJumpNo+1, and so on).

In editor, this numeration is available only when the editor works in hypertext mode:

while user holds  Ctrl  key (see EditorOptions) until he/she releases it, or the document is modified, or the editor loses focus;

if ReadOnly=True.

So, when using this event in editor, perform all actions that use this id before any action changing document or moving focus out of editor.

In viewer, this even can also be initiated using keyboard, if TabNavigation<>rvtnNone. User uses  Tab  to highlight the hyperlink, then  Enter  to activate it (to call this event).


procedure TMyForm.MyRichViewJump(Sender: TObject; id: Integer);

var ItemNo: Integer;

    RVData: TCustomRVFormattedData;

    s: String;


  MyRichView.GetJumpPointLocation(id, RVData, ItemNo);

  s := RVData.GetItemTag(ItemNo);

  Application.MessageBox(PChar(s), 'Link', MB_OK or MB_ICONINFORMATION);



See also events:


See also:

RichView hypertext.

TRichView © trichview.com