Skip to content

Commit

Permalink
proper size of center widget
Browse files Browse the repository at this point in the history
center widget would be rendered as a very small box
  • Loading branch information
aumuell authored and nhongooi committed Mar 13, 2024
1 parent 068c92b commit 08c105d
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions boards/arm/zaphod/zaphod_status_screen.c
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,11 @@ lv_obj_t *zmk_display_status_screen() {

panic_label = lv_label_create(center_frame);
lv_label_set_text(panic_label, "Panic");

lv_obj_update_layout(dont_label); // otherwise proper height is not known
lv_obj_set_y(panic_label, lv_obj_get_height(dont_label));
#endif // IS_ENABLED(CONFIG_ZAPHOD_BONGO_CAT)
lv_obj_set_size(center_frame, LV_SIZE_CONTENT, LV_SIZE_CONTENT);

#if IS_ENABLED(CONFIG_ZMK_WIDGET_LAYER_STATUS)
zmk_widget_layer_status_init(&layer_status_widget, screen);
Expand Down

0 comments on commit 08c105d

Please sign in to comment.