[eog] Tweak gallery ui
- From: Felix Riemann <friemann src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [eog] Tweak gallery ui
- Date: Tue, 3 Nov 2015 18:36:57 +0000 (UTC)
commit c2b0edebe2f19e9d7d2dbf4c445e9745ab3d2c80
Author: Trinh Anh Ngoc <atw1990 gmail com>
Date: Tue Oct 27 14:58:55 2015 +0700
Tweak gallery ui
data/eog.css | 24 ++++++++++++++++++++++++
src/eog-thumb-nav.c | 23 +++++++----------------
src/eog-window.c | 2 +-
3 files changed, 32 insertions(+), 17 deletions(-)
---
diff --git a/data/eog.css b/data/eog.css
index b82e0da..3269d5a 100644
--- a/data/eog.css
+++ b/data/eog.css
@@ -22,3 +22,27 @@ EogScrollView GtkOverlay GtkButton:prelight {
EogStatusbar {
border-top: 1px solid @borders;
}
+
+EogThumbNav {
+ border-top: 1px solid @borders;
+}
+
+EogThumbNav GtkScrolledWindow {
+ border-bottom: none;
+}
+
+EogThumbNav GtkScrolledWindow .undershoot.right {
+ background: none;
+ box-shadow: inset -6px 0 3px -6px @borders;
+}
+
+EogThumbNav GtkScrolledWindow .undershoot.left {
+ background: none;
+ box-shadow: inset 6px 0 3px -6px @borders;
+}
+
+EogThumbNav GtkButton {
+ border-width: 1px 0 0;
+ border-radius: 0;
+ box-shadow: none;
+}
diff --git a/src/eog-thumb-nav.c b/src/eog-thumb-nav.c
index 1d77895..57d23f5 100644
--- a/src/eog-thumb-nav.c
+++ b/src/eog-thumb-nav.c
@@ -338,7 +338,6 @@ static void
eog_thumb_nav_init (EogThumbNav *nav)
{
EogThumbNavPrivate *priv;
- GtkWidget *arrow;
gtk_orientable_set_orientation (GTK_ORIENTABLE (nav),
GTK_ORIENTATION_HORIZONTAL);
@@ -351,15 +350,11 @@ eog_thumb_nav_init (EogThumbNav *nav)
priv->show_buttons = TRUE;
- priv->button_left = gtk_button_new ();
+ priv->button_left = gtk_button_new_from_icon_name ("go-previous-symbolic",
+ GTK_ICON_SIZE_BUTTON);
gtk_button_set_relief (GTK_BUTTON (priv->button_left), GTK_RELIEF_NONE);
- arrow = gtk_image_new_from_icon_name ("pan-start-symbolic", GTK_ICON_SIZE_BUTTON);
- gtk_container_add (GTK_CONTAINER (priv->button_left), arrow);
-
- gtk_widget_set_size_request (GTK_WIDGET (priv->button_left), 25, 0);
-
- gtk_box_pack_start (GTK_BOX (nav), priv->button_left, FALSE, FALSE, 0);
+ gtk_box_pack_start (GTK_BOX (nav), priv->button_left, FALSE, FALSE, 0);
g_signal_connect (priv->button_left,
"clicked",
@@ -405,17 +400,13 @@ eog_thumb_nav_init (EogThumbNav *nav)
G_CALLBACK (eog_thumb_nav_adj_value_changed),
nav);
- gtk_box_pack_start (GTK_BOX (nav), priv->sw, TRUE, TRUE, 0);
+ gtk_box_pack_start (GTK_BOX (nav), priv->sw, TRUE, TRUE, 0);
- priv->button_right = gtk_button_new ();
+ priv->button_right = gtk_button_new_from_icon_name ("go-next-symbolic",
+ GTK_ICON_SIZE_BUTTON);
gtk_button_set_relief (GTK_BUTTON (priv->button_right), GTK_RELIEF_NONE);
- arrow = gtk_image_new_from_icon_name ("pan-end-symbolic", GTK_ICON_SIZE_BUTTON);
- gtk_container_add (GTK_CONTAINER (priv->button_right), arrow);
-
- gtk_widget_set_size_request (GTK_WIDGET (priv->button_right), 25, 0);
-
- gtk_box_pack_start (GTK_BOX (nav), priv->button_right, FALSE, FALSE, 0);
+ gtk_box_pack_start (GTK_BOX (nav), priv->button_right, FALSE, FALSE, 0);
g_signal_connect (priv->button_right,
"clicked",
diff --git a/src/eog-window.c b/src/eog-window.c
index 09de1b7..eef981f 100644
--- a/src/eog-window.c
+++ b/src/eog-window.c
@@ -305,7 +305,7 @@ eog_window_set_gallery_mode (EogWindow *window,
} else {
mode = EOG_THUMB_NAV_MODE_ONE_ROW;
- priv->layout = gtk_box_new (GTK_ORIENTATION_VERTICAL, 2);
+ priv->layout = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
if (position == EOG_WINDOW_GALLERY_POS_BOTTOM) {
gtk_box_pack_start (GTK_BOX (priv->layout), hpaned, TRUE, TRUE, 0);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]