| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495 |
- {========================================================================}
- {= (c) 1995-98 SwiftSoft Ronald Dittrich =}
- {========================================================================}
- {= All Rights Reserved =}
- {========================================================================}
- {= D 01099 Dresden = Tel.: +0351-8012255 =}
- {= Loewenstr.7a = info@swiftsoft.de =}
- {========================================================================}
- {= Actual versions on http://www.swiftsoft.de/mmtools.html =}
- {========================================================================}
- {= This code is for reference purposes only and may not be copied or =}
- {= distributed in any format electronic or otherwise except one copy =}
- {= for backup purposes. =}
- {= =}
- {= No Delphi Component Kit or Component individually or in a collection=}
- {= subclassed or otherwise from the code in this unit, or associated =}
- {= .pas, .dfm, .dcu, .asm or .obj files may be sold or distributed =}
- {= without express permission from SwiftSoft. =}
- {= =}
- {= For more licence informations please refer to the associated =}
- {= HelpFile. =}
- {========================================================================}
- {= $Date: 20.01.1998 - 18:00:00 $ =}
- {========================================================================}
- unit MMScroll;
- {$I COMPILER.INC}
- interface
- uses
- {$IFDEF WIN32}
- Windows,
- {$ELSE}
- WinProcs,
- WinTypes,
- {$ENDIF}
- SysUtils,
- Messages,
- Classes,
- Graphics,
- Controls,
- ExtCtrls,
- MMObj,
- MMUtils,
- MMString,
- MMMulDiv;
- type
- TMMScrollPanelKind = (spHorizontal, spVertical);
- TMMScrollShiftKind = (sknone, skleft, skright, skboth, skJump);
- TMMScrollChangeEvent = procedure(Sender : TObject; Min, Max : longint) of object;
- {-- TMMScrollPanel ----------------------------------------------------}
- TMMScrollPanel = class(TMMGraphicControl)
- public
- constructor Create(AOwner : TComponent); override;
- destructor Destroy; override;
- procedure Paint; override;
- procedure SetSliderAll(Min, Max: Longint);
- procedure SetRangeAll(Min, Max: Longint);
- published
- property OnTrack: TMMScrollChangeEvent read FOnTrack write FOnTrack;
- property OnTrackEnd: TMMScrollChangeEvent read FOnTrackEnd write FOnTrackend;
- property OnTrackSize: TMMScrollChangeEvent read FOnTrackSize write FOnTrackSize;
- property Align;
- property Bevel;
- property Color;
- property Enabled;
- property Font;
- property ShowHint;
- property Visible;
- property Width default 100;
- property Height default 22;
- property Caption;
- property ParentFont;
- property ParentColor;
- property ParentShowHint;
- property Kind: TMMScrollPanelKind read FKind write SetKind default spHorizontal;
- property RangeMin: Longint read FRangeMin write SetRangeMin default 0;
- property RangeMax: Longint read FRangeMax write SetRangeMax default 1000;
- property Sizeable: Boolean read FSizeable write FSizeable default True;
- property SliderMin: Longint read FSliderMin write SetSliderMin default 200;
- property SliderMax: Longint read FSliderMax write SetSliderMax default 500;
- property Locator: Longint read FLocator write SetLocator default -1;
- property LocatorColor: TColor read FLocColor write SetLocColor default clYellow;
- property SliderColor: TColor read FSliderColor write SetSliderColor default clBtnFace;
- end;
- implementation
|