Vcl.Graphics.TBitmap.TransparentColor

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

property TransparentColor: TColor read GetTransparentColor  write SetTransparentColor stored TransparentColorStored;

C++

__property System::Uitypes::TColor TransparentColor = {read=GetTransparentColor, write=SetTransparentColor, stored=TransparentColorStored, nodefault};

Properties

Type Visibility Source Unit Parent
property public
Vcl.Graphics.pas
Vcl.Graphics.hpp
Vcl.Graphics TBitmap

Description

Determines which color of the bitmap is to be transparent when the bitmap is drawn.

Use TransparentColor to determine how to draw the bitmap transparently. When the TransparentMode property is set to tmAuto (default), TransparentColor returns the color of the first pixel in the bitmap image data. For "bottom-up" bitmaps, the first pixel is the bottom leftmost pixel shown onscreen. For "top-down" bitmaps (less common), the first pixel is in the top left corner shown onscreen.

If TransparentColor is assigned, the TransparentMode is automatically set to tmFixed so that the new transparent color can be used later. If you want TransparentColor to disregard any assignments and return the bottom leftmost pixel color again, set TransparentMode to tmAuto.

See Also

Code Examples