electrum-bitcoinprivate/gui/kivy/uix/ui_screens/send.kv

148 lines
4.7 KiB
Plaintext
Raw Normal View History

#:import _ electrum.i18n._
#:import Decimal decimal.Decimal
#:import Factory kivy.factory.Factory
#:set btc_symbol unichr(171)
#:set mbtc_symbol unichr(187)
#:set font_light 'data/fonts/Roboto-Condensed.ttf'
2015-10-14 04:03:13 -07:00
<SendToggle@ToggleButton>
source: ''
markup: False
bold: True
border: 4, 4, 4, 4
group: 'transfer_type'
background_normal: self.background_down
color:
(.140, .140, .140, 1) if self.state == 'down' else (.796, .796, .796, 1)
canvas.after:
Color:
rgba: 1, 1, 1, 1
Image:
source: root.source
color: root.color
size: '30dp', '30dp'
center_x: root.center_x - ((root.texture_size[0]/2)+(self.width/1.5))
center_y: root.center_y
<SendReceiveToggle@BoxLayout>
padding: '5dp', '5dp'
size_hint: 1, None
height: '45dp'
canvas.before:
Color:
rgba: 1, 1, 1, 1
BorderImage:
border: 12, 12, 12, 12
source: 'atlas://gui/kivy/theming/light/card'
size: self.width + dp(3), self.height
pos: self.x - dp(1.5), self.y
SendScreen:
2015-10-06 05:30:44 -07:00
id: send_screen
name: 'send'
2015-10-06 01:43:37 -07:00
#action_view: Factory.SendActionView()
#on_deactivate:
# self.ids.amount_e.focus = False
# self.ids.payto_e.focus = False
# self.ids.message_e.focus = False
BoxLayout
padding: '12dp', '12dp', '12dp', '12dp'
spacing: '12dp'
orientation: 'vertical'
SendReceiveToggle:
2015-10-14 09:03:02 -07:00
size_hint: 1, None
SendToggle:
2015-10-14 04:03:13 -07:00
id: qr
2015-10-14 06:13:47 -07:00
text: 'QR Code'
group: 'send_type'
2015-10-14 04:03:13 -07:00
source: 'atlas://gui/kivy/theming/light/qrcode'
on_release:
2015-10-14 04:03:13 -07:00
app.scan_qr(on_complete=root.set_qr_data)
state: 'down'
background_down: 'atlas://gui/kivy/theming/light/btn_send_nfc'
SendToggle:
2015-10-14 04:03:13 -07:00
id: nfc_toggle
text: 'NFC'
group: 'send_type'
2015-10-14 04:03:13 -07:00
state: 'normal'
source: 'atlas://gui/kivy/theming/light/nfc'
background_down: 'atlas://gui/kivy/theming/light/btn_send_nfc'
2015-10-14 07:52:10 -07:00
SendReceiveBlueBottom:
id: blue_bottom
size_hint: 1, None
height: self.minimum_height
2015-10-14 07:52:10 -07:00
BoxLayout:
size_hint: 1, None
2015-10-14 07:52:10 -07:00
height: blue_bottom.item_height
spacing: '5dp'
Image:
source: 'atlas://gui/kivy/theming/light/contact'
size_hint: None, None
size: '22dp', '22dp'
pos_hint: {'center_y': .5}
2015-10-14 09:03:02 -07:00
TextInputBlue:
2015-10-14 07:52:10 -07:00
id: payto_e
hint_text: "Recipient"
CardSeparator:
opacity: message_selection.opacity
color: blue_bottom.foreground_color
BoxLayout:
size_hint: 1, None
height: blue_bottom.item_height
Image:
source: 'atlas://gui/kivy/theming/light/bit_logo'
size_hint: None, None
size: '22dp', '22dp'
pos_hint: {'center_y': .5}
Button:
id: amount_e
2015-10-14 09:03:02 -07:00
default_text: 'Amount'
text: self.default_text
text_size: (self.width-15, None)
2015-10-14 07:52:10 -07:00
halign: 'left'
size_hint: 0.5, None
height: '38dp'
2015-10-30 07:48:17 -07:00
on_release: app.amount_dialog(self, None, True)
2015-10-14 07:52:10 -07:00
background_color: .238, .585, .878, 0
CardSeparator:
opacity: message_selection.opacity
color: blue_bottom.foreground_color
BoxLayout:
id: message_selection
opacity: 1
size_hint: 1, None
height: blue_bottom.item_height
spacing: '5dp'
Image:
source: 'atlas://gui/kivy/theming/light/pen'
size_hint: None, None
size: '22dp', '22dp'
pos_hint: {'center_y': .5}
2015-10-14 09:03:02 -07:00
TextInputBlue:
2015-10-14 07:52:10 -07:00
id: message_e
2015-10-14 09:45:26 -07:00
hint_text: 'Description (optional)'
2015-10-14 04:03:13 -07:00
BoxLayout:
2015-10-14 07:52:10 -07:00
size_hint: 1, None
2015-10-14 09:03:02 -07:00
height: '38dp'
2015-10-14 04:03:13 -07:00
Button:
text: _('Clear')
2015-10-14 09:03:02 -07:00
size_hint: 1, None
2015-10-14 04:03:13 -07:00
height: '38dp'
2015-10-14 05:18:15 -07:00
on_release: send_screen.do_clear()
2015-10-14 04:03:13 -07:00
Button:
text: _('Send')
2015-10-14 09:03:02 -07:00
size_hint: 1, None
2015-10-14 04:03:13 -07:00
height: '38dp'
on_release: send_screen.do_send()
2015-10-14 07:52:10 -07:00
Widget:
2015-10-14 09:03:02 -07:00
size_hint: 1, 1