Relative performance of Darren Hiebert's ctags parser and KDevelop
Richard Dale
Richard_Dale at tipitina.demon.co.uk
Fri Apr 13 20:48:39 UTC 2001
No, that doesn't mean you have to have QDom to implement code completion, and
yes of course I knew what ithe parser uses QDom for. It just means you have to
be able to parse a single .ii file, and put it into either QDom for KDEStudio,
or the ClassStore for KDevelop. And then display that file in a suitable
widget. Do you really want to have another parser just for parsing the
temporary .ii file, and code completion?
-- Richard
On Fri, 13 Apr 2001, you wrote:
> Richard Dale wrote:
> >
> > I've had another look at the KDEStudio parser, and indeed it does use Darren
> > Hiebert's ctags parser - they have left the GPL'd headers and author credits
> > in, just not credited themselves much. Of course it doesn't need to generate
> > ctags - just QDom constructs they've changed it to that. An efficient use
> > of open source resources, but had me confused.
> Didn't you believe me? Some days before I already wrote they use a
> QDom-based class-parser.
> Their code completion is based on using this DOM tree.
>
> See this piece of code which is essential for code completion:
>
> void SCodeCompletion::slotCodeCompletion()
> {
> ...
> if (parserDocument)
> delete parserDocument;
> parserDocument = new QDomDocument("ClassData");
> PARSER->parseOneFile(flname,parserDocument);
>
> // remove preprocessor output file .... after parsing ...
> QDir().remove( flname );
>
> QDomElement element =
> parserDocument->documentElement().firstChild().toElement();
> if ( sd->init( element, className ) ){
> popup->move( currentEditor->mapToGlobal(
> currentEditor->getTextCursorPosition() ) );
> popup->show();
> ...
> }
unsubscribe your-email-address
-
to unsubscribe from this list send an email to kdevelop-devel-request at kdevelop.org with the following body:
unsubscribe »your-email-address«
More information about the KDevelop-devel
mailing list