IChameleonElementType and language highlighting
I understand that IChameleonElementType is the right way to go if I want to inject a language in another, and that the main language has to return a single token of type IChameleonElementType for the entire subcontent of the other language. Now my question is how does the highlighting work in this case? I use two lexers for parsing and highlighting. For the highlighting is it enough if I return a IChameleonElementType with the adequate language?
请先登录再写评论。
Have tried to use IChameleonElementType approach for my language injection, yet i am not able to get the highlighter to work. The embedded language does not get highlighted.
Do i need to implement LanguageInjector for this to work? I somehow fail to understand the coexistence of these two concepts.
Chameleon type helps in parsing of content, you need own
SyntaxHighlighter or Lexer that can process mix of the languages
Dan Cioca wrote:
--
Best regards,
Maxim Mossienko
IntelliJ Labs / JetBrains Inc.
http://www.intellij.com
"Develop with pleasure!"