Main Page | Class Hierarchy | Class List | File List | Class Members | File Members

htpal.h

Go to the documentation of this file.
00001 /* 
00002  *      HT Editor
00003  *      htpal.h
00004  *
00005  *      Copyright (C) 1999-2002 Stefan Weyergraf (stefan@weyergraf.de)
00006  *
00007  *      This program is free software; you can redistribute it and/or modify
00008  *      it under the terms of the GNU General Public License version 2 as
00009  *      published by the Free Software Foundation.
00010  *
00011  *      This program is distributed in the hope that it will be useful,
00012  *      but WITHOUT ANY WARRANTY; without even the implied warranty of
00013  *      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00014  *      GNU General Public License for more details.
00015  *
00016  *      You should have received a copy of the GNU General Public License
00017  *      along with this program; if not, write to the Free Software
00018  *      Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
00019  */
00020 
00021 #ifndef __HTPAL_H__
00022 #define __HTPAL_H__
00023 
00024 #include "htdata.h"
00025 #include "htobj.h"
00026 #include "htreg.h"
00027 
00028 #define rnt_palette_name                "palette"
00029 
00030 struct defpal {
00031         int idx;
00032         char *name;
00033         int color;
00034 };
00035 
00036 /*
00037  *      CLASS palette_entry
00038  */
00039 
00040 class palette_entry: public ht_registry_data {
00041 public:
00042         UINT idx;
00043         vcp color;
00044 
00045                         palette_entry(UINT idx=0, vcp color=0);
00046 /* overwritten */
00047         virtual bool editdialog(const char *keyname);
00048         virtual   void strvalue(char *buf32bytes);
00049         virtual int  load(ht_object_stream *f);
00050         virtual OBJECT_ID object_id() const;
00051         virtual void store(ht_object_stream *f);
00052 };
00053 
00054 /*
00055  *      palette_key
00056  */
00057 
00058 #define palettekey "palette"
00059 
00060 /*
00061  *   palette class keys
00062  */
00063 
00064 #define palclasskey_generic                                             "generic"
00065 #define palclasskey_tags                                                "tags"
00066 #define palclasskey_syntax                                      "syntax"
00067 
00068 /*
00069  *      generic palette
00070  */
00071 
00072 #define palkey_generic_window_default                           "window"
00073 #define palkey_generic_dialog_default                           "dialog"
00074 #define palkey_generic_menu_default                             "menu"
00075 #define palkey_generic_keys_default                             "keyline"
00076 #define palkey_generic_desktop_default                          "desktop"
00077 #define palkey_generic_help_default                             "help"
00078 
00079 #define palkey_generic_cyan                                             "cyan"
00080 #define palkey_generic_black                                            "black"
00081 #define palkey_generic_blue                                             "blue"
00082 #define palkey_generic_gray                                             "gray"
00083 #define palkey_generic_special                                  "special"
00084 
00085 #define palidx_generic_body                                             0
00086 #define palidx_generic_text_focused                             1
00087 #define palidx_generic_text_unfocused                           2
00088 #define palidx_generic_text_shortcut                            3
00089 #define palidx_generic_text_shortcut_selected           4
00090 #define palidx_generic_text_selected                            5
00091 #define palidx_generic_text_disabled                            6
00092 #define palidx_generic_frame_focused                            7
00093 #define palidx_generic_frame_unfocused                          8
00094 #define palidx_generic_frame_move_resize                        9
00095 #define palidx_generic_frame_killer                             10
00096 #define palidx_generic_scrollbar                                        11
00097 #define palidx_generic_input_focused                            12
00098 #define palidx_generic_input_unfocused                          13
00099 #define palidx_generic_input_selected                           14
00100 #define palidx_generic_input_clip                                       15
00101 #define palidx_generic_button_focused                           16
00102 #define palidx_generic_button_unfocused                         17
00103 #define palidx_generic_button_shadow                            18
00104 #define palidx_generic_button_shortcut                          19
00105 #define palidx_generic_list_focused_selected                    20
00106 #define palidx_generic_list_focused_unselected          21
00107 #define palidx_generic_list_unfocused_selected          22
00108 #define palidx_generic_list_unfocused_unselected                23
00109 #define palidx_generic_cluster_focused                          24
00110 #define palidx_generic_cluster_unfocused                        25
00111 #define palidx_generic_cluster_shortcut                         26
00112 
00113 /*
00114  *   reg/pal management
00115  */
00116 
00117 vcp getcolorv(palette *pal, UINT index);
00118 bool load_pal(char *pal_class, char *pal_flavour, palette *p);
00119 
00120 /*
00121  *      INIT
00122  */
00123 
00124 bool init_pal();
00125 
00126 /*
00127  *      DONE
00128  */
00129 
00130 void done_pal();
00131 
00132 #endif /* !__HTPAL_H__ */

Generated on Fri May 7 21:15:36 2004 by doxygen 1.3.5