1 /* -*- Mode: C; tab-width: 2; indent-tabs-mode: t; c-basic-offset: 2 -*- */ 2 3 #ifndef _CONF_H_ 4 #define _CONF_H_ 5 6 #include <gconf/gconf.h> 7 #include <glib.h> 8 #include "im-ja.h" 9 10 typedef struct _IMJAConfig IMJAConfig; 11 12 struct _IMJAConfig{ 13 guint hotkey_states[HOTKEYS_TOTAL]; 14 guint hotkey_values[HOTKEYS_TOTAL]; 15 16 GdkColor preedit_colors[4]; /* preedit string colors: n_fg, n_bg, hl_fg, hl_bg */ 17 gboolean custom_preedit_n; 18 gboolean custom_preedit_hl; 19 20 gint status_win_position; 21 gchar *status_win_labels[IM_JA_INPUT_METHODS_TOTAL]; 22 gint status_win_coords[2]; 23 24 gint default_conv_engine; 25 gchar *wnn_address; 26 gchar *wnnenvrc; 27 28 gboolean canna_enabled; 29 30 gboolean kanjipad_enabled; 31 gboolean kanjipad_custom_size; 32 gint kanjipad_size[2]; 33 34 gboolean use_systray; 35 gboolean preedit_window_on; 36 gint startup_input_method; 37 gchar *im_ja_version; 38 gint candwin_style; 39 gboolean custom_candwin_font; 40 gchar *candwin_font; 41 gboolean commit_on_reset; 42 43 gchar *browser; 44 gboolean dont_show_save_warning; 45 46 gint temp[200]; 47 }; 48 49 /* public function prototypes */ 50 gboolean im_ja_init_conf_handler(); 51 void im_ja_finalize_conf_handler(IMJAConfig *cfg); 52 gboolean im_ja_load_conf(IMJAConfig *cfg); 53 gboolean im_ja_save_conf(IMJAConfig *cfg); 54 gchar *get_string_from_color(GdkColor *color); 55 gboolean im_ja_get_gconf_client(); 56 gchar *im_ja_get_keyname(guint state, guint keyval); 57 58 #endif 59