tabbar: default to a dummy, non-empty state

This is to avoid computing a zero height initial tab bar as discussed
in https://github.com/wez/wezterm/commit/808d7df8d44f489680bd704d77fe23e5951cc79d#commitcomment-69980693

cc: @davidrios
This commit is contained in:
Wez Furlong committed 2022-03-31 07:50:34 -07:00
1 parent 1b31ee5f94
commit 34090580a0
1 file changed
+6 -1
+6 -1
View File
@@ -159,7 +159,12 @@ impl TabBarState {
pub fn default() -> Self {
Self {
line: Line::with_width(1, SEQ_ZERO),
items: vec![],
items: vec![TabEntry {
item: TabBarItem::None,
title: Line::from_text(" ", &CellAttributes::blank(), 1),
x: 1,
width: 1,
}],
}
}