PDFium Delphi Component Docs

OnFormSelectionRect 事件

元件: TPdf  ·  單元: PDFium
表單層每回報一個選取矩形就引發一次

語法

property OnFormSelectionRect: TPdfFormSelectionRectEvent read FOnFormSelectionRect write FOnFormSelectionRect;

說明

OnFormSelectionRect 對焦點欄位的每個相異選取矩形各引發一次。處理常式會收到一個 TPdfFormSelectionRect,內含以 1 為基底的 PageNumber 與頁面空間座標的 Bounds

連續的重複項會被抑制;每個回報的矩形也會附加到 FormSelectionRects 公開的清單

備註

範例

procedure TMain.Pdf1FormSelectionRect(Sender: TObject; const SelectionRect: TPdfFormSelectionRect);
begin
  HighlightSelection(SelectionRect.PageNumber, SelectionRect.Bounds);
end;

另請參閱

FormSelectionRects, ClearFormSelectionRects, TPdfView.SelectionRectangles