From 444bde2e739d73c27418461fa001adb7b9ce83db Mon Sep 17 00:00:00 2001 From: Jose Antonio Ortega Ruiz Date: Sun, 24 Jun 2001 13:06:53 +0000 Subject: split windows mode --- mixgtk/.cvsignore | 3 + mixgtk/Makefile.am | 6 +- mixgtk/mixgtk.c | 64 +- mixgtk/mixgtk.glade | 3673 ++++++++++++++++++++++++++++------------ mixgtk/mixgtk_cmd_dispatcher.c | 11 +- mixgtk/mixgtk_cmd_dispatcher.h | 2 +- mixgtk/mixgtk_config.c | 22 +- mixgtk/mixgtk_config.h | 7 + mixgtk/mixgtk_fontsel.c | 23 +- mixgtk/mixgtk_fontsel.h | 2 +- mixgtk/mixgtk_mixal.c | 13 +- mixgtk/mixgtk_mixal.h | 3 +- mixgtk/mixgtk_mixvm.c | 23 +- mixgtk/mixgtk_mixvm.h | 3 +- mixgtk/mixgtk_widgets.c | 32 +- mixgtk/mixgtk_widgets.h | 7 +- mixgtk/mixgtk_wm.c | 139 ++ mixgtk/mixgtk_wm.h | 46 + 18 files changed, 2889 insertions(+), 1190 deletions(-) create mode 100644 mixgtk/mixgtk_wm.c create mode 100644 mixgtk/mixgtk_wm.h diff --git a/mixgtk/.cvsignore b/mixgtk/.cvsignore index 3682f8f..cf6d3f7 100644 --- a/mixgtk/.cvsignore +++ b/mixgtk/.cvsignore @@ -5,5 +5,8 @@ gmixvm gmixvm.core hello.mix mixgtk +mixgtk.glade.org +mixgtk.glade1 +mixgtk.split.glade paper.dev semantic.cache diff --git a/mixgtk/Makefile.am b/mixgtk/Makefile.am index 83b5035..c7e9aed 100644 --- a/mixgtk/Makefile.am +++ b/mixgtk/Makefile.am @@ -10,9 +10,10 @@ # WITHOUT ANY WARRANTY, to the extent permitted by law; without even the # implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. -EXTRA_DIST = mixgtk.glade +EXTRA_DIST = mixgtk.glade mixgtk.split.glade INCLUDES = -I$(includedir) -DGLADE_FILE=\""$(pkgdatadir)/mixgtk.glade"\"\ -DLOCAL_GLADE_FILE=\"mixgtk.glade\" + LDADD = $(top_builddir)/mixlib/libmix.a $(top_builddir)/lib/libreplace.a $(INTLLIBS) if MAKE_GUI @@ -28,7 +29,8 @@ gmixvm_SOURCES = gmixvm.c mixgtk.h mixgtk.c \ mixgtk_mixal.h mixgtk_mixal.c \ mixgtk_input.h mixgtk_input.c \ mixgtk_colorsel.h mixgtk_colorsel.c \ - mixgtk_fontsel.h mixgtk_fontsel.c + mixgtk_fontsel.h mixgtk_fontsel.c \ + mixgtk_wm.h mixgtk_wm.c endif diff --git a/mixgtk/mixgtk.c b/mixgtk/mixgtk.c index ff218f6..6089dd2 100644 --- a/mixgtk/mixgtk.c +++ b/mixgtk/mixgtk.c @@ -32,27 +32,20 @@ #include "mixgtk_colorsel.h" #include "mixgtk_fontsel.h" #include "mixgtk_config.h" +#include "mixgtk_wm.h" #include "mixgtk.h" +static const gchar *SPLIT_ARG_ = "-s"; +static const gchar *SPLIT_LONG_ARG_ = "--s"; /* initialise the app */ gboolean mixgtk_init (int argc, char *argv[]) { mix_vm_t *vm; - - const gchar *gfile = GLADE_FILE; - FILE *f = fopen (gfile, "r"); - if (!f && !(f = fopen ((gfile = LOCAL_GLADE_FILE), "r"))) - { - g_error ("Configuration file not found (tried %s and %s)", - GLADE_FILE, LOCAL_GLADE_FILE); - return FALSE; - } - fclose (f); + gboolean split = FALSE; + gint k; - gtk_init (&argc, &argv); - mix_init_lib (); if (!mixgtk_config_load ()) @@ -61,41 +54,62 @@ mixgtk_init (int argc, char *argv[]) return FALSE; } - if (!mixgtk_widget_factory_init (gfile)) + for (k = 0; k < argc; ++k) + if (!strcmp (argv[k], SPLIT_ARG_) || !strcmp (argv[k], SPLIT_LONG_ARG_)) + { + split = TRUE; + break; + } + if (!split && mixgtk_config_is_split ()) split = TRUE; + mixgtk_config_set_split (split); + + gtk_init (&argc, &argv); + + if (!mixgtk_widget_factory_init (split)) { - g_error ("Unable to initialise application using %s\n", gfile); + g_error ("Unable to initialise application: missing glade file"); return FALSE; } - if (!mixgtk_cmd_dispatcher_init ()) + if (!mixgtk_cmd_dispatcher_init (MIXGTK_MAIN)) { g_error ("Unable to initialise application (command dispatcher)\n"); return FALSE; } + if (split) + gtk_widget_show (mixgtk_widget_factory_get_dialog (MIXGTK_MAIN)); + vm = mixgtk_cmd_dispatcher_get_vm (); - if (!mixgtk_device_init (GTK_NOTEBOOK - (mixgtk_widget_factory_get (MIXGTK_WIDGET_DEVICE)), - vm)) + if (!mixgtk_mixvm_init (vm, MIXGTK_MIXVM_DIALOG)) { - g_error ("Unable to initialise application (devices)\n"); + g_error ("Unable to initialise application (mixvm widgets)\n"); return FALSE; } - if (!mixgtk_mixvm_init (vm)) + if (!mixgtk_mixal_init (vm, MIXGTK_MIXAL_DIALOG)) { - g_error ("Unable to initialise application (mixvm widgets)\n"); + g_error ("Unable to initialise application (mixal widgets)\n"); return FALSE; } - if (!mixgtk_mixal_init (vm)) + if (!mixgtk_device_init (GTK_NOTEBOOK + (mixgtk_widget_factory_get + (MIXGTK_DEVICES_DIALOG, MIXGTK_WIDGET_DEVICE)), + vm)) { - g_error ("Unable to initialise application (mixal widgets)\n"); + g_error ("Unable to initialise application (devices)\n"); return FALSE; } - - mixgtk_fontsel_load_defaults (); + + if (!mixgtk_wm_init ()) + { + g_error ("Unable to initialise application (visibility)\n"); + return FALSE; + } + + mixgtk_fontsel_load_defaults (split); return TRUE; } diff --git a/mixgtk/mixgtk.glade b/mixgtk/mixgtk.glade index 9962eb7..9d6fa49 100644 --- a/mixgtk/mixgtk.glade +++ b/mixgtk/mixgtk.glade @@ -351,6 +351,25 @@ False + + GtkCheckMenuItem + split_windows + + toggled + on_split_windows_toggled + Sun, 24 Jun 2001 12:39:53 GMT + + + False + False + + + + GtkMenuItem + separator3 + False + + GtkMenuItem save @@ -1344,177 +1363,706 @@ - GtkDialog - word_dialog + GtkWindow + split_main_window False destroy - gtk_widget_hide - Tue, 13 Mar 2001 00:53:39 GMT - - - destroy_event - gtk_widget_hide - Tue, 13 Mar 2001 00:55:38 GMT - - - delete_event - gtk_widget_hide - Tue, 13 Mar 2001 00:56:33 GMT + on_main_window_destroy + Tue, 20 Feb 2001 21:58:29 GMT - Enter value - GTK_WINDOW_DIALOG - GTK_WIN_POS_MOUSE - True - 250 - False - False - False + gmixvm + GTK_WINDOW_TOPLEVEL + GTK_WIN_POS_NONE + False + 570 + 215 + True + True + True GtkVBox - Dialog:vbox - dialog-vbox5 + main_vbox + 2 False - 0 + 2 - GtkHBox - Dialog:action_area - dialog-action_area5 - 10 - 250 - True - 5 + GtkMenuBar + mainmenubar + GTK_SHADOW_OUT 0 False - False - GTK_PACK_END + True - GtkHButtonBox - hbuttonbox5 - 250 - GTK_BUTTONBOX_DEFAULT_STYLE - 30 - 85 - 27 - 7 - 0 - - 0 - False - False - + GtkMenuItem + file + + False - GtkButton - word_reset - True - True - - clicked - on_word_reset_clicked - Mon, 12 Mar 2001 22:40:33 GMT - - - GTK_RELIEF_NORMAL - + GtkMenu + file_menu - - GtkButton - word_ok - True - True - - clicked - on_word_ok_clicked - Mon, 12 Mar 2001 22:40:45 GMT - - - GTK_RELIEF_NORMAL - + + GtkMenuItem + file_open + Load a MIX file + + GDK_MOD1_MASK + GDK_F3 + activate + + + activate + on_file_open_activate + Tue, 20 Feb 2001 22:37:58 GMT + + + False + - - GtkButton - word_cancel - True - True - - clicked - on_word_cancel_clicked - Mon, 12 Mar 2001 23:18:49 GMT - - - GTK_RELIEF_NORMAL - - - + + GtkMenuItem + edit + Edit a MIXAL source file + + GDK_MOD1_MASK + GDK_F4 + activate + + + activate + on_file_edit_activate + Fri, 08 Jun 2001 21:11:13 GMT + + + False + - - GtkFixed - word_layout - 250 - 97 - - 0 - False - False - + + GtkMenuItem + compile + Compile a MIXAL source file + + GDK_MOD1_MASK + GDK_F5 + activate + + + activate + on_file_compile_activate + Fri, 08 Jun 2001 21:11:33 GMT + + + False + - - GtkEntry - word_decimal - 88 - 32 - 143 - 22 - True - True - - key_press_event - on_word_dec_key_press - True - Mon, 12 Mar 2001 22:37:13 GMT - - True - True - 11 - 0 - + + GtkMenuItem + separator2 + False + - - GtkEntry - word_b2 - 136 - 64 - 22 - 22 - True - - key_press_event - on_word_byte_key_press - True - Mon, 12 Mar 2001 22:38:56 GMT - - True - True - 3 - 00 + + GtkMenuItem + file_exit + Exit application + + GDK_MOD1_MASK + GDK_Q + activate + + + activate + on_file_exit_activate + Tue, 20 Feb 2001 22:37:58 GMT + + + False + + - GtkEntry - word_b3 - 160 - 64 - 22 - 22 - True - - key_press_event + GtkMenuItem + view + + False + + + GtkMenu + view_menu + + + GtkCheckMenuItem + mix_view + + toggled + on_view_toggled + Sun, 24 Jun 2001 12:24:52 GMT + + + True + False + + + + GtkCheckMenuItem + mixal_view + + toggled + on_view_toggled + Sun, 24 Jun 2001 12:25:14 GMT + + + True + False + + + + GtkCheckMenuItem + devices_view + + toggled + on_view_toggled + Sun, 24 Jun 2001 12:25:38 GMT + + + True + False + + + + + + GtkMenuItem + debug + + False + + + GtkMenu + debug_menu + + + GtkMenuItem + debug_run + Run program + + GDK_MOD1_MASK + GDK_R + activate + + + activate + on_debug_run_activate + Sat, 10 Mar 2001 11:35:16 GMT + + + False + + + + GtkMenuItem + debug_next + Execute next instruction + + GDK_MOD1_MASK + GDK_N + activate + + + activate + on_debug_next_activate + Sat, 10 Mar 2001 11:35:16 GMT + + + False + + + + GtkMenuItem + clear_breakpoints + Clear all set breakpoints + + GDK_MOD1_MASK + GDK_C + activate + + + activate + on_clear_breakpoints_activate + Thu, 15 Mar 2001 23:26:49 GMT + + + False + + + + GtkMenuItem + symbols + Show the symbol table + + GDK_MOD1_MASK + GDK_Y + activate + + + activate + on_symbols_activate + Mon, 18 Jun 2001 22:17:06 GMT + + + False + + + + + + GtkMenuItem + settings1 + + False + + + GtkMenu + settings1_menu + + + GtkMenuItem + colors + Change colors of MIXAL + + activate + on_colors_activate + Wed, 11 Apr 2001 23:15:11 GMT + + + False + + + + GtkMenuItem + fonts1 + + False + + + GtkMenu + fonts1_menu + + + GtkMenuItem + mix + + activate + on_mix_font_activate + Wed, 25 Apr 2001 01:55:53 GMT + + + False + + + + GtkMenuItem + mixal + + activate + on_mixal_font_activate + Wed, 25 Apr 2001 01:55:53 GMT + + + False + + + + GtkMenuItem + command_prompt + + activate + on_prompt_font_activate + Wed, 25 Apr 2001 01:55:53 GMT + + + False + + + + GtkMenuItem + command_log + + activate + on_log_font_activate + Wed, 25 Apr 2001 01:55:53 GMT + + + False + + + + GtkMenuItem + devices + + activate + on_devices_font_activate + Thu, 10 May 2001 21:38:40 GMT + + + False + + + + + + GtkMenuItem + device_output1 + Change format of binary devices output + + activate + on_devform_activate + Wed, 30 May 2001 20:44:48 GMT + + + False + + + + GtkMenuItem + external_programs1 + + activate + on_external_programs_activate + Fri, 01 Jun 2001 23:35:01 GMT + + + False + + + + GtkMenuItem + separator1 + False + + + + GtkCheckMenuItem + split_windows + + toggled + on_split_windows_toggled + Sun, 24 Jun 2001 12:26:00 GMT + + + True + False + + + + GtkMenuItem + separator3 + False + + + + GtkMenuItem + save + Save current settings + + activate + on_save_activate + Sat, 28 Apr 2001 22:51:02 GMT + + + False + + + + GtkCheckMenuItem + save_on_exit + Toogle save settings on exit + + toggled + on_save_on_exit_toggle + Sun, 29 Apr 2001 10:26:16 GMT + + + False + False + + + + + + GtkMenuItem + help + + True + + + GtkMenu + help_menu + + + GtkMenuItem + about + + activate + on_about_activate + Tue, 13 Mar 2001 01:37:20 GMT + + + True + + + + + + + GtkStatusbar + main_statusbar + + 0 + False + False + GTK_PACK_END + + + + + GtkVBox + vbox3 + False + 0 + + 0 + True + True + + + + GtkScrolledWindow + mixcmd_scrolledwindow + GTK_POLICY_AUTOMATIC + GTK_POLICY_AUTOMATIC + GTK_UPDATE_CONTINUOUS + GTK_UPDATE_CONTINUOUS + + 0 + True + True + + + + GtkText + command_log + False + + + + + + GtkEntry + command_prompt + Enter MIXVM command here + True + True + + key_press_event + on_command_prompt_key_press_event + True + Wed, 06 Jun 2001 06:46:05 GMT + + True + True + 0 + + + 0 + False + False + + + + + + + + GtkDialog + word_dialog + False + + destroy + gtk_widget_hide + Tue, 13 Mar 2001 00:53:39 GMT + + + destroy_event + gtk_widget_hide + Tue, 13 Mar 2001 00:55:38 GMT + + + delete_event + gtk_widget_hide + Tue, 13 Mar 2001 00:56:33 GMT + + Enter value + GTK_WINDOW_DIALOG + GTK_WIN_POS_MOUSE + True + 250 + False + False + False + + + GtkVBox + Dialog:vbox + dialog-vbox5 + False + 0 + + + GtkHBox + Dialog:action_area + dialog-action_area5 + 10 + 250 + True + 5 + + 0 + False + False + GTK_PACK_END + + + + GtkHButtonBox + hbuttonbox5 + 250 + GTK_BUTTONBOX_DEFAULT_STYLE + 30 + 85 + 27 + 7 + 0 + + 0 + False + False + + + + GtkButton + word_reset + True + True + + clicked + on_word_reset_clicked + Mon, 12 Mar 2001 22:40:33 GMT + + + GTK_RELIEF_NORMAL + + + + GtkButton + word_ok + True + True + + clicked + on_word_ok_clicked + Mon, 12 Mar 2001 22:40:45 GMT + + + GTK_RELIEF_NORMAL + + + + GtkButton + word_cancel + True + True + + clicked + on_word_cancel_clicked + Mon, 12 Mar 2001 23:18:49 GMT + + + GTK_RELIEF_NORMAL + + + + + + GtkFixed + word_layout + 250 + 97 + + 0 + False + False + + + + GtkEntry + word_decimal + 88 + 32 + 143 + 22 + True + True + + key_press_event + on_word_dec_key_press + True + Mon, 12 Mar 2001 22:37:13 GMT + + True + True + 11 + 0 + + + + GtkEntry + word_b2 + 136 + 64 + 22 + 22 + True + + key_press_event + on_word_byte_key_press + True + Mon, 12 Mar 2001 22:38:56 GMT + + True + True + 3 + 00 + + + + GtkEntry + word_b3 + 160 + 64 + 22 + 22 + True + + key_press_event on_word_byte_key_press True Mon, 12 Mar 2001 22:39:26 GMT @@ -1526,93 +2074,570 @@ - GtkEntry - word_b4 - 184 - 64 - 22 - 22 - True - - key_press_event - on_word_byte_key_press - True - Mon, 12 Mar 2001 22:39:50 GMT - - True - True - 3 - 00 + GtkEntry + word_b4 + 184 + 64 + 22 + 22 + True + + key_press_event + on_word_byte_key_press + True + Mon, 12 Mar 2001 22:39:50 GMT + + True + True + 3 + 00 + + + + GtkEntry + word_b5 + 208 + 64 + 22 + 22 + True + + key_press_event + on_word_byte_key_press + True + Mon, 12 Mar 2001 22:40:09 GMT + + True + True + 3 + 00 + + + + GtkEntry + word_b1 + 112 + 64 + 22 + 22 + True + True + + key_press_event + on_word_byte_key_press + True + Mon, 12 Mar 2001 22:38:24 GMT + + True + True + 3 + 00 + + + + GtkEntry + word_sign + 88 + 64 + 16 + 24 + True + + key_press_event + on_word_sign_key_press + Tue, 13 Mar 2001 00:15:28 GMT + + True + True + 1 + + + + + + GtkLabel + label61 + 22 + 67 + 41 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + + GtkLabel + word_label + 16 + 8 + 216 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + + GtkLabel + label60 + 16 + 34 + 67 + 20 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + + + + + GtkWindow + about_dialog + 368 + 99 + False + + delete_event + gtk_widget_hide + Tue, 13 Mar 2001 13:13:42 GMT + + + destroy_event + gtk_widget_hide + Tue, 13 Mar 2001 13:14:02 GMT + + + destroy + gtk_widget_hide + Tue, 13 Mar 2001 13:14:25 GMT + + MDK + GTK_WINDOW_DIALOG + GTK_WIN_POS_CENTER + True + False + False + False + + + GtkLayout + layout1 + 375 + 190 + 200 + 120 + 0 + 0 + + + GtkLabel + label222 + 56 + 16 + 247 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + + GtkLabel + version_label + 152 + 40 + 56 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + + GtkLabel + label224 + 0 + 64 + 358 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + + GtkHSeparator + hseparator4 + 8 + 0 + 356 + 16 + + + + GtkHSeparator + hseparator5 + 8 + 80 + 356 + 16 + + + + GtkVSeparator + vseparator4 + 0 + 7 + 16 + 81 + + + + GtkVSeparator + vseparator5 + 354 + 8 + 16 + 81 + + + + + + GtkDialog + goto_dialog + 193 + 120 + False + + destroy_event + gtk_widget_hide + Wed, 14 Mar 2001 14:39:17 GMT + + + delete_event + gtk_widget_hide + Wed, 14 Mar 2001 14:39:41 GMT + + + destroy + gtk_widget_hide + Wed, 14 Mar 2001 14:40:15 GMT + + Go to memory cell + GTK_WINDOW_DIALOG + GTK_WIN_POS_MOUSE + True + False + False + False + + + GtkVBox + Dialog:vbox + dialog-vbox6 + False + 0 + + + GtkHBox + Dialog:action_area + dialog-action_area6 + 10 + 40 + True + 5 + + 0 + False + True + GTK_PACK_END + + + + GtkHButtonBox + hbuttonbox6 + GTK_BUTTONBOX_DEFAULT_STYLE + 30 + 85 + 27 + 7 + 0 + + 0 + True + True + + + + GtkButton + goto_cancel + True + True + + clicked + on_goto_cancel_clicked + Wed, 14 Mar 2001 14:24:59 GMT + + + GTK_RELIEF_NORMAL + + + + GtkButton + goto_ok + True + True + + clicked + on_goto_ok_clicked + Wed, 14 Mar 2001 14:25:23 GMT + + + GTK_RELIEF_NORMAL + + + + + + GtkVBox + vbox1 + 12 + 75 + False + 0 + + 0 + False + False + + + + GtkLabel + label225 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + 0 + True + True + GtkEntry - word_b5 - 208 - 64 - 22 - 22 + goto_entry + 44 True + True - key_press_event - on_word_byte_key_press - True - Mon, 12 Mar 2001 22:40:09 GMT + activate + on_goto_ok_clicked + Wed, 14 Mar 2001 14:52:26 GMT True True - 3 - 00 + 4 + + + 10 + False + False + + + + + + + + GtkDialog + color_dialog + 275 + 214 + False + + delete_event + gtk_widget_hide + Thu, 12 Apr 2001 21:05:54 GMT + + + destroy_event + gtk_widget_hide + Thu, 12 Apr 2001 21:06:09 GMT + + + destroy + gtk_widget_hide + Thu, 12 Apr 2001 21:06:23 GMT + + MIXAL colors + GTK_WINDOW_DIALOG + GTK_WIN_POS_NONE + True + False + False + False + + + GtkVBox + Dialog:vbox + dialog-vbox7 + False + 0 + + + GtkHBox + Dialog:action_area + dialog-action_area7 + 10 + True + 5 + + 0 + False + True + GTK_PACK_END + + + + GtkHButtonBox + hbuttonbox7 + GTK_BUTTONBOX_DEFAULT_STYLE + 30 + 85 + 27 + 7 + 0 + + 0 + True + True + + + + GtkButton + colors_ok + True + True + + clicked + on_colors_ok_clicked + Thu, 12 Apr 2001 21:05:07 GMT + + + GTK_RELIEF_NORMAL + + + + GtkButton + colors_apply + True + True + + clicked + on_colors_apply_clicked + Thu, 12 Apr 2001 21:04:56 GMT + + + GTK_RELIEF_NORMAL + + + + GtkButton + colors_cancel + True + True + + clicked + on_colors_cancel_clicked + Thu, 12 Apr 2001 21:04:45 GMT + + + GTK_RELIEF_NORMAL + + + + + GtkFixed + fixed1 + + 0 + True + True + - GtkEntry - word_b1 - 112 - 64 - 22 - 22 - True - True - - key_press_event - on_word_byte_key_press - True - Mon, 12 Mar 2001 22:38:24 GMT - - True - True - 3 - 00 + GtkLabel + label230 + 184 + 32 + 78 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 - GtkEntry - word_sign - 88 - 64 - 16 - 24 - True - - key_press_event - on_word_sign_key_press - Tue, 13 Mar 2001 00:15:28 GMT - - True - True - 1 - + + GtkLabel + label226 + 0 + 8 + 143 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 GtkLabel - label61 - 22 - 67 - 41 + label227 + 0 + 56 + 79 16 - + GTK_JUSTIFY_CENTER False 0.5 @@ -1623,12 +2648,12 @@ GtkLabel - word_label - 16 - 8 - 216 + label229 + 88 + 32 + 78 16 - + GTK_JUSTIFY_CENTER False 0.5 @@ -1637,14 +2662,84 @@ 0 + + GtkDrawingArea + clbg_area + 90 + 56 + 75 + 15 + + + + GtkDrawingArea + clfg_area + 184 + 56 + 75 + 15 + + + + GtkDrawingArea + bpfg_area + 184 + 94 + 75 + 15 + + + + GtkDrawingArea + plbg_area + 90 + 128 + 75 + 15 + + GtkLabel - label60 - 16 - 34 - 67 - 20 - + label231 + 1 + 128 + 77 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + + GtkDrawingArea + bpbg_area + 90 + 94 + 75 + 15 + + + + GtkDrawingArea + plfg_area + 184 + 128 + 75 + 15 + + + + GtkLabel + label228 + 0 + 94 + 76 + 16 + GTK_JUSTIFY_CENTER False 0.5 @@ -1657,154 +2752,173 @@ - GtkWindow - about_dialog - 368 - 99 + GtkColorSelectionDialog + colorsel_dialog + 10 False delete_event gtk_widget_hide - Tue, 13 Mar 2001 13:13:42 GMT + Sat, 21 Apr 2001 23:14:28 GMT destroy_event gtk_widget_hide - Tue, 13 Mar 2001 13:14:02 GMT + Sat, 21 Apr 2001 23:14:54 GMT destroy gtk_widget_hide - Tue, 13 Mar 2001 13:14:25 GMT + Sat, 21 Apr 2001 23:15:12 GMT - MDK + Select Color GTK_WINDOW_DIALOG - GTK_WIN_POS_CENTER + GTK_WIN_POS_NONE True False False False + GTK_UPDATE_CONTINUOUS - GtkLayout - layout1 - 375 - 190 - 200 - 120 - 0 - 0 - - - GtkLabel - label222 - 56 - 16 - 247 - 16 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - - - - GtkLabel - version_label - 152 - 40 - 56 - 16 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - + GtkButton + ColorSel:ok_button + ok_colorserdlg + True + True + + clicked + on_ok_colorseldlg_clicked + Sat, 21 Apr 2001 23:17:15 GMT + + + GTK_RELIEF_NORMAL + - - GtkLabel - label224 - 0 - 64 - 358 - 16 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - + + GtkButton + ColorSel:cancel_button + cancel_colorseldlg + True + True + + clicked + on_cancel_colorseldlg_clicked + Sat, 21 Apr 2001 23:17:37 GMT + + + GTK_RELIEF_NORMAL + - - GtkHSeparator - hseparator4 - 8 - 0 - 356 - 16 - + + GtkButton + ColorSel:help_button + help_button1 + True + True + + GTK_RELIEF_NORMAL + + - - GtkHSeparator - hseparator5 - 8 - 80 - 356 - 16 - + + GtkFontSelectionDialog + fontsel_dialog + 4 + False + + delete_event + gtk_widget_hide + Thu, 26 Apr 2001 21:14:34 GMT + + + destroy_event + gtk_widget_hide + Thu, 26 Apr 2001 21:15:02 GMT + + + destroy + gtk_widget_hide + Thu, 26 Apr 2001 21:15:13 GMT + + Select Font + GTK_WINDOW_DIALOG + GTK_WIN_POS_NONE + False + False + True + True - - GtkVSeparator - vseparator4 - 0 - 7 - 16 - 81 - + + GtkButton + FontSel:ok_button + ok_button1 + True + True + + clicked + on_fontsel_ok_clicked + Thu, 26 Apr 2001 21:40:53 GMT + + + GTK_RELIEF_NORMAL + - - GtkVSeparator - vseparator5 - 354 - 8 - 16 - 81 - + + GtkButton + FontSel:apply_button + apply_button1 + True + True + + clicked + on_fontsel_apply_clicked + Thu, 26 Apr 2001 21:41:12 GMT + + + GTK_RELIEF_NORMAL + + + + GtkButton + FontSel:cancel_button + cancel_button1 + True + True + + clicked + on_fontsel_cancel_clicked + Thu, 26 Apr 2001 21:41:33 GMT + + + GTK_RELIEF_NORMAL GtkDialog - goto_dialog - 193 - 120 + devform_dialog + 308 + 172 False - destroy_event + delete_event gtk_widget_hide - Wed, 14 Mar 2001 14:39:17 GMT + Wed, 30 May 2001 20:14:53 GMT - delete_event + destroy_event gtk_widget_hide - Wed, 14 Mar 2001 14:39:41 GMT + Wed, 30 May 2001 20:15:13 GMT destroy gtk_widget_hide - Wed, 14 Mar 2001 14:40:15 GMT + Wed, 30 May 2001 20:15:29 GMT - Go to memory cell + Device output format GTK_WINDOW_DIALOG - GTK_WIN_POS_MOUSE + GTK_WIN_POS_NONE True False False @@ -1813,16 +2927,15 @@ GtkVBox Dialog:vbox - dialog-vbox6 + dialog-vbox8 False 0 GtkHBox Dialog:action_area - dialog-action_area6 + dialog-action_area8 10 - 40 True 5 @@ -1834,7 +2947,7 @@ GtkHButtonBox - hbuttonbox6 + hbuttonbox8 GTK_BUTTONBOX_DEFAULT_STYLE 30 85 @@ -1849,111 +2962,199 @@ GtkButton - goto_cancel + devok_button True True clicked - on_goto_cancel_clicked - Wed, 14 Mar 2001 14:24:59 GMT + on_devok_button_clicked + Wed, 30 May 2001 20:13:56 GMT - + GTK_RELIEF_NORMAL GtkButton - goto_ok + devapp_button True True clicked - on_goto_ok_clicked - Wed, 14 Mar 2001 14:25:23 GMT + on_devapp_button_clicked + Wed, 30 May 2001 20:14:05 GMT - + + GTK_RELIEF_NORMAL + + + + GtkButton + devcancel_button + True + True + + clicked + on_devcancel_button_clicked + Wed, 30 May 2001 20:14:17 GMT + + GTK_RELIEF_NORMAL - GtkVBox - vbox1 - 12 - 75 - False - 0 + GtkFixed + fixed2 0 - False - False + True + True + + GtkButton + devset_button + 208 + 80 + 79 + 24 + Set all devices to current format + True + + clicked + on_devset_button_clicked + Wed, 30 May 2001 20:13:37 GMT + + + GTK_RELIEF_NORMAL + + GtkLabel - label225 - + label232 + 16 + 22 + 48 + 16 + GTK_JUSTIFY_CENTER False 0.5 0.5 0 0 - - 0 - True - True - - GtkEntry - goto_entry - 44 + GtkLabel + label233 + 216 + 22 + 48 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + + GtkCombo + dev_combo + 16 + 48 + 150 + 22 + True + True + False + True + False + + + + GtkEntry + GtkCombo:entry + combo-entry1 + Choose a device + True + + changed + on_deventry_changed + Wed, 30 May 2001 19:50:03 GMT + + True + True + 0 + + + + + + GtkRadioButton + decradio + 184 + 48 + 48 + 24 + Show output as decimal numbers True - True - activate - on_goto_ok_clicked - Wed, 14 Mar 2001 14:52:26 GMT + toggled + on_decradio_toggled + Wed, 30 May 2001 20:13:03 GMT - True - True - 4 - - - 10 - False - False - + + False + True + format_group + + + + GtkRadioButton + wordradio + 240 + 48 + 56 + 24 + Show output as MIX words + True + + False + True + format_group - - GtkDialog - color_dialog - 275 - 214 + + GtkDialog + external_dialog + 285 + 210 False delete_event gtk_widget_hide - Thu, 12 Apr 2001 21:05:54 GMT + Fri, 01 Jun 2001 23:57:57 GMT destroy_event gtk_widget_hide - Thu, 12 Apr 2001 21:06:09 GMT + Fri, 01 Jun 2001 23:58:51 GMT destroy gtk_widget_hide - Thu, 12 Apr 2001 21:06:23 GMT + Fri, 01 Jun 2001 23:59:02 GMT - MIXAL colors + External programs GTK_WINDOW_DIALOG GTK_WIN_POS_NONE True @@ -1964,16 +3165,16 @@ GtkVBox Dialog:vbox - dialog-vbox7 + dialog-vbox9 False 0 GtkHBox Dialog:action_area - dialog-action_area7 - 10 - True + dialog-action_area9 + 3 + False 5 0 @@ -1984,12 +3185,12 @@ GtkHButtonBox - hbuttonbox7 - GTK_BUTTONBOX_DEFAULT_STYLE - 30 + hbuttonbox9 + GTK_BUTTONBOX_SPREAD + 10 85 27 - 7 + 5 0 0 @@ -1999,51 +3200,39 @@ GtkButton - colors_ok - True - True - - clicked - on_colors_ok_clicked - Thu, 12 Apr 2001 21:05:07 GMT - - - GTK_RELIEF_NORMAL - - - - GtkButton - colors_apply + extern_cancel_button True True clicked - on_colors_apply_clicked - Thu, 12 Apr 2001 21:04:56 GMT + on_extern_cancel_button_clicked + Mon, 04 Jun 2001 21:31:50 GMT - + GTK_RELIEF_NORMAL GtkButton - colors_cancel + extern_ok_button True True clicked - on_colors_cancel_clicked - Thu, 12 Apr 2001 21:04:45 GMT + on_extern_ok_button_clicked + Mon, 04 Jun 2001 21:32:21 GMT - + GTK_RELIEF_NORMAL - GtkFixed - fixed1 + GtkVBox + vbox2 + True + 0 0 True @@ -2051,718 +3240,861 @@ - GtkLabel - label230 - 184 - 32 - 78 - 16 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - - - - GtkLabel - label226 - 0 - 8 - 143 - 16 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - - - - GtkLabel - label227 - 0 - 56 - 79 - 16 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - - - - GtkLabel - label229 - 88 - 32 - 78 - 16 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - - - - GtkDrawingArea - clbg_area - 90 - 56 - 75 - 15 - - - - GtkDrawingArea - clfg_area - 184 - 56 - 75 - 15 - - - - GtkDrawingArea - bpfg_area - 184 - 94 - 75 - 15 - - - - GtkDrawingArea - plbg_area - 90 - 128 - 75 - 15 - + GtkFixed + fixed3 + + 0 + True + True + - - GtkLabel - label231 - 1 - 128 - 77 - 16 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - + + GtkEntry + editor_entry + 48 + 40 + 220 + 24 + True + True + True + 0 + xterm -e vi %s + - - GtkDrawingArea - bpbg_area - 90 - 94 - 75 - 15 + + GtkLabel + label234 + 3 + 16 + 223 + 16 + + GTK_JUSTIFY_LEFT + False + 0.5 + 0.5 + 0 + 0 + - GtkDrawingArea - plfg_area - 184 - 128 - 75 - 15 - + GtkFixed + fixed4 + + 0 + True + True + - - GtkLabel - label228 - 0 - 94 - 76 - 16 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 + + GtkEntry + mixasm_entry + 48 + 40 + 220 + 22 + True + True + True + 0 + mixasm -g %s + + + + GtkLabel + label235 + 0 + 16 + 278 + 16 + + GTK_JUSTIFY_LEFT + False + 0.5 + 0.5 + 0 + 0 + - GtkColorSelectionDialog - colorsel_dialog - 10 + GtkDialog + symbols_dialog False delete_event gtk_widget_hide - Sat, 21 Apr 2001 23:14:28 GMT + Mon, 18 Jun 2001 21:10:39 GMT destroy_event gtk_widget_hide - Sat, 21 Apr 2001 23:14:54 GMT + Mon, 18 Jun 2001 21:10:53 GMT destroy gtk_widget_hide - Sat, 21 Apr 2001 23:15:12 GMT + Mon, 18 Jun 2001 21:11:08 GMT - Select Color + Symbol table GTK_WINDOW_DIALOG - GTK_WIN_POS_NONE - True - False - False + GTK_WIN_POS_CENTER + False + 350 + 265 + True + True False - GTK_UPDATE_CONTINUOUS - GtkButton - ColorSel:ok_button - ok_colorserdlg - True - True - - clicked - on_ok_colorseldlg_clicked - Sat, 21 Apr 2001 23:17:15 GMT - - - GTK_RELIEF_NORMAL - + GtkVBox + Dialog:vbox + dialog-vbox10 + False + 0 - - GtkButton - ColorSel:cancel_button - cancel_colorseldlg - True - True - - clicked - on_cancel_colorseldlg_clicked - Sat, 21 Apr 2001 23:17:37 GMT - - - GTK_RELIEF_NORMAL - + + GtkHBox + Dialog:action_area + dialog-action_area10 + 10 + True + 5 + + 0 + False + True + GTK_PACK_END + - - GtkButton - ColorSel:help_button - help_button1 - True - True - - GTK_RELIEF_NORMAL - - + + GtkButton + button1 + 77 + True + + clicked + on_symbol_ok_clicked + Mon, 18 Jun 2001 21:10:02 GMT + + + GTK_RELIEF_NORMAL + + 0 + False + False + + + - - GtkFontSelectionDialog - fontsel_dialog - 4 - False - - delete_event - gtk_widget_hide - Thu, 26 Apr 2001 21:14:34 GMT - - - destroy_event - gtk_widget_hide - Thu, 26 Apr 2001 21:15:02 GMT - - - destroy - gtk_widget_hide - Thu, 26 Apr 2001 21:15:13 GMT - - Select Font - GTK_WINDOW_DIALOG - GTK_WIN_POS_NONE - False - False - True - True + + GtkScrolledWindow + scrolledwindow26 + GTK_POLICY_ALWAYS + GTK_POLICY_ALWAYS + GTK_UPDATE_CONTINUOUS + GTK_UPDATE_CONTINUOUS + + 0 + True + True + - - GtkButton - FontSel:ok_button - ok_button1 - True - True - - clicked - on_fontsel_ok_clicked - Thu, 26 Apr 2001 21:40:53 GMT - - - GTK_RELIEF_NORMAL - + + GtkCList + symbols_clist + True + 3 + 80,112,80 + GTK_SELECTION_SINGLE + True + GTK_SHADOW_IN - - GtkButton - FontSel:apply_button - apply_button1 - True - True - - clicked - on_fontsel_apply_clicked - Thu, 26 Apr 2001 21:41:12 GMT - - - GTK_RELIEF_NORMAL - + + GtkLabel + CList:title + label236 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + - - GtkButton - FontSel:cancel_button - cancel_button1 - True - True - - clicked - on_fontsel_cancel_clicked - Thu, 26 Apr 2001 21:41:33 GMT - - - GTK_RELIEF_NORMAL + + GtkLabel + CList:title + label237 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + + GtkLabel + CList:title + label238 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + - GtkDialog - devform_dialog - 308 - 172 + GtkWindow + mixvm_window False delete_event - gtk_widget_hide - Wed, 30 May 2001 20:14:53 GMT + on_window_hide + Sun, 24 Jun 2001 12:33:45 GMT destroy_event - gtk_widget_hide - Wed, 30 May 2001 20:15:13 GMT + on_window_hide + Sun, 24 Jun 2001 12:33:54 GMT destroy - gtk_widget_hide - Wed, 30 May 2001 20:15:29 GMT + on_window_hide + Sun, 24 Jun 2001 12:34:03 GMT - Device output format - GTK_WINDOW_DIALOG + + show + mixgtk_mixvm_update_vm_widgets + True + Sun, 24 Jun 2001 12:45:56 GMT + + Virtual machine + GTK_WINDOW_TOPLEVEL GTK_WIN_POS_NONE - True + False + 640 + 290 False - False + True False - GtkVBox - Dialog:vbox - dialog-vbox8 - False - 0 + GtkFixed + mixvm_widget + 640 + 287 - GtkHBox - Dialog:action_area - dialog-action_area8 - 10 - True - 5 - - 0 - False - True - GTK_PACK_END - + GtkEntry + rJ_entry + 304 + 88 + 60 + 24 + True + + button_press_event + on_register_click + Sun, 11 Mar 2001 11:45:00 GMT + + False + True + 0 + + - - GtkHButtonBox - hbuttonbox8 - GTK_BUTTONBOX_DEFAULT_STYLE - 30 - 85 - 27 - 7 - 0 - - 0 - True - True - + + GtkEntry + rA_entry + 40 + 24 + 120 + 24 + True + + button_press_event + on_register_click + Mon, 12 Mar 2001 23:09:49 GMT + + False + True + 0 + + - - GtkButton - devok_button - True - True - - clicked - on_devok_button_clicked - Wed, 30 May 2001 20:13:56 GMT - - - GTK_RELIEF_NORMAL - + + GtkEntry + rX_entry + 248 + 24 + 120 + 24 + True + + button_press_event + on_register_click + Sun, 11 Mar 2001 11:43:29 GMT + + False + True + 0 + + - - GtkButton - devapp_button - True - True - - clicked - on_devapp_button_clicked - Wed, 30 May 2001 20:14:05 GMT - - - GTK_RELIEF_NORMAL - + + GtkEntry + rI2_entry + 40 + 144 + 60 + 22 + True + + button_press_event + on_register_click + Sun, 11 Mar 2001 11:45:39 GMT + + False + True + 0 + + - - GtkButton - devcancel_button - True - True - - clicked - on_devcancel_button_clicked - Wed, 30 May 2001 20:14:17 GMT - - - GTK_RELIEF_NORMAL - - + + GtkEntry + rI1_entry + 40 + 88 + 60 + 24 + True + + button_press_event + on_register_click + Sun, 11 Mar 2001 11:43:44 GMT + + False + True + 0 + - GtkFixed - fixed2 - - 0 - True - True - + GtkEntry + rI3_entry + 40 + 200 + 60 + 22 + True + + button_press_event + on_register_click + Sun, 11 Mar 2001 11:46:37 GMT + + False + True + 0 + + - - GtkButton - devset_button - 208 - 80 - 79 - 24 - Set all devices to current format - True - - clicked - on_devset_button_clicked - Wed, 30 May 2001 20:13:37 GMT - - - GTK_RELIEF_NORMAL - + + GtkEntry + rI4_entry + 168 + 88 + 60 + 24 + True + + button_press_event + on_register_click + Sun, 11 Mar 2001 11:44:21 GMT + + False + True + 0 + + - - GtkLabel - label232 - 16 - 22 - 48 - 16 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - + + GtkEntry + rI6_entry + 168 + 200 + 60 + 22 + True + + button_press_event + on_register_click + Sun, 11 Mar 2001 11:46:58 GMT + + False + True + 0 + + + + + GtkLabel + label100 + 8 + 91 + 31 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + + GtkLabel + label102 + 8 + 200 + 31 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + + GtkLabel + label101 + 8 + 144 + 31 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + + GtkLabel + label103 + 136 + 88 + 32 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + + GtkLabel + label104 + 136 + 144 + 31 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + + GtkLabel + label105 + 136 + 200 + 31 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + + GtkLabel + label98 + 216 + 24 + 31 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + + GtkLabel + label97 + 8 + 24 + 31 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + + GtkVSeparator + vseparator2 + 0 + 8 + 16 + 263 + + + + GtkVSeparator + vseparator3 + 626 + 8 + 16 + 267 + + + + GtkLabel + label99 + 272 + 88 + 31 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + + GtkHSeparator + hseparator2 + 6 + 265 + 627 + 16 + + + + GtkLabel + label159 + 8 + 248 + 64 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + - - GtkLabel - label233 - 216 - 22 - 48 - 16 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - + + GtkLabel + label158 + 128 + 248 + 64 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + - - GtkCombo - dev_combo - 16 - 48 - 150 - 22 - True - True - False - True - False - + + GtkLabel + label157 + 256 + 248 + 48 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + - - GtkEntry - GtkCombo:entry - combo-entry1 - Choose a device - True - - changed - on_deventry_changed - Wed, 30 May 2001 19:50:03 GMT - - True - True - 0 - - - + + GtkVSeparator + vseparator1 + 376 + 10 + 16 + 263 + - - GtkRadioButton - decradio - 184 - 48 - 48 - 24 - Show output as decimal numbers - True - - toggled - on_decradio_toggled - Wed, 30 May 2001 20:13:03 GMT - - - False - True - format_group - + + GtkEntry + rI5_entry + 168 + 144 + 60 + 22 + True + + button_press_event + on_register_click + Sun, 11 Mar 2001 11:46:05 GMT + + False + True + 0 + + - - GtkRadioButton - wordradio - 240 - 48 - 56 - 24 - Show output as MIX words - True - - False - True - format_group - + + GtkEntry + loc_entry + 300 + 200 + 40 + 22 + True + False + True + 0 + - - - - GtkDialog - external_dialog - 285 - 210 - False - - delete_event - gtk_widget_hide - Fri, 01 Jun 2001 23:57:57 GMT - - - destroy_event - gtk_widget_hide - Fri, 01 Jun 2001 23:58:51 GMT - - - destroy - gtk_widget_hide - Fri, 01 Jun 2001 23:59:02 GMT - - External programs - GTK_WINDOW_DIALOG - GTK_WIN_POS_NONE - True - False - False - False + + GtkLabel + label167 + 256 + 200 + 48 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + - - GtkVBox - Dialog:vbox - dialog-vbox9 - False - 0 + + GtkButton + loc_arrow + 346 + 202 + 29 + 18 + True + + clicked + on_loc_arrow_clicked + Fri, 09 Mar 2001 20:18:22 GMT + + + GTK_RELIEF_NONE + - GtkHBox - Dialog:action_area - dialog-action_area9 - 3 - False - 5 - - 0 - False - True - GTK_PACK_END - + GtkHSeparator + hseparator1 + 8 + 232 + 377 + 16 + - - GtkHButtonBox - hbuttonbox9 - GTK_BUTTONBOX_SPREAD - 10 - 85 - 27 - 5 - 0 - - 0 - True - True - + + GtkLabel + program_label + 184 + 248 + 56 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + - - GtkButton - extern_cancel_button - True - True - - clicked - on_extern_cancel_button_clicked - Mon, 04 Jun 2001 21:31:50 GMT - - - GTK_RELIEF_NORMAL - + + GtkLabel + elapsed_label + 64 + 248 + 48 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + - - GtkButton - extern_ok_button - True - True - - clicked - on_extern_ok_button_clicked - Mon, 04 Jun 2001 21:32:21 GMT - - - GTK_RELIEF_NORMAL - - + + GtkLabel + uptime_label + 296 + 248 + 72 + 16 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + + GtkCheckButton + over_toggle + 288 + 168 + 88 + 16 + True + + toggled + on_overflow_toggled + Tue, 06 Mar 2001 21:32:39 GMT + + + False + True + + + + GtkRadioButton + greater_radio + 336 + 128 + 32 + 24 + Comparison flag: greater + True + + toggled + on_cmp_g_toggled + Tue, 06 Mar 2001 21:21:40 GMT + + + False + True + cmp_group - GtkVBox - vbox2 - True - 0 - - 0 - True - True - + GtkScrolledWindow + memory_scroll + 398 + 16 + 225 + 248 + GTK_POLICY_NEVER + GTK_POLICY_ALWAYS + GTK_UPDATE_CONTINUOUS + GTK_UPDATE_CONTINUOUS - GtkFixed - fixed3 - - 0 - True - True - - - - GtkEntry - editor_entry - 48 - 40 - 220 - 24 - True - True - True - 0 - xterm -e vi %s - + GtkCList + memory_cells + 195 + 248 + Click cell to change value + True + + select_row + on_memory_cells_select_row + True + Tue, 13 Mar 2001 07:38:52 GMT + + + click_column + on_memory_cells_click_column + Wed, 14 Mar 2001 14:18:57 GMT + + 2 + 53,135 + GTK_SELECTION_SINGLE + True + GTK_SHADOW_IN GtkLabel - label234 - 3 - 16 - 223 - 16 - - GTK_JUSTIFY_LEFT + CList:title + label165 + + GTK_JUSTIFY_CENTER False 0.5 0.5 0 0 - - - - GtkFixed - fixed4 - - 0 - True - True - - - - GtkEntry - mixasm_entry - 48 - 40 - 220 - 22 - True - True - True - 0 - mixasm -g %s - GtkLabel - label235 - 0 - 16 - 278 - 16 - - GTK_JUSTIFY_LEFT + CList:title + label166 + + GTK_JUSTIFY_CENTER False 0.5 0.5 @@ -2771,86 +4103,204 @@ + + + GtkRadioButton + lesser_radio + 264 + 128 + 35 + 24 + Comparison flag: lesser + True + + toggled + on_cmp_l_toggled + Tue, 06 Mar 2001 21:21:51 GMT + + + False + True + cmp_group + + + + GtkRadioButton + equal_radio + 304 + 128 + 31 + 24 + Comparison flag: equal + True + + toggled + on_cmp_e_toggled + Tue, 06 Mar 2001 21:22:04 GMT + + + False + True + cmp_group + + + + GtkHSeparator + hseparator3 + 6 + 1 + 627 + 16 + - GtkDialog - symbols_dialog + GtkWindow + mixal_window False delete_event - gtk_widget_hide - Mon, 18 Jun 2001 21:10:39 GMT + on_window_hide + Sun, 24 Jun 2001 12:34:28 GMT destroy_event - gtk_widget_hide - Mon, 18 Jun 2001 21:10:53 GMT + on_window_hide + Sun, 24 Jun 2001 12:34:36 GMT destroy - gtk_widget_hide - Mon, 18 Jun 2001 21:11:08 GMT + on_window_hide + Sun, 24 Jun 2001 12:34:42 GMT - Symbol table - GTK_WINDOW_DIALOG - GTK_WIN_POS_CENTER + + show + mixgtk_mixal_update + True + Sun, 24 Jun 2001 12:43:33 GMT + + MIXAL source + GTK_WINDOW_TOPLEVEL + GTK_WIN_POS_NONE False - 350 - 265 + 475 + 200 True True False - GtkVBox - Dialog:vbox - dialog-vbox10 - False - 0 + GtkScrolledWindow + scrolledwindow27 + GTK_POLICY_ALWAYS + GTK_POLICY_AUTOMATIC + GTK_UPDATE_CONTINUOUS + GTK_UPDATE_CONTINUOUS - GtkHBox - Dialog:action_area - dialog-action_area10 - 10 - True - 5 - - 0 - False - True - GTK_PACK_END - + GtkCList + mixal_clist + Click to toggle breakpoint + True + GDK_POINTER_MOTION_MASK + + select_row + on_mixal_select_row + True + Sun, 11 Mar 2001 01:15:28 GMT + + + motion_notify_event + on_mixal_motion_notify_event + Sun, 17 Jun 2001 19:44:48 GMT + + + leave_notify_event + on_mixal_leave_notify_event + Sat, 23 Jun 2001 22:26:17 GMT + + 2 + 152,80 + GTK_SELECTION_SINGLE + True + GTK_SHADOW_IN - GtkButton - button1 - 77 - True - - clicked - on_symbol_ok_clicked - Mon, 18 Jun 2001 21:10:02 GMT - - - GTK_RELIEF_NORMAL - - 0 - False - False - + GtkLabel + CList:title + label213 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + + GtkLabel + CList:title + label214 + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 + + + + + GtkWindow + devices_window + False + + delete_event + on_window_hide + Sun, 24 Jun 2001 12:34:51 GMT + + + destroy_event + on_window_hide + Sun, 24 Jun 2001 12:34:59 GMT + + + destroy + on_window_hide + Sun, 24 Jun 2001 12:35:09 GMT + + Devices + GTK_WINDOW_TOPLEVEL + GTK_WIN_POS_NONE + False + 550 + 250 + True + True + False + + + GtkVBox + vbox4 + False + 0 - GtkScrolledWindow - scrolledwindow26 - GTK_POLICY_ALWAYS - GTK_POLICY_ALWAYS - GTK_UPDATE_CONTINUOUS - GTK_UPDATE_CONTINUOUS + GtkNotebook + devices_notebook + True + True + True + GTK_POS_TOP + True + 2 + 2 + False 0 True @@ -2858,53 +4308,20 @@ - GtkCList - symbols_clist - True - 3 - 80,112,80 - GTK_SELECTION_SINGLE - True - GTK_SHADOW_IN - - - GtkLabel - CList:title - label236 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - - - - GtkLabel - CList:title - label237 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - + Placeholder + - - GtkLabel - CList:title - label238 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - + + GtkLabel + Notebook:tab + label + + GTK_JUSTIFY_CENTER + False + 0.5 + 0.5 + 0 + 0 diff --git a/mixgtk/mixgtk_cmd_dispatcher.c b/mixgtk/mixgtk_cmd_dispatcher.c index 240cf9e..be24fd5 100644 --- a/mixgtk/mixgtk_cmd_dispatcher.c +++ b/mixgtk/mixgtk_cmd_dispatcher.c @@ -290,13 +290,15 @@ on_extern_ok_button_clicked () /* initialise the command dispatcher */ gboolean -mixgtk_cmd_dispatcher_init (void) +mixgtk_cmd_dispatcher_init (mixgtk_dialog_id_t top) { if (!dis_data_.prompt) { - dis_data_.prompt = mixgtk_widget_factory_get (MIXGTK_WIDGET_PROMPT); + dis_data_.prompt = + mixgtk_widget_factory_get (top, MIXGTK_WIDGET_PROMPT); g_return_val_if_fail (dis_data_.prompt != NULL, FALSE); - dis_data_.log = mixgtk_widget_factory_get (MIXGTK_WIDGET_LOG); + dis_data_.log = + mixgtk_widget_factory_get (top, MIXGTK_WIDGET_LOG); g_return_val_if_fail (dis_data_.log != NULL, FALSE); } @@ -324,7 +326,8 @@ mixgtk_cmd_dispatcher_init (void) if (!dis_data_.status) { - dis_data_.status = mixgtk_widget_factory_get (MIXGTK_WIDGET_STATUSBAR); + dis_data_.status = + mixgtk_widget_factory_get (MIXGTK_MAIN, MIXGTK_WIDGET_STATUSBAR); g_return_val_if_fail (dis_data_.status != NULL, FALSE); dis_data_.context = gtk_statusbar_get_context_id (GTK_STATUSBAR (dis_data_.status), diff --git a/mixgtk/mixgtk_cmd_dispatcher.h b/mixgtk/mixgtk_cmd_dispatcher.h index 915f72b..a67ec26 100644 --- a/mixgtk/mixgtk_cmd_dispatcher.h +++ b/mixgtk/mixgtk_cmd_dispatcher.h @@ -30,7 +30,7 @@ /* initialise the command dispatcher */ extern gboolean -mixgtk_cmd_dispatcher_init (void); +mixgtk_cmd_dispatcher_init (mixgtk_dialog_id_t top); /* dispatch an externally provided command */ extern void diff --git a/mixgtk/mixgtk_config.c b/mixgtk/mixgtk_config.c index b886238..dfb1ad8 100644 --- a/mixgtk/mixgtk_config.c +++ b/mixgtk/mixgtk_config.c @@ -29,9 +29,13 @@ #include "mixgtk.h" #include "mixgtk_config.h" -#define CONFIG_FILENAME "config" -#define COMMENT_PREFIX '#' -#define AUTOSAVE_FLAG "Autosave" +static const gchar *CONFIG_FILENAME = "config"; +static const gchar COMMENT_PREFIX = '#'; +static const gchar *AUTOSAVE_FLAG = "Autosave"; +static const gchar *SPLIT_KEY = "Split"; +static const gchar *SPLIT_YES = "Yes"; +static const gchar *SPLIT_NO = "No"; + static GHashTable *items_; static gchar *config_ = NULL; @@ -147,3 +151,15 @@ mixgtk_config_save (void) +gboolean +mixgtk_config_is_split (void) +{ + const gchar *split = mixgtk_config_get (SPLIT_KEY); + return (split && !strcmp (split, SPLIT_YES)); +} + +void +mixgtk_config_set_split (gboolean split) +{ + mixgtk_config_update (SPLIT_KEY, split? SPLIT_YES : SPLIT_NO); +} diff --git a/mixgtk/mixgtk_config.h b/mixgtk/mixgtk_config.h index 04cc1d4..ea54ba4 100644 --- a/mixgtk/mixgtk_config.h +++ b/mixgtk/mixgtk_config.h @@ -50,6 +50,13 @@ mixgtk_config_get (const gchar *key); extern void mixgtk_config_save (void); +/* shared config params */ +extern gboolean +mixgtk_config_is_split (void); + +extern void +mixgtk_config_set_split (gboolean split); + #endif /* MIXGTK_CONFIG_H */ diff --git a/mixgtk/mixgtk_fontsel.c b/mixgtk/mixgtk_fontsel.c index 0e7712d..ffb2209 100644 --- a/mixgtk/mixgtk_fontsel.c +++ b/mixgtk/mixgtk_fontsel.c @@ -46,6 +46,14 @@ static mixgtk_widget_id_t widget_ids_[] = { MIXGTK_WIDGET_DEVICE }; +static mixgtk_dialog_id_t dialog_ids_[] = { + MIXGTK_MIXVM_DIALOG, + MIXGTK_MAIN, + MIXGTK_MAIN, + MIXGTK_MIXAL_DIALOG, + MIXGTK_DEVICES_DIALOG +}; + static const gchar *keys_[] = { "MIX.font", "Prompt.font", "Log.font", "MIXAL.font", "Device.font" }; @@ -80,14 +88,17 @@ change_font_ (mixgtk_widget_id_t widget) } void -mixgtk_fontsel_load_defaults (void) +mixgtk_fontsel_load_defaults (gboolean split) { int i; const gchar *font = NULL; winfo_ = g_hash_table_new (NULL, NULL); + if (!split) + for (i - 0; i < WIDGET_NO_; ++i) dialog_ids_[i] = MIXGTK_MAIN; for (i = 0; i < WIDGET_NO_; ++i) { - infos_[i].widget = mixgtk_widget_factory_get (widget_ids_[i]); + infos_[i].widget = + mixgtk_widget_factory_get (dialog_ids_[i], widget_ids_[i]); g_assert (infos_[i].widget != NULL); infos_[i].style = gtk_style_copy (gtk_widget_get_style (infos_[i].widget)); @@ -96,8 +107,9 @@ mixgtk_fontsel_load_defaults (void) { int k; for (k = MIXGTK_WIDGET_rA; k <= MIXGTK_WIDGET_UPTIME; ++k) - gtk_widget_set_style (mixgtk_widget_factory_get (k), - infos_[i].style); + gtk_widget_set_style + (mixgtk_widget_factory_get (MIXGTK_MIXVM_DIALOG, k), + infos_[i].style); } infos_[i].key = keys_[i]; g_hash_table_insert (winfo_, GINT_TO_POINTER (widget_ids_[i]), @@ -129,7 +141,8 @@ mixgtk_fontsel_set (mixgtk_widget_id_t widget, const gchar *font) { int k; for (k = MIXGTK_WIDGET_rA; k <= MIXGTK_WIDGET_UPTIME; ++k) - gtk_widget_draw (mixgtk_widget_factory_get (k), NULL); + gtk_widget_draw + (mixgtk_widget_factory_get (MIXGTK_MIXVM_DIALOG, k), NULL); } } mixgtk_config_update (w->key, w->font); diff --git a/mixgtk/mixgtk_fontsel.h b/mixgtk/mixgtk_fontsel.h index af09c15..705b369 100644 --- a/mixgtk/mixgtk_fontsel.h +++ b/mixgtk/mixgtk_fontsel.h @@ -30,7 +30,7 @@ /* load default (configured) fonts */ extern void -mixgtk_fontsel_load_defaults (void); +mixgtk_fontsel_load_defaults (gboolean split); /* set a widget's font */ extern void diff --git a/mixgtk/mixgtk_mixal.c b/mixgtk/mixgtk_mixal.c index 916ef1e..73e9fc0 100644 --- a/mixgtk/mixgtk_mixal.c +++ b/mixgtk/mixgtk_mixal.c @@ -128,16 +128,17 @@ init_color_ (GdkColor *c, const gchar *name) /* initialise the mixal widgets */ gboolean -mixgtk_mixal_init (mix_vm_t *vm) +mixgtk_mixal_init (mix_vm_t *vm, mixgtk_dialog_id_t top) { int i,j; g_return_val_if_fail (vm != NULL, FALSE); vm_ = vm; - clist_ = GTK_CLIST (mixgtk_widget_factory_get (MIXGTK_WIDGET_MIXAL)); + clist_ = GTK_CLIST (mixgtk_widget_factory_get (top, MIXGTK_WIDGET_MIXAL)); g_return_val_if_fail (clist_ != NULL, FALSE); - status_ = GTK_STATUSBAR (mixgtk_widget_factory_get (MIXGTK_WIDGET_STATUSBAR)); + status_ = GTK_STATUSBAR + (mixgtk_widget_factory_get (MIXGTK_MAIN, MIXGTK_WIDGET_STATUSBAR)); g_return_val_if_fail (status_ != NULL, FALSE); status_context_ = gtk_statusbar_get_context_id (status_, "MIXAL status"); @@ -420,3 +421,9 @@ on_notebook_switch_page (GtkNotebook *notebook) if (p != MIXAL_TAB_POS_) gtk_statusbar_pop (status_, status_context_); if (p == MIXAL_TAB_POS_) mixgtk_mixal_update (); } + +void +on_mixal_leave_notify_event () +{ + gtk_statusbar_pop (status_, status_context_); +} diff --git a/mixgtk/mixgtk_mixal.h b/mixgtk/mixgtk_mixal.h index eaf0e23..a1ab681 100644 --- a/mixgtk/mixgtk_mixal.h +++ b/mixgtk/mixgtk_mixal.h @@ -27,6 +27,7 @@ #include #include +#include "mixgtk_widgets.h" /* the possible colorised elements */ typedef enum { @@ -43,7 +44,7 @@ typedef enum { /* initialise the mixal widget */ extern gboolean -mixgtk_mixal_init (mix_vm_t *vm); +mixgtk_mixal_init (mix_vm_t *vm, mixgtk_dialog_id_t top); /* set the plain, location pointer and break colors */ extern void diff --git a/mixgtk/mixgtk_mixvm.c b/mixgtk/mixgtk_mixvm.c index bee588a..2b13f18 100644 --- a/mixgtk/mixgtk_mixvm.c +++ b/mixgtk/mixgtk_mixvm.c @@ -109,7 +109,7 @@ on_mem_adj_change_ (GtkAdjustment *adj) /* initialise the mixvm widgets */ gboolean -mixgtk_mixvm_init (mix_vm_t *vm) +mixgtk_mixvm_init (mix_vm_t *vm, mixgtk_dialog_id_t top) { int k; gchar *text[] = {"", ""}; @@ -124,34 +124,35 @@ mixgtk_mixvm_init (mix_vm_t *vm) for (k = 0; k < REGISTER_NO_; ++k) { reg_entries_[k] = - GTK_ENTRY (mixgtk_widget_factory_get (MIXGTK_WIDGET_rA + k)); + GTK_ENTRY (mixgtk_widget_factory_get (top, MIXGTK_WIDGET_rA + k)); g_return_val_if_fail (reg_entries_[k] != NULL, FALSE); } - loc_entry_ = GTK_ENTRY (mixgtk_widget_factory_get (MIXGTK_WIDGET_LOC)); + loc_entry_ = GTK_ENTRY (mixgtk_widget_factory_get (top, MIXGTK_WIDGET_LOC)); g_return_val_if_fail (loc_entry_ != NULL, FALSE); - uptime_ = GTK_LABEL (mixgtk_widget_factory_get (MIXGTK_WIDGET_UPTIME)); + uptime_ = GTK_LABEL (mixgtk_widget_factory_get (top, MIXGTK_WIDGET_UPTIME)); g_return_val_if_fail (uptime_ != NULL, FALSE); - progtime_ = GTK_LABEL (mixgtk_widget_factory_get (MIXGTK_WIDGET_PROGTIME)); + progtime_ = + GTK_LABEL (mixgtk_widget_factory_get (top, MIXGTK_WIDGET_PROGTIME)); g_return_val_if_fail (progtime_ != NULL, FALSE); - laptime_ = GTK_LABEL (mixgtk_widget_factory_get (MIXGTK_WIDGET_LAPTIME)); + laptime_ = GTK_LABEL (mixgtk_widget_factory_get (top, MIXGTK_WIDGET_LAPTIME)); g_return_val_if_fail (laptime_ != NULL, FALSE); over_button_ = - GTK_TOGGLE_BUTTON (mixgtk_widget_factory_get (MIXGTK_WIDGET_OVER)); + GTK_TOGGLE_BUTTON (mixgtk_widget_factory_get (top, MIXGTK_WIDGET_OVER)); g_return_val_if_fail (over_button_ != NULL, FALSE); for (k = 0; k < 3; ++k) { - cmp_buttons_[k] = - GTK_TOGGLE_BUTTON (mixgtk_widget_factory_get (MIXGTK_WIDGET_CMP_L +k)); + cmp_buttons_[k] = GTK_TOGGLE_BUTTON + (mixgtk_widget_factory_get (top, MIXGTK_WIDGET_CMP_L +k)); g_return_val_if_fail (cmp_buttons_[k] != NULL, FALSE); } - memory_ = GTK_CLIST (mixgtk_widget_factory_get (MIXGTK_WIDGET_CELLS)); + memory_ = GTK_CLIST (mixgtk_widget_factory_get (top, MIXGTK_WIDGET_CELLS)); g_return_val_if_fail (memory_ != NULL, FALSE); gtk_clist_set_column_justification (memory_, 0, GTK_JUSTIFY_CENTER); gtk_clist_set_column_justification (memory_, 1, GTK_JUSTIFY_CENTER); @@ -165,7 +166,7 @@ mixgtk_mixvm_init (mix_vm_t *vm) } gtk_clist_thaw (memory_); - scrol = mixgtk_widget_factory_get (MIXGTK_WIDGET_CELLS_SCROLL); + scrol = mixgtk_widget_factory_get (top, MIXGTK_WIDGET_CELLS_SCROLL); g_return_val_if_fail (scrol != NULL, FALSE); adj = gtk_scrolled_window_get_vadjustment (GTK_SCROLLED_WINDOW (scrol)); gtk_signal_connect (GTK_OBJECT (adj), "value_changed", diff --git a/mixgtk/mixgtk_mixvm.h b/mixgtk/mixgtk_mixvm.h index 04d210a..f74b409 100644 --- a/mixgtk/mixgtk_mixvm.h +++ b/mixgtk/mixgtk_mixvm.h @@ -27,10 +27,11 @@ #include #include "mixgtk.h" +#include "mixgtk_widgets.h" /* initialise the mixvm widgets */ extern gboolean -mixgtk_mixvm_init (mix_vm_t *vm); +mixgtk_mixvm_init (mix_vm_t *vm, mixgtk_dialog_id_t top); /* update register widgets */ extern void diff --git a/mixgtk/mixgtk_widgets.c b/mixgtk/mixgtk_widgets.c index d665cc6..243c6b3 100644 --- a/mixgtk/mixgtk_widgets.c +++ b/mixgtk/mixgtk_widgets.c @@ -31,6 +31,9 @@ /* dialog names */ static const gchar * dnames_[] = { "main_window", + "mixvm_window", + "mixal_window", + "devices_window", "word_dialog", "about_dialog", "goto_dialog", @@ -42,6 +45,8 @@ static const gchar * dnames_[] = { "symbols_dialog" }; +const gchar *SPLIT_MAIN_NAME_ = "split_main_window"; + #define DLG_NO_ (sizeof (dnames_) / sizeof(dnames_[0])) /* widget names */ @@ -80,6 +85,8 @@ static const gchar *names_[] = { #define GPL_TEXT_ "gpl_text" #define AUTOSAVE_ITEM_ "save_on_exit" +static gboolean split_; + /* the glade specs */ static GladeXML *xml_[DLG_NO_] = {NULL}; /* the about dialog */ @@ -122,10 +129,26 @@ init_about_ (void) /* create a new factory from an xml glade file */ gboolean -mixgtk_widget_factory_init (const char *glade_file) +mixgtk_widget_factory_init (gboolean split) { + const gchar *glade_file = GLADE_FILE; + const gchar *local_glade_file = LOCAL_GLADE_FILE; + FILE *f; + glade_init (); + split_ = split; + + f = fopen (glade_file, "r"); + if (!f) { + f = fopen (local_glade_file, "r"); + if (!f) return FALSE; + glade_file = local_glade_file; + } + fclose (f); file_ = g_strdup (glade_file); + + if (split_) dnames_[MIXGTK_MAIN] = SPLIT_MAIN_NAME_; + init_xml_ (MIXGTK_MAIN); init_autosave_ (); return TRUE; @@ -133,16 +156,18 @@ mixgtk_widget_factory_init (const char *glade_file) /* get a widget */ GtkWidget * -mixgtk_widget_factory_get (mixgtk_widget_id_t widget) +mixgtk_widget_factory_get (mixgtk_dialog_id_t dlg, mixgtk_widget_id_t widget) { g_return_val_if_fail (widget < WIDGET_NO_, NULL); - return glade_xml_get_widget (xml_[MIXGTK_MAIN], names_[widget]); + if (!split_ && dlg < MIXGTK_WORD_DIALOG) dlg = MIXGTK_MAIN; + return mixgtk_widget_factory_get_child_by_name (dlg, names_[widget]); } GtkWidget * mixgtk_widget_factory_get_dialog (mixgtk_dialog_id_t dlg) { + if (!split_ && dlg < MIXGTK_WORD_DIALOG) dlg = MIXGTK_MAIN; if (!xml_[dlg]) init_xml_ (dlg); return glade_xml_get_widget (xml_[dlg], dnames_[dlg]); } @@ -153,6 +178,7 @@ mixgtk_widget_factory_get_child_by_name (mixgtk_dialog_id_t dlg, { g_return_val_if_fail (dlg < DLG_NO_, NULL); g_return_val_if_fail (name != NULL, NULL); + if (!split_ && dlg < MIXGTK_WORD_DIALOG) dlg = MIXGTK_MAIN; if (!xml_[dlg]) init_xml_ (dlg); return glade_xml_get_widget (xml_[dlg], name); } diff --git a/mixgtk/mixgtk_widgets.h b/mixgtk/mixgtk_widgets.h index b50fa10..6e2f633 100644 --- a/mixgtk/mixgtk_widgets.h +++ b/mixgtk/mixgtk_widgets.h @@ -31,6 +31,9 @@ /* enumeration of gmixvm dialogs */ typedef enum { MIXGTK_MAIN, /* main app window */ + MIXGTK_MIXVM_DIALOG, /* mixvm dialog */ + MIXGTK_MIXAL_DIALOG, /* mixal dialog */ + MIXGTK_DEVICES_DIALOG, /* devices dialog */ MIXGTK_WORD_DIALOG, /* input dialog for a mix word */ MIXGTK_ABOUT_DIALOG, MIXGTK_GOTO_DIALOG, @@ -75,7 +78,7 @@ typedef enum { /* create a new factory from an xml glade file */ extern gboolean -mixgtk_widget_factory_init (const char *glade_file); +mixgtk_widget_factory_init (gboolean split); /* get a dialog */ extern GtkWidget * @@ -83,7 +86,7 @@ mixgtk_widget_factory_get_dialog (mixgtk_dialog_id_t dlg); /* get a widget */ extern GtkWidget * -mixgtk_widget_factory_get (mixgtk_widget_id_t widget); +mixgtk_widget_factory_get (mixgtk_dialog_id_t dlg, mixgtk_widget_id_t widget); /* Get a widget by name */ extern GtkWidget * diff --git a/mixgtk/mixgtk_wm.c b/mixgtk/mixgtk_wm.c new file mode 100644 index 0000000..2666180 --- /dev/null +++ b/mixgtk/mixgtk_wm.c @@ -0,0 +1,139 @@ +/* -*-c-*- -------------- mixgtk_wm.c : + * Implementation of the functions declared in mixgtk_wm.h + * ------------------------------------------------------------------ + * Last change: Time-stamp: "2001-06-24 14:36:18 jao" + * ------------------------------------------------------------------ + * Copyright (C) 2001 Free Software Foundation, Inc. + * + * 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 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., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + * + */ + +#include "mixgtk_widgets.h" +#include "mixgtk_config.h" +#include "mixgtk_wm.h" + +typedef struct window_info_t_ +{ + mixgtk_dialog_id_t dialog; + GtkWidget *widget; + GtkCheckMenuItem *menu; + const gchar *menu_name; + const gchar *config_key; + gboolean visible; +} window_info_t_; + +static window_info_t_ infos_[] = { + {MIXGTK_MIXVM_DIALOG, NULL, NULL, "mix_view", "MIX.view"}, + {MIXGTK_MIXAL_DIALOG, NULL, NULL, "mixal_view", "MIXAL.view"}, + {MIXGTK_DEVICES_DIALOG, NULL, NULL, "devices_view", "Devices.view"} +}; + +static size_t INF_NO_ = sizeof (infos_) / sizeof (infos_[0]); + +static gboolean split_ = FALSE; +static const gchar *SPLIT_MENU_NAME_ = "split_windows"; +static GtkCheckMenuItem *split_menu_ = NULL; + +static const gchar *VIEW_YES_ = "Yes"; +static const gchar *VIEW_NO_ = "No"; + +gboolean +mixgtk_wm_init (void) +{ + split_ = mixgtk_config_is_split (); + if (split_) + { + gint i; + const gchar *view; + split_menu_ = GTK_CHECK_MENU_ITEM + (mixgtk_widget_factory_get_child_by_name (MIXGTK_MAIN, + SPLIT_MENU_NAME_)); + g_return_val_if_fail (split_menu_, FALSE); + gtk_check_menu_item_set_active (split_menu_, TRUE); + for (i = 0; i < INF_NO_; ++i) + { + infos_[i].widget = + mixgtk_widget_factory_get_dialog (infos_[i].dialog); + g_return_val_if_fail (infos_[i].widget, FALSE); + infos_[i].menu = GTK_CHECK_MENU_ITEM + (mixgtk_widget_factory_get_child_by_name + (MIXGTK_MAIN, infos_[i].menu_name)); + g_return_val_if_fail (infos_[i].menu, FALSE); + view = mixgtk_config_get (infos_[i].config_key); + infos_[i].visible = !view || !strcmp (VIEW_YES_, view); + if (infos_[i].visible) gtk_widget_show (infos_[i].widget); + gtk_check_menu_item_set_active (infos_[i].menu, infos_[i].visible); + } + } + return TRUE; +} + +void +mixgtk_wm_show_window (mixgtk_window_id_t w) +{ + g_return_if_fail (w < INF_NO_); + if (!infos_[w].visible) + { + infos_[w].visible = TRUE; + gtk_check_menu_item_set_active (infos_[w].menu, TRUE); + mixgtk_config_update (infos_[w].config_key, VIEW_YES_); + gtk_widget_show (infos_[w].widget); + } +} + +void +mixgtk_wm_hide_window (mixgtk_window_id_t w) +{ + g_return_if_fail (w < INF_NO_); + if (infos_[w].visible) + { + infos_[w].visible = FALSE; + gtk_check_menu_item_set_active (infos_[w].menu, FALSE); + mixgtk_config_update (infos_[w].config_key, VIEW_NO_); + gtk_widget_hide (infos_[w].widget); + } +} + +/* callbacks */ +void +on_view_toggled (GtkCheckMenuItem *item) +{ + gint k; + for (k = 0; k < INF_NO_; ++k) + if (item == infos_[k].menu) break; + g_return_if_fail (k < INF_NO_); + if (item->active) + mixgtk_wm_show_window (k); + else + mixgtk_wm_hide_window (k); +} + +void +on_split_windows_toggled (GtkCheckMenuItem *item) +{ + mixgtk_config_set_split (item->active); +} + +void +on_window_hide (GtkWidget *w) +{ + gint k; + for (k = 0; k < INF_NO_; ++k) + if (w == infos_[k].widget) break; + g_return_if_fail (k < INF_NO_); + mixgtk_wm_hide_window (k); +} + diff --git a/mixgtk/mixgtk_wm.h b/mixgtk/mixgtk_wm.h new file mode 100644 index 0000000..66ef9ce --- /dev/null +++ b/mixgtk/mixgtk_wm.h @@ -0,0 +1,46 @@ +/* -*-c-*- ---------------- mixgtk_wm.h : + * FUnctions for window management + * ------------------------------------------------------------------ + * Last change: Time-stamp: <01/02/12 00:23:41 jose> + * ------------------------------------------------------------------ + * Copyright (C) 2001 Free Software Foundation, Inc. + * + * 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 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., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + * + */ + + +#ifndef MIXGTK_WM_H +#define MIXGTK_WM_H + +#include "mixgtk.h" + +typedef enum { + MIXGTK_MIXVM_WINDOW, + MIXGTK_MIXAL_WINDOW, + MIXGTK_DEVICES_WINDOW +} mixgtk_window_id_t; + +extern gboolean +mixgtk_wm_init (void); + +extern void +mixgtk_wm_show_window (mixgtk_window_id_t w); + +extern void +mixgtk_wm_hide_window (mixgtk_window_id_t w); + +#endif /* MIXGTK_WM_H */ + -- cgit v1.2.3