advsmoothlistbox.hpp
来自「TMSPack基本上涵盖了Delphi所有的基础控件」· HPP 代码 · 共 849 行 · 第 1/3 页
HPP
849 行
void __fastcall SetOpacityTo(const Byte Value);
void __fastcall SetGradientType(const Advsmoothgdip::TAdvGradientType Value);
void __fastcall SetHatchStyle(const Advsmoothgdip::HatchStyle Value);
void __fastcall SetOnTop(const bool Value);
protected:
void __fastcall Changed(void);
void __fastcall FontChanged(System::TObject* Sender);
__property Classes::TNotifyEvent OnChange = {read=FOnChange, write=FOnChange};
void __fastcall InitLookupBar(void);
public:
__fastcall TAdvSmoothListBoxLookUpBar(TAdvSmoothListBox* AOwner);
__fastcall virtual ~TAdvSmoothListBoxLookUpBar(void);
virtual void __fastcall Assign(Classes::TPersistent* Source);
int __fastcall GetWidth(void);
__published:
__property Graphics::TColor Color = {read=FColor, write=SetColor, default=16777215};
__property Graphics::TColor ColorTo = {read=FColorTo, write=SetColorTo, default=16777215};
__property Advsmoothgdip::TAdvGradientType GradientType = {read=FGradientType, write=SetGradientType, default=0};
__property Advsmoothgdip::HatchStyle HatchStyle = {read=FHatchStyle, write=SetHatchStyle, default=0};
__property Byte Opacity = {read=FOpacity, write=SetOpacity, default=100};
__property Byte OpacityTo = {read=FOpacityTo, write=SetOpacityTo, default=100};
__property bool Numeric = {read=FNumeric, write=SetNumeric, default=0};
__property bool Visible = {read=FVisible, write=SetVisible, default=1};
__property TAdvSmoothListBoxLookUpBarPosition Position = {read=FPosition, write=SetPosition, default=1};
__property Graphics::TFont* Font = {read=FFont, write=SetFont};
__property bool OnTop = {read=FOnTop, write=SetOnTop, default=0};
__property Graphics::TFont* DisabledFont = {read=FDisabledFont, write=SetDisabledFont};
};
class DELPHICLASS TAdvSmoothListBoxSections;
#pragma option push -b-
enum TAdvSmoothListBoxCategoryType { alphanumeric, alphabetic, numeric, date, time, custom };
#pragma option pop
class PASCALIMPLEMENTATION TAdvSmoothListBoxSections : public Classes::TPersistent
{
typedef Classes::TPersistent inherited;
private:
TAdvSmoothListBox* FOwner;
Byte FOpacity;
Graphics::TColor FBorderColor;
Advsmoothgdip::TAdvGradientType FGradientType;
Byte FOpacityTo;
Advsmoothgdip::HatchStyle FHatchStyle;
Graphics::TColor FColor;
Graphics::TColor FColorTo;
Graphics::TFont* FFont;
bool FVisible;
Classes::TNotifyEvent FOnChange;
TAdvSmoothListBoxCategoryType FCategoryType;
int FBorderWidth;
void __fastcall SetBorderColor(const Graphics::TColor Value);
void __fastcall SetColor(const Graphics::TColor Value);
void __fastcall SetColorTo(const Graphics::TColor Value);
void __fastcall SetFont(const Graphics::TFont* Value);
void __fastcall SetGradientType(const Advsmoothgdip::TAdvGradientType Value);
void __fastcall SetHatchStyle(const Advsmoothgdip::HatchStyle Value);
void __fastcall SetOpacity(const Byte Value);
void __fastcall SetOpacityTo(const Byte Value);
void __fastcall SetVisible(const bool Value);
void __fastcall SetCategoryType(const TAdvSmoothListBoxCategoryType Value);
void __fastcall SetBorderWidth(const int Value);
public:
void __fastcall Changed(void);
void __fastcall FontChanged(System::TObject* Sender);
__fastcall TAdvSmoothListBoxSections(TAdvSmoothListBox* AOwner);
__fastcall virtual ~TAdvSmoothListBoxSections(void);
virtual void __fastcall Assign(Classes::TPersistent* Source);
__published:
__property Graphics::TFont* Font = {read=FFont, write=SetFont};
__property bool Visible = {read=FVisible, write=SetVisible, default=0};
__property Advsmoothgdip::TAdvGradientType GradientType = {read=FGradientType, write=SetGradientType, default=0};
__property Advsmoothgdip::HatchStyle HatchStyle = {read=FHatchStyle, write=SetHatchStyle, default=0};
__property Graphics::TColor BorderColor = {read=FBorderColor, write=SetBorderColor, default=12632256};
__property int BorderWidth = {read=FBorderWidth, write=SetBorderWidth, default=1};
__property Graphics::TColor Color = {read=FColor, write=SetColor, default=16777215};
__property Graphics::TColor ColorTo = {read=FColorTo, write=SetColorTo, default=12632256};
__property Byte Opacity = {read=FOpacity, write=SetOpacity, default=180};
__property Byte OpacityTo = {read=FOpacityTo, write=SetOpacityTo, default=180};
__property Classes::TNotifyEvent OnChange = {read=FOnChange, write=FOnChange};
__property TAdvSmoothListBoxCategoryType CategoryType = {read=FCategoryType, write=SetCategoryType, default=0};
};
class DELPHICLASS TAdvSmoothListBoxHeaderFooter;
#pragma option push -b-
enum TAdvSmoothListBoxCaptionLocation { cpTopLeft, cpTopCenter, cpTopRight, cpCenterLeft, cpCenterCenter, cpCenterRight, cpBottomLeft, cpBottomCenter, cpBottomRight, cpCustom };
#pragma option pop
class PASCALIMPLEMENTATION TAdvSmoothListBoxHeaderFooter : public Classes::TPersistent
{
typedef Classes::TPersistent inherited;
private:
TAdvSmoothListBox* FOwner;
Graphics::TFont* FFont;
AnsiString FCaption;
int FHeight;
Classes::TNotifyEvent FOnChange;
bool FVisible;
int FCaptionTop;
int FCaptionLeft;
Gdipfill::TGDIPFill* FFill;
Graphics::TColor FCaptionShadowColor;
TAdvSmoothListBoxCaptionLocation FCaptionLocation;
Graphics::TColor FCaptionURLColor;
int FCaptionShadowOffset;
void __fastcall SetCaption(const AnsiString Value);
void __fastcall SetFont(const Graphics::TFont* Value);
void __fastcall SetVisible(const bool Value);
void __fastcall SetCaptionLeft(const int Value);
void __fastcall SetCaptionTop(const int Value);
void __fastcall SetFill(const Gdipfill::TGDIPFill* Value);
void __fastcall SetHeight(const int Value);
void __fastcall SetCaptionLocation(const TAdvSmoothListBoxCaptionLocation Value);
void __fastcall SetCaptionShadowColor(const Graphics::TColor Value);
void __fastcall SetCaptionShadowOffset(const int Value);
void __fastcall SetCaptionURLColor(const Graphics::TColor Value);
public:
void __fastcall Changed(void);
void __fastcall FontChanged(System::TObject* Sender);
void __fastcall FillChanged(System::TObject* Sender);
__fastcall TAdvSmoothListBoxHeaderFooter(TAdvSmoothListBox* AOwner);
__fastcall virtual ~TAdvSmoothListBoxHeaderFooter(void);
virtual void __fastcall Assign(Classes::TPersistent* Source);
int __fastcall GetHeight(void);
AnsiString __fastcall GetAnchorAt(const Types::TRect &r, int X, int Y);
__published:
__property Gdipfill::TGDIPFill* Fill = {read=FFill, write=SetFill};
__property int Height = {read=FHeight, write=SetHeight, default=40};
__property AnsiString Caption = {read=FCaption, write=SetCaption};
__property Graphics::TColor CaptionURLColor = {read=FCaptionURLColor, write=SetCaptionURLColor, default=16711680};
__property Graphics::TColor CaptionShadowColor = {read=FCaptionShadowColor, write=SetCaptionShadowColor, default=8421504};
__property int CaptionShadowOffset = {read=FCaptionShadowOffset, write=SetCaptionShadowOffset, default=5};
__property TAdvSmoothListBoxCaptionLocation CaptionLocation = {read=FCaptionLocation, write=SetCaptionLocation, default=4};
__property int CaptionLeft = {read=FCaptionLeft, write=SetCaptionLeft, default=0};
__property int CaptionTop = {read=FCaptionTop, write=SetCaptionTop, default=0};
__property Graphics::TFont* Font = {read=FFont, write=SetFont};
__property Classes::TNotifyEvent OnChange = {read=FOnChange, write=FOnChange};
__property bool Visible = {read=FVisible, write=SetVisible, default=1};
};
class DELPHICLASS TAdvSmoothListBoxIndicator;
class PASCALIMPLEMENTATION TAdvSmoothListBoxIndicator : public Classes::TPersistent
{
typedef Classes::TPersistent inherited;
private:
TAdvSmoothListBox* FOwner;
Advsmoothgdip::TAdvGradientType FGradientType;
Byte FOpacity;
Advsmoothgdip::HatchStyle FHatchStyle;
Graphics::TColor FColor;
Graphics::TColor FColorTo;
bool FVisible;
bool FFade;
Classes::TNotifyEvent FOnChange;
int FWidth;
int FHeight;
int FAnimateOpacity;
void __fastcall SetColor(const Graphics::TColor Value);
void __fastcall SetColorTo(const Graphics::TColor Value);
void __fastcall SetGradientType(const Advsmoothgdip::TAdvGradientType Value);
void __fastcall SetHatchStyle(const Advsmoothgdip::HatchStyle Value);
void __fastcall SetOpacity(const Byte Value);
void __fastcall SetVisible(const bool Value);
void __fastcall SetFade(const bool Value);
void __fastcall Setwidth(const int Value);
protected:
void __fastcall Changed(void);
public:
__fastcall TAdvSmoothListBoxIndicator(TAdvSmoothListBox* AOwner);
__fastcall virtual ~TAdvSmoothListBoxIndicator(void);
virtual void __fastcall Assign(Classes::TPersistent* Source);
Byte __fastcall GetAnimationOpacity(void);
int __fastcall GetWidth(void);
__published:
__property bool Visible = {read=FVisible, write=SetVisible, default=1};
__property Graphics::TColor Color = {read=FColor, write=SetColor, default=0};
__property Graphics::TColor ColorTo = {read=FColorTo, write=SetColorTo, default=8421504};
__property Byte Opacity = {read=FOpacity, write=SetOpacity, default=100};
__property Advsmoothgdip::TAdvGradientType GradientType = {read=FGradientType, write=SetGradientType, default=0};
__property Advsmoothgdip::HatchStyle HatchStyle = {read=FHatchStyle, write=SetHatchStyle, default=0};
__property bool Fade = {read=FFade, write=SetFade, default=1};
__property Classes::TNotifyEvent OnChange = {read=FOnChange, write=FOnChange};
__property int Width = {read=FWidth, write=Setwidth, default=5};
};
#pragma option push -b-
enum TAdvSmoothListBoxDetailStatus { dsDetailsNotVisible, dsDetailsVisible };
#pragma option pop
typedef void __fastcall (__closure *TAdvSmoothListBoxItemClickEvent)(System::TObject* Sender, int itemindex);
typedef void __fastcall (__closure *TAdvSmoothListBoxScrollEvent)(System::TObject* Sender, double CurrentPosition, double EndPosition);
typedef void __fastcall (__closure *TAdvSmoothListBoxDetailEvent)(System::TObject* Sender, int itemindex);
typedef void __fastcall (__closure *TAdvSmoothListBoxItemDrawEvent)(System::TObject* Sender, Graphics::TCanvas* Canvas, int itemindex, const Types::TRect &itemrect, bool &defaultdraw);
typedef void __fastcall (__closure *TAdvSmoothListBoxItemTextEvent)(System::TObject* Sender, int itemindex, AnsiString &itemcaption, AnsiString &iteminfo, AnsiString &itemnotes);
typedef void __fastcall (__closure *TAdvSmoothListBoxItemBkgDrawEvent)(System::TObject* Sender, Graphics::TCanvas* Canvas, int itemindex, const Types::TRect &itemRect, bool &defaultdraw);
typedef void __fastcall (__closure *TAdvSmoothListBoxAnchorClickEvent)(System::TObject* Sender, AnsiString Anchor);
typedef void __fastcall (__closure *TAdvSmoothListBoxItemCheckedEvent)(System::TObject* Sender, int itemindex, bool checked);
typedef void __fastcall (__closure *TAdvSmoothListBoxItemCaptionClick)(System::TObject* Sender, int itemindex);
typedef void __fastcall (__closure *TAdvSmoothListBoxItemInfoClick)(System::TObject* Sender, int itemindex);
typedef void __fastcall (__closure *TAdvSmoothListBoxItemAnchorClickEvent)(System::TObject* Sender, AnsiString Anchor, int ItemIndex);
class PASCALIMPLEMENTATION TAdvSmoothListBox : public Controls::TCustomControl
{
typedef Controls::TCustomControl inherited;
private:
int FTimerCount;
bool FDesignTime;
bool FFocused;
Controls::TControl* FCurrentControl;
AnsiString FLookupKey;
Graphics::TBitmap* FAnimateBitmap;
int FClickX;
int FClickY;
bool FLookUp;
int FLookUpSize;
double FSp;
int FTimeStart;
int FTimeStop;
bool FDetailShow;
bool FAnimatingdetail;
bool FAnimatingScroll;
bool FMouseUp;
bool FAnimating;
bool FAnimate;
bool FMouseDown;
int FDetailIndex;
int FDragY;
int FScrollY;
Extctrls::TTimer* FSmoothTimer;
int FScPosTo;
int FCurrentScPos;
int FSelectedItemIndex;
TAdvSmoothListBoxItems* FItems;
TAdvSmoothListBoxDisplayList* FDisplayList;
TAdvSmoothListBoxItemAppearance* FItemAppearance;
TAdvSmoothListBoxLookUpBar* FLookUpBar;
int FSpeedFactor;
bool FSorted;
TAdvSmoothListBoxSections* FSections;
TAdvSmoothListBoxHeaderFooter* FHeader;
TAdvSmoothListBoxIndicator* FScrollIndicator;
TAdvSmoothListBoxHeaderFooter* FFooter;
Controls::TControl* FControl;
TAdvSmoothListBoxDetailStatus FDetailStatus;
TAdvSmoothListBoxItemClickEvent FOnItemDblClick;
TAdvSmoothListBoxItemClickEvent FOnItemClick;
bool FKeyBoardLookup;
int FSplitterHeight;
TAdvSmoothListBoxScrollEvent FOnScroll;
TAdvSmoothListBoxDetailEvent FOnShowDetail;
TAdvSmoothListBoxDetailEvent FOnHideDetail;
TAdvSmoothListBoxItemDrawEvent FOnItemDraw;
TAdvSmoothListBoxItemTextEvent FOnItemText;
TAdvSmoothListBoxItemBkgDrawEvent FOnItemBkgDraw;
Gdippicturecontainer::TGDIPPictureContainer* FContainer;
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?