1 /********************************************************************\
2  * gnc-gtk-utils.h -- utility functions based on glib functions     *
3  * Copyright (C) 2006 David Hampton <hampton@employees.org>         *
4  *                                                                  *
5  * This program is free software; you can redistribute it and/or    *
6  * modify it under the terms of the GNU General Public License as   *
7  * published by the Free Software Foundation; either version 2 of   *
8  * the License, or (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, contact:                        *
17  *                                                                  *
18  * Free Software Foundation           Voice:  +1-617-542-5942       *
19  * 51 Franklin Street, Fifth Floor    Fax:    +1-617-542-2652       *
20  * Boston, MA  02110-1301,  USA       gnu@gnu.org                   *
21  *                                                                  *
22 \********************************************************************/
23 
24 /** @addtogroup Gtk Gtk Utilities
25 
26     The API in this file is designed to provide support functions that
27     wrap the base gtk functions and make them easier to use.
28 
29     @{ */
30 /** @file gnc-gtk-utils.h
31  *  @brief gtk helper routines.
32  *  @author Copyright (C) 2006 David Hampton <hampton@employees.org>
33  */
34 
35 #ifndef GNC_GTK_UTILS_H
36 #define GNC_GTK_UTILS_H
37 
38 #include <gtk/gtk.h>
39 
40 /** @name gtk Miscellaneous Functions
41  @{
42 */
43 
44 void gnc_cbwe_set_by_string(GtkComboBox *cbwe, const gchar *text);
45 void gnc_cbwe_add_completion (GtkComboBox *cbwe);
46 void gnc_cbwe_require_list_item (GtkComboBox *cbwe);
47 
48 gboolean gnc_is_dark_theme (GdkRGBA *fg_color);
49 void gnc_style_context_get_background_color (GtkStyleContext *context,
50                                              GtkStateFlags    state,
51                                              GdkRGBA         *color);
52 void gnc_style_context_get_border_color (GtkStyleContext *context,
53                                          GtkStateFlags    state,
54                                          GdkRGBA         *color);
55 
56 /** @} */
57 
58 #endif /* GNC_GTK_UTILS_H */
59 /** @} */
60