WIP: cleaning ...
This commit is contained in:
parent
8578047ab1
commit
0c2530020d
|
@ -179,21 +179,19 @@ void window_bar(GtkWindow *window, char *title){
|
||||||
}
|
}
|
||||||
|
|
||||||
void experimental_activate_00 (GtkApplication *app, GtkWindow *window) {
|
void experimental_activate_00 (GtkApplication *app, GtkWindow *window) {
|
||||||
// window_bar (window, "E coli (with permission from David S. Goodsell, 2009)");
|
GtkWidget *header_bar = gtk_header_bar_new ();
|
||||||
GtkWidget *my_header_bar = gtk_header_bar_new ();
|
GtkWidget *title = GTK_WIDGET (gtk_label_new ("GemGraph 0.1.0"));
|
||||||
gtk_header_bar_set_title_widget (GTK_HEADER_BAR (my_header_bar), GTK_WIDGET (gtk_label_new ("E coli (with permission from David S. Goodsell, 2009)")));
|
title = GTK_WIDGET (gtk_label_new ("E coli (with permission from David S. Goodsell, 2009)"));
|
||||||
|
gtk_header_bar_set_title_widget (GTK_HEADER_BAR (header_bar), title);
|
||||||
GtkWidget *run_edit = gtk_toggle_button_new ();
|
GtkWidget *run_edit = gtk_toggle_button_new ();
|
||||||
gtk_button_set_icon_name (GTK_BUTTON (run_edit), "document-edit-symbolic");
|
gtk_button_set_icon_name (GTK_BUTTON (run_edit), "document-edit-symbolic");
|
||||||
gtk_button_set_icon_name (GTK_BUTTON (run_edit), "system-run-symbolic");
|
gtk_button_set_icon_name (GTK_BUTTON (run_edit), "system-run-symbolic");
|
||||||
// gtk_toggle_button_set_active (run_edit, TRUE);
|
gtk_actionable_set_action_name (GTK_ACTIONABLE (run_edit), "app.togglerunedit");
|
||||||
gtk_actionable_set_action_name (run_edit, "app.togglerunedit");
|
gtk_header_bar_pack_start (GTK_HEADER_BAR (header_bar), run_edit);
|
||||||
// gtk_actionable_set_action_target_value (GTK_WIDGET (run_edit), "togglerunedit"); // ui_toggle_run_edit() GVariant
|
gtk_window_set_titlebar (window, header_bar);
|
||||||
gtk_header_bar_pack_start (GTK_HEADER_BAR (my_header_bar), run_edit);
|
|
||||||
gtk_window_set_titlebar (window, my_header_bar);
|
|
||||||
|
|
||||||
|
|
||||||
GtkNotebook *run_notebook = GTK_NOTEBOOK (gtk_notebook_new());
|
GtkNotebook *run_notebook = GTK_NOTEBOOK (gtk_notebook_new());
|
||||||
// gtk_notebook_set_tab_pos (run_notebook, GTK_POS_TOP); // TOP par défaut ? sinon : GTK_POS_LEFT
|
// gtk_notebook_set_tab_pos (run_notebook, GTK_POS_TOP); // TOP par défaut, I presume. Sinon : GTK_POS_LEFT
|
||||||
|
|
||||||
gtk_notebook_append_page (run_notebook, get_run_space_page_new(), gtk_label_new ("space"));
|
gtk_notebook_append_page (run_notebook, get_run_space_page_new(), gtk_label_new ("space"));
|
||||||
gtk_notebook_append_page (run_notebook, get_run_rules_page_new(), gtk_label_new ("rules"));
|
gtk_notebook_append_page (run_notebook, get_run_rules_page_new(), gtk_label_new ("rules"));
|
||||||
|
@ -203,7 +201,6 @@ gtk_actionable_set_action_name (run_edit, "app.togglerunedit");
|
||||||
gtk_notebook_append_page (run_notebook, get_run_help_page_new(), gtk_label_new ("help"));
|
gtk_notebook_append_page (run_notebook, get_run_help_page_new(), gtk_label_new ("help"));
|
||||||
|
|
||||||
GtkNotebook *edit_notebook = GTK_NOTEBOOK (gtk_notebook_new());
|
GtkNotebook *edit_notebook = GTK_NOTEBOOK (gtk_notebook_new());
|
||||||
// gtk_notebook_set_tab_pos (edit_notebook, GTK_POS_TOP); // TOP par défaut, I presume
|
|
||||||
|
|
||||||
gtk_notebook_append_page (edit_notebook, get_edit_space_page_new(), gtk_label_new ("space"));
|
gtk_notebook_append_page (edit_notebook, get_edit_space_page_new(), gtk_label_new ("space"));
|
||||||
gtk_notebook_append_page (edit_notebook, get_edit_rules_page_new(), gtk_label_new ("rules"));
|
gtk_notebook_append_page (edit_notebook, get_edit_rules_page_new(), gtk_label_new ("rules"));
|
||||||
|
|
|
@ -99,10 +99,7 @@ static GtkWidget *get_scroll_speed(){
|
||||||
const gchar *new_name = "new_name"; gtk_widget_set_name (scroll_speed, new_name);
|
const gchar *new_name = "new_name"; gtk_widget_set_name (scroll_speed, new_name);
|
||||||
// const GtkWidgetPath* gtk_style_context_get_path (GtkStyleContext* context);
|
// const GtkWidgetPath* gtk_style_context_get_path (GtkStyleContext* context);
|
||||||
// GtkStyleContext *my_context = gtk_style_context_new ();
|
// GtkStyleContext *my_context = gtk_style_context_new ();
|
||||||
gtk_style_context_set_state (gtk_widget_get_style_context (scroll_speed), 100);
|
// gtk_style_context_set_state (gtk_widget_get_style_context (scroll_speed), 100);
|
||||||
if (0) printf("display.get_scroll_speed() gtk_style_context_get_state (gtk_widget_get_style_context (scroll_speed)) = %d\n",\
|
|
||||||
gtk_style_context_get_state (gtk_widget_get_style_context (scroll_speed)));
|
|
||||||
|
|
||||||
return scroll_speed;
|
return scroll_speed;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue