Unit Gfvcl

----------------------------------------------------------------------------} { A Gradient Fill component for Delphi. } { Copyright 1995, Curtis White. All Rights Reserved. } { This component can be freely used and distributed in commercial and private } { environments, provied this notice is not modified in any way. } { ----------------------------------------------------------------------------} { Feel free to contact me if you have any questions, comments or suggestions } { at cwhite@teleport.com } { ----------------------------------------------------------------------------} { Date last modified: 12/28/96 } { ----------------------------------------------------------------------------} { ----------------------------------------------------------------------------} { TGradientFill v1.35 } { ----------------------------------------------------------------------------} { Description: } { A graphic control that displays a gradient beginning with a chosen color } { and ending with another chosen color. } { Features: } { The begin and end colors can be any colors. } { The fill direction can be set to Top-To-Bottom, Bottom-To-Top, } { Right-To-Left, or Left-To-Right. } { The number of colors, between 1 and 255 can be set for the fill. } { ----------------------------------------------------------------------------} { ----------------------------------------------------------------------------} { Revision History: } { 1.00: Initial release } { 1.10: Added routines to use a realized palette for systems less than true } { color. This gets rid of Windows 16 color dithering on systems that } { can display only 256 or less colors. } { 1.20: Added two new properties to allow the Gradient Fill component to be } { used as a background in MDI forms. The fill paints to a bitmap, } { which is a published property, then copies the bitmap to the canvas. } { This allows the bitmap to be copied to the background of an MDI form.} { A palette handle property has also been added to allow the palette } { to be realized by the forms canvas when the Realize property is true.} { 1.30: Fixed resource leak. Added a flag to allow properties to be set } { without repainting each time a property is set. Then this flag can } { be set and the gradient fill will repaint itself with all the new } { changes in place. Also added a new method to allow it to realise } { it's palette as a background palette. The method is designed to be } { called by the owning app if it gets a WM_PALETTECHANGED message to } { try and keep the colors as close as possible on a 256 system. This } { routine was contributed by Colin Messitt (74774.1347@compuserve.com) } { 1.35: Changed the About box and made it compatible with Delphi 2.0 } { (32-bit version). Removed the component editor for the about box. } { ----------------------------------------------------------------------------

Classes

TGFPropAbout - --------------------------------------------------------------------} { Component AboutBox } { TGFCompAbout = class(TComponentEditor) procedure ExecuteVerb(Index: Integer); override; function GetVerb(Index: Integer): string; override; function GetVerbCount: Integer; override; procedure ShowAbout; end; {--------------------------------------------------------------------} { Property AboutBox
TGradientFill -

Functions

Register - Register the component

Types

TFillDirection
TNumberOfColors

Constants

Variables


Functions


procedure Register;

Register the component

Types


TFillDirection = (fdTopToBottom, fdBottomToTop, fdLeftToRight, fdRightToLeft);
Direction of fill
TNumberOfColors = 1..256
Range of valid colors

Constants


Variables