QtCreator 2.5.0 & GLSL syntax highlighting
matti- last edited by
So the new QtCreator does syntax highlighting for .fsh/.vsh files which is rather annoying - everything is an error:
bq. vec4 tex_color = texture2D(texture, ex_texCoord);
= "texture2D not declared in this scope"
Any tricks to disable this? Tried installing the highlighting definitions for "GLSL" but no change. Couldn't figure out how to disable highlighting for certain filetypes.
I was annoyed by this as well and rolled my own syntax highlighting. See this blogpost: http://renderingpipeline.com/2012/11/glsl-syntax-highlighting-for-qtcreator-and-kate/ .
Did you "file a bug report":http://bugreports.qt-project.org/ ? I never used GLSL highlighters myself, but was told that they work well.
the highlighting works well for GLSL 1.20, but the latest version is 4.30 and thus newer keywords are marked as errors and deprecated ones are not marked as such.
So it's not buggy, it's just outdated. But as QTCreator supports the language XML files from Kate, you can just add support for recent GLSL versions on your own (see link).
IMHO being outdated is a bug, too... It should not be too hard to add a couple of keywords (not that I can actually judge this, not having touched the codemodel code ever;-).
I have added a suggestion the bugtracker.
Do you have the bug number somewhere?
The number is QTCREATORBUG-8331 .