I am using python-2.7
and kivy
.Someone help me that when i click into TextBox
then how to select text using python or kivy code?
test.py
from kivy.app import App
from kivy.uix.boxlayout import BoxLayout
from kivy.core.window import Window
Window.clearcolor = (0.5, 0.5, 0.5, 1)
Window.size = (400, 50)
class abc(BoxLayout):
pass
class Test(App):
def build(self):
return abc()
if __name__ == '__main__':
Test().run()
test.kv
<abc>:
BoxLayout:
orientation: "vertical"
size_hint_y: .5
BoxLayout:
orientation: "horizontal"
spacing: 10, 10
size_hint_x: .6
Label:
text: "TEXT"
text_size: self.size
valign: 'middle'
size_hint_x: .2
TextInput:
size_hint_x: .4