From: John Melton G0ORX Date: Sun, 11 Oct 2020 09:34:57 +0000 (+0100) Subject: Added scrolled window to oc_menu X-Git-Url: https://git.rkrishnan.org/%5B/%5D%20/file/readonly?a=commitdiff_plain;h=e1ccf83576e0a8ba13a0bc974646acb096404db7;p=pihpsdr.git Added scrolled window to oc_menu --- diff --git a/oc_menu.c b/oc_menu.c index 6d11145..df51beb 100644 --- a/oc_menu.c +++ b/oc_menu.c @@ -131,6 +131,11 @@ g_print("oc_menu: parent=%p\n",parent); GtkWidget *content=gtk_dialog_get_content_area(GTK_DIALOG(dialog)); + GtkWidget *sw=gtk_scrolled_window_new (NULL, NULL); + gtk_scrolled_window_set_policy(GTK_SCROLLED_WINDOW(sw),GTK_POLICY_AUTOMATIC,GTK_POLICY_ALWAYS); + gtk_widget_set_size_request(sw, 600, 400); + GtkWidget *viewport=gtk_viewport_new(NULL,NULL); + GtkWidget *grid=gtk_grid_new(); gtk_grid_set_column_spacing (GTK_GRID(grid),10); //gtk_grid_set_row_spacing (GTK_GRID(grid),10); @@ -305,7 +310,9 @@ g_print("oc_menu: parent=%p\n",parent); g_signal_connect(oc_memory_tune_time_b,"value_changed",G_CALLBACK(oc_memory_tune_time_cb),NULL); j++; - gtk_container_add(GTK_CONTAINER(content),grid); + gtk_container_add(GTK_CONTAINER(viewport),grid); + gtk_container_add(GTK_CONTAINER(sw),viewport); + gtk_container_add(GTK_CONTAINER(content),sw); sub_menu=dialog;