Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix standout mode #8708

Merged
merged 1 commit into from Jul 10, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/nvim/tui/tui.c
Expand Up @@ -459,8 +459,8 @@ static void update_attrs(UI *ui, HlAttrs attrs)
bool underline = attr & (HL_UNDERLINE), undercurl = attr & (HL_UNDERCURL);

if (unibi_get_str(data->ut, unibi_set_attributes)) {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For me this condition appears to be true always, which results in the else below not being reached (where standout is set).

if (bold || reverse || underline || undercurl) {
UNIBI_SET_NUM_VAR(data->params[0], 0); // standout
if (bold || reverse || underline || undercurl || standout) {
UNIBI_SET_NUM_VAR(data->params[0], standout);
UNIBI_SET_NUM_VAR(data->params[1], underline || undercurl);
UNIBI_SET_NUM_VAR(data->params[2], reverse);
UNIBI_SET_NUM_VAR(data->params[3], 0); // blink
Expand Down Expand Up @@ -520,7 +520,7 @@ static void update_attrs(UI *ui, HlAttrs attrs)
}

data->default_attr = fg == -1 && bg == -1
&& !bold && !italic && !underline && !undercurl && !reverse;
&& !bold && !italic && !underline && !undercurl && !reverse && !standout;
}

static void final_column_wrap(UI *ui)
Expand Down