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

Chaos with Syntax and utilities in inactive code areas #243

Open
RobertMtx opened this issue Jan 8, 2023 · 0 comments
Open

Chaos with Syntax and utilities in inactive code areas #243

RobertMtx opened this issue Jan 8, 2023 · 0 comments

Comments

@RobertMtx
Copy link

RobertMtx commented Jan 8, 2023

Most of the features seem to break down when trying to write code inside of an inactive code fragment, such as when blocking code off with preprocessor directives:

#define X 1
#ifdef X
  - this area works great
#else
  - this area throws fits
#endif

When typing code inside of an inactive portion, the auto-completions and other utilities fail to function correctly. I'm not sure what causes this to happen, but I would recommend only changing the syntax color of inactive areas. It is very common to use preprocessor directives to convert one shader into multiple shaders, so the inactive portion is usually just as important as the active portion.

Perhaps we could even have an option to completely disable the syntax changes of inactive code, so that all sections appear to be active at once? But if not, we definitely need to be able to write code in them, which is currently not very feasible. For example, even if I have a variable named g declared, if I type "g = ", I get "else =".

Since I'm doing a lot of complaining, I wanted to mention how much I love this addon! It is incredibly useful! Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant