scrolling many objects and situations in the bottom horizontal pane
This commit is contained in:
parent
bb0379bb08
commit
8e4be2ff08
|
@ -11,7 +11,7 @@
|
||||||
#define H 960
|
#define H 960
|
||||||
#define W_IMAGE 1920 - 320
|
#define W_IMAGE 1920 - 320
|
||||||
#define H_IMAGE 960 - 126
|
#define H_IMAGE 960 - 126
|
||||||
#define H_STYLES_PANE 60
|
#define H_STYLES_PANE 30
|
||||||
|
|
||||||
void activate (GtkApplication *app, gpointer user_data);
|
void activate (GtkApplication *app, gpointer user_data);
|
||||||
|
|
||||||
|
|
21
display.c
21
display.c
|
@ -112,23 +112,34 @@ GtkProgressBar *get_ELAPSED_TIME_ProgressBar(){ // To rename : DO - UNDO - REDO
|
||||||
|
|
||||||
static GtkBox *get_objects_box(){
|
static GtkBox *get_objects_box(){
|
||||||
GtkBox *objects_box = GTK_BOX(gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0));
|
GtkBox *objects_box = GTK_BOX(gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0));
|
||||||
|
GtkAdjustment *adjust = gtk_adjustment_new (0, 0, 255, 1, 0, 0);
|
||||||
|
if (0) for (int i = 0; i < 10; i++)
|
||||||
|
gtk_box_append (objects_box, gtk_scrollbar_new (GTK_ORIENTATION_VERTICAL, adjust));
|
||||||
|
char string[7];
|
||||||
|
for (int i = 0; i < 16; i++){
|
||||||
|
sprintf(string, "[%d] ", i);
|
||||||
|
if (0) printf("%s\n", string); // répété deux fois ! pourquoi ?
|
||||||
|
gtk_box_append (objects_box, GTK_WIDGET (gtk_label_new (string)));
|
||||||
|
}
|
||||||
gtk_box_append (objects_box, GTK_WIDGET (gtk_label_new (" membrane ")));
|
gtk_box_append (objects_box, GTK_WIDGET (gtk_label_new (" membrane ")));
|
||||||
gtk_box_append (objects_box, GTK_WIDGET (gtk_label_new (" co-enzyme A ")));
|
gtk_box_append (objects_box, GTK_WIDGET (gtk_label_new (" co-enzyme A ")));
|
||||||
gtk_box_append (objects_box, GTK_WIDGET (gtk_label_new (" ribosome ")));
|
gtk_box_append (objects_box, GTK_WIDGET (gtk_label_new (" ribosome ")));
|
||||||
gtk_box_append (objects_box, GTK_WIDGET (gtk_label_new (" cytochrome C ")));
|
|
||||||
gtk_box_append (objects_box, GTK_WIDGET (gtk_label_new (" ATP synthase ")));
|
gtk_box_append (objects_box, GTK_WIDGET (gtk_label_new (" ATP synthase ")));
|
||||||
gtk_box_append (objects_box, GTK_WIDGET (gtk_label_new (" chromosome ")));
|
|
||||||
return objects_box;
|
return objects_box;
|
||||||
}
|
}
|
||||||
|
|
||||||
static GtkBox *get_situations_box(){
|
static GtkBox *get_situations_box(){
|
||||||
GtkBox *situations_box = GTK_BOX(gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0));
|
GtkBox *situations_box = GTK_BOX(gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0));
|
||||||
|
char string[7];
|
||||||
|
for (int i = 0; i < 64; i++){
|
||||||
|
sprintf(string, "[%d] ", i);
|
||||||
|
if (0) printf("%s\n", string); // répété deux fois ! pourquoi ?
|
||||||
|
gtk_box_append (situations_box, GTK_WIDGET (gtk_label_new (string)));
|
||||||
|
}
|
||||||
gtk_box_append (situations_box, GTK_WIDGET (gtk_label_new (" transcription ")));
|
gtk_box_append (situations_box, GTK_WIDGET (gtk_label_new (" transcription ")));
|
||||||
gtk_box_append (situations_box, GTK_WIDGET (gtk_label_new (" activation opéron lactose ")));
|
|
||||||
gtk_box_append (situations_box, GTK_WIDGET (gtk_label_new (" translation ")));
|
|
||||||
gtk_box_append (situations_box, GTK_WIDGET (gtk_label_new (" transport Na/K ")));
|
gtk_box_append (situations_box, GTK_WIDGET (gtk_label_new (" transport Na/K ")));
|
||||||
gtk_box_append (situations_box, GTK_WIDGET (gtk_label_new (" ubiquitination ")));
|
gtk_box_append (situations_box, GTK_WIDGET (gtk_label_new (" ubiquitination ")));
|
||||||
gtk_box_append (situations_box, GTK_WIDGET (gtk_label_new (" rotation du moteur flagellaire ")));
|
gtk_box_append (situations_box, GTK_WIDGET (gtk_label_new (" rotation moteur flagellaire ")));
|
||||||
return situations_box;
|
return situations_box;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue