00001
00002
00003
00004
00005
00006
00007
00008
00009
00010 #pragma once
00011
00012 #include <string>
00013 #include <sys/types.h>
00014
00015 namespace AUGUI {
00016 typedef enum {
00017 kInteger,
00018 kFloat,
00019 kString,
00020 kPicture,
00021 kColor,
00022 kPoint,
00023 kRect,
00024 kFont,
00025 kBool
00026 } property_type_t;
00027
00028 class font_t {
00029 public:
00030 CFStringRef name;
00031 long size;
00032 };
00033
00034 class color_t {
00035 public:
00036 float red, green, blue, alpha;
00037 };
00038
00039 class point_t {
00040 public:
00041 float x, y;
00042 };
00043
00044 class rect_t {
00045 public:
00046 float x, y, w, h;
00047 };
00048
00049 class property_t {
00050 public:
00051 property_t() : mTag(0) {};
00052 property_t(uint32_t tag, CFStringRef name, CFStringRef label, property_type_t type) :
00053 mTag(tag), mName(name), mLabel(label), mType(type) {};
00054 uint32_t tag() const { return mTag; };
00055 property_type_t type() const { return mType; };
00056 CFStringRef label() const { return mLabel; };
00057 CFStringRef name() const { return mName; };
00058
00059 static property_t null;
00060 protected:
00061 uint32_t mTag;
00062 CFStringRef mName;
00063 CFStringRef mLabel;
00064 property_type_t mType;
00065 };
00066 };