changeset 422:6925f540a0c6

Tweak zoom button layout
author Neil Muller <drnlmuller@gmail.com>
date Sat, 07 Sep 2013 13:00:31 +0200
parents 2cb12311fedc
children eb1a4a269d37
files tools/area_editor.py
diffstat 1 files changed, 7 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/tools/area_editor.py	Sat Sep 07 13:00:36 2013 +0200
+++ b/tools/area_editor.py	Sat Sep 07 13:00:31 2013 +0200
@@ -993,13 +993,14 @@
 
         zoom_out = Button('Zoom out', action=self.level_widget.zoom_out)
         zoom_out.rect = BUTTON_RECT.copy()
+        zoom_out.rect.width = zoom_out.rect.width // 2
         zoom_out.rect.move_ip(MENU_LEFT, y)
         widgets.append(zoom_out)
-        y += MENU_BUTTON_HEIGHT + MENU_PAD
 
         zoom_in = Button('Zoom in', action=self.level_widget.zoom_in)
         zoom_in.rect = BUTTON_RECT.copy()
-        zoom_in.rect.move_ip(MENU_LEFT, y)
+        zoom_in.width = zoom_in.width // 2
+        zoom_in.rect.move_ip(MENU_LEFT + zoom_out.width, y)
         widgets.append(zoom_in)
 
         y = SCREEN[1] - MENU_BUTTON_HEIGHT - MENU_PAD
@@ -1075,14 +1076,16 @@
 
         zoom_out = Button('Zoom out', action=self.level_widget.zoom_out)
         zoom_out.rect = BUTTON_RECT.copy()
+        zoom_out.rect.width = zoom_out.rect.width // 2
         zoom_out.rect.move_ip(MENU_LEFT, y)
         widgets.append(zoom_out)
-        y += MENU_BUTTON_HEIGHT + MENU_PAD
 
         zoom_in = Button('Zoom in', action=self.level_widget.zoom_in)
         zoom_in.rect = BUTTON_RECT.copy()
-        zoom_in.rect.move_ip(MENU_LEFT, y)
+        zoom_in.width = zoom_in.width // 2
+        zoom_in.rect.move_ip(MENU_LEFT + zoom_out.width, y)
         widgets.append(zoom_in)
+        y += MENU_BUTTON_HEIGHT + MENU_PAD
 
         y = SCREEN[1] - MENU_BUTTON_HEIGHT - MENU_PAD
         quit_but = Button('Quit', action=self.quit)