-
Notifications
You must be signed in to change notification settings - Fork 27
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
Add GLSL syntax? #16
Comments
I think my personal preference is for less, but @kfish has done more work with GLSL in Elm by doing elm-shadertoy so I'd be curious what he thinks. I feel I could go either way on this one. Perhaps if the open and close symbols were strong, it would feel less confusing. Not really sure. |
With short shaders like this, I prefer the no color one because it does not make me think there is a new Elm declaration on every line. I think in larger shaders, it'll become more pleasant. @kfish will probably know better, or have some examples to try out in elm-shadertoy. |
The other thing is, if you don't want the extra highlighting, you could always just not install an extra plugin. GLSL syntax isn't supported by Sublime Text out of the box. |
I decided to go ahead with this change for now. I like it locally, with the shaders I've been writing. I'm still open to the idea of removing it later. |
I remember using an emacs package which only highlighted the syntax of the I think it was called multi-html-mode
|
I was just thinking that this wouldn't be possible in Sublime Text, but this plugin makes it seem possible with the right tricks! I think it's a pretty cool idea. |
Whoa, that'd be pretty cool! |
@evancz I prefer to keep shaders in separate files anyway just to keep that logic separate from the shapes and physics. As a result it's not too confusing to have syntax highlighting on the shader also. |
@johnpmayer I just got that context-sensitive highlighting thing working in one direction. Now I can gray out GLSL when you're not inside a GLSL block, and restore the highlighting when you are. This is pretty cool. |
This is legit
|
@evancz
On a local branch I just added support for GLSL syntax, which I didn't have before. Anything inside a GLSL block gets highlighted according to whichever GLSL syntax highlighting plugin you have installed, if any. If you don't have a GLSL syntax highlighting plugin, it doesn't do any highlighting at all inside a GLSL block. (This is the current behavior even if you do have a GLSL highlighting plugin installed)
Do you think this is a bad idea? I know you don't seem to be a fan of special cases like this, in general...
The text was updated successfully, but these errors were encountered: