From 5ed55684b0226c2371f1d39cd7f984da44c9ccb1 Mon Sep 17 00:00:00 2001 From: dimitri Date: Fri, 27 Sep 2002 17:06:31 +0000 Subject: Release-1.2.18-20020927 --- INSTALL | 4 +- README | 4 +- VERSION | 2 +- addon/doxywizard/doxywizard.cpp | 9 +- doc/config.doc | 9 + doc/index.doc | 3 +- packages/rpm/doxygen.spec | 2 +- qtools/Doxyfile | 49 ++- src/classdef.cpp | 2 - src/cmdmapper.cpp | 1 + src/config.l | 14 +- src/docparser.cpp | 194 ++++----- src/docparser.h | 410 ++++++++++--------- src/doctokenizer.h | 25 +- src/doctokenizer.l | 96 ++--- src/docvisitor.h | 11 +- src/doxygen.cpp | 5 +- src/filedef.cpp | 1 + src/groupdef.cpp | 1 + src/htmlattrib.h | 53 +++ src/htmldocvisitor.cpp | 110 ++++-- src/htmldocvisitor.h | 6 +- src/htmlgen.cpp | 5 +- src/latexdocvisitor.cpp | 22 +- src/latexdocvisitor.h | 8 +- src/libdoxygen.pro.in | 3 + src/mandocvisitor.cpp | 854 ++++++++++++++++++++++++++++++++++++++++ src/mandocvisitor.h | 144 +++++++ src/mangen.cpp | 6 +- src/memberdef.cpp | 16 +- src/namespacedef.cpp | 1 + src/rtfdocvisitor.cpp | 28 +- src/rtfdocvisitor.h | 10 +- src/scanner.l | 34 +- src/translator_fr.h | 13 + src/util.cpp | 6 +- src/xmldocvisitor.cpp | 10 +- src/xmldocvisitor.h | 8 +- src/xmlgen.cpp | 26 +- 39 files changed, 1731 insertions(+), 474 deletions(-) create mode 100644 src/htmlattrib.h create mode 100644 src/mandocvisitor.cpp create mode 100644 src/mandocvisitor.h diff --git a/INSTALL b/INSTALL index 9bec971..13d4443 100644 --- a/INSTALL +++ b/INSTALL @@ -1,6 +1,6 @@ -DOXYGEN Version 1.2.18 +DOXYGEN Version 1.2.18-20020927 Please read the installation section of the manual for instructions. -------- -Dimitri van Heesch (18 September 2002) +Dimitri van Heesch (27 September 2002) diff --git a/README b/README index a41c386..6833013 100644 --- a/README +++ b/README @@ -1,4 +1,4 @@ -DOXYGEN Version 1.2.18 +DOXYGEN Version 1.2.18_20020927 Please read INSTALL for compilation instructions. @@ -17,4 +17,4 @@ to subscribe to the lists or to visit the archives. Enjoy, -Dimitri van Heesch (dimitri@stack.nl) (18 September 2002) +Dimitri van Heesch (dimitri@stack.nl) (27 September 2002) diff --git a/VERSION b/VERSION index 591bdbc..9086ed6 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.2.18 +1.2.18-20020927 diff --git a/addon/doxywizard/doxywizard.cpp b/addon/doxywizard/doxywizard.cpp index 84f9f08..4c6b91e 100644 --- a/addon/doxywizard/doxywizard.cpp +++ b/addon/doxywizard/doxywizard.cpp @@ -266,11 +266,18 @@ void Wizard::saveAsFile() void Wizard::runDoxygen() { saveFile(); - QString s = "doxygen " + configFileName; + QString orgDir = QDir::currentDirPath(); + QFileInfo fi(configFileName); + // cd to the config dir + QDir::setCurrent(fi.dirPath()); + // run doxygen on the config file + QString s = "doxygen \"" + fi.fileName() + "\""; + // actually run the exe system((const char*)s); statusBar()->message("doxygen completed: "+ configFileName, messageTimeout ); hasChanged = FALSE; refreshCaption(); + QDir::setCurrent(orgDir); } diff --git a/doc/config.doc b/doc/config.doc index ab0da8e..d6a9fd7 100644 --- a/doc/config.doc +++ b/doc/config.doc @@ -103,6 +103,7 @@ followed by the descriptions of the tags grouped by category. \refitem cfg_full_path_names FULL_PATH_NAMES \refitem cfg_generate_buglist GENERATE_BUGLIST \refitem cfg_generate_chi GENERATE_CHI +\refitem cfg_generate_todolist GENERATE_DEPRECIATELIST \refitem cfg_generate_html GENERATE_HTML \refitem cfg_generate_htmlhelp GENERATE_HTMLHELP \refitem cfg_generate_latex GENERATE_LATEX @@ -459,6 +460,14 @@ followed by the descriptions of the tags grouped by category. documentation sections, marked by \ref cmdif "\\if" \ ... \ref cmdendif "\\endif" blocks. +\anchor cfg_generate_deprecatedlist +
\c GENERATE_DEPRECATEDLIST
+ \addindex GENERATE_DEPRECATEDLIST + The GENERATE_DEPRECATEDLIST tag can be used to enable (YES) or + disable (NO) the deprecated list. This list is created by + putting \ref cmddeprecated "\\deprecated" + commands in the documentation. + \anchor cfg_generate_todolist
\c GENERATE_TODOLIST
\addindex GENERATE_TODOLIST diff --git a/doc/index.doc b/doc/index.doc index 5639b61..130922d 100644 --- a/doc/index.doc +++ b/doc/index.doc @@ -180,7 +180,8 @@ Thanks go to: All language maintainers for providing translations into many languages.
  • Erik Jan Lingen of Habanera, Mark Roddy, Paul Schwartz, Charles Duffy, Vadym Voznyuk, Philip Walton, - Dwight Browne, Andreas Fredriksson, and Karel Lindveld for donating money. + Dwight Browne, Andreas Fredriksson, Karel Lindveld, and Ivan Lee + for donating money.
  • The Comms group of Symbian for donating an ultra cool Revo plus organizer! diff --git a/packages/rpm/doxygen.spec b/packages/rpm/doxygen.spec index ff621d6..ff43038 100644 --- a/packages/rpm/doxygen.spec +++ b/packages/rpm/doxygen.spec @@ -1,6 +1,6 @@ Summary: A documentation system for C/C++. Name: doxygen -Version: 1.2.18 +Version: 1.2.18_20020927 Release: 1 Epoch: 1 Source0: ftp://ftp.stack.nl/pub/users/dimitri/%{name}-%{version}.src.tar.gz diff --git a/qtools/Doxyfile b/qtools/Doxyfile index 838a299..c1f7e45 100644 --- a/qtools/Doxyfile +++ b/qtools/Doxyfile @@ -1,4 +1,4 @@ -# Doxyfile 1.2.5-20010304 +# Doxyfile 1.2.18 #--------------------------------------------------------------------------- # General configuration options @@ -10,35 +10,40 @@ OUTPUT_LANGUAGE = English EXTRACT_ALL = YES EXTRACT_PRIVATE = YES EXTRACT_STATIC = YES +EXTRACT_LOCAL_CLASSES = YES HIDE_UNDOC_MEMBERS = NO HIDE_UNDOC_CLASSES = NO +HIDE_FRIEND_COMPOUNDS = NO BRIEF_MEMBER_DESC = YES REPEAT_BRIEF = YES ALWAYS_DETAILED_SEC = NO +INLINE_INHERITED_MEMB = NO FULL_PATH_NAMES = YES STRIP_FROM_PATH = $(PWD)/ INTERNAL_DOCS = NO -CLASS_DIAGRAMS = YES -SOURCE_BROWSER = YES -INLINE_SOURCES = NO STRIP_CODE_COMMENTS = YES CASE_SENSE_NAMES = NO +SHORT_NAMES = NO HIDE_SCOPE_NAMES = NO VERBATIM_HEADERS = YES SHOW_INCLUDE_FILES = YES JAVADOC_AUTOBRIEF = YES +MULTILINE_CPP_IS_BRIEF = NO +DETAILS_AT_TOP = NO INHERIT_DOCS = YES INLINE_INFO = YES SORT_MEMBER_DOCS = YES DISTRIBUTE_GROUP_DOC = NO TAB_SIZE = 8 -ENABLED_SECTIONS = GENERATE_TODOLIST = YES GENERATE_TESTLIST = YES GENERATE_BUGLIST = YES +GENERATE_DEPRECATEDLIST= YES ALIASES = +ENABLED_SECTIONS = MAX_INITIALIZER_LINES = 30 OPTIMIZE_OUTPUT_FOR_C = NO +OPTIMIZE_OUTPUT_JAVA = NO SHOW_USED_FILES = YES #--------------------------------------------------------------------------- # configuration options related to warning and progress messages @@ -56,13 +61,23 @@ FILE_PATTERNS = *.h \ *.cpp \ *.doc RECURSIVE = NO +EXCLUDE = +EXCLUDE_SYMLINKS = NO EXCLUDE_PATTERNS = EXAMPLE_PATH = EXAMPLE_PATTERNS = +EXAMPLE_RECURSIVE = NO IMAGE_PATH = INPUT_FILTER = FILTER_SOURCE_FILES = NO #--------------------------------------------------------------------------- +# configuration options related to source browsing +#--------------------------------------------------------------------------- +SOURCE_BROWSER = YES +INLINE_SOURCES = NO +REFERENCED_BY_RELATION = YES +REFERENCES_RELATION = YES +#--------------------------------------------------------------------------- # configuration options related to the alphabetical class index #--------------------------------------------------------------------------- ALPHABETICAL_INDEX = YES @@ -73,11 +88,14 @@ IGNORE_PREFIX = Q #--------------------------------------------------------------------------- GENERATE_HTML = YES HTML_OUTPUT = +HTML_FILE_EXTENSION = .html HTML_HEADER = HTML_FOOTER = HTML_STYLESHEET = HTML_ALIGN_MEMBERS = YES GENERATE_HTMLHELP = NO +CHM_FILE = +HHC_LOCATION = GENERATE_CHI = NO BINARY_TOC = NO TOC_EXPAND = NO @@ -90,6 +108,8 @@ TREEVIEW_WIDTH = 250 #--------------------------------------------------------------------------- GENERATE_LATEX = NO LATEX_OUTPUT = +LATEX_CMD_NAME = latex +MAKEINDEX_CMD_NAME = makeindex COMPACT_LATEX = NO PAPER_TYPE = a4wide EXTRA_PACKAGES = @@ -105,12 +125,24 @@ RTF_OUTPUT = COMPACT_RTF = NO RTF_HYPERLINKS = NO RTF_STYLESHEET_FILE = +RTF_EXTENSIONS_FILE = #--------------------------------------------------------------------------- # configuration options related to the man page output #--------------------------------------------------------------------------- GENERATE_MAN = NO MAN_OUTPUT = MAN_EXTENSION = .3 +MAN_LINKS = NO +#--------------------------------------------------------------------------- +# configuration options related to the XML output +#--------------------------------------------------------------------------- +GENERATE_XML = YES +XML_SCHEMA = +XML_DTD = +#--------------------------------------------------------------------------- +# configuration options for the AutoGen Definitions output +#--------------------------------------------------------------------------- +GENERATE_AUTOGEN_DEF = NO #--------------------------------------------------------------------------- # Configuration options related to the preprocessor #--------------------------------------------------------------------------- @@ -122,23 +154,30 @@ INCLUDE_PATH = INCLUDE_FILE_PATTERNS = PREDEFINED = EXPAND_AS_DEFINED = +SKIP_FUNCTION_MACROS = YES #--------------------------------------------------------------------------- # Configuration::addtions related to external references #--------------------------------------------------------------------------- TAGFILES = GENERATE_TAGFILE = ../qtools_docs/qtools.tag ALLEXTERNALS = NO +EXTERNAL_GROUPS = YES PERL_PATH = /usr/bin/perl #--------------------------------------------------------------------------- # Configuration options related to the dot tool #--------------------------------------------------------------------------- +CLASS_DIAGRAMS = YES +HIDE_UNDOC_RELATIONS = YES HAVE_DOT = YES CLASS_GRAPH = YES COLLABORATION_GRAPH = YES +TEMPLATE_RELATIONS = YES INCLUDE_GRAPH = YES INCLUDED_BY_GRAPH = NO GRAPHICAL_HIERARCHY = YES +DOT_IMAGE_FORMAT = png DOT_PATH = +DOTFILE_DIRS = MAX_DOT_GRAPH_WIDTH = 2048 MAX_DOT_GRAPH_HEIGHT = 2048 GENERATE_LEGEND = YES diff --git a/src/classdef.cpp b/src/classdef.cpp index 2d4864f..0a9ae3e 100644 --- a/src/classdef.cpp +++ b/src/classdef.cpp @@ -790,9 +790,7 @@ void ClassDef::writeDocumentation(OutputList &ol) } ol.endTextLink(); ol.popGeneratorState(); - ol.disable(OutputGenerator::Man); ol.newParagraph(); - ol.enable(OutputGenerator::Man); } } ol.writeSynopsis(); diff --git a/src/cmdmapper.cpp b/src/cmdmapper.cpp index b2aedcf..449d467 100644 --- a/src/cmdmapper.cpp +++ b/src/cmdmapper.cpp @@ -175,6 +175,7 @@ CommandMap htmlTagMap[] = { "h1", HTML_H1 }, { "h2", HTML_H2 }, { "h3", HTML_H3 }, + { 0, 0 } }; //---------------------------------------------------------------------------- diff --git a/src/config.l b/src/config.l index daf461d..68515a6 100644 --- a/src/config.l +++ b/src/config.l @@ -1459,13 +1459,6 @@ void Config::create() FALSE ); cb = addBool( - "STRIP_CODE_COMMENTS", - "Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct \n" - "doxygen to hide any special comment blocks from generated source code \n" - "fragments. Normal C and C++ comments will always remain visible. \n", - TRUE - ); - cb = addBool( "CASE_SENSE_NAMES", "If the CASE_SENSE_NAMES tag is set to NO then Doxygen will only generate \n" "file names in lower case letters. If set to YES upper case letters are also \n" @@ -1784,6 +1777,13 @@ void Config::create() "of functions and classes directly in the documentation. \n", FALSE ); + cb = addBool( + "STRIP_CODE_COMMENTS", + "Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct \n" + "doxygen to hide any special comment blocks from generated source code \n" + "fragments. Normal C and C++ comments will always remain visible. \n", + TRUE + ); cb = addBool( "REFERENCED_BY_RELATION", "If the REFERENCED_BY_RELATION tag is set to YES (the default) \n" "then for each documented function all documented \n" diff --git a/src/docparser.cpp b/src/docparser.cpp index 14968e7..f8c0e19 100644 --- a/src/docparser.cpp +++ b/src/docparser.cpp @@ -48,29 +48,29 @@ static MemberDef * g_memberDef; static QDict g_paramsFound; // include file state -static QCString g_includeFileText; +static QString g_includeFileText; static uint g_includeFileOffset; static uint g_includeFileLength; // parser state -static QCString g_context; +static QString g_context; static bool g_inSeeBlock; static bool g_insideHtmlLink; static QStack g_nodeStack; static QStack g_styleStack; static QList g_copyStack; -static QCString g_fileName; +static QString g_fileName; struct DocParserContext { - QCString context; + QString context; bool inSeeBlock; bool insideHtmlLink; QStack nodeStack; QStack styleStack; QList copyStack; MemberDef *memberDef; - QCString fileName; + QString fileName; }; static QStack g_parserStack; @@ -107,7 +107,7 @@ static void docParserPopContext() //--------------------------------------------------------------------------- -static void checkArgumentName(const QCString &name,bool isParam) +static void checkArgumentName(const QString &name,bool isParam) { if (g_memberDef==0) return; // not a member ArgumentList *al=g_memberDef->isDocsForDefinition() ? @@ -120,14 +120,14 @@ static void checkArgumentName(const QCString &name,bool isParam) int p=0,i=0,l; while ((i=re.match(name,p,&l))!=-1) { - QCString aName=name.mid(i,l); + QString aName=name.mid(i,l); //printf("aName=%s\n",aName.data()); ArgumentListIterator ali(*al); Argument *a; bool found=FALSE; for (ali.toFirst();(a=ali.current());++ali) { - QCString argName = g_memberDef->isDefine() ? a->type : a->name; + QString argName = g_memberDef->isDefine() ? a->type : a->name; if (argName.right(3)=="...") argName=argName.left(argName.length()-3); if (aName==argName) { @@ -140,7 +140,7 @@ static void checkArgumentName(const QCString &name,bool isParam) if (!found && isParam) { //printf("member type=%d\n",memberDef->memberType()); - QCString scope=g_memberDef->getScopeString(); + QString scope=g_memberDef->getScopeString(); if (!scope.isEmpty()) scope+="::"; else scope=""; warn(g_memberDef->docFile(),g_memberDef->docLine(), "Warning: argument `%s' of command @param " @@ -167,7 +167,7 @@ static void checkUndocumentedParams() bool found=FALSE; for (ali.toFirst();(a=ali.current());++ali) { - QCString argName = g_memberDef->isDefine() ? a->type : a->name; + QString argName = g_memberDef->isDefine() ? a->type : a->name; if (argName.right(3)=="...") argName=argName.left(argName.length()-3); if (!argName.isEmpty() && g_paramsFound.find(argName)==0) { @@ -177,7 +177,7 @@ static void checkUndocumentedParams() } if (found) { - QCString scope=g_memberDef->getScopeString(); + QString scope=g_memberDef->getScopeString(); if (!scope.isEmpty()) scope+="::"; else scope=""; warn(g_memberDef->docFile(),g_memberDef->docLine(), "Warning: The following parameters of " @@ -186,7 +186,7 @@ static void checkUndocumentedParams() argListToString(al).data()); for (ali.toFirst();(a=ali.current());++ali) { - QCString argName = g_memberDef->isDefine() ? a->type : a->name; + QString argName = g_memberDef->isDefine() ? a->type : a->name; if (!argName.isEmpty() && g_paramsFound.find(argName)==0) { warn_cont( " parameter %s\n",argName.data()); @@ -199,15 +199,15 @@ static void checkUndocumentedParams() //--------------------------------------------------------------------------- -static QCString stripKnownExtensions(const char *text) +static QString stripKnownExtensions(const char *text) { - QCString result=text; + QString result=text; if (result.right(4)==".tex") { result=result.left(result.length()-4); } else if (result.right(Doxygen::htmlFileExtension.length())== - Doxygen::htmlFileExtension) + QString(Doxygen::htmlFileExtension)) { result=result.left(result.length()-Doxygen::htmlFileExtension.length()); } @@ -293,12 +293,12 @@ static bool insideLang(DocNode *n) * @retval FALSE if name was not found. */ static bool findDocsForMemberOrCompound(const char *commandName, - QCString *pDoc, + QString *pDoc, Definition **pDef) { - pDoc->resize(0); + *pDoc=""; *pDef=0; - QCString cmdArg=commandName; + QString cmdArg=commandName; int l=cmdArg.length(); if (l==0) return FALSE; @@ -306,10 +306,10 @@ static bool findDocsForMemberOrCompound(const char *commandName, if (funcStart==-1) funcStart=l; //int lastScopeStart=cmdArg.findRev("::",funcStart); //int lastScopeEnd = lastScopeStart==-1 ? 0 : lastScopeStart+2; - //QCString scope=cmdArg.left(QMAX(lastScopeStart,0)); - //QCString name=cmdArg.mid(lastScopeEnd,funcStart-lastScopeEnd); - QCString name=cmdArg.left(funcStart); - QCString args=cmdArg.right(l-funcStart); + //QString scope=cmdArg.left(QMAX(lastScopeStart,0)); + //QString name=cmdArg.mid(lastScopeEnd,funcStart-lastScopeEnd); + QString name=cmdArg.left(funcStart); + QString args=cmdArg.right(l-funcStart); // try if the link is to a member MemberDef *md=0; @@ -318,7 +318,7 @@ static bool findDocsForMemberOrCompound(const char *commandName, NamespaceDef *nd=0; GroupDef *gd=0; PageInfo *pi=0; - bool found = getDefs(g_context,name,args,md,cd,fd,nd,gd,FALSE,0,TRUE); + bool found = getDefs(g_context.latin1(),name.latin1(),args,md,cd,fd,nd,gd,FALSE,0,TRUE); if (found && md) { *pDoc=md->documentation(); @@ -330,7 +330,7 @@ static bool findDocsForMemberOrCompound(const char *commandName, int scopeOffset=g_context.length(); do // for each scope { - QCString fullName=cmdArg; + QString fullName=cmdArg; if (scopeOffset>0) { fullName.prepend(g_context.left(scopeOffset)+"::"); @@ -398,8 +398,9 @@ static bool defaultHandleToken(DocNode *parent,int tok, static int handleStyleArgument(DocNode *parent,QList &children, - const QCString &cmdName) + const QString &cmdName) { + QString tokenName = g_token->name; int tok=doctokenizerYYlex(); if (tok!=TK_WHITESPACE) { @@ -407,7 +408,9 @@ static int handleStyleArgument(DocNode *parent,QList &children, cmdName.data()); return tok; } - while ((tok=doctokenizerYYlex()) && tok!=TK_WHITESPACE && tok!=TK_NEWPARA) + while ((tok=doctokenizerYYlex()) && + tok!=TK_WHITESPACE && tok!=TK_NEWPARA && tok!=TK_LISTITEM && tok!=TK_ENDLIST + ) { if (!defaultHandleToken(parent,tok,children)) { @@ -415,15 +418,15 @@ static int handleStyleArgument(DocNode *parent,QList &children, { case TK_COMMAND: warn(g_fileName,doctokenizerYYlineno,"Error: Illegal command \\%s as the argument of a \\%s command", - g_token->name.data(),cmdName.data()); + tokenName.data(),cmdName.data()); break; case TK_SYMBOL: warn(g_fileName,doctokenizerYYlineno,"Error: Unsupported symbol %s found", - g_token->name.data()); + tokenName.data()); break; default: warn(g_fileName,doctokenizerYYlineno,"Error: Unexpected token %s", - g_token->name.data()); + tokenName.data()); break; } } @@ -540,7 +543,7 @@ static bool defaultHandleToken(DocNode *parent,int tok, QList &children DBG((" name=%s",g_token->name.data())); } DBG(("\n")); - QCString tokenName = g_token->name; + QString tokenName = g_token->name; switch (tok) { case TK_COMMAND: @@ -803,7 +806,7 @@ handlepara: //--------------------------------------------------------------------------- -DocSymbol::SymType DocSymbol::decodeSymbol(const QCString &symName,char *letter) +DocSymbol::SymType DocSymbol::decodeSymbol(const QString &symName,char *letter) { int l=symName.length(); DBG(("decodeSymbol(%s) l=%d\n",symName.data(),l)); @@ -856,7 +859,7 @@ DocSymbol::SymType DocSymbol::decodeSymbol(const QCString &symName,char *letter) //--------------------------------------------------------------------------- static int internalValidatingParseDoc(DocNode *parent,QList &children, - const QCString &doc) + const QString &doc) { int retval = RetVal_OK; @@ -887,7 +890,7 @@ static int internalValidatingParseDoc(DocNode *parent,QList &children, //--------------------------------------------------------------------------- -static void readTextFileByName(const QCString &file,QCString &text) +static void readTextFileByName(const QString &file,QString &text) { bool ambig; FileDef *fd; @@ -911,7 +914,7 @@ static void readTextFileByName(const QCString &file,QCString &text) //--------------------------------------------------------------------------- -DocAnchor::DocAnchor(DocNode *parent,const QCString &id,bool newAnchor) +DocAnchor::DocAnchor(DocNode *parent,const QString &id,bool newAnchor) : m_parent(parent) { if (id.isEmpty()) @@ -1080,7 +1083,7 @@ void DocIncOperator::parse() void DocCopy::parse() { - QCString doc; + QString doc; Definition *def; if (findDocsForMemberOrCompound(m_link,&doc,&def)) { @@ -1114,7 +1117,7 @@ void DocCopy::parse() void DocXRefItem::parse() { - QCString listName; + QString listName; switch(m_type) { case Bug: listName="bug"; break; @@ -1143,7 +1146,7 @@ void DocXRefItem::parse() DocFormula::DocFormula(DocNode *parent,int id) : m_parent(parent) { - QCString formCmd; + QString formCmd; formCmd.sprintf("\\form#%d",id); Formula *formula=Doxygen::formulaNameDict[formCmd]; if (formula) @@ -1306,7 +1309,7 @@ endsecreflist: //--------------------------------------------------------------------------- -DocInternalRef::DocInternalRef(DocNode *parent,const QCString &ref) +DocInternalRef::DocInternalRef(DocNode *parent,const QString &ref) : m_parent(parent) { int i=ref.find('#'); @@ -1357,11 +1360,12 @@ void DocInternalRef::parse() //--------------------------------------------------------------------------- -DocRef::DocRef(DocNode *parent,const QCString &target) : +DocRef::DocRef(DocNode *parent,const QString &target) : m_parent(parent), m_refToSection(FALSE), m_refToAnchor(FALSE) { Definition *compound = 0; - MemberDef *member = 0; + PageInfo *pageInfo = 0; + QCString anchor; ASSERT(!target.isEmpty()); SectionInfo *sec = Doxygen::sectionDict[target]; if (sec) // ref to section or anchor @@ -1375,16 +1379,25 @@ DocRef::DocRef(DocNode *parent,const QCString &target) : m_refToAnchor = sec->type==SectionInfo::Anchor; m_refToSection = sec->type!=SectionInfo::Anchor; } - else if (resolveRef(g_context,target,TRUE,&compound,&member)) + else if (resolveLink(g_context,target,TRUE,&compound,&pageInfo,anchor)) { - if (member) // ref to member + m_text = target; + m_anchor = anchor; + if (pageInfo) // ref to page { - m_file = compound->getOutputFileBase(); - m_ref = compound->getReference(); - m_anchor = member->anchor(); + m_file = pageInfo->getOutputFileBase(); + m_ref = pageInfo->getReference(); } - else // ref to compound + else if (compound) // ref to compound { + if (anchor.isEmpty() && /* compound link */ + compound->definitionType()==Definition::TypeGroup && /* is group */ + ((GroupDef *)compound)->groupTitle() /* with title */ + ) + { + m_text=((GroupDef *)compound)->groupTitle(); // use group's title as l + } + m_file = compound->getOutputFileBase(); m_ref = compound->getReference(); } @@ -1432,14 +1445,16 @@ void DocRef::parse() //--------------------------------------------------------------------------- -DocLink::DocLink(DocNode *parent,const QCString &target) : +DocLink::DocLink(DocNode *parent,const QString &target) : m_parent(parent) { Definition *compound; PageInfo *page; + QCString anchor; if (resolveLink(g_context,stripKnownExtensions(target),g_inSeeBlock, - &compound,&page,m_anchor)) + &compound,&page,anchor)) { + m_anchor = anchor; if (compound) { m_file = compound->getOutputFileBase(); @@ -1459,9 +1474,9 @@ DocLink::DocLink(DocNode *parent,const QCString &target) : } -QCString DocLink::parse(bool isJavaLink) +QString DocLink::parse(bool isJavaLink) { - QCString result; + QString result; g_nodeStack.push(this); DBG(("DocLink::parse() start\n")); @@ -1495,7 +1510,7 @@ QCString DocLink::parse(bool isJavaLink) case TK_WORD: if (isJavaLink) // special case to detect closing } { - QCString w = g_token->name; + QString w = g_token->name; uint l=w.length(); int p; if (w=="}") @@ -1882,7 +1897,7 @@ int DocIndexEntry::parse() warn(g_fileName,doctokenizerYYlineno,"Error: expected whitespace after \\addindex command"); goto endindexentry; } - m_entry.resize(0); + m_entry=""; while ((tok=doctokenizerYYlex()) && tok!=TK_WHITESPACE && tok!=TK_NEWPARA) { switch (tok) @@ -2078,7 +2093,7 @@ int DocHtmlRow::parse() // parse one or more cells do { - cell=new DocHtmlCell(this,isHeading); + cell=new DocHtmlCell(this,g_token->attribs,isHeading); cell->markFirst(isFirst); isFirst=FALSE; m_children.append(cell); @@ -2125,7 +2140,7 @@ getrow: } else { - m_caption = new DocHtmlCaption(this); + m_caption = new DocHtmlCaption(this,g_token->attribs); retval=m_caption->parse(); if (retval==RetVal_OK) // caption was parsed ok @@ -2154,7 +2169,7 @@ getrow: // parse one or more rows while (retval==RetVal_TableRow) { - DocHtmlRow *tr=new DocHtmlRow(this); + DocHtmlRow *tr=new DocHtmlRow(this,g_token->attribs); m_children.append(tr); retval=tr->parse(); } @@ -2231,6 +2246,7 @@ endtitle: int DocHtmlDescData::parse() { + m_attribs = g_token->attribs; int retval=0; g_nodeStack.push(this); DBG(("DocHtmlDescData::parse() start\n")); @@ -2295,7 +2311,7 @@ int DocHtmlDescList::parse() do { - DocHtmlDescTitle *dt=new DocHtmlDescTitle(this); + DocHtmlDescTitle *dt=new DocHtmlDescTitle(this,g_token->attribs); m_children.append(dt); DocHtmlDescData *dd=new DocHtmlDescData(this); m_children.append(dd); @@ -2417,7 +2433,7 @@ int DocHtmlList::parse() do { - DocHtmlListItem *li=new DocHtmlListItem(this); + DocHtmlListItem *li=new DocHtmlListItem(this,g_token->attribs); m_children.append(li); retval=li->parse(); } while (retval==RetVal_ListItem); @@ -2598,7 +2614,7 @@ int DocSimpleSect::parse(bool userTitle) //-------------------------------------------------------------------------- -int DocParamList::parse(const QCString &cmdName) +int DocParamList::parse(const QString &cmdName) { int retval=RetVal_OK; DBG(("DocParamList::parse() start\n")); @@ -2648,7 +2664,7 @@ int DocParamList::parse(const QCString &cmdName) //-------------------------------------------------------------------------- -int DocParamSect::parse(const QCString &cmdName) +int DocParamSect::parse(const QString &cmdName) { int retval=RetVal_OK; DBG(("DocParamSect::parse() start\n")); @@ -2686,7 +2702,7 @@ int DocPara::handleSimpleSection(DocSimpleSect::Type t) return (rv!=TK_NEWPARA) ? rv : RetVal_OK; } -int DocPara::handleParamSection(const QCString &cmdName,DocParamSect::Type t) +int DocPara::handleParamSection(const QString &cmdName,DocParamSect::Type t) { DocParamSect *ps=0; @@ -2722,7 +2738,7 @@ int DocPara::handleXRefItem(DocXRefItem::Type t) return retval; } -void DocPara::handleIncludeOperator(const QCString &cmdName,DocIncOperator::Type t) +void DocPara::handleIncludeOperator(const QString &cmdName,DocIncOperator::Type t) { int tok=doctokenizerYYlex(); if (tok!=TK_WHITESPACE) @@ -2772,7 +2788,7 @@ void DocPara::handleIncludeOperator(const QCString &cmdName,DocIncOperator::Type op->parse(); } -void DocPara::handleImage(const QCString &cmdName) +void DocPara::handleImage(const QString &cmdName) { int tok=doctokenizerYYlex(); if (tok!=TK_WHITESPACE) @@ -2796,7 +2812,7 @@ void DocPara::handleImage(const QCString &cmdName) return; } DocImage::Type t; - QCString imgType = g_token->name.lower(); + QString imgType = g_token->name.lower(); if (imgType=="html") t=DocImage::Html; else if (imgType=="latex") t=DocImage::Latex; else if (imgType=="rtf") t=DocImage::Rtf; @@ -2821,7 +2837,7 @@ void DocPara::handleImage(const QCString &cmdName) img->parse(); } -void DocPara::handleDotFile(const QCString &cmdName) +void DocPara::handleDotFile(const QString &cmdName) { int tok=doctokenizerYYlex(); if (tok!=TK_WHITESPACE) @@ -2844,7 +2860,7 @@ void DocPara::handleDotFile(const QCString &cmdName) df->parse(); } -void DocPara::handleLink(const QCString &cmdName,bool isJavaLink) +void DocPara::handleLink(const QString &cmdName,bool isJavaLink) { int tok=doctokenizerYYlex(); if (tok!=TK_WHITESPACE) @@ -2864,14 +2880,14 @@ void DocPara::handleLink(const QCString &cmdName,bool isJavaLink) doctokenizerYYsetStatePara(); DocLink *lnk = new DocLink(this,g_token->name); m_children.append(lnk); - QCString leftOver = lnk->parse(isJavaLink); + QString leftOver = lnk->parse(isJavaLink); if (!leftOver.isEmpty()) { m_children.append(new DocWord(this,leftOver)); } } -void DocPara::handleRef(const QCString &cmdName) +void DocPara::handleRef(const QString &cmdName) { int tok=doctokenizerYYlex(); if (tok!=TK_WHITESPACE) @@ -2941,7 +2957,7 @@ endlang: return retval; } -void DocPara::handleInclude(const QCString &cmdName,DocInclude::Type t) +void DocPara::handleInclude(const QString &cmdName,DocInclude::Type t) { int tok=doctokenizerYYlex(); if (tok!=TK_WHITESPACE) @@ -2971,7 +2987,7 @@ void DocPara::handleInclude(const QCString &cmdName,DocInclude::Type t) } -int DocPara::handleCommand(const QCString &cmdName) +int DocPara::handleCommand(const QString &cmdName) { int retval = RetVal_OK; switch (CmdMapper::map(cmdName)) @@ -3310,23 +3326,23 @@ int DocPara::handleCommand(const QCString &cmdName) } -int DocPara::handleHtmlStartTag(const QCString &tagName,const QList