⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 plannercal.hpp

📁 一个非常棒的控件.做商业软件特别适用.里面的控件涉及面非常的广,有兴趣的话可以下来用用就知道了.
💻 HPP
📖 第 1 页 / 共 4 页
字号:
// Borland C++ Builder
// Copyright (c) 1995, 2005 by Borland Software Corporation
// All rights reserved

// (DO NOT EDIT: machine generated header) 'Plannercal.pas' rev: 10.00

#ifndef PlannercalHPP
#define PlannercalHPP

#pragma delphiheader begin
#pragma option push
#pragma option -w-      // All warnings off
#pragma option -Vx      // Zero-length empty class member functions
#pragma pack(push,8)
#include <System.hpp>	// Pascal unit
#include <Sysinit.hpp>	// Pascal unit
#include <Sysutils.hpp>	// Pascal unit
#include <Windows.hpp>	// Pascal unit
#include <Messages.hpp>	// Pascal unit
#include <Classes.hpp>	// Pascal unit
#include <Graphics.hpp>	// Pascal unit
#include <Controls.hpp>	// Pascal unit
#include <Forms.hpp>	// Pascal unit
#include <Dialogs.hpp>	// Pascal unit
#include <Stdctrls.hpp>	// Pascal unit
#include <Extctrls.hpp>	// Pascal unit
#include <Advstyleif.hpp>	// Pascal unit
#include <Advimage.hpp>	// Pascal unit
#include <Menus.hpp>	// Pascal unit

//-- user supplied -----------------------------------------------------------

