rules tree & rules inspection (WIP)

This commit is contained in:
Jean Sirmai 2024-05-11 08:23:14 +02:00
parent 1248bff327
commit e05411f80d
Signed by: jean
GPG Key ID: FB3115C340E057E3
5 changed files with 39 additions and 35 deletions

View File

@ -8,8 +8,17 @@
GtkWidget *get_edit_rules_page_new(){ GtkWidget *get_edit_rules_page_new(){
GtkWidget *xxx_grid = gtk_grid_new(); GtkPaned *hpaned = GTK_PANED (gtk_paned_new (GTK_ORIENTATION_HORIZONTAL));
return xxx_grid;
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 *get_edit_measures_page_new(){
@ -164,5 +173,6 @@ void activate (GtkApplication *app, gpointer user_data) {
gtk_window_present (GTK_WINDOW (window)); gtk_window_present (GTK_WINDOW (window));
gtk_notebook_set_current_page (run_notebook, 1); // @see hot.c 2024-05-11 (line 68) gtk_notebook_set_current_page (run_notebook, 1); // @see hot.c 2024-05-11 (line 68)
gtk_notebook_set_current_page (edit_notebook, 1); // @see hot.c 2024-05-11 (line 68)
} }

BIN
contain.o

Binary file not shown.

60
hot.c
View File

@ -15,48 +15,42 @@
GtkWidget *get_run_rules_page_new(){ GtkWidget *get_selected_rules_vpaned_new(){
GtkPaned *vpaned = GTK_PANED (gtk_paned_new (GTK_ORIENTATION_VERTICAL));
GtkWidget *règle_sélectionnée_n_1 = gtk_frame_new ("(1)");
GtkWidget *règle_sélectionnée_n_2 = gtk_frame_new ("(2)");
gtk_paned_set_start_child (vpaned, GTK_WIDGET (règle_sélectionnée_n_1));
gtk_paned_set_end_child (vpaned, GTK_WIDGET (règle_sélectionnée_n_2));
// gtk_paned_set_wide_handle (vpaned, TRUE);
return GTK_WIDGET (vpaned);
}
GtkWidget *get_rules_tree_hpaned_new(){
GtkPaned *hpaned = GTK_PANED (gtk_paned_new (GTK_ORIENTATION_HORIZONTAL)); GtkPaned *hpaned = GTK_PANED (gtk_paned_new (GTK_ORIENTATION_HORIZONTAL));
GtkWidget *arbre_des_règles = gtk_frame_new ("Arbre des règles"); GtkWidget *arbre_des_règles = gtk_frame_new ("Arbre");
GtkWidget *édition_de_la_règle_sélectionnée = gtk_frame_new ("Édition de la règle sélectionnée"); GtkWidget *comparaison_des_règles_sélectionnées = gtk_frame_new ("Sélection");
gtk_paned_set_start_child (hpaned, GTK_WIDGET (arbre_des_règles)); 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_paned_set_end_child (hpaned, GTK_WIDGET (comparaison_des_règles_sélectionnées));
// gtk_widget_set_size_request (GTK_WIDGET (hpaned), W, H); gtk_paned_set_position (hpaned, 300);
gtk_paned_set_wide_handle (hpaned, TRUE); gtk_paned_set_wide_handle (hpaned, TRUE);
return GTK_WIDGET (hpaned); return GTK_WIDGET (hpaned);
} }
/*
GtkWidget *get_run_rules_page_new(){ GtkWidget *get_run_rules_page_new(){
GtkWidget *rules_grid = gtk_grid_new(); GtkPaned *hpaned = GTK_PANED (gtk_paned_new (GTK_ORIENTATION_HORIZONTAL));
GtkWidget *hpaned = gtk_paned_new (GTK_ORIENTATION_HORIZONTAL);
gtk_grid_attach (GTK_GRID (rules_grid), hpaned, 0, 0, 1, 1);
GtkWidget *frame1 = gtk_frame_new ("hello ?"); // GtkWidget *arbre_des_règles = gtk_frame_new ("Arbre des règles");
GtkWidget *frame2 = gtk_frame_new ("it's me !"); // GtkWidget *édition_de_la_règle_sélectionnée_n_1 = gtk_frame_new ("Inspection");
GtkWidget *grid_3 = gtk_grid_new(); gtk_paned_set_start_child (hpaned, GTK_WIDGET (get_rules_tree_hpaned_new()));
gtk_frame_set_child ( GTK_FRAME(frame2), grid_3); gtk_paned_set_end_child (hpaned, GTK_WIDGET (get_selected_rules_vpaned_new()));
gtk_paned_set_position (hpaned, 600);
gtk_paned_set_start_child (GTK_PANED(hpaned), GTK_WIDGET (frame1)); gtk_paned_set_wide_handle (hpaned, TRUE);
gtk_paned_set_end_child (GTK_PANED(hpaned), GTK_WIDGET (frame2)); // gtk_widget_set_size_request (GTK_WIDGET (hpaned), W, H); // inutile... ?
gtk_widget_set_size_request (hpaned, W, H); return GTK_WIDGET (hpaned);
gtk_grid_attach (GTK_GRID (grid_3), gtk_button_new_with_label ("in the right pane"), 0, 0, 1, 1);
return rules_grid;
} }
*/

BIN
hot.o

Binary file not shown.

BIN
myprogram

Binary file not shown.