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

Improve style for lines with both syntax and code inspection errors #62

Merged
merged 1 commit into from
Jun 15, 2019

Conversation

arcticicestudio
Copy link
Contributor

Resolves #60

A line that contained both a syntax error as well as a IntelliJ Code Inspection (ERRORS_ATTRIBUTES editor scheme key) error was unreadable because both error detection scopes/types applied their different highlighting styles resulting in a background and foreground color colorized with nord11. This made it impossible to read the text.

Highlighting resulting in unreadable text when combined with error text

Some tests using a opacity of 60% for nord11 as background color instead resulted in a “dirty redish“ color due to the miy with the base editor background color.

Reduced opacity of 60%

Therefore a better style of highlighting these errors has been designed.
The new style doesn't make use of a background color at all based on the fact that it is a duplicate highlighting. If there's a syntax error the invalid tokens will be highlighted with nord11 due to the syntax error so there is no need to additionally colorize the background with nord11 which is the main reason for the unreadable text.

The new styles for Code Inspection errors has been simplified to use nord11 as foreground color with a bold underline and the already used error stripe next to the line numbers. This design decision also comes with a change for the “Unknown Symbol“ highlighting (WRONG_REFERENCES_ATTRIBUTES color scheme key) that now uses a dotted underline instead to differentiate from the new error styles.

Improved error and Unknown Symbol styles

A line that contained both a syntax error as well as a
"IntelliJ Code Inspection" (`ERRORS_ATTRIBUTES` editor scheme key) error
was unreadable because both error detection scopes/types applied their
different highlighting styles resulting in a background and foreground
color colorized with `nord11`. This made it impossible to read the text.

Some tests using a opacity of 60% for `nord11` as background color
instead resulted in a "dirty redish" color due to the miy with thge base
editor background color.

Therefore a better style of highlighting these errors has been designed.
The new style doesn't make use of a background color at all based on the
fact that it is a duplicate highlighting. If there's a syntax error the
invalid tokens will be highlighted with `nord11` due to the syntax error
so there is no need to additionally colorize the background with
`nord11` which is the main reson for the unreadable text.

The new styles for "Code Inspection" errors has been simplified to use
`nord11` as foreground color with a bold underline and the already used
error stripe next to the line numbers. This design decision also comes
with a change for the "Unknown Symbol" highlighting
(`WRONG_REFERENCES_ATTRIBUTES` color scheme key) that now uses a
dotted underline instead to differentiate from the new error styles.

GH-60
@arcticicestudio arcticicestudio merged commit e3189d0 into develop Jun 15, 2019
@arcticicestudio arcticicestudio deleted the improvenent/gh-60-error-unreadable-content branch June 15, 2019 08:30
@arcticicestudio arcticicestudio removed their assignment Jun 15, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Lines containing syntax errors are impossible to read
2 participants