home *** CD-ROM | disk | FTP | other *** search
/ Chip 1997 October / Chip_1997-10_cd.bin / tema / sybase / powerj / hpp.z / DTUOBJ.HPP < prev    next >
C/C++ Source or Header  |  1997-01-26  |  7KB  |  119 lines

  1. #ifndef _DTUOBJ_HPP
  2. #define _DTUOBJ_HPP
  3.  
  4. #include "dtobase.hpp"
  5.  
  6. class METAEXPORTCLASSDEF DTUObject : public DTObject {
  7.     public:
  8.         DTUObject( const MetaObject * meta, WObject * imp = NULL );
  9.         ~DTUObject();
  10.  
  11.     public:
  12.         WBool           operator== ( const DTObject & ) const;
  13.         void            DTGetRectangle( WRect & r,
  14.                                                 WBool abs = FALSE ) const;
  15.         void            DTSetRectangle( const WRect & r );
  16.         void            DTGetClientRectangle( WRect & r ) const;
  17.         void            DTGetRCRectangle( WRect & r ) const;
  18.         WRect           DTMapPixelsToDLU( const WRect & pix ) const;
  19.         WRect           DTMapDLUToPixels( const WRect & dlu ) const;
  20.         void            DTBringToTop();
  21.         void            DTRepaint();
  22.         void GenFileFragment( MMFileFragment fg, WStringList &,
  23.                                         MMFileGenerationParms * parms ) const;
  24.         void GenerateCode( MMCodeGeneration, ostream &, MMCodeGenerationParms & );
  25.         void GetRequiredIncludes( WStringList & a ) const;
  26.         void GetRequiredBaseClasses( WStringList & a ) const;
  27.         const MetaObject *  GetMeta() const;
  28.         void                SetMeta( const MetaObject * );
  29.         const MetaObject *  GetRefCardMeta() const;
  30.         void            DTSetName( const WString & name );
  31.         WString         DTGetName() const;
  32.         void            SetClassDefinition( const WString & );
  33.         WString         GetClassDefinition() const;
  34.         void            SetClassIncludes( const WString & );
  35.         WString         GetClassIncludes() const;
  36.         WObject *       GetWImplementation() const;
  37.         void            SetWImplementation( WObject * wobj );
  38.         DTObject *      GetConcreteImplementation();
  39.         WWindow *       GetWindow() const;
  40.         WWindow *       DTGetParent() const;
  41.         void            SetResourceID( long id );
  42.         long            GetResourceID() const;
  43.         void            SetTabIndex( long idx );
  44.         long            GetTabIndex() const;
  45.         const DTCodeBlockList & GetCodeBlockList() const;
  46.         DTCodeBlockList &       GetCodeBlockList();
  47.         WInt                    GetAllCodeBlockLists( DTCodeBlockListList & );
  48.         DTCodeBlockBase *       RemoveEvent( DTCodeBlockBase * );
  49.         DTCodeBlockBase *       FindEvent( const char * ) const;
  50.         FormEdit *      GetForm() const;
  51.         DTFormEditBase *GetDTForm() const;
  52.         void            SetForm( DTFormEditBase * );
  53.         int             GetChildCount() const;
  54.         DTObject *      GetChild( int index ) const;
  55.         WBool           AddChild( DTObject *, int after = -1 );
  56.         WBool           RemoveChild( DTObject * );
  57.         DTObject *      GetParent() const;
  58.         WStyle          GetStyle() const;
  59.         WBool           SetStyle( WStyle stl, WBool clone=FALSE );
  60.         WStyle          GetDefaultStyle() const;
  61.         WStyle          GetExtendedStyle() const;
  62.         WBool           SetExtendedStyle( WStyle style, WBool clone=FALSE );
  63.         WStyle          GetDefaultExtendedStyle() const;
  64.         WBool           Create( WWindow * parent, const WRect & r,
  65.                                         const WChar * text, WStyle style,
  66.                                         WStyle exStyle, void * data = NULL,
  67.                                         WBool isLoading = FALSE );
  68.         WBool           GetNonVisual() const;
  69.         WBool           HasDTInfo();
  70.         WBool           SaveDTInfo( SaveSource & );
  71.         WBool           LoadDTInfo( SaveBlock *, WBool beforeCreate );
  72.         WBool           CreateEventPopupMenu( WPopupMenu * popup );
  73.         WBool           GetIsResizeable();
  74.         WBool           GetIsHollow();  // groupbox
  75.         WRect           GetHollowRect();        // interior of groupbox
  76.         WBool           SetDTPopupMenu( DTObject * );
  77.         DTObject *      GetDTPopupMenu() const;
  78.         void            AmendPopup( WPopupMenu *, WBool before );
  79.         WBool           IsValidChild( const MetaObject *obj, WString &errMsg ) const;
  80.         WBool           IsValidContainer( const DTObject *obj, WString &errMsg ) const;
  81.         WBool           DTSetEventHandler( WEventID id, WObject * object, WEventHandler handler, void *userdata=NULL );
  82.         DTIInterface *  GetDTIInterface( const WChar * ifname );
  83.         WBool           GetProtected() const;
  84.         WBool           EditProperties( WWindow *, WBool child = FALSE );
  85.         void                    ClearPropertyEditor( WBool deleteNow = FALSE );
  86.         WBool                   UpdatePropertyRect();
  87.         MTPropertyDialog *      GetPropDialog();
  88.         WBool                   HasProperty( const WString & name ) const;
  89.         WString                 GetProperty( const WString & name, DT_TextifyV t = 1 ) const;
  90.         WBool                   GetPropertyBool( const WString & name ) const;
  91.         WLong                   GetPropertyEnum( const WString & name ) const;
  92.         WRect                   GetPropertyRect( const WString & name ) const;
  93.         WLong                   GetPropertyLong( const WString & name ) const;
  94.         WBool                   SetProperty( const WString & name, const WString & val, DT_TextifyV t = 1 );
  95.         WBool                   SetPropertyBool( const WString & name, WBool val );
  96.         void                    SetPropertyEnum( const WString & name, WLong val );
  97.         void                    SetPropertyRect( const WString & name, const WRect & r );
  98.         void                    SetPropertyLong( const WString & name, WLong r );
  99.         WString                 GetMappedValue( WUInt i ) const;
  100.         void                    SetMappedValue( WUInt i, const WString & s );
  101.         void                    PropertyChanged( const WString & name );
  102.         void                    DetachEditor();
  103.         WString                 GetObjectPrefix() const;
  104.         void                    GenName( WUInt id, WString & ) const;
  105.         void                    GenClassName( WString & ) const;
  106.         void                    GenResourceName( WString & ) const;
  107.         void                    GenResourceStyles( WStringList &, WStringList & ) const;
  108.         void                    GenEventObjectName( WString & ) const;
  109.         const MMStyle *         FindStyle( const char * ) const;
  110.         const MMProperty *      FindProperty( const char * ) const;
  111.         DTObjectImp *           GetImplementation();
  112.         void                    EscapeCString( WString &, const WString & ) const;
  113.  
  114.     private:
  115.         DTObject *              _base;
  116. };
  117.  
  118. #endif // _DTUOBJ_HPP
  119.