acid-drop

- Hacking the planet from a LilyGo T-Deck using custom firmware
git clone git://git.acid.vegas/acid-drop.git
Log | Files | Refs | Archive | README | LICENSE

lv_example_flex_6.py (421B)

      1 #
      2 # RTL base direction changes order of the items.
      3 # Also demonstrate how horizontal scrolling works with RTL.
      4 #
      5 
      6 cont = lv.obj(lv.scr_act())
      7 cont.set_style_base_dir(lv.BASE_DIR.RTL,0)
      8 cont.set_size(300, 220)
      9 cont.center()
     10 cont.set_flex_flow(lv.FLEX_FLOW.ROW_WRAP)
     11 
     12 for i in range(20):
     13     obj = lv.obj(cont)
     14     obj.set_size(70, lv.SIZE.CONTENT)
     15 
     16     label = lv.label(obj)
     17     label.set_text(str(i))
     18     label.center()
     19