1 /* 2 * Copyright (C) 2001 Havoc Pennington 3 * Copyright (C) 2016 Alberts Muktupāvels 4 * 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 2 of the License, or 8 * (at your option) any later version. 9 * 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. 14 * 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/>. 17 */ 18 19 #ifndef META_COLOR_SPEC_PRIVATE_H 20 #define META_COLOR_SPEC_PRIVATE_H 21 22 #include <gtk/gtk.h> 23 24 G_BEGIN_DECLS 25 26 typedef enum _MetaColorSpecType MetaColorSpecType; 27 typedef enum _MetaGtkColorComponent MetaGtkColorComponent; 28 typedef struct _MetaColorSpec MetaColorSpec; 29 30 G_GNUC_INTERNAL 31 MetaColorSpec *meta_color_spec_new (MetaColorSpecType type); 32 33 G_GNUC_INTERNAL 34 MetaColorSpec *meta_color_spec_new_from_string (const gchar *str, 35 GError **error); 36 37 G_GNUC_INTERNAL 38 MetaColorSpec *meta_color_spec_new_gtk (MetaGtkColorComponent component, 39 GtkStateFlags state); 40 41 G_GNUC_INTERNAL 42 void meta_color_spec_free (MetaColorSpec *spec); 43 44 G_GNUC_INTERNAL 45 void meta_color_spec_render (MetaColorSpec *spec, 46 GtkStyleContext *context, 47 GdkRGBA *color); 48 49 G_GNUC_INTERNAL 50 gboolean meta_gtk_state_from_string (const gchar *str, 51 GtkStateFlags *state); 52 53 G_END_DECLS 54 55 #endif 56