Custom language annoyances

I'm working on a language plugin, and I've got a couple of silly problems;
if anyone could help me out, I'd appreciate it.

1) My comments show up just fine, except that "TODO" comments aren't being
colorized as TODO comments. The documentation implied that this happened
automatically; am I missing something?

2) Code folding works great, except when I first open a file. The code
folding shows up only after I've made some edit to the file. Do I need to do
some extra initialization when I first pop open a file?

Thanks,
Kurt Christensen

3 comments
Comment actions Permalink

On question (1) - I had neglected to provide a FindUsagesProvider, the need for which is clearly stated in the documentation. I copied Ruby's, and now TODO comments show up just fine. Sorry about the noise. But...

Question (2) remains unanswered. Any help would be greatly appreciated!

Thanks again,
Kurt Christensen

0
Comment actions Permalink

When you build FoldingDescriptors you need code like following to force
parsing of tree (ASTNode navigation does not do it), e.g. in javascript
case it looks like following:

if (node.getElementType() == JSElementTypes.FILE) {
// expand chameleon
final PsiElement firstChild = node.getPsi().getFirstChild();
}

Kurt Christenen wrote:

On question (1) - I had neglected to provide a FindUsagesProvider, the need for which is clearly stated in the documentation. I copied Ruby's, and now TODO comments show up just fine. Sorry about the noise. But...

Question (2) remains unanswered. Any help would be greatly appreciated!

Thanks again,
Kurt Christensen


--
Best regards,
Maxim Mossienko
IntelliJ Labs / JetBrains Inc.
http://www.intellij.com
"Develop with pleasure!"

0
Comment actions Permalink

Thanks for the help!

0

Please sign in to leave a comment.