Back to Devexpress

TdxCustomSmartImage Class

vcl-dxsmartimage-bd5c5a63.md

latest7.0 KB
Original Source

TdxCustomSmartImage Class

The base class for all classes that implement DevExpress image containers.

Declaration

delphi
TdxCustomSmartImage = class(
    TGraphic
)

Remarks

The TdxCustomSmartImage class implements base functionality for all universal image containers used in all DevExpress controls.

Main API Members

The list below outlines key API members of the TdxCustomSmartImage class that allow you to work with images.

Image Container Creation

CloneCreates a new image container populated with a copy of the stored image.CreateSizeThese overloaded methods create an image container filled with a specific color.CreateFromBitmap | CreateFromHBitmap | CreateFromBits | CreateFromStreamCreate an image container and populate it from the specified source.GetAsBitmapCreates a TBitmap container and populates it with the stored image.

Data Import and Export

Assign | AssignFromGraphic | AssignFromSmartImageRepopulate the image container with an image from another image container.CopyToClipboard | CutToClipboard | PasteFromClipboardMove image data between the image container and the clipboard.GetBitmapBitsReturns the stored image as an array of pixel data.LoadFromBits | LoadFromFieldValue | LoadFromResource | LoadFromStreamRepopulate the image container from the specified source.SaveToStream | SaveToStreamByCodecSave the stored image to a stream.SaveToFileSaves the stored image to a file.

Content and Resource Management

ClearClears the image container.ChangeColorFills all pixels of the stored image with a color.ConvertToBitmapRasterizes the stored vector image.Dormant | HandleNeededAllow you to suspend and restore the image container to optimize GDI resource usage.ImageCodecSpecifies the format of the stored image. You can use this property to convert the stored image to any supported format, except for SVG.Resize | ScaleScale the source image.

Animation and Multi-Frame Image Settings

ActiveFrameSpecifies the currently displayed frame in a multi-frame image.AnimationFrameCountReturns the number of frames in a multi-frame image.Animation | AnimationLoop | AnimationLoopCount | AnimationLoopIndex | StartAnimation | StopAnimationAllow you to track and manage animation playback for the stored animated image.

General-Purpose API Members

ClientRect | SizeReturn stored image dimensions.CompareCompares two image containers.GetHashCodeCalculates a CRC32 hash code from stored image data.IsAlphaUsedAllows you to identify if the stored image has transparent pixels.

Terminal TdxCustomSmartImage Class Descendants

Do not use the TdxCustomSmartImage class directly. Use the following descendants instead:

Universal Image Containers

TdxSmartGlyphA DPI-aware universal image container that can load an image from a DFM file.TdxSmartImageA universal container designed to store images in different formats.TdxOfficeImageA universal image container compatible with popular document formats.

Format-Specific Image Containers

TdxBMPImageA Smart Image container designed to store BMP images.TdxGIFImageA Smart Image container designed to store GIF images.TdxJPEGImageA Smart Image container designed to store JPEG images.TdxPNGImageA Smart Image container designed to store PNG images.

Inheritance

TObject TPersistent TInterfacedPersistent TGraphic TdxCustomSmartImage

See Also

TdxGPImage Class

TdxCustomSmartImage Members

dxSmartImage Unit