Quick-Turn-Studio / CLionSupportForQt

19 stars 0 forks source link

QML Editor fails to highlighted QML syntax, cannot find declarations to go #55

Closed SebastianMosiej closed 2 years ago

SebastianMosiej commented 2 years ago

Linux, Debian 11, CLion 2021.3 (Build #CL-213.5744.254, built on November 30, 2021), project in CMake Non-Bundled Plugins: quickturnstudio.language.qml.QmlEditor (0.9.10-2020.3+) org.toml.lang (213.5744.224) io.probst.idea.clangformat (1.1.0) IdeaVIM (1.8.1) GrepConsole (12.1.211.6086.0) zielu.gittoolbox (212.8.1) com.virtuslab.git-machete (1.1.0) com.ppolivka.plugin.gitcleaner (1.1.4) org.rust.lang (0.4.161.4292-213) izhangzhihao.rainbow.brackets (6.21)

QML files syntax is not highlighted. When I disable QML Editor, CLion notifies that it found plugins supporting qml extension, recommends usage of QML Editor. After enable of plugin and restart - no changes. Attempts to jump to sibling QML custom components (the same folder) ends with Cannot find declaration to go

bkarpati commented 2 years ago

I encountered a similar issue before. I had the QML Editor plugin disabled for a while and when I re-enabled it I didn't get any syntax highlighting. For me the issues was that files with the .qml extensions were registered as plain text files by CLion. I assume this got set when I disabled the plugin but then it didn't get overwritten.

You can check this by going to Settings > Editor > File Types and looking for the entry QML language file. Make sure that this has *.qml set as one of its File name patterns.

SebastianMosiej commented 2 years ago

I confirm. *.qml pattern was assigned to Text file type. When I reassign it to QML - at least syntax highlighting start working properly. Thank you