Fix recently introduced ncurses redraw artifact

This commit is contained in:
Maxime Coste 2019-11-18 21:17:22 +11:00
parent ba621dedd6
commit c031a276d5

View File

@ -94,6 +94,8 @@ void NCursesUI::Window::draw(Palette& palette, ConstArrayView<DisplayAtom> atoms
#endif #endif
}; };
wbkgdset(win, COLOR_PAIR(palette.get_color_pair(default_face)));
ColumnCount column = getcurx(win); ColumnCount column = getcurx(win);
for (const DisplayAtom& atom : atoms) for (const DisplayAtom& atom : atoms)
{ {
@ -113,10 +115,7 @@ void NCursesUI::Window::draw(Palette& palette, ConstArrayView<DisplayAtom> atoms
} }
if (column < size.column) if (column < size.column)
{
wbkgdset(win, COLOR_PAIR(palette.get_color_pair(default_face)));
wclrtoeol(win); wclrtoeol(win);
}
} }
constexpr int NCursesUI::default_shift_function_key; constexpr int NCursesUI::default_shift_function_key;