home *** CD-ROM | disk | FTP | other *** search
/ Dream 52 / Amiga_Dream_52.iso / Linux / Divers / freedraft.tar.gz / freedraft.tar / FREEdraft-050298 / CORE / attributes.h < prev    next >
C/C++ Source or Header  |  1998-04-29  |  2KB  |  56 lines

  1. // attributes.h
  2. // 
  3. // 
  4. // Copyright (C) 1997,1998  Cliff Johnson                                       //
  5. //                                                                         //
  6. // This program is free software; you can redistribute it and/or           //
  7. // modify it under the terms of the GNU  General Public                    //
  8. // License as published by the Free Software Foundation; either            //
  9. // version 2 of the License, or (at your option) any later version.        //
  10. //                                                                         //
  11. // This software is distributed in the hope that it will be useful,        //
  12. // but WITHOUT ANY WARRANTY; without even the implied warranty of          //
  13. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU       //
  14. // General Public License for more details.                                //
  15. //                                                                         //
  16. // You should have received a copy of the GNU General Public License       //
  17. // along with this software (see COPYING); if not, write to the        //
  18. // Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //
  19.  
  20.  
  21. #ifndef ATTRIBUTES_H
  22. #define ATTRIBUTES_H
  23.  
  24. #include <attrib_enum.h>
  25.  
  26.  
  27. class Attributes
  28. {
  29.  
  30. // manager class for graphical attributes of an entity
  31. // a support class for the gl canvas pane
  32.  
  33. private:
  34.     int colorValue;
  35.     unsigned short lineStyle;
  36.     unsigned int thickness;
  37.     unsigned int layer;
  38. public:
  39.     Attributes();
  40.     Attributes(int color, unsigned short style, unsigned int thick,unsigned int layer);
  41.     ~Attributes();
  42.  
  43.     Attributes(const Attributes& a);
  44.     Attributes& operator=(const Attributes& a);
  45.  
  46.     inline int GetColor() const { return colorValue; }
  47.     inline unsigned short GetLineStyle() const { return lineStyle; }
  48.     inline unsigned int GetThick() const { return thickness; }
  49.     inline unsigned int GetPointSize() const { return thickness; }
  50.     inline unsigned int GetLayer() const { return layer; } 
  51.  
  52.     friend bool operator==(const Attributes& a1, const Attributes& a2);
  53. };
  54.  
  55. #endif
  56.