File size: 845 Bytes
148aca7
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
<TextGenLayout>:
    orientation: 'vertical'
    padding: 20
    spacing: 15

    Label:
        text: "🤖 Enter a Prompt for AI Text Generation"
        font_size: 20
        size_hint_y: 0.1

    TextInput:
        id: prompt_input
        multiline: True
        hint_text: "Start typing a prompt here..."
        size_hint_y: 0.3

    Button:
        text: "🧠 Generate Text"
        size_hint_y: 0.15
        on_press: root.generate()

    Label:
        text: "✍️ AI Response:"
        font_size: 18
        size_hint_y: 0.1

    ScrollView:
        size_hint_y: 0.35
        do_scroll_x: False

        Label:
            id: output_box
            text: ""
            text_size: self.width, None
            size_hint_y: None
            height: self.texture_size[1]
            font_size: 16