Fixed custom cell color also coloring the separator in FullRowSelect mode

This commit is contained in:
Thomas Nind
2021-06-28 18:35:07 +01:00
parent b3ce131fbf
commit f2c40ac83f

View File

@@ -415,9 +415,14 @@ namespace Terminal.Gui {
Driver.SetAttribute (isSelectedCell ? scheme.HotFocus : scheme.Normal);
Driver.AddStr (TruncateOrPad(val,representation, current.Width, colStyle));
// Reset color scheme to normal for drawing separators if we drew text with custom scheme
if(scheme != ColorScheme) {
Driver.SetAttribute (isSelectedCell ? ColorScheme.HotFocus : ColorScheme.Normal);
}
// If not in full row select mode always, reset color scheme to normal and render the vertical line (or space) at the end of the cell
if(!FullRowSelect)
if (!FullRowSelect)
Driver.SetAttribute (ColorScheme.Normal);
RenderSeparator(current.X-1,row,false);