[gimp] Add a notebook for the display shells
- From: Michael Natterer <mitch src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gimp] Add a notebook for the display shells
- Date: Tue, 29 Sep 2009 20:16:05 +0000 (UTC)
commit e8061e5a7e7bb4eb3c675407785544cd8aef703a
Author: Michael Natterer <mitch gimp org>
Date: Tue Sep 29 21:57:57 2009 +0200
Add a notebook for the display shells
app/display/gimpimagewindow.c | 17 +++++++++++++++--
1 files changed, 15 insertions(+), 2 deletions(-)
---
diff --git a/app/display/gimpimagewindow.c b/app/display/gimpimagewindow.c
index e0b87cb..756d089 100644
--- a/app/display/gimpimagewindow.c
+++ b/app/display/gimpimagewindow.c
@@ -70,6 +70,7 @@ struct _GimpImageWindowPrivate
GtkWidget *main_vbox;
GtkWidget *menubar;
GtkWidget *hbox;
+ GtkWidget *notebook;
GtkWidget *statusbar;
GdkWindowState window_state;
@@ -256,6 +257,13 @@ gimp_image_window_constructor (GType type,
TRUE, TRUE, 0);
gtk_widget_show (private->hbox);
+ private->notebook = gtk_notebook_new ();
+ gtk_notebook_set_show_border (GTK_NOTEBOOK (private->notebook), FALSE);
+ gtk_notebook_set_show_tabs (GTK_NOTEBOOK (private->notebook), FALSE);
+ gtk_box_pack_start (GTK_BOX (private->hbox), private->notebook,
+ TRUE, TRUE, 0);
+ gtk_widget_show (private->notebook);
+
private->statusbar = gimp_statusbar_new ();
gimp_help_set_help_data (private->statusbar, NULL,
GIMP_HELP_IMAGE_WINDOW_STATUS_BAR);
@@ -546,8 +554,13 @@ gimp_image_window_add_shell (GimpImageWindow *window,
private->shells = g_list_append (private->shells, shell);
/* FIXME multiple shells */
- gtk_box_pack_start (GTK_BOX (private->hbox), GTK_WIDGET (shell),
- TRUE, TRUE, 0);
+ gtk_notebook_append_page (GTK_NOTEBOOK (private->notebook),
+ GTK_WIDGET (shell),
+ gtk_label_new ("foo"));
+
+ if (g_list_length (private->shells) > 1)
+ gtk_notebook_set_show_tabs (GTK_NOTEBOOK (private->notebook), TRUE);
+
gtk_widget_show (GTK_WIDGET (shell));
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]