Back to index

easystroke  0.5.5.1
Public Member Functions | Public Attributes
RGBA Struct Reference

#include <prefdb.h>

List of all members.

Public Member Functions

 RGBA ()
 RGBA (Gdk::Color c)
template<class Archive >
void save (Archive &ar, unsigned int version) const
template<class Archive >
void load (Archive &ar, unsigned int version)
bool operator== (const RGBA rgba)

Public Attributes

Gdk::Color color
guint16 alpha

Detailed Description

Definition at line 67 of file prefdb.h.


Constructor & Destructor Documentation

RGBA::RGBA ( ) [inline]

Definition at line 70 of file prefdb.h.

: alpha(65535) {}
RGBA::RGBA ( Gdk::Color  c) [inline]

Definition at line 71 of file prefdb.h.

: color(c), alpha(65535) {}

Member Function Documentation

template<class Archive >
void RGBA::load ( Archive &  ar,
unsigned int  version 
) [inline]

Definition at line 82 of file prefdb.h.

                                                                            {
              gushort r, g, b;
              ar & r;
              ar & g;
              ar & b;
              ar & alpha;
              color.set_red(r);
              color.set_green(g);
              color.set_blue(b);
       }
bool RGBA::operator== ( const RGBA  rgba) [inline]

Definition at line 92 of file prefdb.h.

                                        {
              return color == rgba.color && alpha == rgba.alpha;
       }
template<class Archive >
void RGBA::save ( Archive &  ar,
unsigned int  version 
) const [inline]

Definition at line 72 of file prefdb.h.

                                                                                  {
              gushort r, g, b;
              r = color.get_red();
              g = color.get_green();
              b = color.get_blue();
              ar & r;
              ar & g;
              ar & b;
              ar & alpha;
       }

Member Data Documentation

guint16 RGBA::alpha

Definition at line 69 of file prefdb.h.

Gdk::Color RGBA::color

Definition at line 68 of file prefdb.h.


The documentation for this struct was generated from the following file: