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

TDragImageList

[Properties (by Name)] [Methods (by Name)] [Events (by Name)]

A multi-resolution list of Images used during Drag operations.

Declaration

Source position: controls.pp line 444

type TDragImageList = class(TCustomImageList)

protected

  function GetResolutionClass; override;

  procedure Initialize; override;

  

initializes the cursor shape and image index for the list.

public

  function BeginDrag();

  

Start dragging an image; returns True if successful.

  function DragLock();

  

Show drag image during drag operation.

  function DragMove();

  

Shows the drag image at a new location.

  procedure DragUnlock;

  

Hide the drag image.

  function EndDrag;

  

Finish dragging of the image, restore the old cursor shape.

  procedure HideDragImage;

  

Hides the drag image without unlocking the window.

  function SetDragImage();

  

Set index of dragged image and hotspot.

  procedure ShowDragImage;

  

Displays the drag image.

  property DragCursor: TCursor; [rw]

  

The cursor shape to use while dragging.

  property DragHotspot: TPoint; [rw]

  

The position of the HotSpot image, i.e. the offset to the mouse position while dragging.

  property Dragging: Boolean; [r]

  

True if dragging in progress.

  property DraggingResolution: TDragImageListResolution; [r]

  

Gets the scaled image resolution with the drag images for the list.

  property Resolution []: TDragImageListResolution; [r]

  

Gets the image resolution for the specified image width.

end;

Inheritance

TDragImageList

  

A multi-resolution list of Images used during Drag operations.

|

TCustomImageList

  

The base class for TImageList.

|

TLCLComponent

  

The base class for LCL components which have an associated widget.

|

TComponent,IUnknown,IInterfaceComponentReference

|

TPersistent,IFPObserved

|

TObject

Description

TDragImageList is a TCustomImageList descendant which provides a multi-resolution container for images displayed when a drop-drop operation is active. A drag image is shown when a drag operation is active and a DragImageList has been supplied.

TDragImageList overrides and reimplements methods from the ancestor to support the TDragImageListResolution type used in the image Resolution property. Additional properties and methods are provided to work with a drag image and its hot spot when the operation is started or stopped, and when the mouse position is changed.

In drag-dock operations, a drag image is not typically displayed since the DockRect frame already provides visual feedback.

This is a general overview of the usage of this class:

TDragImageList is the ancestor for the TImageList class defined in the LCL. It is also the type returned from the GetDragImages method in TControl.

See also

TImageList

  

Implements a multi-resolution container for images used in an application.

TControl.GetDragImages

  

Get the list of images used when a drag operation is active.

TCustomImageList

  

The base class for TImageList.


Version 3.2 Generated 2024-02-25 Home