devhelp r1232 - in trunk: . src
- From: rhult svn gnome org
- To: svn-commits-list gnome org
- Subject: devhelp r1232 - in trunk: . src
- Date: Thu, 6 Nov 2008 17:31:14 +0000 (UTC)
Author: rhult
Date: Thu Nov 6 17:31:13 2008
New Revision: 1232
URL: http://svn.gnome.org/viewvc/devhelp?rev=1232&view=rev
Log:
2008-11-06 Richard Hult <richard imendio com>
* src/dh-window.c: (window_activate_close),
(window_activate_about), (window_populate), (window_open_new_tab):
Don't show notebook tabs if there is only one tab to save some
space and get a cleaner look. Paddings/shadow might need some
further tweaking.
Modified:
trunk/ChangeLog
trunk/src/dh-window.c
Modified: trunk/src/dh-window.c
==============================================================================
--- trunk/src/dh-window.c (original)
+++ trunk/src/dh-window.c Thu Nov 6 17:31:13 2008
@@ -186,7 +186,7 @@
gtk_widget_destroy (GTK_WIDGET (window));
}
else if (pages == 1) {
- /*gtk_notebook_set_show_tabs (GTK_NOTEBOOK (priv->notebook), FALSE);*/
+ gtk_notebook_set_show_tabs (GTK_NOTEBOOK (priv->notebook), FALSE);
}
}
@@ -372,7 +372,7 @@
"translator-credits",
strcmp (translator_credits, "translator_credits") != 0 ?
translator_credits : NULL,
- "website", "http://developer.imendio.com/wiki/Devhelp",
+ "website", "http://developer.imendio.com/projects/devhelp/",
"logo-icon-name", "devhelp",
NULL);
}
@@ -720,6 +720,8 @@
/* HTML tabs notebook. */
priv->notebook = gtk_notebook_new ();
+ gtk_container_set_border_width (GTK_CONTAINER (priv->notebook), 0);
+ gtk_notebook_set_show_border (GTK_NOTEBOOK (priv->notebook), FALSE);
gtk_box_pack_start (GTK_BOX (priv->vbox), priv->notebook, TRUE, TRUE, 0);
g_signal_connect (priv->notebook,
@@ -1034,7 +1036,6 @@
priv = window->priv;
view = webkit_web_view_new ();
-
gtk_widget_show (view);
scrolled_window = gtk_scrolled_window_new (NULL, NULL);
@@ -1042,12 +1043,7 @@
GTK_POLICY_AUTOMATIC,
GTK_POLICY_AUTOMATIC);
gtk_widget_show (scrolled_window);
-
- gtk_scrolled_window_set_shadow_type (GTK_SCROLLED_WINDOW (scrolled_window),
- GTK_SHADOW_IN);
- gtk_container_set_border_width (GTK_CONTAINER (scrolled_window), 2);
gtk_container_add (GTK_CONTAINER (scrolled_window), view);
-
g_object_set_data (G_OBJECT (scrolled_window), "web_view", view);
label = window_new_tab_label (window, _("Empty Page"));
@@ -1076,9 +1072,11 @@
gtk_notebook_set_tab_label (GTK_NOTEBOOK (priv->notebook),
scrolled_window, label);
- /*gtk_notebook_set_show_tabs (GTK_NOTEBOOK (priv->notebook),
- gtk_notebook_get_n_pages (GTK_NOTEBOOK (priv->notebook)) > 1);
- */
+ if (gtk_notebook_get_n_pages (GTK_NOTEBOOK (priv->notebook)) > 1) {
+ gtk_notebook_set_show_tabs (GTK_NOTEBOOK (priv->notebook), TRUE);
+ } else {
+ gtk_notebook_set_show_tabs (GTK_NOTEBOOK (priv->notebook), FALSE);
+ }
if (location) {
webkit_web_view_open (WEBKIT_WEB_VIEW (view), location);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]