Rx Clip Board Viewer

RX Library

Control Name Unit Class
RX Clip Board Viewer ClipView TClipboardViewer

Description: TClipBoardViewer is a special panel that can display the contents of the Windows Clipboard on a form. This is useful for examining the contents of the Windows clipboard without cutting & pasting.

As the clipboard stores information in multiple formats, you can use this to feature to transfer information between programs that use different formats.

The
ViewFormat property allows you to change current display format of Clipboard contents. The ClipboardFormatNames indexed property (run-time and read-only) is a list of the formats available for the information currently on the Clipboard.

TClipboardViewer component automatically changes
ViewFormat property when Clipboard contents is changed. You can set format you needed in your handler of OnChange event.

Use TClipboard class to determine formats currently available on the Clipboard.


Property ClipboardFormatNames[Index: Integer]
Declaration: ClipboardFormatNames[Index: Integer]: string;

The ClipboardFormatNames indexed property (run-time and read-only) is a list of the formats available for the information currently on the Clipboard. Use FormatCount property of TClipboard class to determine maximum value of index for ClipboardFormatNames.

You can use values of this property, fo example, to display list of currently available clipboard formats or to create menu items with clipboard format names.


Property ViewFormat
Declaration: ViewFormat: TClipboardViewFormat;

The Clipboard stores information in multiple formats so that you can transfer information between programs that use different formats. The ViewFormat property allows you to change current display format of Clipboard contents. TClipboardViewer component automatically changes ViewFormat property when Clipboard contents is changed. You can set format you needed in your handler of OnChange event.

To determine whether or not TClipboardViewer can display specified data format use CanDrawFormat method.


Event OnChange
Declaration: OnChange: TNotifyEvent;

OnChange occurs whenever the contents of the clipboard may have changed.
Write an OnChange event handler to take specific action whenever the contents of the clipboard may have changed. For example, you can specify appropriate display format of TClipboardViewer component (ViewFormat property) in this event handler.


Method CanDrawFormat
Declaration: function CanDrawFormat(ClipboardFormat: Word): Boolean;

This class method returns True if data format specified by ClipboardFormat parameter is supported by TClipboardViewer class and can be displayed. Otherwise CanDrawFormat returns False.


Type TClipboardViewFormat
Declaration: TClipboardViewFormat = (cvDefault, cvEmpty, cvUnknown, cvText, cvBitmap, cvMetafile, cvPalette, cvOemText, cvPicture, cvComponent, cvIcon);

The TClipboardViewFormat type defines the possible values for the ViewFormat property of the TClipboardViewer component.


Index Page | About | Download
Creation Date: 4 Feb 1998 | Last Update: 16 Mar 2000