Skip to content

Commit c75898b

Browse files
committed
Fix TabWidgetBase::preferred_size_impl() implementation
The tab widget double-counted padding, potentially causing windows containing tab widgets to progressively grow after each re-layout step.
1 parent 206e4e2 commit c75898b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/tabwidget.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ Vector2i TabWidgetBase::preferred_size_impl(NVGcontext* ctx) const {
111111
}
112112

113113
return Vector2i(width + 1,
114-
font_size() + 2 * m_theme->m_tab_button_vertical_padding + 2*m_padding);
114+
font_size() + 2 * m_theme->m_tab_button_vertical_padding);
115115
}
116116

117117
void TabWidgetBase::draw(NVGcontext* ctx) {

0 commit comments

Comments
 (0)