2 * Claws Mail -- a GTK based, lightweight, and fast e-mail client
3 * Copyright (C) 2001-2012 Hiroyuki Yamamoto & The Claws Mail Team
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 3 of the License, or
8 * (at your option) any later version.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this program. If not, see <http://www.gnu.org/licenses/>.
20 #if !defined(COLORLABEL_H__)
21 #define COLORLABEL_H__
26 /* max value of color label index (0..max) - see also procmsg.h */
27 #define COLORLABELS 15
29 #define MAINWIN_COLORMENU 0
30 #define SUMMARY_COLORMENU 1
33 /* Columns for model used in GtkComboBox color menu */
41 void colorlabel_update_colortable_from_prefs(void);
42 gint
colorlabel_get_color_count (void);
43 GdkRGBA
colorlabel_get_color (gint color_index
);
44 GdkRGBA
colorlabel_get_default_color (gint color_index
);
45 gchar
*colorlabel_get_color_default_text (gint color_index
);
46 GtkImage
*colorlabel_create_color_pixmap (GdkColor color
);
47 GtkWidget
*colorlabel_create_check_color_menu_item
51 GtkWidget
*colorlabel_create_color_menu (void);
52 guint
colorlabel_get_color_menu_active_item (GtkWidget
*menu
);
54 /* Creates a GtkComboBox with selection of configured colors */
55 GtkWidget
*colorlabel_create_combobox_colormenu(void);
57 /* Resets contents of an existing combobox with matching
58 * model. Can be useful after prefs, and therefore configured
60 void colorlabel_refill_combobox_colormenu(GtkComboBox
*combobox
);
62 /* Returns index of selected color in the colormenu combobox.
63 * 0 if "none" is selected, and 1-16 for colors 0-15. */
64 gint
colorlabel_get_combobox_colormenu_active(GtkComboBox
*combobox
);
66 /* Select specified color entry in the colormenu combobox.
67 * The color parameter corresponds to return value of
68 * colorlabel_get_combobox_colormenu_active(). */
69 void colorlabel_set_combobox_colormenu_active(GtkComboBox
*combobox
,
72 #endif /* COLORLABEL_H__ */