Skip to content
This repository was archived by the owner on Oct 22, 2021. It is now read-only.

Incorrect string literal highlighting in dark theme with "%" character #3

Closed
spacegaier opened this issue Oct 19, 2019 · 3 comments
Closed
Labels
topic: theme Issues related to color themes type: imperfection Something isn't working

Comments

@spacegaier
Copy link

Describe the bug
"%" is in red font color instead of the orange that the rest of the string literal uses.

To Reproduce
Steps to reproduce the behavior:

  1. Start IDE with dark theme.
  2. New INO file with source code: const char* string = "string%withPercent";

Expected behavior
All orange font for string literal.

Screenshots
test

Desktop (please complete the following information):

  • OS: Win 10
  • Version 0.0.1
@spacegaier spacegaier added the type: imperfection Something isn't working label Oct 19, 2019
@svenefftinge svenefftinge added the topic: theme Issues related to color themes label Nov 28, 2019
@svenefftinge
Copy link

I cannot reproduce this on OSX with the next milestone (v0.0.3).
Screenshot 2019-11-28 at 09 15 41

@spacegaier
Copy link
Author

It seems to depend on the actual string literal. Your "foo%test" also works fine for me, but my original test value still has the wrong highlight in v0.0.3 as does a simple value like "a%b". "a%a" however is weirdly fine.
grafik

@spoenemann
Copy link

That's because the highlighting supports format specifiers used by printf and other standard functions. It does not check whether the string is actually used within a call to printf, but that's a limitation we cannot overcome.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
topic: theme Issues related to color themes type: imperfection Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants