From ea1030f67d753fcdb8a9e2c2e013ca3e73b64533 Mon Sep 17 00:00:00 2001 From: Adrien 'neox' Bourmault Date: Tue, 10 Sep 2024 12:10:45 +0200 Subject: [PATCH] src/widget/state/middle.c: call ui_setup_glarea + fix copyright header --- src/widget/state/middle.c | 46 ++++++++++++++++----------------------- 1 file changed, 19 insertions(+), 27 deletions(-) diff --git a/src/widget/state/middle.c b/src/widget/state/middle.c index 5c3eee7..4c9bfbf 100644 --- a/src/widget/state/middle.c +++ b/src/widget/state/middle.c @@ -1,30 +1,26 @@ -/* * * * * * * * * * * * * * * * * * * * * * * * * * * -* * +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * Gem-graph client * -* * * State * * * -* Copyright © 2021 Libre en Communs * -* Copyright © 2021 Jean Sirmai * +* Copyright © 2021 Libre en Communs * +* Copyright © 2023-2024 Adrien Bourmault * +* Copyright © 2024 Jean Sirmai * * * -* This file is part of Gem-graph. * +* This file is part of Gem-graph. * * * -* This program is free software: you can redistribute it and/or modify it * -* under the terms of the GNU Affero General Public License * -* as published by the Free Software Foundation, * -* either version 3 of the License, * -* or (at your option) any later version. * +* This program is free software: you can redistribute it and/or modify it * +* under the terms of the GNU Affero General Public License * +* as publishedby the Free Software Foundation, * +* either version 3 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 Affero General Public License for more details. * +* 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 Affero General Public License for more details. * * * -* You should have received a copy of the GNU Affero General Public License * -* along with this program. If not, see . * -* * -* * * * * * * * * * * * * * * * * * * * * * * * * * */ +* You should have received a copy of the GNU Affero General Public License * +* along with this program. If not, see . * +* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ #include "../../../include/fsm.h" @@ -91,12 +87,8 @@ static void *get_ZOOM_box() void *widget_get_space_view(int partition_space_vs_camera) { - GtkBox *E_coli = GTK_BOX (gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0)); - gtk_box_append (GTK_BOX (E_coli), GTK_WIDGET (gtk_picture_new_for_filename - ("/home/jean/Gem-Graph/gem-graph-client/data/image/E coli by D Goodsell.png"))); - gtk_widget_set_size_request (GTK_WIDGET (E_coli), 0, H_E_COLI); // (provisoire) TODO - - // TODO replace this image by >> ui_setup_glarea (0, GTK_WIDGET (~)); + GtkBox *drawbox = GTK_BOX (gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0)); + ui_setup_glarea (GTK_BOX (drawbox)); GtkBox *camera = GTK_BOX (gtk_box_new (GTK_ORIENTATION_VERTICAL, 2)); gtk_box_append (camera, GTK_WIDGET (get_XYZ_box())); @@ -104,7 +96,7 @@ void *widget_get_space_view(int partition_space_vs_camera) gtk_box_append (camera, GTK_WIDGET (get_ZOOM_box())); GtkWidget *view_space_vs_camera = gtk_paned_new (GTK_ORIENTATION_HORIZONTAL); - gtk_paned_set_start_child (GTK_PANED (view_space_vs_camera), GTK_WIDGET (E_coli)); + gtk_paned_set_start_child (GTK_PANED (view_space_vs_camera), GTK_WIDGET (drawbox)); gtk_paned_set_end_child (GTK_PANED (view_space_vs_camera), GTK_WIDGET (camera)); gtk_paned_set_shrink_start_child (GTK_PANED (view_space_vs_camera), FALSE); gtk_paned_set_shrink_end_child (GTK_PANED (view_space_vs_camera), FALSE);