📄 mxoutlookbarpro.~hpp
字号:
class DELPHICLASS TmxButtonImages;
typedef void __fastcall (__closure *TmxEventDrawHeader)(System::TObject* Sender, Graphics::TCanvas*
ACanvas, const Windows::TRect &ARect);
class PASCALIMPLEMENTATION TmxOutlookBarPro : public Controls::TCustomControl
{
typedef Controls::TCustomControl inherited;
private:
bool FAcceptedObject;
bool FLoaded;
bool FStopAlerting;
Graphics::TColor FAlertColor;
TmxButton* FAlertedButton;
Graphics::TColor FDropMarkColor;
TmxDropMode FLastDropMode;
TmxButton* FDraggedButton;
int FDragThreshold;
Windows::TPoint FDragStartPos;
TmxDragDropManager* FDragManager;
TmxOutlookBarStates FDragStates;
TmxButton* FLastVCLDragTarget;
TmxButton* FCurrentTargetButton;
TmxHeader* FCurrentTargetHeader;
unsigned FAutoScrollDelay;
unsigned FAutoButtonScrollDelay;
unsigned FAutoChangeDelay;
unsigned FAlertInterval;
TmxEventDragAllowed FOnDragAllowed;
TmxEventDragOver FOnDragOver;
TmxEventDragEnter FOnDragEnter;
TmxEventDragDrop FOnDragDrop;
bool FEachHeaderSelection;
int FOffset;
bool FScrollDown;
Windows::TRect FScrollUpRect;
TmxButtonState FScrollUpState;
Windows::TRect FScrollDownRect;
TmxButtonState FScrollDownState;
Windows::TRect FButtonScrollUpRect;
TmxButtonState FButtonScrollUpState;
Windows::TRect FButtonScrollDownRect;
TmxButtonState FButtonScrollDownState;
int FSavedHeaderIndex;
TmxHeader* FActiveHeader;
TmxBackground* FBackground;
Controls::TBevelCut FBevelInner;
Controls::TBevelCut FBevelOuter;
Controls::TBevelWidth FBevelWidth;
TmxBorder* FBorder;
Forms::TFormBorderStyle FBorderStyle;
bool FCommonStyle;
TmxCloseButton* FCloseButton;
TmxExplorerMethod FExplorerMethod;
bool FFlat;
TmxHeaders* FHeaders;
TmxHeaderImages* FHeaderImages;
TmxHeader* FMouseInHeader;
TmxHeader* FMouseInHeaderBody;
TmxButton* FMouseInButton;
bool FProcessing;
bool FPainting;
bool FReCalcHeaderPositions;
TmxHeaderScrollType FHeaderScrollType;
Byte FHeaderScrollValue;
Byte FHeaderScrollAcceleration;
int FSequence;
TmxBarSettings* FSettings;
Word FScrollChange;
TmxBarOptions FOptions;
bool FUpdating;
int FUpdateCounter;
int FUpdatedHeaderIndex;
int FVersion;
TmxViewStyle FViewStyle;
TmxInplaceEditor* FEditor;
bool FReadyToPaint;
TmxScrollView FScrollView;
Word FScrollBoxSize;
TmxPreSet FPreSet;
Controls::TContextPopupEvent FOnContextPopup;
Controls::TContextPopupEvent FOnEditorContextPopup;
TmxEventHeaderChange FOnChange;
TmxEventCanChangeHeader FOnCanChange;
TmxEventChangeViewStyle FOnChangeViewStyle;
TmxEventDrawHeaderButtons FOnDrawHeaderButtons;
TmxEventDrawHeaderButtons FOnAfterDrawHeaderButtons;
Classes::TNotifyEvent FOnHide;
Classes::TNotifyEvent FOnShow;
TmxEventDrawButton FOnDrawCloseButton;
TmxEventAfterChangeStyle FOnAfterChangeStyle;
MESSAGE void __fastcall WMTimer(Messages::TWMTimer &Message);
HIDESBASE MESSAGE void __fastcall WMLButtonDown(Messages::TWMMouse &Message);
HIDESBASE MESSAGE void __fastcall WMLButtonUp(Messages::TWMMouse &Message);
HIDESBASE MESSAGE void __fastcall WMNCDestroy(Messages::TWMNoParams &Message);
HIDESBASE MESSAGE void __fastcall WMSize(Messages::TWMSize &Message);
HIDESBASE MESSAGE void __fastcall CMDesignHitTest(Messages::TWMMouse &Msg);
HIDESBASE MESSAGE void __fastcall WMSetFocus(Messages::TWMSetFocus &Message);
HIDESBASE MESSAGE void __fastcall WMKillFocus(Messages::TWMSetFocus &Message);
HIDESBASE MESSAGE void __fastcall CMBorderChanged(Messages::TMessage &Message);
HIDESBASE MESSAGE void __fastcall CMCtl3DChanged(Messages::TMessage &Message);
HIDESBASE MESSAGE void __fastcall CMSysColorChange(Messages::TMessage &Message);
HIDESBASE MESSAGE void __fastcall CMColorChanged(Messages::TMessage &Message);
HIDESBASE MESSAGE void __fastcall CMEnabledChanged(Messages::TMessage &Message);
HIDESBASE MESSAGE void __fastcall CMFontChanged(Messages::TMessage &Msg);
MESSAGE void __fastcall CMTextChanged(Messages::TMessage &Msg);
HIDESBASE MESSAGE void __fastcall CMVisibleChanged(Messages::TMessage &Message);
HIDESBASE MESSAGE void __fastcall CMDialogChar(Messages::TWMKey &Message);
MESSAGE void __fastcall CNNotify(Messages::TWMNotify &Message);
HIDESBASE MESSAGE void __fastcall CMHintShow(Messages::TMessage &Message);
HIDESBASE MESSAGE void __fastcall CMDrag(Controls::TCMDrag &Message);
HIDESBASE MESSAGE void __fastcall CMMouseWheel(Controls::TCMMouseWheel &Message);
HIDESBASE MESSAGE void __fastcall WMContextMenu(Messages::TWMContextMenu &Message);
void __fastcall SetBorderStyle(Forms::TBorderStyle AValue);
void __fastcall SetBevelInner(Controls::TBevelCut AValue);
void __fastcall SetBevelOuter(Controls::TBevelCut AValue);
HIDESBASE void __fastcall SetBevelWidth(Controls::TBevelWidth AValue);
void __fastcall SetScrollView(TmxScrollView AValue);
int __fastcall GetHeaderCount(void);
int __fastcall GetVisibleHeaderCount(void);
int __fastcall GetEnabledHeaderCount(void);
void __fastcall SetCommonStyle(bool AValue);
void __fastcall SetViewStyle(TmxViewStyle AValue);
void __fastcall SetFlat(bool AValue);
void __fastcall SetHeaderScrollType(TmxHeaderScrollType AValue);
void __fastcall SetHeaderScrollValue(Byte AValue);
void __fastcall SetHeaderScrollAcceleration(Byte AValue);
void __fastcall SetVersion(AnsiString AValue);
AnsiString __fastcall GetVersion(void);
int __fastcall GetNextVisibleIndex(int ActiveIndex);
int __fastcall GetActiveHeaderIndex(void);
void __fastcall CheckImages(TmxButtonImages* AImages, Classes::TComponent* AComponent, Classes::TOperation
Operation);
void __fastcall CheckHeaderImages(TmxHeaderImages* AImages, Classes::TComponent* AComponent, Classes::TOperation
Operation);
void __fastcall PropertyChanged(System::TObject* Sender);
void __fastcall ReadAlign(Classes::TReader* Reader);
void __fastcall WriteAlign(Classes::TWriter* Writer);
void __fastcall ReadIndex(Classes::TReader* Reader);
void __fastcall WriteIndex(Classes::TWriter* Writer);
TmxEventDrawHeader __fastcall GetOnDrawCloseHeader(void);
void __fastcall SetOnDrawCloseHeader(TmxEventDrawHeader AValue);
TmxEventDrawHeader __fastcall GetOnAfterDrawCloseHeader(void);
void __fastcall SetOnAfterDrawCloseHeader(TmxEventDrawHeader AValue);
Classes::TNotifyEvent __fastcall GetOnClose(void);
void __fastcall SetOnClose(Classes::TNotifyEvent AValue);
void __fastcall SetExplorerMethod(TmxExplorerMethod AValue);
void __fastcall SetHeaders(TmxHeaders* AValue);
TmxHeaders* __fastcall GetHeaders(void);
TmxHeader* __fastcall GetHeader(int Index);
void __fastcall SetOptions(TmxBarOptions AValue);
void __fastcall SetScrollChange(Word AValue);
void __fastcall DoScrollUp(void);
void __fastcall DoScrollDown(void);
void __fastcall SetInplaceEditor(TmxInplaceEditor* AValue);
void __fastcall SetActiveHeader(TmxHeader* ANewHeader);
void __fastcall SetScrollBoxSize(Word AValue);
HIDESBASE void __fastcall SetBorderWidth(Controls::TBorderWidth AValue);
Controls::TBorderWidth __fastcall GetBorderWidth(void);
void __fastcall SetPreSet(TmxPreSet AValue);
void __fastcall SetEachHeaderSelection(bool AValue);
bool __fastcall ProcessOLEData(TmxOutlookBarPro* Source, _di_IDataObject DataObject, TmxButton* TargetButton
, TmxHitPosition HitMode, int &Effect);
void __fastcall SetAlertedButton(TmxButton* AButton);
void __fastcall SetAlertInterval(unsigned AValue);
bool __fastcall GetDragging(void);
virtual HRESULT __fastcall DoDragEnter(const _di_IDataObject DataObject, int KeyState, const Windows::TPoint
&Pt, int &Effect);
virtual HRESULT __fastcall DoDragOver(System::TObject* Source, int KeyState, Controls::TDragState DragState
, const Windows::TPoint &Pt, int &Effect);
virtual HRESULT __fastcall DoDragDrop(const _di_IDataObject DataObject, int KeyState, const Windows::TPoint
&Pt, int &Effect);
void __fastcall DoDragging(const Windows::TPoint &P);
virtual void __fastcall DoDragLeave(void);
virtual int __fastcall SuggestDropEffect(System::TObject* Source, Classes::TShiftState Shift, const
Windows::TPoint &Pt, int AllowedEffects);
TmxButton* __fastcall GetHitTestInfoAt(int X, int Y, TmxHitPosition &HitInfo);
void __fastcall StopTimer(int ID);
virtual Windows::TRect __fastcall InvalidateButton(TmxButton* Button);
void __fastcall FinishButtonHeader(Classes::TStream* Stream, int StartPos, int EndPos);
virtual void __fastcall WriteButton(Classes::TStream* Stream, TmxButton* AButton);
void __fastcall WriteButtonToStream(Classes::TStream* Stream, TmxButton* AButton);
TmxButton* __fastcall GetButtonAt(int X, int Y);
TmxHeader* __fastcall GetHeaderAt(int X, int Y);
TmxButton* __fastcall GetButtonExactlyAt(int X, int Y);
TmxHeader* __fastcall GetHeaderButtonAt(int X, int Y);
HIDESBASE void __fastcall BeginDrag(bool Immediate, int Threshold);
void __fastcall HandleMouseDown(Messages::TWMMouse &Message);
void __fastcall HandleMouseUp(Messages::TWMMouse &Message);
virtual void __fastcall DoPaintDropMark(Graphics::TCanvas* Canvas, const Windows::TRect &R, TmxHitPosition
DragDropHitStatus);
virtual void __fastcall DoAutoScroll(int X, int Y);
void __fastcall DoInvalidate(void);
void __fastcall ProcessMouseLeave(void);
void __fastcall EditorContext(System::TObject* Sender, const Windows::TPoint &MousePos, bool &Handled
);
void __fastcall ConfigureOfficeBackground(TmxHeader* Header);
void __fastcall ConfigureNormalBackground(Graphics::TColor BackColor, int FirstTop, TmxHeader* Header
);
void __fastcall ConfigureExplorerBackground(Graphics::TColor BackColor, int FirstTop, bool DrawBorder
, TmxHeader* Header);
void __fastcall SetPresetHeader(TmxHeader* AHeader);
protected:
DYNAMIC void __fastcall DoMyContextPopup(System::TObject* Sender, const Windows::TPoint &MousePos,
bool &Handled);
virtual void __fastcall AdjustClientRect(Windows::TRect &Rect);
virtual void __fastcall CreateParams(Controls::TCreateParams &Params);
DYNAMIC void __fastcall Change(void);
virtual void __fastcall DefineProperties(Classes::TFiler* Filer);
DYNAMIC void __fastcall KeyDown(Word &Key, Classes::TShiftState Shift);
virtual void __fastcall Notification(Classes::TComponent* AComponent, Classes::TOperation Operation
);
DYNAMIC void __fastcall MouseMove(Classes::TShiftState Shift, int X, int Y);
DYNAMIC void __fastcall MouseDown(Controls::TMouseButton Button, Classes::TShiftState Shift, int X,
int Y);
DYNAMIC void __fastcall MouseUp(Controls::TMouseButton Button, Classes::TShiftState Shift, int X, int
Y);
virtual void __fastcall Paint(void);
HIDESBASE MESSAGE void __fastcall WMEraseBkgnd(Messages::TWMEraseBkgnd &Message);
HIDESBASE MESSAGE void __fastcall CMMouseEnter(Messages::TMessage &Message);
HIDESBASE MESSAGE void __fastcall CMMouseLeave(Messages::TMessage &Message);
virtual void __fastcall Loaded(void);
virtual void __fastcall CreateWnd(void);
virtual void __fastcall DoChange(int OldIndex, int NewIndex);
virtual void __fastcall DoCanChange(TmxHeader* NewHeader, bool &CanChange);
virtual bool __fastcall DoChangeViewStyle(System::TObject* Sender, TmxViewStyle OldStyle, TmxViewStyle
NewStyle);
virtual void __fastcall DoDrawHeaderButtons(Graphics::TCanvas* ACanvas, const Windows::TRect &ARect
, int ActiveIndex);
virtual void __fastcall DoAfterDrawHeaderButtons(Graphics::TCanvas* ACanvas, const Windows::TRect &
ARect, int ActiveIndex);
virtual void __fastcall DoDrawCloseButton(Graphics::TCanvas* ACanvas, const Windows::TRect &ARect,
TmxButtonState State);
virtual void __fastcall DoShow(void);
virtual void __fastcall DoHide(void);
virtual void __fastcall DoClose(void);
virtual bool __fastcall DoBeforeDrag(TmxButton* AButton);
virtual void __fastcall WndProc(Messages::TMessage &Message);
public:
__property int ActiveHeaderIndex = {read=GetActiveHeaderIndex, nodefault};
__property TmxHeader* MouseInControl = {read=FMouseInHeader};
__property int HeaderCount = {read=GetHeaderCount, nodefault};
__property int VisibleHeaderCount = {read=GetVisibleHeaderCount, nodefault};
__property int EnabledHeaderCount = {read=GetEnabledHeaderCount, nodefault};
__fastcall virtual TmxOutlookBarPro(Classes::TComponent* AOwner);
__fastcall virtual ~TmxOutlookBarPro(void);
int __fastcall CreateHeader(void);
TmxHeader* __fastcall AddHeader(void);
void __fastcall RemoveHeader(TmxHeader* AHeader);
void __fastcall DeleteHeader(int AHeaderIndex);
void __fastcall ClearHeaders(void);
__property TmxHeader* Header[int Index] = {read=GetHeader};
TmxHeader* __fastcall HeaderByIndex(int Index);
TmxHeader* __fastcall HeaderByName(AnsiString Name);
int __fastcall HeaderIndexByName(AnsiString Name);
DYNAMIC bool __fastcall CanFocus(void);
virtual void __fastcall BeginUpdate(void);
virtual void __fastcall EndUpdate(void);
TmxHitType __fastcall GetItemAt(int X, int Y, int &HeaderIndex, int &ButtonIndex);
TmxHeader* __fastcall GetPrevHeader(TmxHeader* AHeader);
TmxHeader* __fastcall GetNextHeader(TmxHeader* AHeader);
void __fastcall CollapseAll(void);
void __fastcall ExpandAll(void);
void __fastcall RenameHeader(TmxHeader* AHeader);
void __fastcall RenameHeaderByIndex(int AHeaderIndex);
virtual void __fastcall LoadFromFile(const AnsiString FileName);
virtual void __fastcall LoadFromStream(Classes::TStream* Stream);
virtual void __fastcall SaveToFile(const AnsiString FileName);
virtual void __fastcall SaveToStream(Classes::TStream* Stream);
__property bool Dragging = {read=GetDragging, nodefault};
bool __fastcall ProcessOuterDrop(_di_IDataObject DataObject, TmxButton* NewButton, TmxButton* TargetButton
, int &Effect, TmxHitPosition HitMode);
bool __fastcall ProcessDrop(_di_IDataObject DataObject, TmxButton* TargetButton, int &Effect, TmxHitPosition
HitMode);
__property TmxButton* CurrentTargetButton = {read=FCurrentTargetButton};
__property TmxHeader* CurrentTargetHeader = {read=FCurrentTargetHeader};
__published:
__property Graphics::TColor AlertColor = {read=FAlertColor, write=FAlertColor, default=255};
__property TmxHeader* ActiveHeader = {read=FActiveHeader, write=SetActiveHeader, stored=false};
__property unsigned AutoButtonScrollDelay = {read=FAutoButtonScrollDelay, write=FAutoButtonScrollDelay
, default=600};
__property unsigned AutoScrollDelay = {read=FAutoScrollDelay, write=FAutoScrollDelay, default=500};
__property unsigned AutoChangeDelay = {read=FAutoChangeDelay, write=FAutoChangeDelay, default=100};
__property unsigned AlertInterval = {read=FAlertInterval, write=SetAlertInterval, default=500};
__property TmxBackground* Background = {read=FBackground, write=FBackground};
__property Controls::TBevelCut BevelInner = {read=FBevelInner, write=SetBevelInner, default=0};
__property Controls::TBevelCut BevelOuter = {read=FBevelOuter, write=SetBevelOuter, default=2};
__property Controls::TBevelWidth BevelWidth = {read=FBevelWidth, write=SetBevelWidth, default=1};
__property TmxBorder* Border = {read=FBorder, write=FBorder};
__property Forms::TBorderStyle BorderStyle = {read=FBorderStyle, write=SetBorderStyle, default=0};
__property bool CommonStyle = {read=FCommonStyle, write=SetCommonStyle, nodefault};
__property TmxCloseButton* CloseButton = {read=FCloseButton, write=FCloseButton};
__property Graphics::TColor DropMarkColor = {read=FDropMarkColor, write=FDropMarkColor, default=0};
__property bool EachHeaderSelection = {read=FEachHeaderSelection, write=SetEachHeaderSelection, default=0
};
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -