Code::Blocks Forums
Developer forums (C::B DEVELOPMENT STRICTLY!) => Development => CodeCompletion redesign => Topic started by: Mikachu on May 17, 2010, 11:58:38 pm
-
Hello,
I'm trying to implement a Documentation Tooltip inside the CC plugin.
The goal is to display the Doxygen associated with a class/function/variable when your mouse is over it.
I find this feature very useful in Eclipse for java, especially when working with external APIs...
Right now, I have a proof of concept working (some refinements needed, of course), but before finishing it and issuing a patch, I'd like to know a few things :
* Is someone already working on such a feature? (Or is it hidden in C::B and I missed it?)
* I need a GUI component to show the doc. Reading the code, I see that displaying call tip uses a scintilla function. So, should I add necessary code to scintilla or just create the component directly in CC plugin?
-
@MikaChu
I'm so grad to hear this. We have discussed this function some months ago, but there's not such function in the current CC. Also, I didn't heard someone was implementing that feature.
* Is someone already working on such a feature? (Or is it hidden in C::B and I missed it?)
No, and this feature is not exist in the CB either.
* I need a GUI component to show the doc. Reading the code, I see that displaying call tip uses a scintilla function. So, should I add necessary code to scintilla or just create the component directly in CC plugin?
Yes, at present, the CC call tip window is just a tip window created by scintilla. We don't own a self-made tip window of CC. We just pass the wxString to the displaying call tip function of scintilla.
I personally suggest you should create a self made windows( or derive some window class from scintilla) to show the docs.
But the big problems is: How can we collect the "doxygen style comments", for now, all the comments were skipped by the parser in CC plugin. So, one you would like to show the doxygen style comments, you need to either collect the comments when doing parsing, and store them as a property of Token. or you need to parse the code snippet around the call tip Token when you want to show the doxygen comment.
I don't think code into the scitallia is a good idea, because they update quite frequency. :D