home *** CD-ROM | disk | FTP | other *** search
/ Chip 1997 October / Chip_1997-10_cd.bin / tema / sybase / powerj / hpp.z / dtjtyped.hpp < prev    next >
C/C++ Source or Header  |  1996-11-21  |  2KB  |  68 lines

  1. #ifndef _DTJTYPED_HPP
  2. #define _DTJTYPED_HPP
  3.  
  4. #include <stddef.h>
  5. #include "dttype.hpp"
  6.  
  7. #define TYPE_ALIAS( _base, _alias )    \
  8. typedef DT ## _base DT ## _alias;
  9.  
  10. /******************
  11.  *** Color Type ***
  12.  ******************/
  13.  
  14. class METAEXPORTCLASSDEF DTType_Color : public DTType {
  15.     public:
  16.     DTType_Color( const MMType * imp );
  17.     ~DTType_Color();
  18.  
  19.     virtual WBool            Textify( WString &, DT_Textify ) const;
  20.     virtual WBool            DeTextify( const WString &, DT_Textify );
  21.  
  22.     virtual WBool            operator==( const DTType & o );
  23.  
  24.     virtual WBool            Set( const WColor & val );
  25.     virtual const WColor &        Get() const;
  26.  
  27.     virtual WBool            Browse( WWindow * parent, DTObject * obj );
  28.  
  29.     virtual WUInt            GetNumValues();
  30.     virtual WString            GetValue( WUInt i );
  31.  
  32.     static DTType *            Instantiate( const MMType * );
  33.  
  34.     private:
  35.     WColor        _c_value;
  36. };
  37.  
  38.  
  39. TYPE_ALIAS( Type_Color, Type_const_Color__ref_ );
  40.  
  41. /******************
  42.  *** JFont Type ***
  43.  ******************/
  44.  
  45. class METAEXPORTCLASSDEF DTType_JFont : public DTType {
  46.     public:
  47.     DTType_JFont( const MMType * imp );
  48.     ~DTType_JFont();
  49.  
  50.     virtual WBool            Textify( WString &, DT_Textify ) const;
  51.     virtual WBool            DeTextify( const WString &, DT_Textify );
  52.  
  53.     virtual WBool            operator==( const DTType & o );
  54.  
  55.     virtual WBool            Set( const WFont & val );
  56.     virtual const WFont &        Get() const;
  57.  
  58.     virtual WBool            Browse( WWindow * parent, DTObject * obj );
  59.  
  60.     static DTType *            Instantiate( const MMType * );
  61.     private:
  62.     WFont        _value;
  63. };
  64.  
  65. TYPE_ALIAS( Type_JFont, Type_const_JFont__ref_ );
  66.  
  67. #endif // _DTJTYPED_HPP
  68.