Skip to content

Tag: kivy

How to stack multi-line labels vertically in BoxLayout

I am trying to create a stack of multiline Labels on Kivy inside a BoxLayout. How do I get the BoxLayout to expand according to its contents? Now the BoxLayout is squeezing the Labels instead. I do not wish to hardcode the multiline Label size as I want each to be flexible to accommodate varying lines of text…

Random list item, but unable to choose the same item twice

Is it possible to run a loop, that chooses a random list item, but is unable to choose the same one twice in a row. I’ve tried running it in a thread and with Clock.schedule_interval Im not sure how to keep the loop and GUI running simultaneously. When the interval goes off, it “resets” the …

Missing Recycle View widget

I need to create an autofill app, I have a label and text input on the top, and recycle view on the bottom. However, when I run the program, the recycle view disappears, even though I have set in the string. This app will facilitate searching content by typing the name in the text input and the relevant conte…

KivyMD DatePicker save multiple dates

I want that you can add and choose multiple dates. I tried to send a number with the button click button_nr but I don’t know how I can pass it to the on_save function, so that I can change the self.ids.date_label(button_nr).text . If somebody has a better idea how to save multiple dates I’m open f…

Kivy Error when I close the DatePicker (MultiScreen)

I’m trying to learn Kivy. Most stuff works when I just code it separate. But when I combine like MultiScreen with other code I always strugle. Here I want that after closing the DatePicker to change the Text(id: date_label. Same code worked without the MultiScreen Error: line 31, in on_cancel self.root.…