434 lines
20 KiB
C
434 lines
20 KiB
C
#include <stdio.h>
|
|
#include <gtk-4.0/gtk/gtk.h>
|
|
|
|
#include "graph_area.h"
|
|
#include "callback.h"
|
|
#include "automaton.h"
|
|
#include "display.h"
|
|
#include "tree.h"
|
|
#include "texts.h"
|
|
|
|
// https://blog.gtk.org/2020/09/08/on-list-models/ < TODO
|
|
// https://docs.gtk.org/gtk4/visual_index.html < widgets gallery
|
|
|
|
|
|
GtkFrame *get_frame_with_label(){ // EN ATTENDANT DE SAVOIR UTILISER : GtkTextTagTable , GtkTextBuffer
|
|
GtkFrame *space_specif = GTK_FRAME(gtk_frame_new ("Space (run / edit) specifications"));
|
|
GtkWidget *any_Label = GTK_WIDGET (gtk_label_new (get_space_run_edit_specif()));
|
|
gtk_frame_set_child (GTK_FRAME (space_specif), GTK_WIDGET (any_Label));
|
|
return space_specif;
|
|
}
|
|
|
|
GtkWidget *get_edit_rules_page_new(){
|
|
GtkPaned *hpaned = GTK_PANED (gtk_paned_new (GTK_ORIENTATION_HORIZONTAL));
|
|
|
|
GtkWidget *arbre_des_règles = gtk_frame_new ("Arbre des règles");
|
|
GtkWidget *édition_de_la_règle_sélectionnée = gtk_frame_new ("Édition de la règle sélectionnée");
|
|
|
|
gtk_paned_set_start_child (hpaned, GTK_WIDGET (arbre_des_règles));
|
|
gtk_paned_set_end_child (hpaned, GTK_WIDGET (édition_de_la_règle_sélectionnée));
|
|
// gtk_widget_set_size_request (GTK_WIDGET (hpaned), W, H);
|
|
gtk_paned_set_wide_handle (hpaned, TRUE);
|
|
|
|
return GTK_WIDGET (hpaned);
|
|
}
|
|
|
|
GtkWidget *get_edit_measures_page_new(){
|
|
GtkWidget *measures_grid = gtk_grid_new();
|
|
return measures_grid;
|
|
}
|
|
|
|
GtkWidget *get_edit_results_page_new(){
|
|
GtkWidget *xxx_grid = gtk_grid_new();
|
|
return xxx_grid;
|
|
}
|
|
|
|
GtkWidget *get_edit_discuss_page_new(){
|
|
GtkWidget *xxx_grid = gtk_grid_new();
|
|
return xxx_grid;
|
|
}
|
|
|
|
GtkWidget *get_edit_help_page_new(){
|
|
GtkWidget *edit_help_grid = gtk_grid_new();
|
|
gtk_grid_attach (GTK_GRID(edit_help_grid), GTK_WIDGET(get_frame_with_label()), 0, 0, 1, 1);
|
|
return edit_help_grid;
|
|
}
|
|
|
|
GtkWidget *get_measures_page_new(){
|
|
GtkWidget *measures_grid = gtk_grid_new();
|
|
gtk_grid_attach (GTK_GRID (measures_grid), gtk_button_new_with_label ("movements"), 0, 0, 1, 1);
|
|
gtk_grid_attach (GTK_GRID (measures_grid), gtk_button_new_with_label ("transports"), 1, 0, 1, 1);
|
|
gtk_grid_attach (GTK_GRID (measures_grid), gtk_button_new_with_label ("transformations"), 2, 0, 1, 1);
|
|
gtk_grid_attach (GTK_GRID (measures_grid), gtk_button_new_with_label ("objects"), 0, 1, 1, 1);
|
|
gtk_grid_attach (GTK_GRID (measures_grid), gtk_button_new_with_label ("situations"), 1, 1, 1, 1);
|
|
return measures_grid;
|
|
}
|
|
|
|
GtkWidget *get_results_page_new(){
|
|
GtkWidget *results_grid = gtk_grid_new();
|
|
gtk_grid_attach (GTK_GRID(results_grid), gtk_button_new_with_label ("Repartitions"), 0, 0, 1, 1);
|
|
gtk_grid_attach (GTK_GRID(results_grid), gtk_button_new_with_label ("Correlations"), 0, 1, 1, 1);
|
|
gtk_grid_attach (GTK_GRID(results_grid), gtk_button_new_with_label ("Evolutions"), 0, 2, 1, 1);
|
|
return results_grid;
|
|
}
|
|
|
|
GtkWidget *get_discuss_page_new(){
|
|
GtkWidget *discuss_grid = gtk_grid_new();
|
|
gtk_grid_attach (GTK_GRID (discuss_grid), gtk_button_new_with_label ("Interpretations"), 0, 0, 1, 1);
|
|
gtk_grid_attach (GTK_GRID (discuss_grid), gtk_button_new_with_label ("Discussions"), 0, 1, 1, 1);
|
|
return discuss_grid;
|
|
}
|
|
|
|
GtkWidget *get_help_page_new(){
|
|
GtkWidget *run_help_grid = gtk_grid_new();
|
|
gtk_grid_attach (GTK_GRID(run_help_grid), GTK_WIDGET(get_frame_with_label()), 0, 0, 1, 1);
|
|
return run_help_grid;
|
|
}
|
|
|
|
GtkWidget *get_edit_space_page_new(){
|
|
GtkWidget *space_grid = gtk_grid_new();
|
|
gtk_grid_attach (GTK_GRID(space_grid), get_image_ALL_SPACE(), 0, 0, 1, 3);
|
|
gtk_grid_attach (GTK_GRID(space_grid), get_OBJECTS_and_SITUATIONS(), 0, 4, 1, 1);
|
|
gtk_grid_attach (GTK_GRID(space_grid), GTK_WIDGET (get_XYZ_box()), 1, 0, 1, 2);
|
|
gtk_grid_attach (GTK_GRID(space_grid), GTK_WIDGET (get_ZOOM_box()), 1, 2, 1, 2);
|
|
gtk_grid_attach (GTK_GRID(space_grid), GTK_WIDGET (get_edit_TOOL_box()), 1, 3, 1, 2);
|
|
gtk_widget_set_size_request (space_grid, W, H);
|
|
return space_grid;
|
|
}
|
|
|
|
//------------------------------------------------------------------------------
|
|
|
|
GtkWidget *get_selected_rules_vpaned_new(){
|
|
GtkPaned *V_selected_1_vs_2 = GTK_PANED (gtk_paned_new (GTK_ORIENTATION_VERTICAL));
|
|
|
|
GtkBox *up_box = GTK_BOX (gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 2));
|
|
gtk_box_append (up_box, GTK_WIDGET (get_image_GLUTAMATE()));
|
|
gtk_box_append (up_box, GTK_WIDGET (gtk_separator_new (GTK_ORIENTATION_VERTICAL)));
|
|
gtk_box_append (up_box, GTK_WIDGET (get_image_GLUTAMINE()));
|
|
|
|
GtkBox *bottom_box = GTK_BOX (gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 2));
|
|
gtk_box_append (bottom_box, GTK_WIDGET (get_image_ATP()));
|
|
gtk_box_append (bottom_box, GTK_WIDGET (gtk_separator_new (GTK_ORIENTATION_VERTICAL)));
|
|
gtk_box_append (bottom_box, GTK_WIDGET (get_image_AMP()));
|
|
|
|
gtk_paned_set_start_child (V_selected_1_vs_2, GTK_WIDGET (up_box));
|
|
gtk_paned_set_end_child (V_selected_1_vs_2, GTK_WIDGET (bottom_box));
|
|
|
|
return GTK_WIDGET (V_selected_1_vs_2);
|
|
}
|
|
|
|
|
|
|
|
GtkWidget *get_TIME_EXEC_controls_box(){
|
|
GtkBox *top_box = GTK_BOX (gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 2));
|
|
gtk_box_append (top_box, GTK_WIDGET (get_ELAPSED_TIME_ProgressBar()));
|
|
gtk_box_append (top_box, GTK_WIDGET(gtk_separator_new (GTK_ORIENTATION_VERTICAL)));
|
|
gtk_box_append (top_box, GTK_WIDGET (get_RUN_STOP_box()));
|
|
return GTK_WIDGET (top_box);
|
|
}
|
|
|
|
GtkWidget *get_SPACE_VIEW_box(){
|
|
GtkBox *right_box = GTK_BOX (gtk_box_new (GTK_ORIENTATION_VERTICAL, 2));
|
|
gtk_box_append (right_box, GTK_WIDGET (get_XYZ_box()));
|
|
gtk_box_append (right_box, GTK_WIDGET (gtk_separator_new (GTK_ORIENTATION_HORIZONTAL)));
|
|
gtk_box_append (right_box, GTK_WIDGET (get_ZOOM_box()));
|
|
|
|
GtkBox *middle_box = GTK_BOX (gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 2));
|
|
// gtk_box_append (middle_box, GTK_WIDGET (get_image_ALL_SPACE()));
|
|
ui_setup_glarea (0, GTK_WIDGET (middle_box));
|
|
|
|
gtk_box_append (middle_box, GTK_WIDGET (gtk_separator_new (GTK_ORIENTATION_VERTICAL)));
|
|
gtk_box_append (middle_box, GTK_WIDGET (right_box));
|
|
return GTK_WIDGET (middle_box);
|
|
}
|
|
|
|
GtkWidget *get_SPACE_EDIT_controls_box() {
|
|
GtkWidget *label_ad_hoc = gtk_label_new ("_____________\n\
|
|
SPACE EDIT\n controls\n_____________");
|
|
return GTK_WIDGET (label_ad_hoc);
|
|
}
|
|
|
|
|
|
void window_main_child_bottom (GtkBox *page_box){
|
|
// gtk_box_append (page_box, GTK_WIDGET (get_TIME_EXEC_controls_box()));
|
|
// gtk_box_append (page_box, GTK_WIDGET (get_SPACE_EDIT_controls_box()));
|
|
}
|
|
|
|
static void icons_for_fun (GtkHeaderBar *header_bar);
|
|
|
|
static GtkButton *btt_open_STATE;
|
|
static GtkButton *btt_open_RULES;
|
|
static GtkButton *btt_open_DATA;
|
|
|
|
GtkButton *get_GtkButton (char *btt_name) {
|
|
if (strcmp (btt_name, "state")) return btt_open_STATE;
|
|
if (strcmp (btt_name, "rules")) return btt_open_RULES;
|
|
if (strcmp (btt_name, "data analysis")) return btt_open_DATA;
|
|
return NULL;
|
|
}
|
|
|
|
void set_check_button_active (GtkButton *button, int active){
|
|
const char *lab = gtk_button_get_label (button);
|
|
if (strcmp (lab, "state")) printf("set_check_button_active > %s\n", lab);
|
|
}
|
|
|
|
|
|
void window_header_bar (GtkWindow *window, char *title){
|
|
GtkWidget *header_bar = GTK_WIDGET (gtk_header_bar_new ());
|
|
gtk_header_bar_set_title_widget (GTK_HEADER_BAR (header_bar), gtk_label_new (title));
|
|
gtk_window_set_titlebar (window, header_bar);
|
|
|
|
gpointer no_local_data = NULL;
|
|
|
|
GtkButton *btt_MODEL_RUN_STOP = GTK_BUTTON (gtk_button_new_with_label (" run "));
|
|
g_signal_connect (btt_MODEL_RUN_STOP, "clicked", G_CALLBACK (on_toggle_MODEL_RUN_STOP), no_local_data);
|
|
|
|
GtkButton *btt_XOR_EXEC_EDIT = GTK_BUTTON (gtk_toggle_button_new ());
|
|
gtk_button_set_icon_name (btt_XOR_EXEC_EDIT, "system-run-symbolic"); // https://thenounproject.com/icon/train-134324/
|
|
gtk_button_set_icon_name (btt_XOR_EXEC_EDIT, "process-stop-symbolic");
|
|
gtk_button_set_icon_name (btt_XOR_EXEC_EDIT, "power-profile-balanced-rtl-symbolic");
|
|
g_signal_connect (btt_XOR_EXEC_EDIT, "clicked", G_CALLBACK (on_toggle_EXEC_EDIT), btt_MODEL_RUN_STOP);
|
|
|
|
GtkWidget *any_Label = GTK_WIDGET (gtk_label_new (" | "));
|
|
|
|
GtkCheckButton *group_STATE_RULES_DATA = GTK_CHECK_BUTTON (gtk_check_button_new ());
|
|
|
|
btt_open_STATE = GTK_BUTTON (gtk_check_button_new_with_label ("state"));
|
|
g_signal_connect (btt_open_STATE, "toggled", G_CALLBACK (on_toggle_STATE_RULES_DATA), no_local_data);
|
|
gtk_check_button_set_group (GTK_CHECK_BUTTON (btt_open_STATE), group_STATE_RULES_DATA);
|
|
|
|
btt_open_RULES = GTK_BUTTON (gtk_check_button_new_with_label ("rules"));
|
|
g_signal_connect (btt_open_RULES, "toggled", G_CALLBACK (on_toggle_STATE_RULES_DATA), no_local_data);
|
|
gtk_check_button_set_group (GTK_CHECK_BUTTON (btt_open_RULES), group_STATE_RULES_DATA);
|
|
|
|
btt_open_DATA = GTK_BUTTON (gtk_check_button_new_with_label ("data analysis"));
|
|
g_signal_connect (btt_open_DATA, "toggled", G_CALLBACK (on_toggle_STATE_RULES_DATA), no_local_data);
|
|
gtk_check_button_set_group (GTK_CHECK_BUTTON (btt_open_DATA), group_STATE_RULES_DATA);
|
|
|
|
gtk_header_bar_pack_start (GTK_HEADER_BAR (header_bar), GTK_WIDGET (btt_XOR_EXEC_EDIT));
|
|
gtk_header_bar_pack_start (GTK_HEADER_BAR (header_bar), GTK_WIDGET (btt_MODEL_RUN_STOP)); // << pas ici ! TODO
|
|
gtk_header_bar_pack_start (GTK_HEADER_BAR (header_bar), GTK_WIDGET (any_Label));
|
|
gtk_header_bar_pack_start (GTK_HEADER_BAR (header_bar), GTK_WIDGET (btt_open_STATE));
|
|
gtk_header_bar_pack_start (GTK_HEADER_BAR (header_bar), GTK_WIDGET (btt_open_RULES));
|
|
gtk_header_bar_pack_start (GTK_HEADER_BAR (header_bar), GTK_WIDGET (btt_open_DATA));
|
|
|
|
|
|
icons_for_fun (GTK_HEADER_BAR (header_bar)); // https://iconduck.com/sets/adwaita-icon-theme
|
|
// https://iconduck.com/sets/carbon-icons < pas mal ...
|
|
// ma préférée : Transport Steam Engine Icon mais : [ process icon ] semble un bon choix...
|
|
}
|
|
|
|
void main_window_design (GtkWindow *main_window){
|
|
window_header_bar (main_window,
|
|
"E coli (with permission from David S. Goodsell, 2009)");
|
|
gtk_window_set_child (main_window, GTK_WIDGET (get_window_child_STATE()));
|
|
gtk_check_button_set_active (GTK_CHECK_BUTTON (btt_open_STATE), TRUE);
|
|
gtk_window_present (GTK_WINDOW (main_window));
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
static void icons_for_fun (GtkHeaderBar *header_bar)
|
|
{
|
|
GtkButton *go_home = GTK_BUTTON (gtk_button_new ());
|
|
gtk_button_set_icon_name (go_home, "go-home-symbolic");
|
|
gtk_header_bar_pack_end (header_bar, GTK_WIDGET (go_home));
|
|
|
|
GtkButton *user_trash = GTK_BUTTON (gtk_button_new ());
|
|
gtk_button_set_icon_name (user_trash, "user-trash-symbolic");
|
|
gtk_header_bar_pack_end (header_bar, GTK_WIDGET (user_trash));
|
|
|
|
GtkButton *help_biblio = GTK_BUTTON (gtk_button_new ());
|
|
gtk_button_set_icon_name (help_biblio, "accessories-dictionary-symbolic");
|
|
gtk_header_bar_pack_end (header_bar, GTK_WIDGET (help_biblio));
|
|
|
|
GtkButton *help_doc = GTK_BUTTON (gtk_button_new ());
|
|
gtk_button_set_icon_name (help_doc, "emblem-documents-symbolic");
|
|
gtk_header_bar_pack_end (header_bar, GTK_WIDGET (help_doc));
|
|
|
|
GtkButton *help_about = GTK_BUTTON (gtk_button_new ());
|
|
gtk_button_set_icon_name (help_about, "help-about-symbolic");
|
|
gtk_header_bar_pack_end (header_bar, GTK_WIDGET (help_about));
|
|
|
|
GtkButton *help_faq = GTK_BUTTON (gtk_button_new ());
|
|
gtk_button_set_icon_name (help_faq, "help-faq-symbolic");
|
|
gtk_header_bar_pack_end (header_bar, GTK_WIDGET (help_faq));
|
|
|
|
GtkButton *terminal = GTK_BUTTON (gtk_button_new ());
|
|
gtk_button_set_icon_name (terminal, "utilities-terminal-symbolic");
|
|
gtk_header_bar_pack_end (header_bar, GTK_WIDGET (terminal));
|
|
|
|
GtkButton *search = GTK_BUTTON (gtk_button_new ());
|
|
gtk_button_set_icon_name (search, "folder-saved-search-symbolic");
|
|
gtk_header_bar_pack_end (header_bar, GTK_WIDGET (search));
|
|
|
|
GtkButton *preferences_desktop_appearance = GTK_BUTTON (gtk_button_new ());
|
|
gtk_button_set_icon_name (preferences_desktop_appearance, "preferences-desktop-appearance-symbolic");
|
|
gtk_header_bar_pack_end (header_bar, GTK_WIDGET (preferences_desktop_appearance));
|
|
|
|
GtkButton *preferences_system = GTK_BUTTON (gtk_button_new ());
|
|
gtk_button_set_icon_name (preferences_system, "preferences-system-symbolic");
|
|
gtk_header_bar_pack_end (header_bar, GTK_WIDGET (preferences_system));
|
|
|
|
GtkButton *document_properties = GTK_BUTTON (gtk_button_new ());
|
|
gtk_button_set_icon_name (document_properties, "document-properties-symbolic");
|
|
gtk_header_bar_pack_end (header_bar, GTK_WIDGET (document_properties));
|
|
|
|
GtkButton *text_edit = GTK_BUTTON (gtk_button_new ());
|
|
gtk_button_set_icon_name (text_edit, "text-editor-symbolic");
|
|
gtk_header_bar_pack_end (header_bar, GTK_WIDGET (text_edit));
|
|
|
|
GtkButton *applications_utilities = GTK_BUTTON (gtk_button_new ());
|
|
gtk_button_set_icon_name (applications_utilities, "applications-utilities-symbolic");
|
|
gtk_header_bar_pack_end (header_bar, GTK_WIDGET (applications_utilities));
|
|
|
|
GtkButton *open_menu = GTK_BUTTON (gtk_button_new ());
|
|
gtk_button_set_icon_name (open_menu, "open-menu-symbolic");
|
|
gtk_header_bar_pack_end (header_bar, GTK_WIDGET (open_menu));
|
|
|
|
GtkButton *power_max = GTK_BUTTON (gtk_button_new ());
|
|
gtk_button_set_icon_name (power_max, "power-profile-performance-symbolic");
|
|
gtk_header_bar_pack_end (header_bar, GTK_WIDGET (power_max));
|
|
|
|
GtkButton *power_middle = GTK_BUTTON (gtk_button_new ());
|
|
gtk_button_set_icon_name (power_middle, "power-profile-balanced-rtl-symbolic");
|
|
gtk_header_bar_pack_end (header_bar, GTK_WIDGET (power_middle));
|
|
|
|
GtkButton *power_low = GTK_BUTTON (gtk_button_new ());
|
|
gtk_button_set_icon_name (power_low, "power-profile-power-saver-symbolic");
|
|
gtk_header_bar_pack_end (header_bar, GTK_WIDGET (power_low));
|
|
}
|
|
|
|
GtkWidget *get_window_child_STATE() {
|
|
GtkBox *page_box = GTK_BOX (gtk_box_new (GTK_ORIENTATION_VERTICAL, 2));
|
|
gtk_box_append (page_box, GTK_WIDGET (get_OBJECTS_and_SITUATIONS()));
|
|
gtk_box_append (page_box, GTK_WIDGET (gtk_separator_new (GTK_ORIENTATION_HORIZONTAL)));
|
|
gtk_box_append (page_box, GTK_WIDGET (get_SPACE_VIEW_box()));
|
|
gtk_box_append (page_box, GTK_WIDGET (gtk_separator_new (GTK_ORIENTATION_HORIZONTAL)));
|
|
if (!get_mode ()) gtk_box_append (page_box, GTK_WIDGET (get_TIME_EXEC_controls_box()));
|
|
else gtk_box_append (page_box, GTK_WIDGET (get_SPACE_EDIT_controls_box()));
|
|
//SWITCH_TO (STATE);
|
|
return GTK_WIDGET (page_box);
|
|
}
|
|
|
|
GtkWidget *get_window_child_RULES(){
|
|
GtkPaned *H_tree_vs_selected = GTK_PANED (gtk_paned_new (GTK_ORIENTATION_HORIZONTAL));
|
|
// GtkWidget *arbre_des_règles = gtk_frame_new ("Arbre des règles");
|
|
// GtkWidget *édition_de_la_règle_sélectionnée_n_1 = gtk_frame_new ("Inspection");
|
|
gtk_paned_set_start_child (H_tree_vs_selected, GTK_WIDGET (get_rules_tree_hpaned_new()));
|
|
gtk_paned_set_end_child (H_tree_vs_selected, GTK_WIDGET (get_selected_rules_vpaned_new()));
|
|
gtk_paned_set_position (H_tree_vs_selected, 400); // WARNING : c'est une position "absolue"
|
|
gtk_paned_set_wide_handle (H_tree_vs_selected, TRUE);
|
|
//SWITCH_TO (RULES);
|
|
return GTK_WIDGET (H_tree_vs_selected);
|
|
}
|
|
|
|
GtkWidget *get_window_child_DATA (){
|
|
GtkBox *data_box = GTK_BOX (gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 32));
|
|
|
|
GtkWidget* frame_rule_effect = gtk_frame_new ("rule effect\n-----------");
|
|
gtk_frame_set_label_align (GTK_FRAME (frame_rule_effect), 0.5);
|
|
GtkBox *rule_effect_box = GTK_BOX (gtk_box_new (GTK_ORIENTATION_VERTICAL, 8));
|
|
gtk_frame_set_child (GTK_FRAME (frame_rule_effect), GTK_WIDGET (rule_effect_box));
|
|
|
|
GtkWidget* frame_rule_topic = gtk_frame_new ("rule topic\n----------");
|
|
gtk_frame_set_label_align (GTK_FRAME (frame_rule_topic), 0.5);
|
|
GtkBox *rule_topic_box = GTK_BOX (gtk_box_new (GTK_ORIENTATION_VERTICAL, 8));
|
|
gtk_frame_set_child (GTK_FRAME (frame_rule_topic), GTK_WIDGET (rule_topic_box));
|
|
|
|
GtkWidget* frame_data_type = gtk_frame_new ("data type\n----------");
|
|
gtk_frame_set_label_align (GTK_FRAME (frame_data_type), 0.5);
|
|
GtkBox *data_type_box = GTK_BOX (gtk_box_new (GTK_ORIENTATION_VERTICAL, 8));
|
|
gtk_frame_set_child (GTK_FRAME (frame_data_type), GTK_WIDGET (data_type_box));
|
|
|
|
GtkWidget* frame_interpretations = gtk_frame_new ("interpretation\n---------------");
|
|
gtk_frame_set_label_align (GTK_FRAME (frame_interpretations), 0.5);
|
|
GtkBox *interpretations_box = GTK_BOX (gtk_box_new (GTK_ORIENTATION_VERTICAL, 8));
|
|
gtk_frame_set_child (GTK_FRAME (frame_interpretations), GTK_WIDGET (interpretations_box));
|
|
|
|
GtkWidget* frame_discussions = gtk_frame_new ("discussion\n------------");
|
|
gtk_frame_set_label_align (GTK_FRAME (frame_discussions), 0.5);
|
|
GtkBox *discussions_box = GTK_BOX (gtk_box_new (GTK_ORIENTATION_VERTICAL, 8));
|
|
gtk_frame_set_child (GTK_FRAME (frame_discussions), GTK_WIDGET (discussions_box));
|
|
|
|
GtkWidget* frame_separator = gtk_frame_new ("\n");
|
|
|
|
GtkWidget* frame_game = gtk_frame_new ("game\n------");
|
|
gtk_frame_set_label_align (GTK_FRAME (frame_game), 0.5);
|
|
GtkBox *game_box = GTK_BOX (gtk_box_new (GTK_ORIENTATION_VERTICAL, 8));
|
|
gtk_frame_set_child (GTK_FRAME (frame_game), GTK_WIDGET (game_box));
|
|
|
|
GtkWidget* frame_help = gtk_frame_new ("help\n-----");
|
|
gtk_frame_set_label_align (GTK_FRAME (frame_help), 0.5);
|
|
GtkBox *help_box = GTK_BOX (gtk_box_new (GTK_ORIENTATION_VERTICAL, 8));
|
|
gtk_frame_set_child (GTK_FRAME (frame_help), GTK_WIDGET (help_box));
|
|
|
|
gtk_box_append (data_box, GTK_WIDGET (frame_rule_effect));
|
|
gtk_box_append (data_box, GTK_WIDGET (frame_rule_topic));
|
|
gtk_box_append (data_box, GTK_WIDGET (frame_data_type));
|
|
gtk_box_append (data_box, GTK_WIDGET (frame_interpretations));
|
|
gtk_box_append (data_box, GTK_WIDGET (frame_discussions));
|
|
gtk_box_append (data_box, GTK_WIDGET (frame_separator));
|
|
gtk_box_append (data_box, GTK_WIDGET (frame_game));
|
|
gtk_box_append (data_box, GTK_WIDGET (frame_help));
|
|
|
|
gtk_box_append (rule_effect_box, gtk_button_new_with_label ("movement"));
|
|
gtk_box_append (rule_effect_box, gtk_button_new_with_label ("transport"));
|
|
gtk_box_append (rule_effect_box, gtk_button_new_with_label ("transformation"));
|
|
|
|
gtk_box_append (rule_topic_box, gtk_button_new_with_label ("objects"));
|
|
gtk_box_append (rule_topic_box, gtk_button_new_with_label ("situations"));
|
|
|
|
gtk_box_append (rule_topic_box, GTK_WIDGET (gtk_separator_new (GTK_ORIENTATION_HORIZONTAL)));
|
|
gtk_box_append (rule_topic_box, GTK_WIDGET (gtk_separator_new (GTK_ORIENTATION_HORIZONTAL)));
|
|
gtk_box_append (rule_topic_box, gtk_button_new_with_label ("accuracy"));
|
|
gtk_box_append (rule_topic_box, gtk_button_new_with_label ("pattern recognition"));
|
|
|
|
gtk_box_append (data_type_box, gtk_button_new_with_label ("repartitions"));
|
|
gtk_box_append (data_type_box, gtk_button_new_with_label ("evolutions"));
|
|
gtk_box_append (data_type_box, gtk_button_new_with_label ("correlations"));
|
|
|
|
gtk_box_append (interpretations_box, gtk_button_new_with_label ("stochastic"));
|
|
gtk_box_append (interpretations_box, gtk_button_new_with_label ("deterministic"));
|
|
|
|
gtk_box_append (interpretations_box, GTK_WIDGET (gtk_separator_new (GTK_ORIENTATION_HORIZONTAL)));
|
|
gtk_box_append (interpretations_box, GTK_WIDGET (gtk_separator_new (GTK_ORIENTATION_HORIZONTAL)));
|
|
gtk_box_append (interpretations_box, gtk_button_new_with_label ("physical"));
|
|
gtk_box_append (interpretations_box, gtk_button_new_with_label ("chemical"));
|
|
gtk_box_append (interpretations_box, gtk_button_new_with_label ("biological"));
|
|
gtk_box_append (interpretations_box, gtk_button_new_with_label ("social"));
|
|
gtk_box_append (interpretations_box, GTK_WIDGET (gtk_separator_new (GTK_ORIENTATION_HORIZONTAL)));
|
|
|
|
gtk_box_append (discussions_box, gtk_button_new_with_label ("context"));
|
|
gtk_box_append (discussions_box, gtk_button_new_with_label ("methodology"));
|
|
gtk_box_append (discussions_box, gtk_button_new_with_label ("comparisons"));
|
|
gtk_box_append (discussions_box, gtk_button_new_with_label ("to improve"));
|
|
gtk_box_append (discussions_box, gtk_button_new_with_label ("summary"));
|
|
|
|
gtk_box_append (game_box, gtk_button_new_with_label ("single player"));
|
|
gtk_box_append (game_box, gtk_button_new_with_label ("multiple players"));
|
|
gtk_box_append (game_box, gtk_button_new_with_label ("edition facilities"));
|
|
|
|
gtk_box_append (help_box, gtk_button_new_with_label ("modelization"));
|
|
gtk_box_append (help_box, gtk_button_new_with_label ("measurements"));
|
|
gtk_box_append (help_box, gtk_button_new_with_label ("results"));
|
|
gtk_box_append (help_box, gtk_button_new_with_label ("data analysis"));
|
|
|
|
gtk_box_append (help_box, GTK_WIDGET (gtk_separator_new (GTK_ORIENTATION_HORIZONTAL)));
|
|
gtk_box_append (help_box, GTK_WIDGET (gtk_separator_new (GTK_ORIENTATION_HORIZONTAL)));
|
|
gtk_box_append (help_box, gtk_button_new_with_label ("preferences"));
|
|
|
|
//SWITCH_TO (DATA);
|
|
return GTK_WIDGET (data_box);
|
|
}
|
|
|