Skip to content

Commit

Permalink
update LVGL
Browse files Browse the repository at this point in the history
  • Loading branch information
kisvegabor committed Nov 13, 2023
1 parent 0871cda commit b0f59d7
Show file tree
Hide file tree
Showing 3 changed files with 45,607 additions and 38,782 deletions.
9 changes: 6 additions & 3 deletions examples/Dynamic_loading_font_example.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,22 +38,25 @@
scr = lv.screen_active()
scr.clean()

myfont_cn = lv.font_load("S:%s/font/font-PHT-cn-20.bin" % script_path)
myfont_cn = lv.font_t()
lv.font_load(myfont_cn, "S:%s/font/font-PHT-cn-20.bin" % script_path)

This comment has been minimized.

Copy link
@kdschlosser

kdschlosser Nov 14, 2023

Contributor
myfont_cn = lv.font_t()
myfont_cn.load("S:%s/font/font-PHT-cn-20.bin" % script_path)

label1 = lv.label(scr)
label1.set_style_text_font(myfont_cn, 0) # set the font
label1.set_text("上中下乎")
label1.align(lv.ALIGN.CENTER, 0, -25)

myfont_en = lv.font_load("S:%s/font/font-PHT-en-20.bin" % script_path)
myfont_en = lv.font_t()
lv.font_load(myfont_en, "S:%s/font/font-PHT-en-20.bin" % script_path)

This comment has been minimized.

Copy link
@kdschlosser

kdschlosser Nov 14, 2023

Contributor
myfont_en = lv.font_t()
myfont_en.load("S:%s/font/font-PHT-en-20.bin" % script_path)

label2 = lv.label(scr)
label2.set_style_text_font(myfont_en, 0) # set the font
label2.set_text("Hello LVGL!")
label2.align(lv.ALIGN.CENTER, 0, 25)


myfont_jp = lv.font_load("S:%s/font/font-PHT-jp-20.bin" % script_path)
myfont_jp= lv.font_t()
lv.font_load(myfont_jp, "S:%s/font/font-PHT-jp-20.bin" % script_path)

This comment has been minimized.

Copy link
@kdschlosser

kdschlosser Nov 14, 2023

Contributor
myfont_jp = lv.font_t()
myfont_jp.load("S:%s/font/font-PHT-jp-20.bin" % script_path)

label3 = lv.label(scr)
label3.set_style_text_font(myfont_jp, 0) # set the font
Expand Down
Loading

0 comments on commit b0f59d7

Please sign in to comment.