[Overview][Types][Classes][Procedures and functions][Index] Reference for unit 'Clipbrd' (#lcl)

TClipboard.GetFormat

Gets the data for the specified clipboard format from the LCL interface or cached clipboard data.

Declaration

Source position: clipbrd.pp line 209

public function TClipboard.GetFormat(

  FormatID: TClipboardFormat;

  Stream: TStream

):Boolean;

Arguments

FormatID

  

Format ID for the requested clipboard data.

Stream

  

TStream instance where the data for the format is stored.

Function result

Returns True if data for the format is available, or False when not found.

Description

GetFormat is a Boolean function used to retrieve clipboard data for the specified format into the specified stream. It uses cached clipboard data when available, or calls ClipboardGetData in the LCL interface to retrieve the data for the ClipboardType.

The return value is True for the following conditions:

GetFormat is used in the implementation of methods like GetComponent, GetTextBuf, and GetAsHtml. It is also called when reading the value for the AsText property.

See also

TClipboard.AsText

  

Text stored in the clipboard.

TClipboard.GetComponent

  

Gets a TComponent instance with the specified owner and parent from the clipboard.

TClipboard.GetTextBuf

  

Reads text from the clipboard and returns the content and number of characters.

TClipboard.GetAsHtml

  

Retrieves the HTML content of the clipboard (if available).

TClipboard.Formats

  

Contains the clipboard formats currently in use for the class instance.

TClipboard.OnRequest

  

OnRequest - event handler for a request for clipboard data.

TClipboardFormat


Version 4.0 Generated 2025-05-03 Home