From f651742f86168c40a1fedb7c1d523ed4db25a51d Mon Sep 17 00:00:00 2001 From: ThomasV Date: Wed, 2 Dec 2015 19:25:07 +0100 Subject: [PATCH] kivy: layout --- gui/kivy/main.kv | 2 +- gui/kivy/uix/ui_screens/amount.kv | 29 ++++++++++++++--------------- 2 files changed, 15 insertions(+), 16 deletions(-) diff --git a/gui/kivy/main.kv b/gui/kivy/main.kv index afee54a02..9c937e2ce 100644 --- a/gui/kivy/main.kv +++ b/gui/kivy/main.kv @@ -195,7 +195,7 @@ : background_color: .238, .585, .878, 0 halign: 'left' - text_size: (self.width-15, None) + text_size: (self.width-10, None) size_hint: 0.5, None default_text: 'Amount' text: self.default_text diff --git a/gui/kivy/uix/ui_screens/amount.kv b/gui/kivy/uix/ui_screens/amount.kv index 457f088c2..12a2b2c1d 100644 --- a/gui/kivy/uix/ui_screens/amount.kv +++ b/gui/kivy/uix/ui_screens/amount.kv @@ -12,21 +12,14 @@ Popup: orientation: 'vertical' size_hint: 0.8, 1 BoxLayout: - size_hint: 1, None + size_hint: 1, 1 height: '48dp' Label: id: a amount: '' is_fiat: False text: app.get_amount_text(self.amount, self.is_fiat) - Widget: - size_hint_x: 1 - Button: - id: button_fiat - size_hint: 1, None - height: '48dp' - text: '/' - on_release: a.is_fiat = not a.is_fiat + size_hint: 1, 1 Widget: size_hint: 1, 1 @@ -77,6 +70,17 @@ Popup: height: '48dp' text: 'Max' on_release: a.amount = app.get_max_amount() + Button: + id: button_fiat + size_hint: 1, None + height: '48dp' + text: '/' + on_release: a.is_fiat = not a.is_fiat + Button: + size_hint: 1, None + height: '48dp' + text: 'Clear' + on_release: a.amount = '' Widget: size_hint: 1, None @@ -84,13 +88,8 @@ Popup: BoxLayout: size_hint: 1, None height: '48dp' - Button: - size_hint: 1, None - height: '48dp' - text: 'Clear' - on_release: a.amount = '' Widget: - size_hint: 1, None + size_hint: 2, None height: '48dp' Button: size_hint: 1, None