Skip to content

Commit

Permalink
TabBox: Pass font on adding new tab
Browse files Browse the repository at this point in the history
  • Loading branch information
Zirias committed Aug 7, 2024
1 parent 5665f8b commit 36898a9
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/bin/xmoji/tabbox.c
Original file line number Diff line number Diff line change
Expand Up @@ -430,9 +430,12 @@ void TabBox_addTab(void *self, void *buttonWidget, void *contentWidget)
sizeRequested, 0);
PSC_Event_register(Widget_sizeRequested(tab->contentWidget), tab,
sizeRequested, 0);
Font *font = Widget_font(b);
Widget_setContainer(tab->buttonWidget, b);
if (font) Widget_offerFont(tab->buttonWidget, font);
Widget_setCursor(tab->buttonWidget, XC_HAND);
Widget_setContainer(tab->contentWidget, b);
if (font) Widget_offerFont(tab->contentWidget, font);
PSC_List_append(b->tabs, tab, destroyTab);
if (b->currentIndex < 0) b->currentIndex = 0;
layout(b);
Expand Down

0 comments on commit 36898a9

Please sign in to comment.