CompOption Class Reference

A configuration option with boolean, int, float, String, Color, Key, Button, Edge, Bell, or List. More...

#include <option.h>

List of all members.

Public Types

enum  Type {
  TypeBool, TypeInt, TypeFloat, TypeString,
  TypeColor, TypeAction, TypeKey, TypeButton,
  TypeEdge, TypeBell, TypeMatch, TypeList,
  TypeUnset
}
 Option data types. More...
typedef std::vector< CompOptionVector

Public Member Functions

 CompOption (const CompOption &)
 CompOption (CompString name, Type type)
void setName (CompString name, Type type)
CompString name ()
Type type ()
Valuevalue ()
Restrictionrest ()
bool set (Value &val)
bool isAction ()
CompOptionoperator= (const CompOption &option)

Static Public Member Functions

static CompOptionfindOption (Vector &options, CompString name, unsigned int *index=NULL)
static bool getBoolOptionNamed (const Vector &options, const CompString &name, bool defaultValue=false)
static int getIntOptionNamed (const Vector &options, const CompString &name, int defaultValue=0)
static float getFloatOptionNamed (const Vector &options, const CompString &name, const float &defaultValue=0.0)
static CompString getStringOptionNamed (const Vector &options, const CompString &name, const CompString &defaultValue="")
static unsigned short * getColorOptionNamed (const Vector &options, const CompString &name, unsigned short *defaultValue)
static CompMatch getMatchOptionNamed (const Vector &options, const CompString &name, const CompMatch &defaultValue)
static CompString typeToString (Type type)
static bool stringToColor (CompString color, unsigned short *rgba)
static CompString colorToString (unsigned short *rgba)
static bool setOption (CompOption &o, Value &value)

Classes

class  Class
 TODO. More...
class  Restriction
 TODO. More...
class  Value
 A value of an Option. More...


Detailed Description

A configuration option with boolean, int, float, String, Color, Key, Button, Edge, Bell, or List.

Member Enumeration Documentation

Option data types.


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

Generated on Wed Feb 2 22:44:14 2011 for Compiz by  doxygen 1.5.6