[gnome-tweak-tool] Fix the location of the buttons in the headerbar when is split
- From: John Stowers <jstowers src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-tweak-tool] Fix the location of the buttons in the headerbar when is split
- Date: Sun, 12 Jan 2014 11:24:04 +0000 (UTC)
commit 01144e4d9cd27714768a488dc68ee4d56b1f6b67
Author: Yosef Or Boczko <yoseforb gmail com>
Date: Sun Jan 12 02:37:43 2014 +0200
Fix the location of the buttons in the headerbar when is split
https://bugzilla.gnome.org/show_bug.cgi?id=722017
gtweak/tweakview.py | 7 +++++++
1 files changed, 7 insertions(+), 0 deletions(-)
---
diff --git a/gtweak/tweakview.py b/gtweak/tweakview.py
index 6bac53f..10069b7 100644
--- a/gtweak/tweakview.py
+++ b/gtweak/tweakview.py
@@ -61,6 +61,7 @@ class Window(Gtk.ApplicationWindow):
header = Gtk.Box()
left_header = Gtk.HeaderBar()
+ left_header.props.show_close_button = True
right_header = Gtk.HeaderBar()
right_header.props.show_close_button = True
@@ -69,6 +70,12 @@ class Window(Gtk.ApplicationWindow):
right_header.get_style_context().add_class("titlebar")
right_header.get_style_context().add_class("tweak-titlebar-right")
+ layout_desc = Gtk.Settings.get_default().props.gtk_decoration_layout;
+ tokens = layout_desc.split(":", 2)
+ if tokens != None:
+ right_header.props.decoration_layout = ":" + tokens[1]
+ left_header.props.decoration_layout = tokens[0]
+
self.title = Gtk.Label("")
self.title.get_style_context().add_class("title")
right_header.set_custom_title(self.title)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]