Relative performance of Darren Hiebert's ctags parser and KDevelop
Falk Brettschneider
gigafalk at yahoo.com
Fri Apr 13 11:30:15 UTC 2001
Hi,
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();
...
}
> -- Richard
F at lk
_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com
-
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