How can I reorder BoxLayout in kivy?

I am testing a kiwi and I want to create a BoxLayout to fold a few buttons. My problem is that the children added to the layout follow the lower level logic, but I want the other way around. Do you know how I can cancel an order? Thank you

+3
source share
2 answers

There are two ways to do this. Either pass your buttons to the add_widget () method in reverse order, or if you use Kivy> = 1.0.5, pass the add_widget index

box = BoxLayout(...)
btn = Button(...)
box.add_widget(btn, len(box.children))
+6
source

There is a difficult way to do this.

Use gridlayout and set cols to 1

0
source

All Articles