وثائق PDFiumVCL

ClearSelection procedure

يحافظ إدخال API هذا على المعرّفات والتواقيع وكتل الكود ومصطلحات PDF بصيغتها الأصلية.
Component: TPdfView  ·  Unit: PDFium
Clears the current text selection and invalidates the view.

Syntax

procedure ClearSelection;

Description

Drops any active selection, resets the anchor / cursor endpoints, and invalidates the viewer so the next paint draws a clean page. Fires OnSelectionChange exactly once when the previous selection was non-empty; idempotent when there is nothing to clear (no event, no invalidation).

Called automatically by the viewer on every state change that would invalidate the selection: SetPdf, SetPageNumber, SetActive(False), and DisplayMode transitions.

Remarks

Example

PdfView1.ClearSelection;

See Also

HasSelection, SelectAll, OnSelectionChange