Class TWPPreviewDlg

Hierarchy

System.TObject | System.Classes.TPersistent | System.Classes.TComponent | WPUtil.TWPCustomAttrDlg | TWPPreviewDlg

Description

This dialog shows a preview form for the text stored in the editor which has been attached to its property EditBox. It will also display buttons for important tasks, such as Save, Print and SetupPrinter. You can switch off this buttons in the property DisabledDialogs if they are not required. The preview also shows a button to switch to edit mode when the property AllowEditMode is TRUE. In edit mode the user can type in the preview window. Internally the preview dialog uses the class TWPPreview which inherits from the editor class TWPCustomRtfEdit. For the save and print task it will use the procedures defined in the attached editor (property EditBox). The preview dialog supports single page - (SinglePageMode) and continous scrolling. Depending on the selected zoom mode it will show the pages in one column or in multiple columns. The dual page zoom mode adapts the zoom mode to always show 2 pages side by side.

Methods

Events

OnPrepareDlg : TWPPreviewDlgPrepare= TWPPreviewDlgPrepare

This event can be used to set certain properties in the TWPPreview Component. You can use it to modify the ViewOptions.

OnPrintClick : TNotifyEvent= procedure (Sender : TObject) of Object

OnSaveClick : TNotifyEvent= procedure (Sender : TObject) of Object