1 /* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */ 2 /* 3 * Copyright (C) 2001-2002 Mikael Hallendal <micke@imendio.com> 4 * Copyright (C) 2004,2008 Imendio AB 5 * 6 * This program is free software; you can redistribute it and/or 7 * modify it under the terms of the GNU General Public License as 8 * published by the Free Software Foundation; either version 2 of the 9 * License, or (at your option) any later version. 10 * 11 * This program is distributed in the hope that it will be useful, 12 * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 * General Public License for more details. 15 * 16 * You should have received a copy of the GNU General Public 17 * License along with this program; if not, write to the 18 * Free Software Foundation, Inc., 59 Temple Place - Suite 330, 19 * Boston, MA 02111-1307, USA. 20 */ 21 22 #ifndef __DH_UTIL_H__ 23 #define __DH_UTIL_H__ 24 25 #include <gtk/gtk.h> 26 #include <webkit/webkit.h> 27 #include "dh-link.h" 28 29 G_BEGIN_DECLS 30 31 GtkBuilder * dh_util_builder_get_file (const gchar *filename, 32 const gchar *root, 33 const gchar *domain, 34 const gchar *first_required_widget, 35 ...); 36 void dh_util_builder_connect (GtkBuilder *gui, 37 gpointer user_data, 38 gchar *first_widget, 39 ...); 40 gchar * dh_util_build_data_filename (const gchar *first_part, 41 ...); 42 void dh_util_state_manage_window (GtkWindow *window, 43 const gchar *name); 44 void dh_util_state_manage_paned (GtkPaned *paned, 45 const gchar *name); 46 void dh_util_state_manage_notebook (GtkNotebook *notebook, 47 const gchar *name, 48 const gchar *default_tab); 49 void dh_util_state_set_notebook_page_name (GtkWidget *page, 50 const gchar *page_name); 51 const gchar *dh_util_state_get_notebook_page_name (GtkWidget *page); 52 GSList * dh_util_state_load_books_disabled (void); 53 void dh_util_state_store_books_disabled (GSList *books_disabled); 54 55 void dh_util_font_get_variable (gchar **name, 56 gdouble *size, 57 gboolean use_system_font); 58 void dh_util_font_get_fixed (gchar **name, 59 gdouble *size, 60 gboolean use_system_font); 61 void dh_util_font_add_web_view (WebKitWebView *view); 62 gint dh_util_cmp_book (DhLink *a, 63 DhLink *b); 64 65 G_END_DECLS 66 67 #endif /* __DH_UTIL_H__ */ 68