1 #include "gcin.h"
2 #include "gtab.h"
3 #include "pho.h"
4 #include "tsin.h"
5 #include "gst.h"
6 #include "im-client/gcin-im-client-attr.h"
7 #include "win1.h"
8 #include "gcin-module.h"
9 
10 void show_win_sym(),hide_win_sym(),move_win_sym(),toggle_win_sym();
11 void init_tsin_selection_win(),disp_selections(int x, int y),hide_selections_win();
12 void disp_arrow_up(),disp_arrow_down(), set_tsin_pho_mode();
13 void set_sele_text(int i, char *text, int len);
14 void tsin_set_eng_ch(int nmod);
15 int get_widget_xy(GtkWidget *win, GtkWidget *widget, int *rx, int *ry);
16 void get_win_size(GtkWidget *win, int *width, int *height);
17 void exec_gcin_setup();
18 void load_tab_pho_file();
19 void clear_sele();
20 void send_utf8_ch(char *s);
21 extern gboolean force_show;
22 #if WIN32
23 extern int test_mode;
24 void win32_init_win(GtkWidget *);
25 #endif
26 
init_GCIN_module_main_functions(GCIN_module_main_functions * func)27 void init_GCIN_module_main_functions(GCIN_module_main_functions *func)
28 {
29   func->mf_show_win_sym = show_win_sym;
30   func->mf_hide_win_sym = hide_win_sym;
31   func->mf_move_win_sym = move_win_sym;
32   func->mf_toggle_win_sym = toggle_win_sym;
33 
34   func->mf_init_tsin_selection_win = init_tsin_selection_win;
35   func->mf_clear_sele = clear_sele;
36   func->mf_disp_selections = disp_selections;
37   func->mf_hide_selections_win = hide_selections_win;
38   func->mf_disp_arrow_up = disp_arrow_up;
39   func->mf_disp_arrow_down = disp_arrow_down;
40   func->mf_set_sele_text = set_sele_text;
41   func->mf_set_win1_cb = set_win1_cb;
42 
43   func->mf_tsin_set_eng_ch = tsin_set_eng_ch;
44   func->mf_tsin_pho_mode = tsin_pho_mode;
45   func->mf_set_tsin_pho_mode = set_tsin_pho_mode;
46 
47   func->mf_get_widget_xy = get_widget_xy;
48   func->mf_get_win_size = get_win_size;
49   func->mf_change_win_bg = change_win_bg;
50   func->mf_set_label_font_size = set_label_font_size;
51   func->mf_set_no_focus = set_no_focus;
52 
53 
54   func->mf_current_time = current_time;
55 
56   func->mf_exec_gcin_setup = exec_gcin_setup;
57   func->mf_gcin_edit_display_ap_only = gcin_edit_display_ap_only;
58   func->mf_inmd_switch_popup_handler = inmd_switch_popup_handler;
59   func->mf_load_tab_pho_file = load_tab_pho_file;
60   func->mf_send_text = send_text;
61   func->mf_send_utf8_ch = send_utf8_ch;
62   func->mf_utf8_str_N = utf8_str_N;
63 
64   func->mf_phkbm = &phkbm;
65   func->mf_tss = &tss;
66   func->mf_tsin_chinese_english_toggle_key = &tsin_chinese_english_toggle_key;
67 
68   func->mf_gcin_pop_up_win = &gcin_pop_up_win;
69   func->mf_gcin_font_size = &gcin_font_size;
70   func->mf_gcin_win_color_fg = &gcin_win_color_fg;
71 
72   func->mf_gcin_win_color_use = &gcin_win_color_use;
73   func->mf_tsin_cursor_color = &tsin_cursor_color;
74   func->mf_pho_selkey = &pho_selkey;
75   func->mf_force_show = &force_show;
76   func->mf_win_x = &win_x;
77   func->mf_win_y = &win_y;
78   func->mf_win_xl = &win_xl;
79   func->mf_win_yl = &win_yl;
80   func->mf_dpy_xl = &dpy_xl;
81   func->mf_dpy_yl = &dpy_yl;
82   func->mf_pho_chars = pho_chars;
83   func->mf_box_warn = box_warn;
84 #if DEBUG
85   func->mf___gcin_dbg_ = __gcin_dbg_;
86 #endif
87 
88 #if WIN32
89   func->mf_test_mode = &test_mode;
90   func->mf_win32_init_win = win32_init_win;
91   func->mf__utf16_8 = __utf16_8;
92 #endif
93 }
94