[meld] diffgrid: Support RTL layout flipping for DiffGrid
- From: Kai Willadsen <kaiw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [meld] diffgrid: Support RTL layout flipping for DiffGrid
- Date: Thu, 1 Jan 2015 00:04:00 +0000 (UTC)
commit 576de3da63333d76fa70fd9c60348ce849ca2287
Author: Kai Willadsen <kai willadsen gmail com>
Date: Tue Oct 28 06:10:38 2014 +1000
diffgrid: Support RTL layout flipping for DiffGrid
meld/diffgrid.py | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/meld/diffgrid.py b/meld/diffgrid.py
index a836097..8495741 100644
--- a/meld/diffgrid.py
+++ b/meld/diffgrid.py
@@ -191,6 +191,12 @@ class DiffGrid(Gtk.Grid):
child_alloc.y = yrows[top]
child_alloc.width = columns[left + width] - columns[left]
child_alloc.height = yrows[top + height] - yrows[top]
+
+ if self.get_direction() == Gtk.TextDirection.RTL:
+ child_alloc.x = (
+ allocation.x + allocation.width -
+ (child_alloc.x - allocation.x) - child_alloc.width)
+
child.size_allocate(child_alloc)
for child in self.get_children():
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]