namespace Plannercal
{
//-- type declarations -------------------------------------------------------
typedef AnsiString TDayStr;

typedef AnsiString TMonthStr;

typedef AnsiString TDayArray[14];

typedef AnsiString TMonthArray[12];

#pragma option push -b-
enum TBackGroundPosition { bpTopLeft, bpTopRight, bpBottomLeft, bpBottomRight, bpTiled, bpStretched, bpCenter };
#pragma option pop

typedef void __fastcall (__closure *TDaySelectEvent)(System::TObject* Sender, System::TDateTime SelDate);

typedef void __fastcall (__closure *TDateChangeEvent)(System::TObject* Sender, System::TDateTime origDate, System::TDateTime newDate);

typedef void __fastcall (__closure *TCancelledChangeEvent)(System::TObject* Sender, System::TDateTime CancelledDate);

typedef void __fastcall (__closure *TCellDrawEvent)(System::TObject* Sender, Graphics::TCanvas* Canvas, TDate Day, bool Selected, bool Marked, bool InMonth, const Types::TRect &Rect);

typedef void __fastcall (__closure *TGetDateEvent)(System::TObject* Sender, System::TDateTime dt, bool &isEvent);

typedef void __fastcall (__closure *TGetDateEventHint)(System::TObject* Sender, System::TDateTime dt, bool &isEvent, AnsiString &EventHint);

#pragma option push -b-
enum TEventShape { evsRectangle, evsCircle, evsSquare, evsTriangle, evsNone };
#pragma option pop

#pragma option push -b-
enum TGradientDirection { gdHorizontal, gdVertical };
#pragma option pop

#pragma option push -b-
enum TTodayStyle { tsSunken, tsRaised, tsFlat };
#pragma option pop

#pragma option push -b-
enum TPlannerCalendarStyle { psWindowsXP, psOffice2000, psOffice2003Blue, psOffice2003Olive, psOffice2003Silver, psOffice2003Classic, psFlat, psAvantGarde, psWhidbey, psOffice2007Luna, psOffice2007Obsidian, psCustom };
#pragma option pop

class DELPHICLASS TWeekDays;
class PASCALIMPLEMENTATION TWeekDays : public Classes::TPersistent 
{
	typedef Classes::TPersistent inherited;
	
private:
	bool FSat;
	bool FSun;
	bool FMon;
	bool FTue;
	bool FWed;
	bool FThu;
	bool FFri;
	Classes::TNotifyEvent FChanged;
	void __fastcall SetSat(const bool Value);
	void __fastcall SetSun(const bool Value);
	void __fastcall SetMon(const bool Value);
	void __fastcall SetTue(const bool Value);
	void __fastcall SetWed(const bool Value);
	void __fastcall SetThu(const bool Value);
	void __fastcall SetFri(const bool Value);
	void __fastcall Changed(void);
	
public:
	__fastcall TWeekDays(void);
	
__published:
	__property bool Sat = {read=FSat, write=SetSat, default=1};
	__property bool Sun = {read=FSun, write=SetSun, default=1};
	__property bool Mon = {read=FMon, write=SetMon, default=0};
	__property bool Tue = {read=FTue, write=SetTue, default=0};
	__property bool Wed = {read=FWed, write=SetWed, default=0};
	__property bool Thu = {read=FThu, write=SetThu, default=0};
	__property bool Fri = {read=FFri, write=SetFri, default=0};
	__property Classes::TNotifyEvent OnChanged = {read=FChanged, write=FChanged};
public:
	#pragma option push -w-inl
	/* TPersistent.Destroy */ inline __fastcall virtual ~TWeekDays(void) { }
	#pragma option pop
	
};


class DELPHICLASS TSelDateItem;
class PASCALIMPLEMENTATION TSelDateItem : public Classes::TCollectionItem 
{
	typedef Classes::TCollectionItem inherited;
	
private:
	System::TDateTime FDate;
	AnsiString FHint;
	Graphics::TColor FColor;
	TEventShape FEventShape;
	Graphics::TColor FFontColor;
	System::TObject* FObject;
	int FTag;
	void __fastcall SetDate(const System::TDateTime Value);
	void __fastcall SetColor(const Graphics::TColor Value);
	void __fastcall SetEventShape(const TEventShape Value);
	HIDESBASE void __fastcall Changed(void);
	void __fastcall SetFontColor(const Graphics::TColor Value);
	void __fastcall SetHint(const AnsiString Value);
	
public:
	__fastcall virtual ~TSelDateItem(void);
	virtual void __fastcall Assign(Classes::TPersistent* Source);
	__property System::TDateTime Date = {read=FDate, write=SetDate};
	__property AnsiString Hint = {read=FHint, write=SetHint};
	__property Graphics::TColor FontColor = {read=FFontColor, write=SetFontColor, nodefault};
	__property Graphics::TColor Color = {read=FColor, write=SetColor, nodefault};
	__property TEventShape Shape = {read=FEventShape, write=SetEventShape, nodefault};
	__property System::TObject* ItemObject = {read=FObject, write=FObject};
	__property int Tag = {read=FTag, write=FTag, nodefault};
public:
	#pragma option push -w-inl
	/* TCollectionItem.Create */ inline __fastcall virtual TSelDateItem(Classes::TCollection* Collection) : Classes::TCollectionItem(Collection) { }
	#pragma option pop
	
};


class DELPHICLASS TEventProp;
class PASCALIMPLEMENTATION TEventProp : public TSelDateItem 
{
	typedef TSelDateItem inherited;
	
public:
	#pragma option push -w-inl
	/* TSelDateItem.Destroy */ inline __fastcall virtual ~TEventProp(void) { }
	#pragma option pop
	
public:
	#pragma option push -w-inl
	/* TCollectionItem.Create */ inline __fastcall virtual TEventProp(Classes::TCollection* Collection) : TSelDateItem(Collection) { }
	#pragma option pop
	
};


class DELPHICLASS TSelDateItems;
class DELPHICLASS TCustomCalendarPanel;
class PASCALIMPLEMENTATION TCustomCalendarPanel : public Extctrls::TCustomPanel 
{
	typedef Extctrls::TCustomPanel inherited;
	
private:
	Graphics::TColor FEventMarkerColor;
	TEventShape FEventMarkerShape;
	Graphics::TColor FEventDayColor;
	void __fastcall SetEventMarkerColor(const Graphics::TColor Value);
	void __fastcall SetEventMarkerShape(const TEventShape Value);
	void __fastcall SetEventDayColor(const Graphics::TColor Value);
	
protected:
	virtual void __fastcall UpdateYearStart(void);
	virtual void __fastcall DoPaint(void);
	virtual void __fastcall RepaintDate(System::TDateTime dt);
	
public:
	__property BorderWidth  = {default=0};
	__property BevelWidth  = {default=1};
	
__published:
	__property Graphics::TColor EventDayColor = {read=FEventDayColor, write=SetEventDayColor, nodefault};
	__property Graphics::TColor EventMarkerColor = {read=FEventMarkerColor, write=SetEventMarkerColor, nodefault};
	__property TEventShape EventMarkerShape = {read=FEventMarkerShape, write=SetEventMarkerShape, nodefault};
public:
	#pragma option push -w-inl
	/* TCustomPanel.Create */ inline __fastcall virtual TCustomCalendarPanel(Classes::TComponent* AOwner) : Extctrls::TCustomPanel(AOwner) { }
	#pragma option pop
	
public:
	#pragma option push -w-inl
	/* TCustomControl.Destroy */ inline __fastcall virtual ~TCustomCalendarPanel(void) { }
	#pragma option pop
	
public:
	#pragma option push -w-inl
	/* TWinControl.CreateParented */ inline __fastcall TCustomCalendarPanel(HWND ParentWindow) : Extctrls::TCustomPanel(ParentWindow) { }
	#pragma option pop
	
};


class PASCALIMPLEMENTATION TSelDateItems : public Classes::TCollection 
{
	typedef Classes::TCollection inherited;
	
private:
	TCustomCalendarPanel* FOwner;
	int FUpdateCount;
	Classes::TNotifyEvent FOnChange;
	bool FVisible;
	HIDESBASE TSelDateItem* __fastcall GetItem(int Index);
	HIDESBASE void __fastcall SetItem(int Index, TSelDateItem* Value);
	void __fastcall DoPaint(void);
	TSelDateItem* __fastcall GetDate(System::TDateTime dt);
	
protected:
	virtual void __fastcall Update(Classes::TCollectionItem* Item);
	
public:
	int __fastcall IsInList(int da, int mo, int ye);
	int __fastcall IsDateInList(System::TDateTime dt);
	__fastcall TSelDateItems(TCustomCalendarPanel* AOwner);
	HIDESBASE TSelDateItem* __fastcall Add(void);
	HIDESBASE TSelDateItem* __fastcall Insert(int Index);
	__property TSelDateItem* Items[int Index] = {read=GetItem, write=SetItem};
	__property TSelDateItem* Dates[System::TDateTime dt] = {read=GetDate};
	void __fastcall AddRange(System::TDateTime dt1, System::TDateTime dt2);
	void __fastcall AddRangeSC(System::TDateTime dt1, System::TDateTime dt2, TEventShape Shp, Graphics::TColor Clr);
	void __fastcall DelRange(System::TDateTime dt1, System::TDateTime dt2);
	void __fastcall AddRangeHint(System::TDateTime dt1, System::TDateTime dt2, AnsiString Hint);
	void __fastcall AddRangeHintSC(System::TDateTime dt1, System::TDateTime dt2, AnsiString Hint, TEventShape Shp, Graphics::TColor Clr);
	void __fastcall StartUpdate(void);
	void __fastcall StopUpdate(void);
	void __fastcall ResetUpdate(void);
	void __fastcall RepaintDate(System::TDateTime ADate);
	__property Classes::TNotifyEvent OnChange = {read=FOnChange, write=FOnChange};
	__property bool Visible = {read=FVisible, write=FVisible, nodefault};
public:
	#pragma option push -w-inl
	/* TCollection.Destroy */ inline __fastcall virtual ~TSelDateItems(void) { }
	#pragma option pop
	
};


typedef void __fastcall (__closure *TEventPropEvent)(System::TObject* Sender, System::TDateTime dt, TEventProp* &Event);

class DELPHICLASS TMinMaxDate;
class DELPHICLASS TPlannerCalendar;
#pragma option push -b-
enum TPlannerCalendarLook { lookFlat, look3D };
#pragma option pop

class DELPHICLASS TCalendarBrowsers;
class PASCALIMPLEMENTATION TCalendarBrowsers : public Classes::TPersistent 
{
	typedef Classes::TPersistent inherited;
	
private:
	bool FPrevMonth;
	bool FNextMonth;
	bool FPrevYear;
	bool FNextYear;
	Classes::TNotifyEvent FOnChange;
	void __fastcall SetNextMonth(const bool Value);
	void __fastcall SetNextYear(const bool Value);
	void __fastcall SetPrevMonth(const bool Value);
	void __fastcall SetPrevYear(const bool Value);
	
public:
	__fastcall TCalendarBrowsers(void);
	void __fastcall Changed(void);
	
__published:
	__property bool PrevMonth = {read=FPrevMonth, write=SetPrevMonth, default=1};
	__property bool PrevYear = {read=FPrevYear, write=SetPrevYear, default=1};
	__property bool NextMonth = {read=FNextMonth, write=SetNextMonth, default=1};
	__property bool NextYear = {read=FNextYear, write=SetNextYear, default=1};
	__property Classes::TNotifyEvent OnChange = {read=FOnChange, write=FOnChange};
public:
	#pragma option push -w-inl
	/* TPersistent.Destroy */ inline __fastcall virtual ~TCalendarBrowsers(void) { }
	#pragma option pop
	
};


class DELPHICLASS TYearStartAt;
class PASCALIMPLEMENTATION TYearStartAt : public Classes::TPersistent 
{
	typedef Classes::TPersistent inherited;
	
private:
	TCustomCalendarPanel* FOwner;
	int FStartDay;
	int FStartMonth;
	int FPrevYearStartDay;
	int FPrevYearStartMonth;
	int FNextYearStartDay;
	int FNextYearStartMonth;
	Classes::TNotifyEvent FOnChange;
	bool FISOWeekNumber;
	void __fastcall SetStartDay(int d);
	void __fastcall SetStartMonth(int m);
	void __fastcall SetPrevYearStartDay(int d);

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -