PDFiumVCL Docs

FormCanUndo method

이 API 항목은 식별자, 시그니처, 코드 블록, PDF 용어를 원래 형태로 유지합니다.
Component: TPdfView  ·  Unit: PDFium
Reports whether the focused AcroForm widget has at least one edit to undo.

Syntax

function FormCanUndo: Boolean;

Description

FormCanUndo wraps PDFium's FORM_CanUndo. It returns True when the FOCUSED AcroForm widget has at least one edit in its undo history that FormUndo could roll back, and False otherwise.

Returns False when the view is inactive, the document has no AcroForm, or no widget is focused — matching the contract of the other five form-edit helpers.

The natural use is as the Enabled-state expression for an Undo menu item, toolbar button, or context-menu entry.

Remarks

Example

procedure TForm1.EditMenuPopup(Sender: TObject);
begin
  miUndo.Enabled := PdfView1.FormCanUndo;
  miRedo.Enabled := PdfView1.FormCanRedo;
end;

See Also

FormUndo, FormCanRedo, FormRedo