diff options
Diffstat (limited to 'src/gui')
34 files changed, 457 insertions, 113 deletions
diff --git a/src/gui/bookmark_dialog.h b/src/gui/bookmark_dialog.h index a26e26d..2dd0078 100644 --- a/src/gui/bookmark_dialog.h +++ b/src/gui/bookmark_dialog.h @@ -33,6 +33,11 @@ void on_dialog_response(GtkDialog * dialog, gpointer user_data); void gui_bookmark_dialog(gchar * label, gchar * module_name, gchar * key); void gui_mark_verse_dialog(gchar * module_name, gchar * key); +void on_buffer_changed (GtkTextBuffer *textbuffer, gpointer user_data); +void on_mark_verse_response(GtkDialog * dialog, gint response_id, gpointer user_data); +void on_dialog_enter(void); +void on_mark_verse_enter(void); +gboolean on_treeview_button_release_event(GtkWidget *widget, GdkEventButton *event, gpointer user_data); #ifdef __cplusplus } diff --git a/src/gui/bookmarks_menu.h b/src/gui/bookmarks_menu.h index 85116d7..ce83278 100644 --- a/src/gui/bookmarks_menu.h +++ b/src/gui/bookmarks_menu.h @@ -52,6 +52,21 @@ extern gboolean bookmarks_changed; void gui_save_bookmarks(GtkMenuItem * menuitem, gpointer user_data); void gui_create_bookmark_menu(void); void gui_save_bookmarks_treeview(void); +void bibletime_bookmarks_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_allow_reordering_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_dialog_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_edit_item_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_export_folder_activate(GtkMenuItem * menuitem, gpointer user_data); +void restore_ok(GtkButton * button, GtkWidget * filesel); +void restore_cancel(GtkButton * button, GtkWidget * dlg); +void on_restore_folder_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_delete_item_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_expand_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_collapse_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_add_bookmark_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_insert_bookmark_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_new_folder_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_open_in_tab_activate(GtkMenuItem * menuitem, gpointer user_data); #ifdef __cplusplus } diff --git a/src/gui/bookmarks_treeview.h b/src/gui/bookmarks_treeview.h index 482aa08..e1d8bb4 100644 --- a/src/gui/bookmarks_treeview.h +++ b/src/gui/bookmarks_treeview.h @@ -25,7 +25,7 @@ #ifdef __cplusplus extern "C" { #endif -#include <gnome.h> +#include <gtk/gtk.h> #include <libxml/parser.h> enum { COL_OPEN_PIXBUF, @@ -71,6 +71,8 @@ void gui_parse_bookmarks(GtkTreeView *tree, const xmlChar * file, GtkTreeIter *parent); GtkWidget* gui_create_dialog_add_bookmark(gchar * label, gchar * module_name, gchar * key); +void gui_save_old_bookmarks_to_new(GNode * gnode); + #ifdef __cplusplus } #endif diff --git a/src/gui/commentary_dialog.h b/src/gui/commentary_dialog.h index e16d621..e90da5b 100644 --- a/src/gui/commentary_dialog.h +++ b/src/gui/commentary_dialog.h @@ -30,7 +30,9 @@ extern "C" { void gui_commentary_dialog_sync_toggled(GtkToggleButton * button, DIALOG_DATA * c); void gui_create_commentary_dialog(DIALOG_DATA * d, gboolean do_edit); - +void gui_display_commentary_with_struct(DIALOG_DATA *d, gchar *key); +void gui_close_comm_dialog(DIALOG_DATA * d); + #ifdef __cplusplus } #endif diff --git a/src/gui/debug_glib_null.h b/src/gui/debug_glib_null.h new file mode 100644 index 0000000..52dd627 --- /dev/null +++ b/src/gui/debug_glib_null.h @@ -0,0 +1,47 @@ +/* + * Xiphos Bible Study Tool + * utilities.h - support functions + * + * Copyright (C) 2009 Xiphos Developer Team + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Library General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. + */ + +#ifdef DEBUG + +/* replicating real g_strdup_printf & friends for the sake of our debugging. */ +/* this is a total mind game: we redefine the standard use of glib functions */ +/* so as to use our internal versions. our internal versions scan for mis- */ +/* use of %s, i.e. (char*)NULL that should (by rights) cause crashes anyhow. */ + +#ifdef __cplusplus +extern "C" { +#endif + +#define g_strdup_printf(f, ...) XI_g_strdup_printf(__FILE__, __LINE__, f, __VA_ARGS__) +#define g_string_printf(s, f, ...) XI_g_string_printf(__FILE__, __LINE__, s, f, __VA_ARGS__) + +#include "gui.h" + +#ifdef __cplusplus +} +#endif + +/* the code implementing our versions of these is in src/gnome2/gui.c, */ +/* expressly because gui.c does not need these functions; ergo, gui.c */ +/* does not #include this file: it gets access to real glib functions. */ +/* all other source files include this file to get the replacements. */ + +#endif /* DEBUG */ diff --git a/src/gui/dialog.h b/src/gui/dialog.h index e661c42..22e3700 100644 --- a/src/gui/dialog.h +++ b/src/gui/dialog.h @@ -73,6 +73,7 @@ void gui_generic_warning(char *); gint gui_gs_dialog(GS_DIALOG * info); gint gui_alert_dialog(GS_DIALOG * info); gint gui_yes_no_dialog(char *, char *); +gint gui_close_confirmation_dialog(GS_DIALOG * info); #ifdef __cplusplus } diff --git a/src/gui/dictlex.h b/src/gui/dictlex.h index 8559e9f..7d9fa79 100644 --- a/src/gui/dictlex.h +++ b/src/gui/dictlex.h @@ -37,7 +37,10 @@ void gui_lookup_dictlex_selection(GtkMenuItem * menuitem, void gui_set_dictlex_mod_and_key(gchar *mod, gchar *key); void gui_display_dictlex(gchar * key); GtkWidget *gui_create_dictionary_pane(void); - +void on_entryDictLookup_changed(GtkEditable * editable, gpointer data); +void dict_key_entry_changed(GtkEntry * entry, gpointer data); +void button_back_clicked(GtkButton * button, gpointer user_data); +void button_forward_clicked(GtkButton * button, gpointer user_data); #ifdef __cplusplus } diff --git a/src/gui/dictlex_dialog.h b/src/gui/dictlex_dialog.h index 34eb453..07bd233 100644 --- a/src/gui/dictlex_dialog.h +++ b/src/gui/dictlex_dialog.h @@ -31,6 +31,7 @@ extern "C" { void gui_create_dictlex_dialog(DIALOG_DATA *dlg); void gui_lookup_dictlex_dialog_selection (GtkMenuItem * menuitem, gchar * dict_mod_description); +void on_btnSyncDL_clicked(GtkButton * button, DIALOG_DATA * d); #ifdef __cplusplus } diff --git a/src/gui/export_bookmarks.h b/src/gui/export_bookmarks.h new file mode 100644 index 0000000..dc9ae97 --- /dev/null +++ b/src/gui/export_bookmarks.h @@ -0,0 +1,73 @@ +/* + * Xiphos Bible Study Tool + * export_bookmarks.h - + * + * Copyright (C) 2003-2009 Xiphos Developer Team + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Library General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. + */ + +#ifndef ___EXPORT_BOOKMARKS_H_ +#define ___EXPORT_BOOKMARKS_H_ + +#ifdef __cplusplus +extern "C" { +#endif + +struct _export_bookmarks { + gboolean as_bookmarks; + gboolean as_html; + gboolean as_plain; + gboolean with_scripture; + gint type; + gint verselist; + GtkWidget *rb_bookmarks; + GtkWidget *rb_html; + GtkWidget *rb_plain; + GtkWidget *cb_scripture; + GtkWidget *filechooserwidget; + gchar *filename; + gchar *verselist_name; + GList * verses; +}; +typedef struct _export_bookmarks BK_EXPORT; + +enum { + BOOKMARKS_EXPORT, + VERSE_LIST_EXPORT, + SEARCH_RESULTS_EXPORT, + ADV_SEARCH_RESULTS_EXPORT +}; + +void gui_set_html_item (GString * str, + const gchar * description, + const gchar * module, + const gchar * key, + gboolean with_scripture); +void gui_set_plain_text_item (GString * str, + const gchar * description, + const gchar * module, + const gchar * key, + gboolean with_scripture); +void gui_export_bookmarks_dialog(gint is_verselist, GList * verses); +gboolean dialog_vbox1_key_press_event_cb(GtkWidget * widget, + GdkEventKey * event, + gpointer user_data); + +#ifdef __cplusplus +} +#endif + +#endif /* ___EXPORT_BOOKMARKS_H_ */ diff --git a/src/gui/export_dialog.h b/src/gui/export_dialog.h index 0b53be1..a2ed494 100644 --- a/src/gui/export_dialog.h +++ b/src/gui/export_dialog.h @@ -28,6 +28,9 @@ extern "C" { gchar *gui_get_export_filename(void); void gui_export_dialog(void); +void _get_export_filename(void); +void on_dialog_export_passage_response(GtkDialog * dialog, gint response_id, gpointer user_data); +gint _check_for_distribution_license(gchar * mod_name); #ifdef __cplusplus } diff --git a/src/gui/find_dialog.h b/src/gui/find_dialog.h index dae69d6..484cea4 100644 --- a/src/gui/find_dialog.h +++ b/src/gui/find_dialog.h @@ -22,7 +22,7 @@ #ifndef _FIND_DIALOG_H_ #define _FIND_DIALOG_H_ -#include <gnome.h> +#include <gtk/gtk.h> void gui_find_dlg(GtkWidget *htmlwidget, gchar *mod_name, gboolean regular, gchar *text); diff --git a/src/gui/gbs.h b/src/gui/gbs.h index e666d78..b7992a6 100644 --- a/src/gui/gbs.h +++ b/src/gui/gbs.h @@ -25,5 +25,6 @@ GtkWidget *gui_create_book_pane(void); void gui_update_gbs_global_ops(gchar * option, gboolean choice); void gui_set_book_page_and_key(gchar * mod_name, gchar * key); +void gui_set_book_mod_and_key(gchar * mod_name, gchar * key); #endif diff --git a/src/gui/gbs_dialog.h b/src/gui/gbs_dialog.h index 8706be2..4e4a6d9 100644 --- a/src/gui/gbs_dialog.h +++ b/src/gui/gbs_dialog.h @@ -29,6 +29,7 @@ extern "C" { #include "main/module_dialogs.h" void gui_create_gbs_dialog(DIALOG_DATA * dlg); +void gui_close_gbs_dialog(DIALOG_DATA * dlg); #ifdef __cplusplus } diff --git a/src/gui/gui.h b/src/gui/gui.h index 734d5f0..ff5035e 100644 --- a/src/gui/gui.h +++ b/src/gui/gui.h @@ -4,5 +4,27 @@ void gui_init(int argc, char*argv[]); void gui_main(void); +#ifndef WIN32 +#include <gconf/gconf-client.h> +void gconf_setup(void); #endif +#define GS_GCONF_MAX 6 + +#ifdef DEBUG + + +gchar* XI_g_strdup_printf (const char *filename, + int linenumber, + const char *format, + ...) G_GNUC_PRINTF (3, 4) G_GNUC_MALLOC; + +void XI_g_string_printf (const char *filename, + int linenumber, + GString *string, + const char *format, + ...) G_GNUC_PRINTF (4, 5); + +#endif /* DEBUG */ + +#endif diff --git a/src/gui/html.h b/src/gui/html.h index abffe05..a7a115e 100644 --- a/src/gui/html.h +++ b/src/gui/html.h @@ -26,7 +26,6 @@ extern "C" { #endif -#include <gnome.h> #include <gtkhtml/gtkhtml.h> extern gboolean in_url; diff --git a/src/gui/ipc.h b/src/gui/ipc.h new file mode 100644 index 0000000..0d4c74d --- /dev/null +++ b/src/gui/ipc.h @@ -0,0 +1,83 @@ +/* + * Xiphos Bible Study Tool + * ipc.h - Interprocess Communication - dbus integration + * + * Copyright (C) 2000-2009 Xiphos Developer Team + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Library General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. + */ + + +#ifndef __XIPHOS_IPC_H__ +#define __XIPHOS_IPC_H__ + +#include <glib.h> +#include <dbus/dbus-glib.h> + +G_BEGIN_DECLS + +#define IPC_TYPE_OBJECT (ipc_object_get_type()) +#define IPC_OBJECT(object) \ + (G_TYPE_CHECK_INSTANCE_CAST ((object), \ + IPC_TYPE_OBJECT, IpcObject)) +#define IPC_OBJECT_CLASS(klass) \ + (G_TYPE_CHECK_CLASS_CAST ((klass), \ + IPC_TYPE_OBJECT, IpcObjectClass)) +#define IPC_IS_OBJECT(klass) \ + (G_TYPE_CHECK_CLASS_TYPE ((klass), \ + IPC_TYPE_OBJECT)) +#define IPC_IS_OBJECT_CLASS(klass) \ + (G_TYPE_CHECK_CLASS_TYPE ((klass), \ + IPC_TYPE_OBJECT)) +#define IPC_OBJECT_GET_CLASS(obj) \ + (G_TYPE_INSTANCE_GET_CLASS ((obj), \ + IPC_TYPE_OBJECT, IpcObjectClass)) + +typedef enum { + SEARCH_PERFORMED, + NAVIGATION, + LAST_SIGNAL +} IpcSignalNumber; + +typedef struct _IpcObject IpcObject; +typedef struct _IpcObjectClass IpcObjectClass; + +struct _IpcObject { + GObject parent; + GList *references; + gchar *current_ref; +}; + +struct _IpcObjectClass { + GObjectClass parent; + guint signals[LAST_SIGNAL]; +}; + +GType ipc_object_get_type(void); + +gboolean ipc_object_search_performed (IpcObject* obj, + const gchar* search_term, + const int* hits, + GError** error); +gboolean ipc_object_navigation_signal (IpcObject* obj, + const gchar* reference, + GError** error); + +IpcObject* ipc_init_dbus_connection(IpcObject* obj); +IpcObject* ipc_get_main_ipc(void); + +G_END_DECLS + +#endif /* __XIPHOS_IPC_H__ */ diff --git a/src/gui/main_menu.h b/src/gui/main_menu.h index 7d502bc..02854fc 100644 --- a/src/gui/main_menu.h +++ b/src/gui/main_menu.h @@ -32,6 +32,34 @@ void gui_parallel_tab_activate(GtkCheckMenuItem * menuitem, gpointer user_data); void on_module_manager_activate(GtkMenuItem * menuitem, gpointer user_data); void on_preferences_activate(GtkMenuItem * menuitem, gpointer user_data); void on_help_contents_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_mailing_list_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_live_chat_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_report_bug_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_about_the_sword_project_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_about_translation_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_daily_devotion_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_search_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_verse_style_activate(GtkCheckMenuItem * menuitem, gpointer user_data); +void on_linked_tabs_activate(GtkCheckMenuItem * menuitem, gpointer user_data); +void on_read_aloud_activate(GtkCheckMenuItem * menuitem, gpointer user_data); +void on_show_verse_numbers_activate(GtkCheckMenuItem * menuitem, gpointer user_data); +void on_versehighlight_activate(GtkCheckMenuItem * menuitem, gpointer user_data); +void on_side_preview_activate(GtkCheckMenuItem * menuitem, gpointer user_data); +void on_double_space_text_activate(GtkCheckMenuItem * menuitem, gpointer user_data); +void on_quit_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_about_xiphos_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_save_session_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_open_session_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_show_bible_text_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_preview_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_show_commentary_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_show_dictionary_lexicon_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_open_studypad_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_advanced_search_activate(GtkMenuItem * menuitem, gpointer user_data); +void on_attach_detach_sidebar_activate(GtkMenuItem *menuitem, gpointer user_data); +void on_sidebar_showhide_activate(GtkMenuItem *menuitem, gpointer user_data); +void link_uri_hook(GtkLinkButton *button, const gchar *link, gpointer user_data); + #ifdef __cplusplus } #endif diff --git a/src/gui/main_window.h b/src/gui/main_window.h index 4c441a3..b48efb6 100644 --- a/src/gui/main_window.h +++ b/src/gui/main_window.h @@ -26,7 +26,7 @@ extern "C" { #endif -#include <gnome.h> +#include <gtk/gtk.h> //#include "gui/toolbar_nav.h" #include "main/navbar_versekey.h" diff --git a/src/gui/menu_popup.h b/src/gui/menu_popup.h index 50b57ad..6f9a267 100644 --- a/src/gui/menu_popup.h +++ b/src/gui/menu_popup.h @@ -26,9 +26,50 @@ extern "C" { #endif +#include <glade/glade-xml.h> + #include "main/module_dialogs.h" + void gui_menu_popup (const gchar * mod_name, DIALOG_DATA * d); +gint _get_type_mod_list (void); +gchar * _get_key (gchar * mod_name); +GtkWidget * _get_html (void); +void on_popup_about_activate (GtkMenuItem * menuitem, gpointer user_data); +void on_popup_bookmark_activate (GtkMenuItem *menuitem, gpointer user_data); +void on_popup_export_passage_activate (GtkMenuItem *menuitem, gpointer user_data); +void on_popup_print_activate (GtkMenuItem *menuitem, gpointer user_data); +void on_close_activate (GtkMenuItem *menuitem, gpointer user_data); +void on_popup_copy_activate (GtkMenuItem *menuitem, gpointer user_data); +void on_popup_find_activate (GtkMenuItem *menuitem, gpointer user_data); +void on_popup_font_activate (GtkMenuItem * menuitem, gpointer user_data); +void on_words_of_christ_in_red_activate (GtkCheckMenuItem * menuitem, gpointer user_data); +void on_strong_s_numbers_activate (GtkCheckMenuItem * menuitem, gpointer user_data); +void on_morphological_tags_activate (GtkCheckMenuItem * menuitem, gpointer user_data); +void on_footnotes_activate (GtkCheckMenuItem * menuitem, gpointer user_data); +void on_greek_accents_activate (GtkCheckMenuItem * menuitem, gpointer user_data); +void on_lemmas_activate (GtkCheckMenuItem * menuitem, gpointer user_data); +void on_scripture_cross_references_activate (GtkCheckMenuItem * menuitem, gpointer user_data); +void on_hebrew_vowel_points_activate (GtkCheckMenuItem * menuitem, gpointer user_data); +void on_hebrew_cantillation_activate (GtkCheckMenuItem * menuitem, gpointer user_data); +void on_headings_activate (GtkCheckMenuItem * menuitem, gpointer user_data); +void on_transliteration_activate (GtkCheckMenuItem * menuitem, gpointer user_data); +void on_commentary_by_chapter_activate (GtkCheckMenuItem * menuitem, gpointer user_data); +void on_primary_reading_activate (GtkCheckMenuItem * menuitem, gpointer user_data); +void on_secondary_reading_activate (GtkCheckMenuItem * menuitem, gpointer user_data); +void on_all_readings_activate (GtkCheckMenuItem * menuitem, gpointer user_data); +void on_image_content_activate (GtkCheckMenuItem * menuitem, gpointer user_data); +void on_respect_font_faces_activate (GtkCheckMenuItem * menuitem, gpointer user_data); +void on_unlock_this_module_activate (GtkMenuItem * menuitem, gpointer user_data); +void on_display_book_heading_activate (GtkMenuItem * menuitem, gpointer user_data); +void on_display_chapter_heading_activate (GtkMenuItem * menuitem, gpointer user_data); +void on_use_current_dictionary_activate (GtkMenuItem * menuitem, gpointer user_data); +void on_lookup_google_activate (GtkMenuItem * menuitem, gpointer user_data); +void on_rename_perscomm_activate (GtkMenuItem * menuitem, gpointer user_data); +void on_dump_perscomm_activate (GtkMenuItem * menuitem, gpointer user_data); +void on_read_selection_aloud_activate (GtkMenuItem * menuitem, gpointer user_data); +void on_mark_verse_activate (GtkMenuItem * menuitem, gpointer user_data); +void _add_and_check_global_opts (GladeXML *gxml, const gchar * mod_name, GtkWidget * submenu, DIALOG_DATA * d); #ifdef __cplusplus } diff --git a/src/gui/mod_mgr.h b/src/gui/mod_mgr.h index 19f0a57..f852beb 100644 --- a/src/gui/mod_mgr.h +++ b/src/gui/mod_mgr.h @@ -31,6 +31,25 @@ void gui_update_install_status(glong total, glong done, const gchar *message); void gui_update_install_progressbar(gdouble fraction); void gui_open_mod_mgr(void); void gui_open_mod_mgr_initial_run(void); +void clear_and_hide_progress_bar(void); +void on_notebook1_switch_page(GtkNotebook * notebook, GtkNotebookPage * page, guint page_num, gpointer user_data); +void on_radiobutton2_toggled(GtkToggleButton * togglebutton, gpointer user_data); +void on_radiobutton4_toggled(GtkToggleButton * togglebutton, gpointer user_data); +void save_sources(void); +void on_refresh_clicked(GtkButton * button, gpointer user_data); +void on_install_clicked(GtkButton * button, gpointer user_data); +void on_remove_clicked(GtkButton * button, gpointer user_data); +void on_archive_clicked(GtkButton * button, gpointer user_data); +void on_index_clicked(GtkButton * button, gpointer user_data); +void on_delete_index_clicked(GtkButton * button, gpointer user_data); +void on_load_sources_clicked(GtkButton * button, gpointer user_data); +void on_cancel_clicked(GtkButton * button, gpointer user_data); +void on_mod_mgr_response(GtkDialog * dialog, gint response_id, gpointer user_data); +void on_button5_clicked(GtkButton * button, gpointer user_data); +void on_button6_clicked(GtkButton * button, gpointer user_data); +void on_button7_clicked(GtkButton * button, gpointer user_data); +void on_button8_clicked(GtkButton * button, gpointer user_data); +gboolean on_treeview1_button_release_event(GtkWidget * widget, GdkEventButton * event, gpointer user_data); #ifdef __cplusplus } diff --git a/src/gui/navbar_book.h b/src/gui/navbar_book.h index 07eae78..3b7f66d 100644 --- a/src/gui/navbar_book.h +++ b/src/gui/navbar_book.h @@ -23,5 +23,6 @@ #define ___NAVBAR_BOOK_H_ GtkWidget *gui_navbar_book_new(void); +void on_entry_activate (GtkEntry *entry, gpointer user_data); #endif diff --git a/src/gui/parallel_tab.h b/src/gui/parallel_tab.h index db8b5bb..567c567 100644 --- a/src/gui/parallel_tab.h +++ b/src/gui/parallel_tab.h @@ -30,7 +30,10 @@ extern "C" { void gui_parallel_tab_sync(const gchar * key); GtkWidget *gui_create_parallel_tab(void); void gui_keep_parallel_tab_in_sync(void); +void gui_force_parallel_tab_sync(void); void gui_destroy_parallel_tab(void); +void gui_parallel_close_tab(GtkButton * button, gpointer user_data); +GtkWidget *_create_parallel_tab(void); #ifdef __cplusplus } diff --git a/src/gui/parallel_view.h b/src/gui/parallel_view.h index fe010db..2bde432 100644 --- a/src/gui/parallel_view.h +++ b/src/gui/parallel_view.h @@ -30,6 +30,8 @@ void gui_create_parallel_page(void); void gui_create_parallel_popup(void); void gui_popup_menu_parallel(void); void on_undockInt_activate(GtkMenuItem * menuitem); +void on_paratab_activate(GtkMenuItem * menuitem); +void on_changeint1mod_activate(GtkMenuItem * menuitem, gpointer user_data); #ifdef __cplusplus } diff --git a/src/gui/preferences_cell_renderer.h b/src/gui/preferences_cell_renderer.h deleted file mode 100644 index 1c3ac1f..0000000 --- a/src/gui/preferences_cell_renderer.h +++ /dev/null @@ -1,58 +0,0 @@ -/* - * Xiphos Bible Study Tool - * preferences_cell_renderer.h - * - * Copyright (C) 2002-2008 Dave Camp - * taken form Anjuta-1.1.98 - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. - */ - -#ifndef PREFS_CELL_RENDERER_H -#define PREFS_CELL_RENDERER_H - -#include <gtk/gtkcellrenderer.h> -#include <gtk/gtkcellrenderertext.h> -#include <gtk/gtkcellrendererpixbuf.h> - -G_BEGIN_DECLS - -#define PREFS_TYPE_CELL_RENDERER_CAPTIONED_IMAGE (preferences_cell_renderer_captioned_image_get_type ()) -#define PREFS_CELL_RENDERER_CAPTIONED_IMAGE(obj) (GTK_CHECK_CAST ((obj), PREFS_TYPE_CELL_RENDERER_CAPTIONED_IMAGE, CellRendererCaptionedImage)) -#define PREFS_CELL_RENDERER_CAPTIONED_IMAGE_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), PREFS_TYPE_CELL_RENDERER_CAPTIONED_IMAGE, CellRendererCaptionedImageClass)) -#define PREFS_IS_CELL_RENDERER_CAPTIONED_IMAGE(obj) (GTK_CHECK_TYPE ((obj), PREFS_TYPE_CELL_RENDERER_CAPTIONED_IMAGE)) -#define PREFS_IS_CELL_RENDERER_CAPTIONED_IMAGE_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), PREFS_TYPE_CELL_RENDERER_CAPTIONED_IMAGE)) -#define PREFS_CELL_RENDERER_CAPTIONED_IMAGE_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), PREFS_TYPE_CELL_RENDERER_CAPTIONED_IMAGE, CellRendererCaptionedImageClass)) - -typedef struct _CellRendererCaptionedImage CellRendererCaptionedImage; -typedef struct _CellRendererCaptionedImageClass CellRendererCaptionedImageClass; - -struct _CellRendererCaptionedImage { - GtkCellRenderer parent; - - GtkCellRenderer *image; - GtkCellRenderer *caption; -}; - -struct _CellRendererCaptionedImageClass { - GtkCellRendererClass parent_class; -}; - -GType preferences_cell_renderer_captioned_image_get_type (void); -GtkCellRenderer *gui_preferences_cell_renderer_captioned_image_new (void); - -G_END_DECLS - -#endif diff --git a/src/gui/preferences_dialog.h b/src/gui/preferences_dialog.h index ecefa4c..eef06f3 100644 --- a/src/gui/preferences_dialog.h +++ b/src/gui/preferences_dialog.h @@ -26,6 +26,12 @@ extern "C" { #endif +#define NONE _("None") +extern char *locale_set[]; +/* for selecting special locale */ +/* autogenerated from po/LINGUAS */ +/* see src/gnome2/Makefile.am */ + void on_checkbutton1_toggled(GtkToggleButton * togglebutton, gpointer user_data); void on_checkbutton2_toggled(GtkToggleButton * togglebutton, gpointer user_data); void on_checkbutton3_toggled(GtkToggleButton * togglebutton, gpointer user_data); @@ -52,7 +58,7 @@ void on_combobox12_changed(GtkComboBox * combobox, gpointer user_data); void on_combobox13_changed(GtkComboBox * combobox, gpointer user_data); void on_combobox14_changed(GtkComboBox * combobox, gpointer user_data); void on_combobox15_changed(GtkComboBox * combobox, gpointer user_data); - +void on_combobox16_changed(GtkComboBox * combobox, gpointer user_data); void on_colorbutton1_color_set(GtkColorButton *colorbutton, gpointer user_data); void on_colorbutton2_color_set(GtkColorButton * colorbutton, gpointer user_data); void on_colorbutton3_color_set(GtkColorButton * colorbutton, gpointer user_data); @@ -61,9 +67,20 @@ void on_colorbutton5_color_set(GtkColorButton * colorbutton, gpointer user_data) void on_dialog_prefs_response(GtkDialog * dialog, gint response_id, gpointer user_data); - void gui_setup_preferences_dialog(void); +void on_colorbutton6_color_set(GtkColorButton * colorbutton, gpointer user_data); +void on_colorbutton7_color_set(GtkColorButton * colorbutton, gpointer user_data); +void on_checkbutton10_toggled(GtkToggleButton * togglebutton, gpointer user_data); +void on_checkbutton11_toggled(GtkToggleButton * togglebutton, gpointer user_data); +void on_checkbutton12_toggled(GtkToggleButton * togglebutton, gpointer user_data); +void on_checkbutton_scroll_toggled(GtkToggleButton * togglebutton, gpointer user_data); +void on_checkbutton_imageresize_toggled(GtkToggleButton * togglebutton, gpointer user_data); +void on_checkbutton_versehighlight_toggled(GtkToggleButton * togglebutton, gpointer user_data); +void on_checkbutton_doublespace_toggled(GtkToggleButton * togglebutton, gpointer user_data); +void on_checkbutton_prayerlist_toggled(GtkToggleButton * togglebutton, gpointer user_data); +void on_basecombobox1_changed(GtkComboBox * combobox, gpointer user_data); + #ifdef __cplusplus } #endif diff --git a/src/gui/search_dialog.h b/src/gui/search_dialog.h index 99eb9b8..34abcba 100644 --- a/src/gui/search_dialog.h +++ b/src/gui/search_dialog.h @@ -25,7 +25,7 @@ #ifdef __cplusplus extern "C" { #endif -#include <gnome.h> +#include <gtk/gtk.h> typedef struct _search_dialog1 SEARCH_DIALOG1; @@ -107,6 +107,32 @@ extern gchar *verse_selected; void gui_create_search_dialog(void); void gui_set_drop_target(GtkWidget * target); +void on_comboboxentry2_changed(GtkComboBox * combobox, gpointer user_data); +void button_clean(GtkButton * button, gpointer user_data); +void button_save(GtkButton * button, gpointer user_data); +void button_export(GtkButton * button, gpointer user_data); +void _on_destroy(GtkWidget * dialog, gpointer user_data); +void on_button_begin_search(GtkButton * button, gpointer user_data); +void on_togglebutton_show_main(GtkToggleButton * togglebutton, gpointer user_data); +void list_name_changed(GtkEditable * editable, gpointer user_data); +void range_name_changed(GtkEditable * editable, gpointer user_data); +void range_text_changed(GtkEditable * editable, gpointer user_data); +void new_modlist(GtkButton * button, gpointer user_data); +void clear_modules(GtkButton * button, gpointer user_data); +void delete_module(GtkButton * button, gpointer user_data); +void save_modlist(GtkButton * button, gpointer user_data); +void new_range(GtkButton * button, gpointer user_data); +void save_range(GtkButton * button, gpointer user_data); +void delete_range(GtkButton * button, gpointer user_data); +void delete_list(GtkButton * button, gpointer user_data); +void scope_toggled(GtkToggleButton * togglebutton, gpointer user_data); +void mod_list_toggled(GtkToggleButton * togglebutton, gpointer user_data); +void current_module_toggled(GtkToggleButton * togglebutton, gpointer user_data); +gboolean _on_button_release_event(GtkWidget * widget, GdkEventButton * event, gpointer data); +void on_closebutton2_clicked(GtkButton * button, gpointer user_data); +void _on_dialog2_response(GtkDialog * dialog, gint response_id, gpointer user_data); +void on_toolbutton12_clicked(GtkToolButton * toolbutton, gpointer user_data); +void _on_dialog_response(GtkDialog * dialog, gint response_id, gpointer user_data); #ifdef __cplusplus } diff --git a/src/gui/search_sidebar.h b/src/gui/search_sidebar.h index 33976bd..f3b9b58 100644 --- a/src/gui/search_sidebar.h +++ b/src/gui/search_sidebar.h @@ -25,7 +25,6 @@ #ifdef __cplusplus extern "C" { #endif -//#include <gnome.h> typedef struct _sidebar_search SIDESEARCH; struct _sidebar_search { diff --git a/src/gui/session.h b/src/gui/session.h deleted file mode 100644 index f9942f7..0000000 --- a/src/gui/session.h +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Xiphos Bible Study Tool - * session.h - create and maintain a GNOME session - * - * based on code from gedit - * gedit-session - Basic session management for gedit - * Copyright (C) 2002 Ximian, Inc. - * Authors Federico Mena-Quintero <federico@ximian.com> - * - * Copyright (C) 2000-2009 Xiphos Developer Team - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Library General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. - */ - - -#ifndef __GS_SESSION_H__ -#define __GS_SESSION_H__ - -void gs_session_init (const char *argv0); -gboolean gs_session_is_restored (void); - -#endif diff --git a/src/gui/sidebar.h b/src/gui/sidebar.h index 4e7db49..eadea6d 100644 --- a/src/gui/sidebar.h +++ b/src/gui/sidebar.h @@ -56,6 +56,8 @@ struct _search_results { }; extern GList *list_of_verses; +extern GtkListStore *model_verselist; +extern gboolean is_search_result; #ifdef USE_TREEVIEW_PATH void gui_collapse_treeview_to_book (GtkTreeView * tree, const gchar * book_name); @@ -73,6 +75,24 @@ gboolean vpaned_srch_rslt_button_release_event(GtkWidget * widget, GdkEventButton * event, gpointer user_data); void gui_show_previewer_in_sidebar(gint choice); +void gui_sync_module_treeview(gint direction); +void on_save_list_as_a_single_bookmark_activate (GtkMenuItem * menuitem, gpointer user_data); +void on_save_list_as_a_series_of_bookmarks_activate (GtkMenuItem * menuitem, gpointer user_data); +GtkWidget *create_results_menu(void); +void on_open_in_dialog_activate(GtkMenuItem * menuitem, + gpointer user_data); +void on_open_in_tab_activate2(GtkMenuItem * menuitem, + gpointer user_data); +void on_about2_activate(GtkMenuItem * menuitem, + gpointer user_data); +void on_simple_activate(GtkMenuItem *menuitem, gpointer user_data); +void on_subject_activate(GtkMenuItem *menuitem, gpointer user_data); +void on_monthly_activate(GtkMenuItem *menuitem, gpointer user_data); +void on_journal_activate(GtkMenuItem *menuitem, gpointer user_data); +void on_outlined_topic_activate(GtkMenuItem *menuitem, gpointer user_data); +GtkWidget *create_menu_prayerlist(void); +void on_edit_activate(GtkMenuItem *menuitem, gpointer user_data); +GtkWidget *create_menu_prayerlist_mod(void); #ifdef __cplusplus } diff --git a/src/gui/splash.h b/src/gui/splash.h index 5d4939b..44d0ea9 100644 --- a/src/gui/splash.h +++ b/src/gui/splash.h @@ -27,7 +27,8 @@ GtkType l##_get_type(void)\ } void gui_splash_init(void); -void gui_splash_done(void); +gboolean gui_splash_done(void); void gui_splash_step(gchar *text, gdouble progress, gint step); +gboolean expose_event_callback (GtkWidget *widget, GdkEventExpose *event, gpointer data); #endif diff --git a/src/gui/tabbed_browser.h b/src/gui/tabbed_browser.h index 39cd486..2a6e916 100644 --- a/src/gui/tabbed_browser.h +++ b/src/gui/tabbed_browser.h @@ -26,7 +26,7 @@ #ifdef __cplusplus extern "C" { #endif -#include <gnome.h> +#include <gtk/gtk.h> #include "main/tab_history.h" #define TABHISTORYLENGTH 25 @@ -102,6 +102,12 @@ void on_notebook_main_new_tab_clicked(GtkButton *button, gpointer user_data); extern gboolean change_tabs_no_redisplay; +void gui_recompute_shows(void); +void gui_recompute_view_menu_choices(void); +void setup_book_editor_tab(PASSAGE_TAB_INFO *pt); +GString *pick_tab_label(PASSAGE_TAB_INFO *pt); +void gui_notebook_main_switch_page(GtkNotebook * notebook, GtkNotebookPage * page, gint page_num, GList **tl); + #ifdef __cplusplus } #endif diff --git a/src/gui/treekey-editor.h b/src/gui/treekey-editor.h index 750460d..ae9dc2b 100644 --- a/src/gui/treekey-editor.h +++ b/src/gui/treekey-editor.h @@ -28,6 +28,7 @@ extern "C" #endif GtkWidget *gui_create_editor_tree(EDITOR * editor); +GtkWidget *create_edit_tree_menu (EDITOR * editor); #ifdef __cplusplus } diff --git a/src/gui/utilities.h b/src/gui/utilities.h index 1efcc56..fa3183a 100644 --- a/src/gui/utilities.h +++ b/src/gui/utilities.h @@ -26,9 +26,10 @@ extern "C" { #endif -#include <gnome.h> +#include <libxml/parser.h> #include "main/configs.h" #include "main/module_dialogs.h" +#include <gsf/gsf-outfile.h> gint gui_of2tf(const gchar * on_off); gchar *gui_tf2of(gint true_false); @@ -48,12 +49,8 @@ void gui_load_module_tree(GtkWidget * tree); MOD_FONT *get_font(gchar * mod_name); void free_font(MOD_FONT *mf); gchar * remove_linefeeds(gchar * buf); -void gui_add_item2gnome_menu(GtkWidget * MainFrm, gchar * itemname, - gchar * itemdata, gchar * submenuname, GCallback mycallback); -void gui_add_separator2menu(GtkWidget * MainFrm, gchar * subtreelabel); void gui_add_mods_to_menus(GList * modlist, gchar * menu, GCallback callback); -void gui_remove_menu_items(gchar *startitem, gint numberofitems); void gui_add_mods_2_gtk_menu(gint mod_type, GtkWidget * menu, GCallback callback); gchar *ncr_to_utf8(gchar * text); @@ -77,11 +74,26 @@ void language_make_list(GList *modlist, GtkTreeIter *uninstalled, void (*add)(GtkTreeModel *, GtkTreeIter, gchar **)); -char *image_locator(char *image); +char *image_locator(const char *image); GtkWidget *pixmap_finder(char *image); -GdkPixbuf *pixbuf_finder(char *image, GError **error); +GdkPixbuf *pixbuf_finder(const char *image, int size, GError **error); void HtmlOutput(char *text, GtkWidget *gtkText, MOD_FONT *mf, char *anchor); +void set_window_icon(GtkWindow *window); +gboolean xiphos_open_default(const gchar *file); + +void archive_addfile(GsfOutfile *output, const gchar *file, const gchar *name); +void archive_adddir(GsfOutfile *output, gchar *path, const gchar *name); +void xiphos_create_archive(gchar* conf_file, gchar* datapath, gchar *zip, + const gchar *destination); + + +#ifdef WIN32 +gchar* xiphos_win32_get_subdir(const gchar *subdir); +#endif +void utilities_parse_treeview(xmlNodePtr parent, + GtkTreeIter * tree_parent, + GtkTreeModel *model); enum { LANGSET_BIBLE, @@ -98,6 +110,8 @@ enum { #define LANGSET_COUNT 200 +void language_init(void); + #ifdef __cplusplus } #endif diff --git a/src/gui/widgets.h b/src/gui/widgets.h index b3b2400..196051f 100644 --- a/src/gui/widgets.h +++ b/src/gui/widgets.h @@ -29,7 +29,7 @@ typedef struct _app_widgets WIDGETS; struct _app_widgets { GtkWidget *app, /* main form */ - *appbar, /* gnome status/progress bar */ + *appbar, /* gtk status/progress bar */ *vboxMain, /* */ *page, /* */ *epaned, /* sidebar bar and main panel */ @@ -93,7 +93,7 @@ struct _app_widgets { *cb_books, /* textview widget */ - *textview, + //*textview, /* listview widget */ *listview_dict, *store, |