home *** CD-ROM | disk | FTP | other *** search
/ DOS/V Power Report 1997 May / VPR9705A.ISO / VPR_DATA / PROGRAM / CBTRIAL / SETUP / DATA.Z / FORMS.HPP < prev    next >
C/C++ Source or Header  |  1997-02-14  |  36KB  |  826 lines

  1. //----------------------------------------------------------------------------
  2. // Forms.hpp - bcbdcc32 generated hdr (DO NOT EDIT) rev: 0
  3. // From: Forms.pas
  4. //----------------------------------------------------------------------------
  5. #ifndef FormsHPP
  6. #define FormsHPP
  7. //----------------------------------------------------------------------------
  8. #include <Controls.hpp>
  9. #include <Menus.hpp>
  10. #include <Graphics.hpp>
  11. #include <Classes.hpp>
  12. #include <SysUtils.hpp>
  13. #include <Windows.hpp>
  14. #include <Messages.hpp>
  15. #include <System.hpp>
  16. #pragma warn -par
  17. #pragma warn -hid 
  18. #pragma warn -inl
  19.  
  20. namespace Forms
  21. {
  22. //-- type declarations -------------------------------------------------------
  23. enum TScrollBarKind { sbHorizontal, sbVertical };
  24.  
  25. typedef Word TScrollBarInc;
  26.  
  27. class __declspec(delphiclass) TControlScrollBar;
  28. class __declspec(delphiclass) TScrollingWinControl;
  29. class __declspec(pascalimplementation) TScrollingWinControl : public Controls::TWinControl
  30. {
  31.     typedef Controls::TWinControl inherited;
  32.     
  33. private:
  34.     TControlScrollBar* FHorzScrollBar;
  35.     TControlScrollBar* FVertScrollBar;
  36.     bool FAutoScroll;
  37.     bool FSizing;
  38.     bool FUpdatingScrollBars;
  39.     Byte FReserved;
  40.     void __fastcall CalcAutoRange(void);
  41.     void __fastcall ScaleScrollBars(int M, int D);
  42.     void __fastcall SetAutoScroll(bool Value);
  43.     void __fastcall SetHorzScrollBar(TControlScrollBar* Value);
  44.     void __fastcall SetVertScrollBar(TControlScrollBar* Value);
  45.     void __fastcall UpdateScrollBars(void);
  46.     HIDESBASE MESSAGE void __fastcall WMSize(Messages::TWMSize &Message);
  47.     HIDESBASE MESSAGE void __fastcall WMHScroll(Messages::TWMScroll &Message);
  48.     HIDESBASE MESSAGE void __fastcall WMVScroll(Messages::TWMScroll &Message);
  49.     
  50. protected:
  51.     void __fastcall AutoScrollInView(Controls::TControl* AControl);
  52.     virtual void __fastcall ChangeScale(int M, int D);
  53.     virtual void __fastcall CreateWnd(void);
  54.     virtual void __fastcall AlignControls(Controls::TControl* AControl, Windows::TRect &ARect);
  55.     __property bool AutoScroll = {read=FAutoScroll, write=SetAutoScroll, default=1};
  56.     
  57. public:
  58.     __fastcall virtual TScrollingWinControl(Classes::TComponent* AOwner);
  59.     __fastcall virtual ~TScrollingWinControl(void);
  60.     void __fastcall ScrollInView(Controls::TControl* AControl);
  61.     
  62. __published:
  63.     __property TControlScrollBar* HorzScrollBar = {read=FHorzScrollBar, write=SetHorzScrollBar, nodefault
  64.         };
  65.     __property TControlScrollBar* VertScrollBar = {read=FVertScrollBar, write=SetVertScrollBar, nodefault
  66.         };
  67. public:
  68.     /* TWinControl.CreateParented */ __fastcall TScrollingWinControl(HWND ParentWindow) : Controls::TWinControl(
  69.         ParentWindow) { }
  70.     
  71. };
  72.  
  73. class __declspec(pascalimplementation) TControlScrollBar : public Classes::TPersistent
  74. {
  75.     typedef Classes::TPersistent inherited;
  76.     
  77. private:
  78.     TScrollingWinControl* FControl;
  79.     TScrollBarInc FIncrement;
  80.     int FPosition;
  81.     int FRange;
  82.     int FCalcRange;
  83.     TScrollBarKind FKind;
  84.     Word FMargin;
  85.     bool FVisible;
  86.     bool FTracking;
  87.     bool FScaled;
  88.     __fastcall TControlScrollBar(TScrollingWinControl* AControl, TScrollBarKind AKind);
  89.     void __fastcall CalcAutoRange(void);
  90.     int __fastcall ControlSize(bool ControlSB, bool AssumeSB);
  91.     void __fastcall DoSetRange(int Value);
  92.     int __fastcall GetScrollPos(void);
  93.     bool __fastcall NeedsScrollBarVisible(void);
  94.     void __fastcall ScrollMessage(Messages::TWMScroll &Msg);
  95.     void __fastcall SetPosition(int Value);
  96.     void __fastcall SetRange(int Value);
  97.     void __fastcall SetVisible(bool Value);
  98.     bool __fastcall IsRangeStored(void);
  99.     void __fastcall Update(bool ControlSB, bool AssumeSB);
  100.     
  101. public:
  102.     virtual void __fastcall Assign(Classes::TPersistent* Source);
  103.     __property TScrollBarKind Kind = {read=FKind, nodefault};
  104.     __property int ScrollPos = {read=GetScrollPos, nodefault};
  105.     
  106. __published:
  107.     __property Word Margin = {read=FMargin, write=FMargin, default=0};
  108.     __property TScrollBarInc Increment = {read=FIncrement, write=FIncrement, default=8};
  109.     __property int Range = {read=FRange, write=SetRange, stored=IsRangeStored, default=0};
  110.     __property int Position = {read=FPosition, write=SetPosition, default=0};
  111.     __property bool Tracking = {read=FTracking, write=FTracking, default=0};
  112.     __property bool Visible = {read=FVisible, write=SetVisible, default=1};
  113. public:
  114.     /* TObject.Create */ __fastcall TControlScrollBar(void) : Classes::TPersistent() { }
  115.     /* TObject.Destroy */ __fastcall virtual ~TControlScrollBar(void) { }
  116.     
  117. };
  118.  
  119. enum TFormBorderStyle { bsNone, bsSingle, bsSizeable, bsDialog, bsToolWindow, bsSizeToolWin };
  120.  
  121. typedef TFormBorderStyle TBorderStyle;
  122.  
  123. class __declspec(delphiclass) TScrollBox;
  124. class __declspec(pascalimplementation) TScrollBox : public TScrollingWinControl
  125. {
  126.     typedef TScrollingWinControl inherited;
  127.     
  128. private:
  129.     TFormBorderStyle FBorderStyle;
  130.     Byte FReserved;
  131.     Classes::TNotifyEvent FOnResize;
  132.     void __fastcall SetBorderStyle(TBorderStyle Value);
  133.     HIDESBASE MESSAGE void __fastcall WMSize(Messages::TWMSize &Message);
  134.     HIDESBASE MESSAGE void __fastcall WMNCHitTest(Messages::TMessage &Message);
  135.     HIDESBASE MESSAGE void __fastcall CMCtl3DChanged(Messages::TMessage &Message);
  136.     
  137. protected:
  138.     virtual void __fastcall CreateParams(Controls::TCreateParams &Params);
  139.     virtual void __fastcall Resize(void);
  140.     
  141. public:
  142.     __fastcall virtual TScrollBox(Classes::TComponent* AOwner);
  143.     
  144. __published:
  145.     __property Align ;
  146.     __property AutoScroll ;
  147.     __property TBorderStyle BorderStyle = {read=FBorderStyle, write=SetBorderStyle, default=1};
  148.     __property DragCursor ;
  149.     __property DragMode ;
  150.     __property Enabled ;
  151.     __property Color ;
  152.     __property Ctl3D ;
  153.     __property Font ;
  154.     __property ParentColor ;
  155.     __property ParentCtl3D ;
  156.     __property ParentFont ;
  157.     __property ParentShowHint ;
  158.     __property PopupMenu ;
  159.     __property ShowHint ;
  160.     __property TabOrder ;
  161.     __property TabStop ;
  162.     __property Visible ;
  163.     __property OnClick ;
  164.     __property OnDblClick ;
  165.     __property OnDragDrop ;
  166.     __property OnDragOver ;
  167.     __property OnEndDrag ;
  168.     __property OnEnter ;
  169.     __property OnExit ;
  170.     __property OnMouseDown ;
  171.     __property OnMouseMove ;
  172.     __property OnMouseUp ;
  173.     __property Classes::TNotifyEvent OnResize = {read=FOnResize, write=FOnResize};
  174. public:
  175.     /* TScrollingWinControl.Destroy */ __fastcall virtual ~TScrollBox(void) { }
  176.     
  177. public:
  178.     /* TWinControl.CreateParented */ __fastcall TScrollBox(HWND ParentWindow) : Forms::TScrollingWinControl(
  179.         ParentWindow) { }
  180.     
  181. };
  182.  
  183. class __declspec(delphiclass) TDesigner;
  184. class __declspec(delphiclass) TForm;
  185. enum TBorderIcon { biSystemMenu, biMinimize, biMaximize, biHelp };
  186.  
  187. typedef Set<TBorderIcon, biSystemMenu, biHelp>  TBorderIcons;
  188.  
  189. enum TWindowState { wsNormal, wsMinimized, wsMaximized };
  190.  
  191. enum TShowAction { saIgnore, saRestore, saMinimize, saMaximize };
  192.  
  193. enum TFormStyle { fsNormal, fsMDIChild, fsMDIForm, fsStayOnTop };
  194.  
  195. enum TPosition { poDesigned, poDefault, poDefaultPosOnly, poDefaultSizeOnly, poScreenCenter };
  196.  
  197. enum TTileMode { tbHorizontal, tbVertical };
  198.  
  199. enum Forms_6 { fsCreating, fsVisible, fsShowing, fsModal, fsCreatedMDIChild };
  200.  
  201. typedef Set<Forms_6, fsCreating, fsCreatedMDIChild>  TFormState;
  202.  
  203. enum TPrintScale { poNone, poProportional, poPrintToFit };
  204.  
  205. typedef int TModalResult;
  206.  
  207. class __declspec(delphiclass) TOleFormObject;
  208. class __declspec(pascalimplementation) TOleFormObject : public System::TObject
  209. {
  210.     typedef System::TObject inherited;
  211.     
  212. protected:
  213.     virtual void __fastcall OnDestroy(void) = 0;
  214.     virtual void __fastcall OnResize(void) = 0;
  215. public:
  216.     /* TObject.Create */ __fastcall TOleFormObject(void) : System::TObject() { }
  217.     /* TObject.Destroy */ __fastcall virtual ~TOleFormObject(void) { }
  218.     
  219. };
  220.  
  221. enum TCloseAction { caNone, caHide, caFree, caMinimize };
  222.  
  223. typedef void __fastcall (__closure *TCloseEvent)(System::TObject* Sender, TCloseAction &Action);
  224.  
  225. typedef void __fastcall (__closure *TCloseQueryEvent)(System::TObject* Sender, bool &CanClose);
  226.  
  227. class __declspec(pascalimplementation) TForm : public TScrollingWinControl
  228. {
  229.     typedef TScrollingWinControl inherited;
  230.     
  231. private:
  232.     Controls::TWinControl* FActiveControl;
  233.     Controls::TWinControl* FFocusedControl;
  234.     TBorderIcons FBorderIcons;
  235.     TFormBorderStyle FBorderStyle;
  236.     TWindowState FWindowState;
  237.     TShowAction FShowAction;
  238.     bool FKeyPreview;
  239.     bool FActive;
  240.     bool FIgnoreFontProperty;
  241.     TFormStyle FFormStyle;
  242.     TPosition FPosition;
  243.     TTileMode FTileMode;
  244.     TFormState FFormState;
  245.     bool FDropTarget;
  246.     TPrintScale FPrintScale;
  247.     Controls::TControlCanvas* FCanvas;
  248.     Graphics::TIcon* FIcon;
  249.     Menus::TMainMenu* FMenu;
  250.     TModalResult FModalResult;
  251.     TDesigner* FDesigner;
  252.     HWND FClientHandle;
  253.     Menus::TMenuItem* FWindowMenu;
  254.     int FPixelsPerInch;
  255.     Menus::TMenuItem* FObjectMenuItem;
  256.     TOleFormObject* FOleFormObject;
  257.     int FClientWidth;
  258.     int FClientHeight;
  259.     int FTextHeight;
  260.     void *FDefClientProc;
  261.     void *FClientInstance;
  262.     Controls::TWinControl* FActiveOleControl;
  263.     Classes::TNotifyEvent FOnActivate;
  264.     TCloseEvent FOnClose;
  265.     TCloseQueryEvent FOnCloseQuery;
  266.     Classes::TNotifyEvent FOnDeactivate;
  267.     Classes::TNotifyEvent FOnHide;
  268.     Classes::TNotifyEvent FOnPaint;
  269.     Classes::TNotifyEvent FOnResize;
  270.     Classes::TNotifyEvent FOnShow;
  271.     Classes::TNotifyEvent FOnCreate;
  272.     Classes::TNotifyEvent FOnDestroy;
  273.     virtual void __fastcall AlignControls(Controls::TControl* AControl, Windows::TRect &Rect);
  274.     void __fastcall RefreshMDIMenu(void);
  275.     void __fastcall ClientWndProc(Messages::TMessage &Message);
  276.     void __fastcall CloseModal(void);
  277.     TForm* __fastcall GetActiveMDIChild(void);
  278.     Graphics::TCanvas* __fastcall GetCanvas(void);
  279.     HICON __fastcall GetIconHandle(void);
  280.     int __fastcall GetMDIChildCount(void);
  281.     TForm* __fastcall GetMDIChildren(int I);
  282.     int __fastcall GetPixelsPerInch(void);
  283.     bool __fastcall GetScaled(void);
  284.     int __fastcall GetTextHeight(void);
  285.     void __fastcall IconChanged(System::TObject* Sender);
  286.     bool __fastcall IsAutoScrollStored(void);
  287.     bool __fastcall IsClientSizeStored(void);
  288.     HIDESBASE bool __fastcall IsColorStored(void);
  289.     bool __fastcall IsForm(void);
  290.     bool __fastcall IsFormSizeStored(void);
  291.     bool __fastcall IsIconStored(void);
  292.     void __fastcall MergeMenu(bool MergeState);
  293.     void __fastcall ReadTextHeight(Classes::TReader* Reader);
  294.     void __fastcall SetActive(bool Value);
  295.     void __fastcall SetActiveControl(Controls::TWinControl* Control);
  296.     void __fastcall SetBorderIcons(TBorderIcons Value);
  297.     void __fastcall SetBorderStyle(TFormBorderStyle Value);
  298.     HIDESBASE void __fastcall SetClientHeight(int Value);
  299.     HIDESBASE void __fastcall SetClientWidth(int Value);
  300.     void __fastcall SetDesigner(TDesigner* ADesigner);
  301.     void __fastcall SetFormStyle(TFormStyle Value);
  302.     void __fastcall SetIcon(Graphics::TIcon* Value);
  303.     void __fastcall SetMenu(Menus::TMainMenu* Value);
  304.     void __fastcall SetPixelsPerInch(int Value);
  305.     void __fastcall SetPosition(TPosition Value);
  306.     void __fastcall SetScaled(bool Value);
  307.     HIDESBASE void __fastcall SetVisible(bool Value);
  308.     void __fastcall SetWindowFocus(void);
  309.     void __fastcall SetWindowMenu(Menus::TMenuItem* Value);
  310.     void __fastcall SetObjectMenuItem(Menus::TMenuItem* Value);
  311.     void __fastcall SetWindowState(TWindowState Value);
  312.     void __fastcall WritePixelsPerInch(Classes::TWriter* Writer);
  313.     void __fastcall WriteTextHeight(Classes::TWriter* Writer);
  314.     Graphics::TColor __fastcall NormalColor(void);
  315.     HIDESBASE MESSAGE void __fastcall WMPaint(Messages::TWMPaint &Message);
  316.     HIDESBASE MESSAGE void __fastcall WMEraseBkgnd(Messages::TWMEraseBkgnd &Message);
  317.     MESSAGE void __fastcall WMIconEraseBkgnd(Messages::TWMEraseBkgnd &Message);
  318.     MESSAGE void __fastcall WMQueryDragIcon(Messages::TWMNoParams &Message);
  319.     MESSAGE void __fastcall WMNCCreate(Messages::TWMNCCreate &Message);
  320.     HIDESBASE MESSAGE void __fastcall WMDestroy(Messages::TWMNoParams &Message);
  321.     HIDESBASE MESSAGE void __fastcall WMCommand(Messages::TWMCommand &Message);
  322.     MESSAGE void __fastcall WMInitMenuPopup(Messages::TWMInitMenuPopup &Message);
  323.     MESSAGE void __fastcall WMMenuSelect(Messages::TWMMenuSelect &Message);
  324.     MESSAGE void __fastcall WMActivate(Messages::TWMActivate &Message);
  325.     HIDESBASE MESSAGE void __fastcall WMSize(Messages::TWMSize &Message);
  326.     MESSAGE void __fastcall WMClose(Messages::TWMNoParams &Message);
  327.     MESSAGE void __fastcall WMQueryEndSession(Messages::TWMQueryEndSession &Message);
  328.     HIDESBASE MESSAGE void __fastcall WMSysCommand(Messages::TWMSysCommand &Message);
  329.     MESSAGE void __fastcall WMShowWindow(Messages::TWMShowWindow &Message);
  330.     MESSAGE void __fastcall WMMDIActivate(Messages::TWMMDIActivate &Message);
  331.     MESSAGE void __fastcall WMNextDlgCtl(Messages::TWMNextDlgCtl &Message);
  332.     MESSAGE void __fastcall WMEnterMenuLoop(Messages::TMessage &Message);
  333.     MESSAGE void __fastcall WMHelp(Messages::TWMHelp &Message);
  334.     MESSAGE void __fastcall CMActivate(Messages::TWMNoParams &Message);
  335.     MESSAGE void __fastcall CMAppSysCommand(Messages::TMessage &Message);
  336.     MESSAGE void __fastcall CMDeactivate(Messages::TWMNoParams &Message);
  337.     HIDESBASE MESSAGE void __fastcall CMDialogKey(Messages::TWMKey &Message);
  338.     HIDESBASE MESSAGE void __fastcall CMColorChanged(Messages::TMessage &Message);
  339.     HIDESBASE MESSAGE void __fastcall CMCtl3DChanged(Messages::TMessage &Message);
  340.     HIDESBASE MESSAGE void __fastcall CMFontChanged(Messages::TMessage &Message);
  341.     MESSAGE void __fastcall CMMenuChanged(Messages::TMessage &Message);
  342.     HIDESBASE MESSAGE void __fastcall CMShowingChanged(Messages::TMessage &Message);
  343.     MESSAGE void __fastcall CMIconChanged(Messages::TMessage &Message);
  344.     MESSAGE void __fastcall CMRelease(Messages::TMessage &Message);
  345.     MESSAGE void __fastcall CMTextChanged(Messages::TMessage &Message);
  346.     MESSAGE void __fastcall CMUIActivate(void *Message);
  347.     
  348. protected:
  349.     virtual void __fastcall Activate(void);
  350.     virtual void __fastcall ActiveChanged(void);
  351.     virtual void __fastcall ChangeScale(int M, int D);
  352.     virtual void __fastcall CreateParams(Controls::TCreateParams &Params);
  353.     virtual void __fastcall CreateWindowHandle(const Controls::TCreateParams &Params);
  354.     virtual void __fastcall CreateWnd(void);
  355.     virtual void __fastcall Deactivate(void);
  356.     virtual void __fastcall DefaultHandler(void *Message);
  357.     virtual void __fastcall DefineProperties(Classes::TFiler* Filer);
  358.     virtual void __fastcall DestroyWindowHandle(void);
  359.     virtual void __fastcall DoHide(void);
  360.     virtual void __fastcall DoShow(void);
  361.     virtual Windows::TRect __fastcall GetClientRect(void);
  362.     virtual void __fastcall GetChildren(Classes::TGetChildProc Proc);
  363.     virtual void __fastcall Notification(Classes::TComponent* AComponent, Classes::TOperation Operation
  364.         );
  365.     virtual void __fastcall Paint(void);
  366.     virtual void __fastcall PaintWindow(HDC DC);
  367.     virtual bool __fastcall PaletteChanged(bool Foreground);
  368.     virtual void __fastcall SetChildOrder(Classes::TComponent* Child, int Order);
  369.     virtual void __fastcall ReadState(Classes::TReader* Reader);
  370.     virtual void __fastcall Resize(void);
  371.     virtual void __fastcall SetParent(Controls::TWinControl* AParent);
  372.     virtual void __fastcall ValidateRename(Classes::TComponent* AComponent, const System::AnsiString CurName
  373.         , const System::AnsiString NewName);
  374.     virtual void __fastcall VisibleChanging(void);
  375.     virtual void __fastcall WndProc(Messages::TMessage &Message);
  376.     virtual void __fastcall AfterConstruction(void);
  377.     virtual void __fastcall BeforeDestruction(void);
  378.     
  379. public:
  380.     __fastcall virtual TForm(Classes::TComponent* AOwner);
  381.     __fastcall TForm(Classes::TComponent* AOwner, int Dummy);
  382.     __fastcall virtual ~TForm(void);
  383.     void __fastcall ArrangeIcons(void);
  384.     void __fastcall Cascade(void);
  385.     void __fastcall Close(void);
  386.     bool __fastcall CloseQuery(void);
  387.     void __fastcall DefocusControl(Controls::TWinControl* Control, bool Removing);
  388.     void __fastcall FocusControl(Controls::TWinControl* Control);
  389.     Graphics::TBitmap* __fastcall GetFormImage(void);
  390.     HIDESBASE void __fastcall Hide(void);
  391.     void __fastcall Next(void);
  392.     void __fastcall Previous(void);
  393.     void __fastcall Print(void);
  394.     void __fastcall Release(void);
  395.     HIDESBASE void __fastcall SendCancelMode(Controls::TControl* Sender);
  396.     virtual void __fastcall SetFocus(void);
  397.     bool __fastcall SetFocusedControl(Controls::TWinControl* Control);
  398.     HIDESBASE void __fastcall Show(void);
  399.     int __fastcall ShowModal(void);
  400.     void __fastcall Tile(void);
  401.     __property bool Active = {read=FActive, nodefault};
  402.     __property TForm* ActiveMDIChild = {read=GetActiveMDIChild, nodefault};
  403.     __property Controls::TWinControl* ActiveOleControl = {read=FActiveOleControl, write=FActiveOleControl
  404.         , nodefault};
  405.     __property Graphics::TCanvas* Canvas = {read=GetCanvas, nodefault};
  406.     __property HWND ClientHandle = {read=FClientHandle, nodefault};
  407.     __property TDesigner* Designer = {read=FDesigner, write=SetDesigner, nodefault};
  408.     __property bool DropTarget = {read=FDropTarget, write=FDropTarget, nodefault};
  409.     __property bool IgnoreFontProperty = {read=FIgnoreFontProperty, write=FIgnoreFontProperty, nodefault
  410.         };
  411.     __property TModalResult ModalResult = {read=FModalResult, write=FModalResult, nodefault};
  412.     __property int MDIChildCount = {read=GetMDIChildCount, nodefault};
  413.     __property TForm* MDIChildren[int I] = {read=GetMDIChildren};
  414.     __property TOleFormObject* OleFormObject = {read=FOleFormObject, write=FOleFormObject, nodefault};
  415.     __property TTileMode TileMode = {read=FTileMode, write=FTileMode, default=0};
  416.     
  417. __published:
  418.     __property Controls::TWinControl* ActiveControl = {read=FActiveControl, write=SetActiveControl, stored=
  419.         IsForm, nodefault};
  420.     __property TBorderIcons BorderIcons = {read=FBorderIcons, write=SetBorderIcons, stored=IsForm, default=7
  421.         };
  422.     __property TFormBorderStyle BorderStyle = {read=FBorderStyle, write=SetBorderStyle, stored=IsForm, 
  423.         default=2};
  424.     __property AutoScroll  = {stored=IsAutoScrollStored, default=1};
  425.     __property Caption  = {stored=IsForm};
  426.     __property ClientHeight  = {write=SetClientHeight, stored=IsClientSizeStored};
  427.     __property ClientWidth  = {write=SetClientWidth, stored=IsClientSizeStored};
  428.     __property Ctl3D ;
  429.     __property Color  = {stored=IsColorStored, default=-2147483643};
  430.     __property Enabled ;
  431.     __property Font ;
  432.     __property TFormStyle FormStyle = {read=FFormStyle, write=SetFormStyle, stored=IsForm, default=0};
  433.     __property Height  = {stored=IsFormSizeStored};
  434.     __property HorzScrollBar  = {stored=IsForm};
  435.     __property Graphics::TIcon* Icon = {read=FIcon, write=SetIcon, stored=IsIconStored, nodefault};
  436.     __property bool KeyPreview = {read=FKeyPreview, write=FKeyPreview, stored=IsForm, default=0};
  437.     __property Menus::TMainMenu* Menu = {read=FMenu, write=SetMenu, stored=IsForm, nodefault};
  438.     __property Menus::TMenuItem* ObjectMenuItem = {read=FObjectMenuItem, write=SetObjectMenuItem, stored=
  439.         IsForm, nodefault};
  440.     __property int PixelsPerInch = {read=GetPixelsPerInch, write=SetPixelsPerInch, stored=false, nodefault
  441.         };
  442.     __property PopupMenu  = {stored=IsForm};
  443.     __property TPosition Position = {read=FPosition, write=SetPosition, stored=IsForm, default=0};
  444.     __property TPrintScale PrintScale = {read=FPrintScale, write=FPrintScale, stored=IsForm, default=1}
  445.         ;
  446.     __property bool Scaled = {read=GetScaled, write=SetScaled, stored=IsForm, default=1};
  447.     __property ShowHint ;
  448.     __property VertScrollBar  = {stored=IsForm};
  449.     __property Visible  = {write=SetVisible, default=0};
  450.     __property Width  = {stored=IsFormSizeStored};
  451.     __property TWindowState WindowState = {read=FWindowState, write=SetWindowState, stored=IsForm, default=0
  452.         };
  453.     __property Menus::TMenuItem* WindowMenu = {read=FWindowMenu, write=SetWindowMenu, stored=IsForm, nodefault
  454.         };
  455.     __property Classes::TNotifyEvent OnActivate = {read=FOnActivate, write=FOnActivate, stored=IsForm};
  456.         
  457.     __property OnClick  = {stored=IsForm};
  458.     __property TCloseEvent OnClose = {read=FOnClose, write=FOnClose, stored=IsForm};
  459.     __property TCloseQueryEvent OnCloseQuery = {read=FOnCloseQuery, write=FOnCloseQuery, stored=IsForm}
  460.         ;
  461.     __property Classes::TNotifyEvent OnCreate = {read=FOnCreate, write=FOnCreate, stored=IsForm};
  462.     __property OnDblClick  = {stored=IsForm};
  463.     __property Classes::TNotifyEvent OnDestroy = {read=FOnDestroy, write=FOnDestroy, stored=IsForm};
  464.     __property Classes::TNotifyEvent OnDeactivate = {read=FOnDeactivate, write=FOnDeactivate, stored=IsForm
  465.         };
  466.     __property OnDragDrop  = {stored=IsForm};
  467.     __property OnDragOver  = {stored=IsForm};
  468.     __property Classes::TNotifyEvent OnHide = {read=FOnHide, write=FOnHide, stored=IsForm};
  469.     __property OnKeyDown  = {stored=IsForm};
  470.     __property OnKeyPress  = {stored=IsForm};
  471.     __property OnKeyUp  = {stored=IsForm};
  472.     __property OnMouseDown  = {stored=IsForm};
  473.     __property OnMouseMove  = {stored=IsForm};
  474.     __property OnMouseUp  = {stored=IsForm};
  475.     __property Classes::TNotifyEvent OnPaint = {read=FOnPaint, write=FOnPaint, stored=IsForm};
  476.     __property Classes::TNotifyEvent OnResize = {read=FOnResize, write=FOnResize, stored=IsForm};
  477.     __property Classes::TNotifyEvent OnShow = {read=FOnShow, write=FOnShow, stored=IsForm};
  478. public:
  479.     /* TWinControl.CreateParented */ __fastcall TForm(HWND ParentWindow) : Forms::TScrollingWinControl(
  480.         ParentWindow) { }
  481.     
  482. };
  483.  
  484. class __declspec(pascalimplementation) TDesigner : public System::TObject
  485. {
  486.     typedef System::TObject inherited;
  487.     
  488. private:
  489.     TForm* FForm;
  490.     bool __fastcall GetIsControl(void);
  491.     void __fastcall SetIsControl(bool Value);
  492.     
  493. public:
  494.     virtual bool __fastcall IsDesignMsg(Controls::TControl* Sender, Messages::TMessage &Message) = 0;
  495.     virtual void __fastcall Modified(void) = 0;
  496.     virtual void __fastcall Notification(Classes::TComponent* AComponent, Classes::TOperation Operation
  497.         ) = 0;
  498.     virtual void __fastcall PaintGrid(void) = 0;
  499.     virtual void __fastcall ValidateRename(Classes::TComponent* AComponent, const System::AnsiString CurName
  500.         , const System::AnsiString NewName) = 0;
  501.     __property bool IsControl = {read=GetIsControl, write=SetIsControl, nodefault};
  502.     __property TForm* Form = {read=FForm, write=FForm, nodefault};
  503. public:
  504.     /* TObject.Create */ __fastcall TDesigner(void) : System::TObject() { }
  505.     /* TObject.Destroy */ __fastcall virtual ~TDesigner(void) { }
  506.     
  507. };
  508.  
  509. typedef System::TMetaClass*TFormClass;
  510.  
  511. class __declspec(delphiclass) TDataModule;
  512. class __declspec(pascalimplementation) TDataModule : public Classes::TComponent
  513. {
  514.     typedef Classes::TComponent inherited;
  515.     
  516. private:
  517.     POINT FDesignSize;
  518.     POINT FDesignOffset;
  519.     Classes::TNotifyEvent FOnCreate;
  520.     Classes::TNotifyEvent FOnDestroy;
  521.     void __fastcall ReadHeight(Classes::TReader* Reader);
  522.     void __fastcall ReadHorizontalOffset(Classes::TReader* Reader);
  523.     void __fastcall ReadVerticalOffset(Classes::TReader* Reader);
  524.     void __fastcall ReadWidth(Classes::TReader* Reader);
  525.     void __fastcall WriteWidth(Classes::TWriter* Writer);
  526.     void __fastcall WriteHorizontalOffset(Classes::TWriter* Writer);
  527.     void __fastcall WriteVerticalOffset(Classes::TWriter* Writer);
  528.     void __fastcall WriteHeight(Classes::TWriter* Writer);
  529.     
  530. protected:
  531.     virtual void __fastcall DefineProperties(Classes::TFiler* Filer);
  532.     virtual void __fastcall GetChildren(Classes::TGetChildProc Proc);
  533.     virtual void __fastcall AfterConstruction(void);
  534.     virtual void __fastcall BeforeDestruction(void);
  535.     
  536. public:
  537.     __fastcall virtual TDataModule(Classes::TComponent* AOwner);
  538.     __fastcall TDataModule(Classes::TComponent* AOwner, int Dummy);
  539.     __fastcall virtual ~TDataModule(void);
  540.     __property POINT DesignOffset = {read=FDesignOffset, write=FDesignOffset};
  541.     __property POINT DesignSize = {read=FDesignSize, write=FDesignSize};
  542.     
  543. __published:
  544.     __property Classes::TNotifyEvent OnCreate = {read=FOnCreate, write=FOnCreate};
  545.     __property Classes::TNotifyEvent OnDestroy = {read=FOnDestroy, write=FOnDestroy};
  546. };
  547.  
  548. struct TCursorRec;
  549. typedef TCursorRec *PCursorRec;
  550.  
  551. struct TCursorRec
  552. {
  553.     TCursorRec *Next;
  554.     int Index;
  555.     HICON Handle;
  556. } ;
  557.  
  558. class __declspec(delphiclass) TScreen;
  559. class __declspec(pascalimplementation) TScreen : public Classes::TComponent
  560. {
  561.     typedef Classes::TComponent inherited;
  562.     
  563. private:
  564.     Classes::TStrings* FFonts;
  565.     Classes::TStrings* FImes;
  566.     System::AnsiString FDefaultIme;
  567.     HKL FDefaultKbLayout;
  568.     Classes::TList* FRestoreFocusForms;
  569.     int FPixelsPerInch;
  570.     Controls::TCursor FCursor;
  571.     Classes::TList* FForms;
  572.     Classes::TList* FDataModules;
  573.     TCursorRec *FCursorList;
  574.     HICON FDefaultCursor;
  575.     Controls::TWinControl* FActiveControl;
  576.     TForm* FActiveForm;
  577.     Controls::TWinControl* FLastActiveControl;
  578.     TForm* FLastActiveForm;
  579.     TForm* FFocusedForm;
  580.     Classes::TNotifyEvent FOnActiveControlChange;
  581.     Classes::TNotifyEvent FOnActiveFormChange;
  582.     void __fastcall AddDataModule(TDataModule* DataModule);
  583.     void __fastcall AddForm(TForm* AForm);
  584.     void __fastcall CreateCursors(void);
  585.     void __fastcall DeleteCursor(int Index);
  586.     void __fastcall DestroyCursors(void);
  587.     void __fastcall InitImes(void);
  588.     HICON __fastcall GetCursors(int Index);
  589.     TDataModule* __fastcall GetDataModule(int Index);
  590.     int __fastcall GetDataModuleCount(void);
  591.     int __fastcall GetHeight(void);
  592.     int __fastcall GetWidth(void);
  593.     TForm* __fastcall GetForm(int Index);
  594.     int __fastcall GetFormCount(void);
  595.     void __fastcall InsertCursor(int Index, HICON Handle);
  596.     void __fastcall RemoveDataModule(TDataModule* DataModule);
  597.     void __fastcall RemoveForm(TForm* AForm);
  598.     void __fastcall SetCursors(int Index, HICON Handle);
  599.     void __fastcall SetCursor(Controls::TCursor Value);
  600.     void __fastcall UpdateLastActive(void);
  601.     
  602. public:
  603.     __fastcall virtual TScreen(Classes::TComponent* AOwner);
  604.     __fastcall virtual ~TScreen(void);
  605.     __property Controls::TWinControl* ActiveControl = {read=FActiveControl, nodefault};
  606.     __property TForm* ActiveForm = {read=FActiveForm, nodefault};
  607.     __property Controls::TCursor Cursor = {read=FCursor, write=SetCursor, nodefault};
  608.     __property HICON Cursors[int Index] = {read=GetCursors, write=SetCursors};
  609.     __property TDataModule* DataModules[int Index] = {read=GetDataModule};
  610.     __property int DataModuleCount = {read=GetDataModuleCount, nodefault};
  611.     __property Classes::TStrings* Fonts = {read=FFonts, nodefault};
  612.     __property int Height = {read=GetHeight, nodefault};
  613.     __property Classes::TStrings* Imes = {read=FImes, nodefault};
  614.     __property System::AnsiString DefaultIme = {read=FDefaultIme, nodefault};
  615.     __property HKL DefaultKbLayout = {read=FDefaultKbLayout, nodefault};
  616.     __property Classes::TList* RestoreFocusForms = {read=FRestoreFocusForms, write=FRestoreFocusForms, 
  617.         nodefault};
  618.     __property int PixelsPerInch = {read=FPixelsPerInch, nodefault};
  619.     __property int Width = {read=GetWidth, nodefault};
  620.     __property TForm* Forms[int Index] = {read=GetForm};
  621.     __property int FormCount = {read=GetFormCount, nodefault};
  622.     __property Classes::TNotifyEvent OnActiveControlChange = {read=FOnActiveControlChange, write=FOnActiveControlChange
  623.         };
  624.     __property Classes::TNotifyEvent OnActiveFormChange = {read=FOnActiveFormChange, write=FOnActiveFormChange
  625.         };
  626. };
  627.  
  628. enum TTimerMode { tmShow, tmHide };
  629.  
  630. struct THintInfo
  631. {
  632.     Controls::TControl* HintControl;
  633.     POINT HintPos;
  634.     int HintMaxWidth;
  635.     Graphics::TColor HintColor;
  636.     Windows::TRect CursorRect;
  637.     POINT CursorPos;
  638. } ;
  639.  
  640. typedef void __fastcall (__closure *TMessageEvent)(tagMSG &Msg, bool &Handled);
  641.  
  642. typedef void __fastcall (__closure *TExceptionEvent)(System::TObject* Sender, Sysutils::Exception* E
  643.     );
  644.  
  645. typedef void __fastcall (__closure *TIdleEvent)(System::TObject* Sender, bool &Done);
  646.  
  647. typedef void __fastcall (__closure *TShowHintEvent)( System::AnsiString &HintStr, bool &CanShow, THintInfo 
  648.     &HintInfo);
  649.  
  650. typedef bool __fastcall (__closure *TWindowHook)(Messages::TMessage &Message);
  651.  
  652. class __declspec(delphiclass) TApplication;
  653. class __declspec(pascalimplementation) TApplication : public Classes::TComponent
  654. {
  655.     typedef Classes::TComponent inherited;
  656.     
  657. private:
  658.     HWND FHandle;
  659.     void *FObjectInstance;
  660.     TForm* FMainForm;
  661.     Controls::TControl* FMouseControl;
  662.     System::AnsiString FHelpFile;
  663.     System::AnsiString FHint;
  664.     bool FHintActive;
  665.     bool FUpdateFormatSettings;
  666.     bool FShowMainForm;
  667.     Graphics::TColor FHintColor;
  668.     Controls::TControl* FHintControl;
  669.     Windows::TRect FHintCursorRect;
  670.     int FHintPause;
  671.     int FHintShortPause;
  672.     int FHintHidePause;
  673.     Controls::THintWindow* FHintWindow;
  674.     bool FShowHint;
  675.     bool FTimerActive;
  676.     TTimerMode FTimerMode;
  677.     Word FTimerHandle;
  678.     System::AnsiString FTitle;
  679.     Classes::TList* FTopMostList;
  680.     int FTopMostLevel;
  681.     Graphics::TIcon* FIcon;
  682.     bool FTerminate;
  683.     bool FActive;
  684.     bool FIgnoreFontProperty;
  685.     bool FHandleCreated;
  686.     bool FRunning;
  687.     Classes::TList* FWindowHooks;
  688.     void *FWindowList;
  689.     HWND FDialogHandle;
  690.     TExceptionEvent FOnException;
  691.     TMessageEvent FOnMessage;
  692.     Classes::THelpEvent FOnHelp;
  693.     Classes::TNotifyEvent FOnHint;
  694.     TIdleEvent FOnIdle;
  695.     Classes::TNotifyEvent FOnDeactivate;
  696.     Classes::TNotifyEvent FOnActivate;
  697.     TShowHintEvent FOnShowHint;
  698.     Classes::TNotifyEvent FOnMinimize;
  699.     Classes::TNotifyEvent FOnRestore;
  700.     void __fastcall ActivateHint(const POINT &CursorPos);
  701.     bool __fastcall CheckIniChange(Messages::TMessage &Message);
  702.     HWND __fastcall GetDialogHandle(void);
  703.     System::AnsiString __fastcall GetExeName(void);
  704.     HICON __fastcall GetIconHandle(void);
  705.     System::AnsiString __fastcall GetTitle(void);
  706.     void __fastcall HintTimerExpired(void);
  707.     void __fastcall IconChanged(System::TObject* Sender);
  708.     void __fastcall Idle(void);
  709.     bool __fastcall InvokeHelp(Word Command, long Data);
  710.     bool __fastcall IsDlgMsg(MSG &Msg);
  711.     bool __fastcall IsHintMsg(MSG &Msg);
  712.     bool __fastcall IsKeyMsg(MSG &Msg);
  713.     bool __fastcall IsMDIMsg(MSG &Msg);
  714.     void __fastcall NotifyForms(Word Msg);
  715.     bool __fastcall ProcessMessage(void);
  716.     void __fastcall SetDialogHandle(HWND Value);
  717.     void __fastcall SetHandle(HWND Value);
  718.     void __fastcall SetHint(const System::AnsiString Value);
  719.     void __fastcall SetHintColor(Graphics::TColor Value);
  720.     void __fastcall SetIcon(Graphics::TIcon* Value);
  721.     void __fastcall SetShowHint(bool Value);
  722.     void __fastcall SetTitle(const System::AnsiString Value);
  723.     void __fastcall StartHintTimer(int Value, TTimerMode TimerMode);
  724.     void __fastcall StopHintTimer(void);
  725.     void __fastcall WndProc(Messages::TMessage &Message);
  726.     
  727. public:
  728.     __fastcall virtual TApplication(Classes::TComponent* AOwner);
  729.     __fastcall virtual ~TApplication(void);
  730.     void __fastcall BringToFront(void);
  731.     void __fastcall ControlDestroyed(Controls::TControl* Control);
  732.     void __fastcall CancelHint(void);
  733.     void __fastcall CreateForm(System::TMetaClass* InstanceClass, void *Reference);
  734.     void __fastcall CreateHandle(void);
  735.     void __fastcall HandleException(System::TObject* Sender);
  736.     void __fastcall HandleMessage(void);
  737.     bool __fastcall HelpCommand(int Command, long Data);
  738.     bool __fastcall HelpContext(Classes::THelpContext Context);
  739.     bool __fastcall HelpJump(const System::AnsiString JumpID);
  740.     void __fastcall HideHint(void);
  741.     void __fastcall HintMouseMessage(Controls::TControl* Control, Messages::TMessage &Message);
  742.     void __fastcall HookMainWindow(TWindowHook Hook);
  743.     void __fastcall Initialize(void);
  744.     int __fastcall MessageBox(char * Text, char * Caption, Word Flags);
  745.     void __fastcall Minimize(void);
  746.     void __fastcall NormalizeTopMosts(void);
  747.     void __fastcall ProcessMessages(void);
  748.     void __fastcall Restore(void);
  749.     void __fastcall RestoreTopMosts(void);
  750.     void __fastcall Run(void);
  751.     void __fastcall ShowException(Sysutils::Exception* E);
  752.     void __fastcall Terminate(void);
  753.     void __fastcall UnhookMainWindow(TWindowHook Hook);
  754.     __property bool Active = {read=FActive, nodefault};
  755.     __property HWND DialogHandle = {read=GetDialogHandle, write=SetDialogHandle, nodefault};
  756.     __property System::AnsiString ExeName = {read=GetExeName, nodefault};
  757.     __property HWND Handle = {read=FHandle, write=SetHandle, nodefault};
  758.     __property System::AnsiString HelpFile = {read=FHelpFile, write=FHelpFile, nodefault};
  759.     __property System::AnsiString Hint = {read=FHint, write=SetHint, nodefault};
  760.     __property Graphics::TColor HintColor = {read=FHintColor, write=SetHintColor, nodefault};
  761.     __property int HintPause = {read=FHintPause, write=FHintPause, nodefault};
  762.     __property int HintShortPause = {read=FHintShortPause, write=FHintShortPause, nodefault};
  763.     __property int HintHidePause = {read=FHintHidePause, write=FHintHidePause, nodefault};
  764.     __property Graphics::TIcon* Icon = {read=FIcon, write=SetIcon, nodefault};
  765.     __property bool IgnoreFontProperty = {read=FIgnoreFontProperty, write=FIgnoreFontProperty, nodefault
  766.         };
  767.     __property TForm* MainForm = {read=FMainForm, nodefault};
  768.     __property bool ShowHint = {read=FShowHint, write=SetShowHint, nodefault};
  769.     __property bool ShowMainForm = {read=FShowMainForm, write=FShowMainForm, nodefault};
  770.     __property bool Terminated = {read=FTerminate, nodefault};
  771.     __property System::AnsiString Title = {read=GetTitle, write=SetTitle, nodefault};
  772.     __property bool UpdateFormatSettings = {read=FUpdateFormatSettings, write=FUpdateFormatSettings, nodefault
  773.         };
  774.     __property Classes::TNotifyEvent OnActivate = {read=FOnActivate, write=FOnActivate};
  775.     __property Classes::TNotifyEvent OnDeactivate = {read=FOnDeactivate, write=FOnDeactivate};
  776.     __property TExceptionEvent OnException = {read=FOnException, write=FOnException};
  777.     __property TIdleEvent OnIdle = {read=FOnIdle, write=FOnIdle};
  778.     __property Classes::THelpEvent OnHelp = {read=FOnHelp, write=FOnHelp};
  779.     __property Classes::TNotifyEvent OnHint = {read=FOnHint, write=FOnHint};
  780.     __property TMessageEvent OnMessage = {read=FOnMessage, write=FOnMessage};
  781.     __property Classes::TNotifyEvent OnMinimize = {read=FOnMinimize, write=FOnMinimize};
  782.     __property Classes::TNotifyEvent OnRestore = {read=FOnRestore, write=FOnRestore};
  783.     __property TShowHintEvent OnShowHint = {read=FOnShowHint, write=FOnShowHint};
  784. };
  785.  
  786. typedef void __fastcall (__closure *TWndMethod)(Messages::TMessage &Message);
  787.  
  788. //-- var, const, procedure ---------------------------------------------------
  789. extern TApplication* Application;
  790. extern TScreen* Screen;
  791. extern void *Ctl3DBtnWndProc;
  792. extern long __stdcall (*Ctl3DDlgFramePaint)(HWND Window, long Msg, long wParam, long lParam);
  793. extern long __stdcall (*Ctl3DCtlColorEx)(HWND Window, long Msg, long wParam, long lParam);
  794. extern System::TMetaClass*HintWindowClass;
  795. extern void * __fastcall DisableTaskWindows(HWND ActiveWindow);
  796. extern void __fastcall EnableTaskWindows(void * WindowList);
  797. extern void __fastcall InitCtl3D(void);
  798. extern void __fastcall DoneCtl3D(void);
  799. extern bool __fastcall Subclass3DWnd(HWND Wnd);
  800. extern void __fastcall Subclass3DDlg(HWND Wnd, Word Flags);
  801. extern void __fastcall SetAutoSubClass(bool Enable);
  802. extern void * __fastcall MakeObjectInstance(TWndMethod Method);
  803. extern void __fastcall FreeObjectInstance(void * ObjectInstance);
  804. extern HWND __fastcall AllocateHWnd(TWndMethod Method);
  805. extern void __fastcall DeallocateHWnd(HWND Wnd);
  806. extern Classes::TShiftState __fastcall KeysToShiftState(Word Keys);
  807. extern Classes::TShiftState __fastcall KeyDataToShiftState(long KeyData);
  808. extern bool __fastcall IsAccel(Word VK, const System::AnsiString Str);
  809. extern TForm* __fastcall GetParentForm(Controls::TControl* Control);
  810. extern TForm* __fastcall ValidParentForm(Controls::TControl* Control);
  811. //-- template instantiations -------------------------------------------------
  812. template class TFormState ;
  813. template class TBorderIcons ;
  814.  
  815. }    /* namespace Forms */
  816.  
  817. #pragma warn .par
  818. #pragma warn .hid 
  819. #pragma warn .inl
  820.  
  821. #if !defined(NO_IMPLICIT_NAMESPACE_USE)
  822. using namespace Forms;
  823. #endif
  824. //-- end unit ----------------------------------------------------------------
  825. #endif    // Forms
  826.