File: camerademo.kv

package info (click to toggle)
python-plyer 2.0.0-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 1,668 kB
  • sloc: python: 13,112; sh: 217; makefile: 177
file content (41 lines) | stat: -rw-r--r-- 984 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
#:kivy 1.8.0
<CameraDemo>:
    FloatLayout:
        Label:
            id: path_label
            text: 'Working Directory:'
            pos_hint: {'x': 0.25, 'y': 0.7}
            size_hint: 0.5, 0.1
            
        TextInput:
            id: filename_text
            text: 'enter_file_name_here.jpg'
            pos_hint: {'x': 0.25, 'y': .6}
            size_hint: 0.5, 0.1
            multiline: False
        
        Button:
            text: 'Take picture from camera!'
            pos_hint: {'x': 0.25, 'y': .3}
            size_hint: 0.5, 0.2
            on_press: root.do_capture()

<MsgPopup>:
    size_hint: .7, .4
    title: "Attention"
    
    BoxLayout:
        orientation: 'vertical'
        padding: 10
        spacing: 20

        Label:
            id: message_label
            size_hint_y: 0.4
            text: "Label"
        Button:
            text: 'Dismiss'
            size_hint_y: 0.4
            on_press: root.dismiss()