home *** CD-ROM | disk | FTP | other *** search
/ PC World Komputer 1998 May / Pcwk5b98.iso / Borland / Cplus45 / BC45 / LAYOUT.PAK / LAYDIA.H < prev    next >
C/C++ Source or Header  |  1995-08-29  |  2KB  |  79 lines

  1. //----------------------------------------------------------------------------
  2. // ObjectWindows - (C) Copyright 1993 by Borland International
  3. //----------------------------------------------------------------------------
  4. #ifndef __LAYDIA_H
  5. #define __LAYDIA_H
  6.  
  7. #ifndef __OWL_DIALOG_H
  8.   #include <owl\dialog.h>
  9. #endif
  10. class _OWLCLASS TEdit;
  11. class _OWLCLASS TComboBox;
  12. class _OWLCLASS TListBox;
  13.  
  14. #define WM_SET_X (WM_USER + 100)
  15.  
  16. const int MaxWindows = 10;
  17.  
  18. struct TChildInfo {
  19.   TWindow*       Child;
  20.   TLayoutMetrics LayoutMetrics;
  21. };
  22.  
  23. class TLayoutDialog : public TDialog {
  24.   public:
  25.       TLayoutDialog(TLayoutWindow* parent, TResId resId, TChildInfo* info);
  26.     enum Constraint { X1, X2, Y1, Y2};
  27.  
  28.   protected:
  29.     char*          Title;
  30.     TLayoutWindow* LayoutWindow;
  31.  
  32.     void    SetupWindow();
  33.     void    HandleLayout();
  34.     void    HandleWindowChange();
  35.  
  36.     void    SetLayoutConstraint(TLayoutConstraint& lc, Constraint which);
  37.     void    GetLayoutConstraint(TLayoutConstraint& lc, Constraint which);
  38.  
  39.     TChildInfo*        ChildInfo;
  40.     int                ChildNum;
  41.  
  42.     TListBox*  WindowList;
  43.  
  44.     TComboBox* X1EdgeCombo;
  45.     TComboBox* X2EdgeCombo;
  46.     TComboBox* Y1EdgeCombo;
  47.     TComboBox* Y2EdgeCombo;
  48.  
  49.     TComboBox* X1OtherEdgeCombo;
  50.     TComboBox* X2OtherEdgeCombo;
  51.     TComboBox* Y1OtherEdgeCombo;
  52.     TComboBox* Y2OtherEdgeCombo;
  53.  
  54.     TComboBox* X1UnitsCombo;
  55.     TComboBox* X2UnitsCombo;
  56.     TComboBox* Y1UnitsCombo;
  57.     TComboBox* Y2UnitsCombo;
  58.  
  59.     TEdit*     X1ValueEdit;
  60.     TEdit*     X2ValueEdit;
  61.     TEdit*     Y1ValueEdit;
  62.     TEdit*     Y2ValueEdit;
  63.  
  64.     TComboBox* X1RelationCombo;
  65.     TComboBox* X2RelationCombo;
  66.     TComboBox* Y1RelationCombo;
  67.     TComboBox* Y2RelationCombo;
  68.  
  69.     TComboBox* X1RelWinCombo;
  70.     TComboBox* X2RelWinCombo;
  71.     TComboBox* Y1RelWinCombo;
  72.     TComboBox* Y2RelWinCombo;
  73.  
  74.   DECLARE_RESPONSE_TABLE(TLayoutDialog);
  75. };
  76.  
  77.  
  78. #endif
  79.