]> Dogcows Code - chaz/openbox/blobdiff - otk/rendertexture.hh
REMOVE -fno-rtti. we use that!
[chaz/openbox] / otk / rendertexture.hh
index 3b9d4baa61defb563eef36ee2453278693047930..df38ddf679229415f2d5901876ccdd52a78dc87e 100644 (file)
@@ -35,6 +35,8 @@ private:
   bool _parent_relative;
   //! The relief type of the texture
   ReliefType _relief;
+  //! The way the bevel should be drawn
+  BevelType _bevel;
   //! If a flat border is drawn on the outside, ignored for all ReliefType
   //! values except ReliefType::Flat
   bool _border;
@@ -46,34 +48,46 @@ private:
   //! The base color for the texture, the only color when the texture is solid.
   //! This must always be defined
   const RenderColor *_color;
+  //! The secondary color for a gradient texture.
+  //! This is only defined for gradients
+  const RenderColor *_secondary_color;
   //! The shadow color for the bevel. This must be defined if
-  //! RenderTexture::relief is not RenderTexture::ReliefType::Flat
+  //! RenderTexture::_relief is not RenderTexture::ReliefType::Flat
   const RenderColor *_bevel_dark_color;
   //! The light color for the bevel. This must be defined if
-  //! RenderTexture::relief is not RenderTexture::ReliefType::Flat
+  //! RenderTexture::_relief is not RenderTexture::ReliefType::Flat
   const RenderColor *_bevel_light_color;
-  //! The color for the flat border if RenderTexture::border is true. This must
-  //! be defined if it is true
+  //! The color for the flat border if RenderTexture::_border is true. This
+  //! must be defined if it is true
   const RenderColor *_border_color;
+  //! The color for the interlace lines if RenderTexture. This must be defined
+  //! if it is true
+  const RenderColor *_interlace_color;
 
 public:
-  RenderTexture(bool parent_relative, ReliefType relief, bool border,
-                GradientType gradient, bool interlaced,
-                const RenderColor *color, const RenderColor *bevel_dark_color,
+  RenderTexture(bool parent_relative, ReliefType relief, BevelType bevel,
+                bool border, GradientType gradient, bool interlaced,
+                const RenderColor *color, const RenderColor *secondary_color,
+                const RenderColor *bevel_dark_color,
                 const RenderColor *bevel_light_color,
-                const RenderColor *border_color)
+                const RenderColor *border_color,
+                const RenderColor *interlace_color)
     : _parent_relative(parent_relative),
       _relief(relief),
+      _bevel(bevel),
       _border(border),
       _gradient(gradient),
       _interlaced(interlaced),
       _color(color),
+      _secondary_color(secondary_color),
       _bevel_dark_color(bevel_dark_color),
       _bevel_light_color(bevel_light_color),
-      _border_color(border_color)
+      _border_color(border_color),
+      _interlace_color(interlace_color)
     {
       assert(_relief == Flat || (_bevel_dark_color && _bevel_light_color));
       assert(!_border || _border_color);
+      assert(!_interlaced || _interlace_color);
       assert(_color);
     }
 
@@ -81,6 +95,8 @@ public:
   inline bool parentRelative() const { return _parent_relative; }
   //! The relief type of the texture
   inline ReliefType relief() const { return _relief; }
+  //! The way the bevel should be drawn
+  inline BevelType bevel() const { return _bevel; }
   //! If a flat border is drawn on the outside, ignored for all ReliefType
   //! values except ReliefType::Flat
   inline bool border() const { return _border; }
@@ -92,17 +108,25 @@ public:
   //! The base color for the texture, the only color when the texture is solid.
   //! This must always be defined
   inline const RenderColor& color() const { return *_color; }
+  //! The secondary color for gradient textures.
+  //! This is only defined for gradients
+  inline const RenderColor& secondary_color() const
+    { return *_secondary_color; }
   //! The shadow color for the bevel. This must be defined if
-  //! RenderTexture::relief is not RenderTexture::ReliefType::Flat
+  //! RenderTexture::_relief is not RenderTexture::ReliefType::Flat
   inline const RenderColor& bevelDarkColor() const
     { return *_bevel_dark_color; }
   //! The light color for the bevel. This must be defined if
-  //! RenderTexture::relief is not RenderTexture::ReliefType::Flat
+  //! RenderTexture::)relief is not RenderTexture::ReliefType::Flat
   inline const RenderColor& bevelLightColor() const
     { return *_bevel_light_color; }
-  //! The color for the flat border if RenderTexture::border is true. This must
-  //! be defined if it is true
+  //! The color for the flat border if RenderTexture::_border is true. This
+  //! must be defined if it is true
   inline const RenderColor& borderColor() const { return *_border_color; }
+  //! The color for the interlace lines if RenderTexture. This must be defined
+  //! if it is true
+  inline const RenderColor& interlaceColor() const
+    { return *_interlace_color; }
 };
 
 }
This page took 0.024247 seconds and 4 git commands to generate.