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

TDBImage

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

TDBImage - a data-aware Image box to display a single image from a dataset

Declaration

Source position: dbctrls.pp line 970

type TDBImage = class(TCustomImage)

protected

  procedure Notification(); override;

  

  procedure DataChange();

  

DataChange - if data changed, load new picture

  procedure UpdateData();

  

UpdateData - if data changed, save new picture

  procedure PictureChanged(); override;

  

PictureChanged - software emulaton of the OnPictureChanged event

  procedure LoadPicture; virtual;

  

LoadPicture - loads picture into the appropriate field for the graphic class of the caller

  class procedure WSRegisterClass; override;

public

  constructor Create(); override;

  

Create - constructor for TDBImage: cals inherited Create then sets style and display methods, forms datalinks and actions

  destructor Destroy; override;

  

Destroy - destructor for TDBImage: frees datalinks and calls inherited Destroy

  property Field: TField; [r]

  

The Field in which picture data are stored

  procedure Change; virtual;

  

Change - if picture is changes, datalink needs to be informed

published

  property Align;

  

Specifies the placement of the control inside its Parent.

  property Anchors;

  

The set of anchor definitions for this control.

  property AutoDisplay: Boolean; [rw]

  

AutoDisplay - if True, automatically displays when focus is given

  property AutoSize;

  

Allows to automatically adjust the size of the control, according to its content.

  property BorderSpacing;

  

Determines the inner and outer border spacing for this control.

  property Center;

  

Should image be centered?

  property Constraints;

  

The minimal and maximal Width and Height of this control.

  property DataField: ; [rw]

  

The name of the DataField that holds the image

  property DataSource: TDataSource; [rw]

  

The identity of the DataSource that holds the image

  property DragCursor;

  

The cursor shape shown while the control is dragged.

  property DragMode;

  

Allows the user to drag the control.

  property OnClick;

  

Notification handler for mouse clicks.

  property OnDblClick;

  property OnDragDrop;

  

This handler determines the action on an drop onto this control, in a drag-drop operation.

  property OnDragOver;

  

Event handler for a control being dragged over this control.

  property OnEndDrag;

  

Notification handler for the end of a dragging operation.

  property OnMouseDown;

  

Event handler for mouse button going down.

  property OnMouseMove;

  

Event handler for mouse movement within the control.

  property OnMouseUp;

  

Event handler for mouse button going up.

  property OnStartDrag;

  

Event handler for the start of a dragging operation.

  property Proportional;

  

True if image is proportional

  property QuickDraw: Boolean; [rw]

  

QuickDraw - if True, quick drawing is implemented

  property ReadOnly: Boolean; [rw]

  

ReadOnly if True, image can be inspected byt not modified or written

  property Stretch;

  

True if picture is to be stretched

  property Transparent;

  

True if you can see through the image

  property Visible;

  

Allows to show or hide the control, and all of its children.

end;

Inheritance

TDBImage

  

TDBImage - a data-aware Image box to display a single image from a dataset

|

TCustomImage

  

TCustomImage - the base type for TImage

|

TGraphicControl

  

TGraphicControl is the base class for all lightweight controls.

|

TControl

  

The base class for visible controls.

|

TLCLComponent

  

The base class for LCL components associated with widgets.

|

TComponent

?

TObject

Description

The Image is stored in the database as a Binary Large Object (BLOB)

See also

HowToUseDataAwareControls

  

HowToUseDataAwareControls - Hints for accessing databases