Commit fbf972e7 authored by Dimitri van Heesch's avatar Dimitri van Heesch

Release 1.1.1

parent 69124e6c
DOXYGEN Version 1.1.0-20000305 DOXYGEN Version 1.1.1
CONTENTS CONTENTS
-------- --------
...@@ -15,8 +15,8 @@ INSTALLATION INSTRUCTIONS FOR UNIX: ...@@ -15,8 +15,8 @@ INSTALLATION INSTRUCTIONS FOR UNIX:
1. Unpack the archive, unless you already have: 1. Unpack the archive, unless you already have:
gunzip doxygen-1.1.0-20000305.src.tar.gz # uncompress the archive gunzip doxygen-1.1.1.src.tar.gz # uncompress the archive
tar xf doxygen-1.1.0-20000305.src.tar # unpack it tar xf doxygen-1.1.1.src.tar # unpack it
2. Run the configure script: 2. Run the configure script:
...@@ -252,4 +252,4 @@ The latest version of doxygen can be obtained at ...@@ -252,4 +252,4 @@ The latest version of doxygen can be obtained at
Enjoy, Enjoy,
Dimitri van Heesch (05 March 2000) Dimitri van Heesch (12 March 2000)
...@@ -51,7 +51,7 @@ ps: docs ...@@ -51,7 +51,7 @@ ps: docs
pdf: docs pdf: docs
cd latex ; $(MAKE) cd latex ; $(MAKE)
archive: distclean archive: clean
tar zcvf dx`date +%y%m%d`.tgz tmake doc wintools examples bin objects \ tar zcvf dx`date +%y%m%d`.tgz tmake doc wintools examples bin objects \
src configure configure.bin Makefile.in Makefile.win.in INSTALL \ src configure configure.bin Makefile.in Makefile.win.in INSTALL \
make.bat LANGUAGE.HOWTO LICENSE PLATFORMS VERSION make.bat LANGUAGE.HOWTO LICENSE PLATFORMS VERSION
......
DOXYGEN Version 1.1.0-20000305 DOXYGEN Version 1.1.1
Please read INSTALL for compilation instructions. Please read INSTALL for compilation instructions.
...@@ -7,4 +7,4 @@ The latest version of doxygen can be obtained at ...@@ -7,4 +7,4 @@ The latest version of doxygen can be obtained at
Enjoy, Enjoy,
Dimitri van Heesch (05 March 2000) Dimitri van Heesch (12 March 2000)
1.1.0-20000305 1.1.1
...@@ -104,6 +104,7 @@ followed by the descriptions of the tags grouped by category. ...@@ -104,6 +104,7 @@ followed by the descriptions of the tags grouped by category.
<li> \refitem cfg_input_filter INPUT_FILTER <li> \refitem cfg_input_filter INPUT_FILTER
<li> \refitem cfg_internal_docs INTERNAL_DOCS <li> \refitem cfg_internal_docs INTERNAL_DOCS
<li> \refitem cfg_javadoc_autobrief JAVADOC_AUTOBRIEF <li> \refitem cfg_javadoc_autobrief JAVADOC_AUTOBRIEF
<li> \refitem cfg_latex_batchmode LATEX_BATCHMODE
<li> \refitem cfg_latex_header LATEX_HEADER <li> \refitem cfg_latex_header LATEX_HEADER
<li> \refitem cfg_latex_output LATEX_OUTPUT <li> \refitem cfg_latex_output LATEX_OUTPUT
<li> \refitem cfg_macro_expansion MACRO_EXPANSION <li> \refitem cfg_macro_expansion MACRO_EXPANSION
...@@ -694,6 +695,16 @@ EXTRA_PACKAGES = times ...@@ -694,6 +695,16 @@ EXTRA_PACKAGES = times
the version number of doxygen, the project name (see PROJECT_NAME), or the the version number of doxygen, the project name (see PROJECT_NAME), or the
project number (see PROJECT_NUMBER). project number (see PROJECT_NUMBER).
\anchor cfg_latex_batchmode
<dt>\c LATEX_BATCHMODE <dd>
\addindex LATEX_BATCHMODE
If the \c LATEX_BATCHMODE tag is set to \c YES, doxygen will add the \\batchmode.
command to the generated \f$\mbox{\LaTeX}\f$ files. This will
instruct \f$\mbox{\LaTeX}\f$ to keep running if errors occur, instead of
asking the user for help. This option is also used when generating formulas
in HTML.
</dl> </dl>
\subsection rtf_output RTF related options \subsection rtf_output RTF related options
......
...@@ -173,6 +173,23 @@ void ClassDef::insertMember(const MemberDef *md) ...@@ -173,6 +173,23 @@ void ClassDef::insertMember(const MemberDef *md)
break; break;
default: // any of the other members default: // any of the other members
if (md->isStatic()) if (md->isStatic())
{
if (md->isVariable())
{
switch (md->protection())
{
case Protected:
proStaticAttribs.append(md);
break;
case Public:
pubStaticAttribs.append(md);
break;
case Private:
priStaticAttribs.append(md);
break;
}
}
else // function
{ {
switch (md->protection()) switch (md->protection())
{ {
...@@ -187,7 +204,28 @@ void ClassDef::insertMember(const MemberDef *md) ...@@ -187,7 +204,28 @@ void ClassDef::insertMember(const MemberDef *md)
break; break;
} }
} }
else }
else // not static
{
if (md->isVariable())
{
switch (md->protection())
{
case Protected: proAttribs.append(md); break;
case Public: pubAttribs.append(md); break;
case Private: priAttribs.append(md); break;
}
}
else if (md->isTypedef() || md->isEnumerate())
{
switch (md->protection())
{
case Protected: proTypes.append(md); break;
case Public: pubTypes.append(md); break;
case Private: priTypes.append(md); break;
}
}
else // member function
{ {
switch (md->protection()) switch (md->protection())
{ {
...@@ -196,6 +234,7 @@ void ClassDef::insertMember(const MemberDef *md) ...@@ -196,6 +234,7 @@ void ClassDef::insertMember(const MemberDef *md)
case Private: priMembers.append(md); break; case Private: priMembers.append(md); break;
} }
} }
}
if (md->protection()!=Private || Config::extractPrivateFlag) if (md->protection()!=Private || Config::extractPrivateFlag)
{ {
switch (md->memberType()) switch (md->memberType())
...@@ -282,6 +321,15 @@ void ClassDef::computeAnchors() ...@@ -282,6 +321,15 @@ void ClassDef::computeAnchors()
setAnchors('j',&signals); setAnchors('j',&signals);
setAnchors('k',&related); setAnchors('k',&related);
setAnchors('l',&friends); setAnchors('l',&friends);
setAnchors('m',&pubAttribs);
setAnchors('n',&proAttribs);
setAnchors('o',&priAttribs);
setAnchors('p',&pubStaticAttribs);
setAnchors('q',&proStaticAttribs);
setAnchors('r',&priStaticAttribs);
setAnchors('s',&pubTypes);
setAnchors('t',&proTypes);
setAnchors('u',&priTypes);
} }
// add a file name to the used files set // add a file name to the used files set
...@@ -549,21 +597,39 @@ void ClassDef::writeDocumentation(OutputList &ol) ...@@ -549,21 +597,39 @@ void ClassDef::writeDocumentation(OutputList &ol)
// write member groups // write member groups
ol.startMemberSections(); ol.startMemberSections();
pubMembers.writeDeclarations(ol,this,0,0,theTranslator->trPublicMembers(),0);
pubSlots.writeDeclarations(ol,this,0,0,theTranslator->trPublicSlots(),0); // non static public members
signals.writeDeclarations(ol,this,0,0,theTranslator->trSignals(),0); pubTypes.writeDeclarations(ol,this,0,0,0,theTranslator->trPublicTypes(),0);
pubStaticMembers.writeDeclarations(ol,this,0,0,theTranslator->trStaticPublicMembers(),0); pubMembers.writeDeclarations(ol,this,0,0,0,theTranslator->trPublicMembers(),0);
proMembers.writeDeclarations(ol,this,0,0,theTranslator->trProtectedMembers(),0); pubAttribs.writeDeclarations(ol,this,0,0,0,theTranslator->trPublicAttribs(),0);
proSlots.writeDeclarations(ol,this,0,0,theTranslator->trProtectedSlots(),0); pubSlots.writeDeclarations(ol,this,0,0,0,theTranslator->trPublicSlots(),0);
proStaticMembers.writeDeclarations(ol,this,0,0,theTranslator->trStaticProtectedMembers(),0); signals.writeDeclarations(ol,this,0,0,0,theTranslator->trSignals(),0);
// static public members
pubStaticMembers.writeDeclarations(ol,this,0,0,0,theTranslator->trStaticPublicMembers(),0);
pubStaticAttribs.writeDeclarations(ol,this,0,0,0,theTranslator->trStaticPublicAttribs(),0);
// protected non-static members
proTypes.writeDeclarations(ol,this,0,0,0,theTranslator->trProtectedTypes(),0);
proMembers.writeDeclarations(ol,this,0,0,0,theTranslator->trProtectedMembers(),0);
proAttribs.writeDeclarations(ol,this,0,0,0,theTranslator->trProtectedAttribs(),0);
proSlots.writeDeclarations(ol,this,0,0,0,theTranslator->trProtectedSlots(),0);
// protected static members
proStaticMembers.writeDeclarations(ol,this,0,0,0,theTranslator->trStaticProtectedMembers(),0);
proStaticAttribs.writeDeclarations(ol,this,0,0,0,theTranslator->trStaticProtectedAttribs(),0);
if (Config::extractPrivateFlag) if (Config::extractPrivateFlag)
{ {
priMembers.writeDeclarations(ol,this,0,0,theTranslator->trPrivateMembers(),0); // private non-static members
priSlots.writeDeclarations(ol,this,0,0,theTranslator->trPrivateSlots(),0); priTypes.writeDeclarations(ol,this,0,0,0,theTranslator->trPrivateTypes(),0);
priStaticMembers.writeDeclarations(ol,this,0,0,theTranslator->trStaticPrivateMembers(),0); priMembers.writeDeclarations(ol,this,0,0,0,theTranslator->trPrivateMembers(),0);
} priAttribs.writeDeclarations(ol,this,0,0,0,theTranslator->trPrivateAttribs(),0);
friends.writeDeclarations(ol,this,0,0,theTranslator->trFriends(),0); priSlots.writeDeclarations(ol,this,0,0,0,theTranslator->trPrivateSlots(),0);
related.writeDeclarations(ol,this,0,0, // private static members
priStaticMembers.writeDeclarations(ol,this,0,0,0,theTranslator->trStaticPrivateMembers(),0);
priStaticAttribs.writeDeclarations(ol,this,0,0,0,theTranslator->trStaticPrivateAttribs(),0);
}
friends.writeDeclarations(ol,this,0,0,0,theTranslator->trFriends(),0);
related.writeDeclarations(ol,this,0,0,0,
theTranslator->trRelatedFunctions(), theTranslator->trRelatedFunctions(),
theTranslator->trRelatedSubscript() theTranslator->trRelatedSubscript()
); );
...@@ -1130,21 +1196,21 @@ void ClassDef::writeDeclaration(OutputList &ol,MemberDef *md) ...@@ -1130,21 +1196,21 @@ void ClassDef::writeDeclaration(OutputList &ol,MemberDef *md)
ol.endMemberItem(FALSE,0,0,FALSE); // TODO: pass correct group parameters ol.endMemberItem(FALSE,0,0,FALSE); // TODO: pass correct group parameters
// insert members of this class // insert members of this class
pubMembers.writePlainDeclarations(ol,this,0,0); pubMembers.writePlainDeclarations(ol,this,0,0,0);
pubSlots.writePlainDeclarations(ol,this,0,0); pubSlots.writePlainDeclarations(ol,this,0,0,0);
signals.writePlainDeclarations(ol,this,0,0); signals.writePlainDeclarations(ol,this,0,0,0);
pubStaticMembers.writePlainDeclarations(ol,this,0,0); pubStaticMembers.writePlainDeclarations(ol,this,0,0,0);
proMembers.writePlainDeclarations(ol,this,0,0); proMembers.writePlainDeclarations(ol,this,0,0,0);
proSlots.writePlainDeclarations(ol,this,0,0); proSlots.writePlainDeclarations(ol,this,0,0,0);
proStaticMembers.writePlainDeclarations(ol,this,0,0); proStaticMembers.writePlainDeclarations(ol,this,0,0,0);
if (Config::extractPrivateFlag) if (Config::extractPrivateFlag)
{ {
priMembers.writePlainDeclarations(ol,this,0,0); priMembers.writePlainDeclarations(ol,this,0,0,0);
priSlots.writePlainDeclarations(ol,this,0,0); priSlots.writePlainDeclarations(ol,this,0,0,0);
priStaticMembers.writePlainDeclarations(ol,this,0,0); priStaticMembers.writePlainDeclarations(ol,this,0,0,0);
} }
friends.writePlainDeclarations(ol,this,0,0); friends.writePlainDeclarations(ol,this,0,0,0);
related.writePlainDeclarations(ol,this,0,0); related.writePlainDeclarations(ol,this,0,0,0);
} }
/*! a link to this class is possible within this project */ /*! a link to this class is possible within this project */
......
...@@ -125,7 +125,7 @@ class ClassDef : public Definition ...@@ -125,7 +125,7 @@ class ClassDef : public Definition
BaseClassList *inheritedBy; BaseClassList *inheritedBy;
NamespaceDef *nspace; // the namespace this class is in NamespaceDef *nspace; // the namespace this class is in
/* member list by protection */ /* member lists by protection */
MemberList pubMembers; MemberList pubMembers;
MemberList proMembers; MemberList proMembers;
MemberList priMembers; MemberList priMembers;
...@@ -135,6 +135,15 @@ class ClassDef : public Definition ...@@ -135,6 +135,15 @@ class ClassDef : public Definition
MemberList pubSlots; MemberList pubSlots;
MemberList proSlots; MemberList proSlots;
MemberList priSlots; MemberList priSlots;
MemberList pubAttribs;
MemberList proAttribs;
MemberList priAttribs;
MemberList pubStaticAttribs;
MemberList proStaticAttribs;
MemberList priStaticAttribs;
MemberList pubTypes;
MemberList proTypes;
MemberList priTypes;
MemberList related; MemberList related;
MemberList signals; MemberList signals;
MemberList friends; MemberList friends;
...@@ -218,7 +227,7 @@ class BaseClassList : public QList<BaseClassDef> ...@@ -218,7 +227,7 @@ class BaseClassList : public QList<BaseClassDef>
if (c1==0 || c2==0) if (c1==0 || c2==0)
return FALSE; return FALSE;
else else
return strcasecmp(c1->name(),c2->name()); return stricmp(c1->name(),c2->name());
} }
}; };
......
...@@ -34,7 +34,7 @@ int ClassList::compareItems(GCI item1, GCI item2) ...@@ -34,7 +34,7 @@ int ClassList::compareItems(GCI item1, GCI item2)
//int prefixLength = Config::ignorePrefix.length(); //int prefixLength = Config::ignorePrefix.length();
//int i1 = c1->name().left(prefixLength)==Config::ignorePrefix ? prefixLength : 0; //int i1 = c1->name().left(prefixLength)==Config::ignorePrefix ? prefixLength : 0;
//int i2 = c2->name().left(prefixLength)==Config::ignorePrefix ? prefixLength : 0; //int i2 = c2->name().left(prefixLength)==Config::ignorePrefix ? prefixLength : 0;
return strcasecmp(c1->name().data()+getPrefixIndex(c1->name()), return stricmp(c1->name().data()+getPrefixIndex(c1->name()),
c2->name().data()+getPrefixIndex(c2->name()) c2->name().data()+getPrefixIndex(c2->name())
); );
} }
......
...@@ -301,10 +301,11 @@ static bool getLink(const char *className, ...@@ -301,10 +301,11 @@ static bool getLink(const char *className,
ClassDef *cd; ClassDef *cd;
FileDef *fd; FileDef *fd;
NamespaceDef *nd; NamespaceDef *nd;
GroupDef *gd;
QCString m=memberName; QCString m=memberName;
QCString c=className; QCString c=className;
//printf("Trying `%s'::`%s'\n",c.data(),m.data()); //printf("Trying `%s'::`%s'\n",c.data(),m.data());
if (getDefs(c,m,"()",md,cd,fd,nd) && md->isLinkable()) if (getDefs(c,m,"()",md,cd,fd,nd,gd) && md->isLinkable())
{ {
//printf("Found!\n"); //printf("Found!\n");
if (g_exampleBlock) if (g_exampleBlock)
...@@ -326,7 +327,7 @@ static bool getLink(const char *className, ...@@ -326,7 +327,7 @@ static bool getLink(const char *className,
} }
} }
Definition *d=0; Definition *d=0;
if (cd) d=cd; else if (cd) d=nd; else d=fd; if (cd) d=cd; else if (cd) d=nd; else if (fd) d=fd; else d=gd;
if (d) if (d)
{ {
......
...@@ -115,6 +115,7 @@ struct Config ...@@ -115,6 +115,7 @@ struct Config
static bool showIncFileFlag; // show include file in file documentation? static bool showIncFileFlag; // show include file in file documentation?
static bool stripCommentsFlag; // strip special comments from code fragments? static bool stripCommentsFlag; // strip special comments from code fragments?
static bool sortMembersFlag; // sort members alphabetically? static bool sortMembersFlag; // sort members alphabetically?
static bool latexBatchModeFlag; // continue after latex errors?
}; };
#endif #endif
This diff is collapsed.
...@@ -53,7 +53,7 @@ class DefineList : public QList<Define> ...@@ -53,7 +53,7 @@ class DefineList : public QList<Define>
~DefineList() {} ~DefineList() {}
int compareItems(GCI i1,GCI i2) int compareItems(GCI i1,GCI i2)
{ {
return strcasecmp(((Define *)i1)->name,((Define *)i2)->name); return stricmp(((Define *)i1)->name,((Define *)i2)->name);
} }
}; };
...@@ -65,7 +65,7 @@ class DefineName : public QList<Define> ...@@ -65,7 +65,7 @@ class DefineName : public QList<Define>
const char *nameString() const { return name; } const char *nameString() const { return name; }
int compareItems(GCI i1,GCI i2) int compareItems(GCI i1,GCI i2)
{ {
return strcasecmp(((Define *)i1)->name,((Define *)i2)->name); return stricmp(((Define *)i1)->name,((Define *)i2)->name);
} }
private: private:
......
...@@ -159,7 +159,7 @@ class DotNodeList : public QList<DotNode> ...@@ -159,7 +159,7 @@ class DotNodeList : public QList<DotNode>
~DotNodeList() {} ~DotNodeList() {}
int compareItems(GCI item1,GCI item2) int compareItems(GCI item1,GCI item2)
{ {
return strcasecmp(((DotNode *)item1)->m_label,((DotNode *)item2)->m_label); return stricmp(((DotNode *)item1)->m_label,((DotNode *)item2)->m_label);
} }
}; };
......
...@@ -141,6 +141,7 @@ int annotatedClasses; ...@@ -141,6 +141,7 @@ int annotatedClasses;
int hierarchyClasses; int hierarchyClasses;
int documentedFunctions; int documentedFunctions;
int documentedMembers; int documentedMembers;
int documentedHtmlFiles;
int documentedFiles; int documentedFiles;
int documentedGroups; int documentedGroups;
int documentedNamespaces; int documentedNamespaces;
...@@ -432,6 +433,48 @@ static bool addNamespace(Entry *root,ClassDef *cd) ...@@ -432,6 +433,48 @@ static bool addNamespace(Entry *root,ClassDef *cd)
return FALSE; return FALSE;
} }
static void addClassToGroups(Entry *root,ClassDef *cd)
{
QListIterator<QCString> sli(*root->groups);
QCString *s;
for (;(s=sli.current());++sli)
{
GroupDef *gd=0;
if (!s->isEmpty() && (gd=groupDict[*s]))
{
gd->addClass(cd);
//printf("Compound %s: in group %s\n",cd->name().data(),s->data());
}
}
}
static void addMemberToGroups(Entry *root,MemberDef *md)
{
QListIterator<QCString> sli(*root->groups);
QCString *s;
for (;(s=sli.current());++sli)
{
GroupDef *gd=0;
if (!s->isEmpty() && (gd=groupDict[*s]))
{
GroupDef *mgd = md->groupDef();
if (mgd==0)
{
gd->addMember(md);
md->setGroupDef(gd);
}
else if (mgd!=gd)
{
warn("Warning: Member %s found in multiple groups.!\n"
"The member will be put in group %s, and not in group %s",
md->name().data(),mgd->name().data(),gd->name().data()
);
}
//printf("Member %s: in group %s\n",md->name().data(),s->data());
}
}
}
//---------------------------------------------------------------------- //----------------------------------------------------------------------
// build a list of all classes mentioned in the documentation // build a list of all classes mentioned in the documentation
...@@ -518,6 +561,7 @@ void buildClassList(Entry *root) ...@@ -518,6 +561,7 @@ void buildClassList(Entry *root)
// ); // );
fd->insertClass(cd); fd->insertClass(cd);
} }
addClassToGroups(root,cd);
} }
else // new class else // new class
{ {
...@@ -555,17 +599,7 @@ void buildClassList(Entry *root) ...@@ -555,17 +599,7 @@ void buildClassList(Entry *root)
cd->setBodySegment(root->bodyLine,root->endBodyLine); cd->setBodySegment(root->bodyLine,root->endBodyLine);
cd->setBodyDef(fd); cd->setBodyDef(fd);
QListIterator<QCString> sli(*root->groups); addClassToGroups(root,cd);
QCString *s;
for (;(s=sli.current());++sli)
{
GroupDef *gd=0;
if (!s->isEmpty() && (gd=groupDict[*s]))
{
gd->addClass(cd);
//printf("Compound %s: in group %s\n",cd->name().data(),s->data());
}
}
// see if the class is found inside a namespace // see if the class is found inside a namespace
bool found=addNamespace(root,cd); bool found=addNamespace(root,cd);
...@@ -1340,6 +1374,8 @@ void buildMemberList(Entry *root) ...@@ -1340,6 +1374,8 @@ void buildMemberList(Entry *root)
cd->insertMember(md); cd->insertMember(md);
// add file to list of used files // add file to list of used files
cd->insertUsedFile(root->fileName); cd->insertUsedFile(root->fileName);
addMemberToGroups(root,md);
} }
else if (root->parent && else if (root->parent &&
!(root->parent->section & Entry::COMPOUND_MASK) && !(root->parent->section & Entry::COMPOUND_MASK) &&
...@@ -1493,6 +1529,7 @@ void buildMemberList(Entry *root) ...@@ -1493,6 +1529,7 @@ void buildMemberList(Entry *root)
functionNameDict.insert(name,mn); functionNameDict.insert(name,mn);
functionNameList.inSort(mn); functionNameList.inSort(mn);
} }
addMemberToGroups(root,md);
} }
else else
{ {
...@@ -1874,7 +1911,7 @@ void computeClassRelations(Entry *root) ...@@ -1874,7 +1911,7 @@ void computeClassRelations(Entry *root)
} }
//----------------------------------------------------------------------- //-----------------------------------------------------------------------
// compute the references (anchors in HTML) for each member in the class // compute the references (anchors in HTML) for each function in the file
void computeMemberReferences() void computeMemberReferences()
{ {
...@@ -1884,13 +1921,6 @@ void computeMemberReferences() ...@@ -1884,13 +1921,6 @@ void computeMemberReferences()
cd->computeAnchors(); cd->computeAnchors();
cd=classList.next(); cd=classList.next();
} }
}
//-----------------------------------------------------------------------
// compute the references (anchors in HTML) for each function in the file
void computeFunctionReferences()
{
FileName *fn=inputNameList.first(); FileName *fn=inputNameList.first();
while (fn) while (fn)
{ {
...@@ -1908,6 +1938,12 @@ void computeFunctionReferences() ...@@ -1908,6 +1938,12 @@ void computeFunctionReferences()
nd->computeAnchors(); nd->computeAnchors();
nd=namespaceList.next(); nd=namespaceList.next();
} }
GroupDef *gd=groupList.first();
while (gd)
{
gd->computeAnchors();
gd=groupList.next();
}
} }
...@@ -1994,6 +2030,7 @@ void addMemberDocs(Entry *root,MemberDef *md, const char *funcDecl, ...@@ -1994,6 +2030,7 @@ void addMemberDocs(Entry *root,MemberDef *md, const char *funcDecl,
md->setDefLine(root->startLine); md->setDefLine(root->startLine);
if (root->inLine && !md->isInline()) md->setInline(TRUE); if (root->inLine && !md->isInline()) md->setInline(TRUE);
md->addSectionsToDefinition(root->anchors); md->addSectionsToDefinition(root->anchors);
addMemberToGroups(root,md);
if (cd) cd->insertUsedFile(root->fileName); if (cd) cd->insertUsedFile(root->fileName);
if (root->mGrpId!=-1) if (root->mGrpId!=-1)
{ {
...@@ -3373,7 +3410,7 @@ void computeMemberRelations() ...@@ -3373,7 +3410,7 @@ void computeMemberRelations()
// mcd->name().data(),md->name().data(), // mcd->name().data(),md->name().data(),
// bmcd->name().data(),bmd->name().data() // bmcd->name().data(),bmd->name().data()
// ); // );
if (md!=bmd && bmcd && mcd && mcd->isBaseClass(bmcd)) if (md!=bmd && bmcd && mcd && bmcd!=mcd && mcd->isBaseClass(bmcd))
{ {
//printf(" Base argList=`%s'\n Super argList=`%s'\n", //printf(" Base argList=`%s'\n Super argList=`%s'\n",
// argListToString(bmd->argumentList()).data(), // argListToString(bmd->argumentList()).data(),
...@@ -3386,7 +3423,14 @@ void computeMemberRelations() ...@@ -3386,7 +3423,14 @@ void computeMemberRelations()
mcd->isLinkable() && bmcd->isLinkable() mcd->isLinkable() && bmcd->isLinkable()
) )
{ {
MemberDef *rmd;
if ((rmd=md->reimplements())==0 ||
minClassDistance(mcd,bmcd)<minClassDistance(mcd,rmd->memberClass())
)
{
//printf("setting (new) reimplements member\n");
md->setReimplements(bmd); md->setReimplements(bmd);
}
bmd->insertReimplementedBy(md); bmd->insertReimplementedBy(md);
} }
} }
...@@ -3450,7 +3494,7 @@ void buildCompleteMemberLists() ...@@ -3450,7 +3494,7 @@ void buildCompleteMemberLists()
void generateFileDocs() void generateFileDocs()
{ {
if (documentedFiles==0) return; if (documentedHtmlFiles==0) return;
writeFileIndex(*outputList); writeFileIndex(*outputList);
if (inputNameList.count()>0) if (inputNameList.count()>0)
...@@ -4628,15 +4672,17 @@ void readFormulaRepository() ...@@ -4628,15 +4672,17 @@ void readFormulaRepository()
void usage(const char *name) void usage(const char *name)
{ {
msg("Doxygen version %s\nCopyright Dimitri van Heesch 1997-2000\n\n",versionString); msg("Doxygen version %s\nCopyright Dimitri van Heesch 1997-2000\n\n",versionString);
msg("You can use doxygen in two ways:\n\n"); msg("You can use doxygen in three ways:\n\n");
msg("1) Use doxygen to generate a template configuration file:\n"); msg("1) Use doxygen to generate a template configuration file:\n");
msg(" %s [-s] -g [configName]\n\n",name); msg(" %s [-s] -g [configName]\n\n",name);
msg(" If -s is specified the comments in the config file will be omitted.\n");
msg(" If - is used for configName doxygen will write to standard output.\n\n"); msg(" If - is used for configName doxygen will write to standard output.\n\n");
msg("2) Use doxygen to generate documentation using an existing "); msg("2) Use doxygen to update an old configuration file:\n");
msg(" %s [-s] -u [configName]\n\n",name);
msg("3) Use doxygen to generate documentation using an existing ");
msg("configuration file:\n"); msg("configuration file:\n");
msg(" %s [configName]\n\n",name); msg(" %s [configName]\n\n",name);
msg(" If - is used for configName doxygen will read from standard input.\n\n"); msg(" If - is used for configName doxygen will read from standard input.\n\n");
msg("If -s is specified the comments in the config file will be omitted.\n");
msg("If configName is omitted `Doxyfile' will be used as a default.\n\n"); msg("If configName is omitted `Doxyfile' will be used as a default.\n\n");
exit(1); exit(1);
} }
...@@ -4672,6 +4718,7 @@ int main(int argc,char **argv) ...@@ -4672,6 +4718,7 @@ int main(int argc,char **argv)
const char *debugLabel; const char *debugLabel;
bool genConfig=FALSE; bool genConfig=FALSE;
bool shortList=FALSE; bool shortList=FALSE;
bool updateConfig=FALSE;
while (optind<argc && argv[optind][0]=='-' && while (optind<argc && argv[optind][0]=='-' &&
(isalpha(argv[optind][1]) || argv[optind][1]=='?') (isalpha(argv[optind][1]) || argv[optind][1]=='?')
) )
...@@ -4690,6 +4737,9 @@ int main(int argc,char **argv) ...@@ -4690,6 +4737,9 @@ int main(int argc,char **argv)
case 's': case 's':
shortList=TRUE; shortList=TRUE;
break; break;
case 'u':
updateConfig=TRUE;
break;
case 'h': case 'h':
case '?': case '?':
usage(argv[0]); usage(argv[0]);
...@@ -4711,21 +4761,19 @@ int main(int argc,char **argv) ...@@ -4711,21 +4761,19 @@ int main(int argc,char **argv)
exit(1); exit(1);
} }
compoundKeywordDict.insert("class",(void *)8);
compoundKeywordDict.insert("struct",(void *)8);
compoundKeywordDict.insert("union",(void *)8);
compoundKeywordDict.insert("interface",(void *)8);
compoundKeywordDict.insert("exception",(void *)8);
QFileInfo configFileInfo1("Doxyfile"),configFileInfo2("doxyfile"); QFileInfo configFileInfo1("Doxyfile"),configFileInfo2("doxyfile");
QCString config; QCString config;
if (optind>=argc) if (optind>=argc)
{ {
if (configFileInfo1.exists()) if (configFileInfo1.exists())
{
config=fileToString("Doxyfile"); config=fileToString("Doxyfile");
configName="Doxyfile";
}
else if (configFileInfo2.exists()) else if (configFileInfo2.exists())
{ {
config=fileToString("doxyfile"); config=fileToString("doxyfile");
configName="doxyfile";
} }
else else
{ {
...@@ -4734,11 +4782,31 @@ int main(int argc,char **argv) ...@@ -4734,11 +4782,31 @@ int main(int argc,char **argv)
} }
} }
else else
{
config=fileToString(argv[optind]); config=fileToString(argv[optind]);
configName=argv[optind];
}
parseConfig(config); parseConfig(config);
if (updateConfig)
{
generateConfigFile(configName,shortList);
exit(1);
}
checkConfig(); checkConfig();
/**************************************************************************
* Initialize some global constants
**************************************************************************/
spaces.fill(' ',Config::tabSize); spaces.fill(' ',Config::tabSize);
compoundKeywordDict.insert("class",(void *)8);
compoundKeywordDict.insert("struct",(void *)8);
compoundKeywordDict.insert("union",(void *)8);
compoundKeywordDict.insert("interface",(void *)8);
compoundKeywordDict.insert("exception",(void *)8);
/************************************************************************** /**************************************************************************
* Initialize output generators * * Initialize output generators *
...@@ -4943,9 +5011,6 @@ int main(int argc,char **argv) ...@@ -4943,9 +5011,6 @@ int main(int argc,char **argv)
msg("Computing member references...\n"); msg("Computing member references...\n");
computeMemberReferences(); computeMemberReferences();
msg("Computing function references...\n");
computeFunctionReferences();
msg("Computing member relations...\n"); msg("Computing member relations...\n");
computeMemberRelations(); computeMemberRelations();
...@@ -4990,7 +5055,7 @@ int main(int argc,char **argv) ...@@ -4990,7 +5055,7 @@ int main(int argc,char **argv)
hierarchyClasses = countClassHierarchy(); hierarchyClasses = countClassHierarchy();
documentedMembers = countClassMembers(); documentedMembers = countClassMembers();
documentedFunctions = countFileMembers(); documentedFunctions = countFileMembers();
documentedFiles = countFiles(); countFiles(documentedHtmlFiles,documentedFiles);
documentedGroups = countGroups(); documentedGroups = countGroups();
documentedNamespaces = countNamespaces(); documentedNamespaces = countNamespaces();
documentedNamespaceMembers = countNamespaceMembers(); documentedNamespaceMembers = countNamespaceMembers();
......
...@@ -124,6 +124,7 @@ extern int documentedFunctions; ...@@ -124,6 +124,7 @@ extern int documentedFunctions;
extern int documentedMembers; extern int documentedMembers;
extern int documentedDefines; extern int documentedDefines;
extern int documentedFiles; extern int documentedFiles;
extern int documentedHtmlFiles;
extern int documentedGroups; extern int documentedGroups;
extern int documentedNamespaces; extern int documentedNamespaces;
extern int documentedNamespaceMembers; extern int documentedNamespaceMembers;
......
...@@ -23,6 +23,7 @@ Entry::Entry() ...@@ -23,6 +23,7 @@ Entry::Entry()
num++; num++;
//printf("New Entry %d\n",num); //printf("New Entry %d\n",num);
parent=0; parent=0;
section = EMPTY_SEC;
sublist = new QList<Entry>; sublist = new QList<Entry>;
sublist->setAutoDelete(TRUE); sublist->setAutoDelete(TRUE);
extends = new QList<BaseInfo>; extends = new QList<BaseInfo>;
......
...@@ -294,7 +294,7 @@ void FileDef::writeDocumentation(OutputList &ol) ...@@ -294,7 +294,7 @@ void FileDef::writeDocumentation(OutputList &ol)
if (found) ol.endMemberList(); if (found) ol.endMemberList();
} }
allMemberList.writeDeclarations(ol,0,0,this,0,0); allMemberList.writeDeclarations(ol,0,0,this,0,0,0);
ol.endMemberSections(); ol.endMemberSections();
//doc=doc.stripWhiteSpace(); //doc=doc.stripWhiteSpace();
...@@ -346,75 +346,74 @@ void FileDef::writeDocumentation(OutputList &ol) ...@@ -346,75 +346,74 @@ void FileDef::writeDocumentation(OutputList &ol)
} }
} }
//memList->countDocMembers();
defineMembers.countDocMembers(); defineMembers.countDocMembers();
if ( /*memList->defineCount()>0*/ defineMembers.totalCount()>0 ) if (defineMembers.totalCount()>0 )
{ {
ol.writeRuler(); ol.writeRuler();
ol.startGroupHeader(); ol.startGroupHeader();
parseText(ol,theTranslator->trDefineDocumentation()); parseText(ol,theTranslator->trDefineDocumentation());
ol.endGroupHeader(); ol.endGroupHeader();
/*memList->*/defineMembers.writeDocumentation(ol,name()/*,MemberDef::Define*/); defineMembers.writeDocumentation(ol,name());
} }
protoMembers.countDocMembers(); protoMembers.countDocMembers();
if ( /*memList->protoCount()>0*/ protoMembers.totalCount()>0 ) if (protoMembers.totalCount()>0 )
{ {
ol.writeRuler(); ol.writeRuler();
ol.startGroupHeader(); ol.startGroupHeader();
parseText(ol,theTranslator->trFunctionPrototypeDocumentation()); parseText(ol,theTranslator->trFunctionPrototypeDocumentation());
ol.endGroupHeader(); ol.endGroupHeader();
/*memList->*/protoMembers.writeDocumentation(ol,name()/*,MemberDef::Prototype*/); protoMembers.writeDocumentation(ol,name());
} }
typedefMembers.countDocMembers(); typedefMembers.countDocMembers();
if ( /*memList->typedefCount()>0*/ typedefMembers.totalCount()>0 ) if (typedefMembers.totalCount()>0 )
{ {
ol.writeRuler(); ol.writeRuler();
ol.startGroupHeader(); ol.startGroupHeader();
parseText(ol,theTranslator->trTypedefDocumentation()); parseText(ol,theTranslator->trTypedefDocumentation());
ol.endGroupHeader(); ol.endGroupHeader();
/*memList->*/typedefMembers.writeDocumentation(ol,name()/*,MemberDef::Typedef*/); typedefMembers.writeDocumentation(ol,name());
} }
enumMembers.countDocMembers(); enumMembers.countDocMembers();
if ( /*memList->enumCount()>0*/ enumMembers.totalCount()>0 ) if (enumMembers.totalCount()>0 )
{ {
ol.writeRuler(); ol.writeRuler();
ol.startGroupHeader(); ol.startGroupHeader();
parseText(ol,theTranslator->trEnumerationTypeDocumentation()); parseText(ol,theTranslator->trEnumerationTypeDocumentation());
ol.endGroupHeader(); ol.endGroupHeader();
/*memList->*/enumMembers.writeDocumentation(ol,name()/*,MemberDef::Enumeration*/); enumMembers.writeDocumentation(ol,name());
} }
enumValMembers.countDocMembers(); enumValMembers.countDocMembers();
if ( /*memList->enumValueCount()>0*/ enumValMembers.totalCount()>0 ) if (enumValMembers.totalCount()>0 )
{ {
ol.writeRuler(); ol.writeRuler();
ol.startGroupHeader(); ol.startGroupHeader();
parseText(ol,theTranslator->trEnumerationValueDocumentation()); parseText(ol,theTranslator->trEnumerationValueDocumentation());
ol.endGroupHeader(); ol.endGroupHeader();
/*memList->*/enumValMembers.writeDocumentation(ol,name()/*,MemberDef::EnumValue*/); enumValMembers.writeDocumentation(ol,name());
} }
funcMembers.countDocMembers(); funcMembers.countDocMembers();
if ( /*memList->funcCount()>0*/ funcMembers.totalCount()>0 ) if (funcMembers.totalCount()>0 )
{ {
ol.writeRuler(); ol.writeRuler();
ol.startGroupHeader(); ol.startGroupHeader();
parseText(ol,theTranslator->trFunctionDocumentation()); parseText(ol,theTranslator->trFunctionDocumentation());
ol.endGroupHeader(); ol.endGroupHeader();
/*memList->*/funcMembers.writeDocumentation(ol,name()/*,MemberDef::Function*/); funcMembers.writeDocumentation(ol,name());
} }
varMembers.countDocMembers(); varMembers.countDocMembers();
if ( /*memList->varCount()>0*/ varMembers.totalCount()>0 ) if (varMembers.totalCount()>0 )
{ {
ol.writeRuler(); ol.writeRuler();
ol.startGroupHeader(); ol.startGroupHeader();
parseText(ol,theTranslator->trVariableDocumentation()); parseText(ol,theTranslator->trVariableDocumentation());
ol.endGroupHeader(); ol.endGroupHeader();
/*memList->*/varMembers.writeDocumentation(ol,name()/*,MemberDef::Variable*/); varMembers.writeDocumentation(ol,name());
} }
// write Author section (Man only) // write Author section (Man only)
...@@ -573,8 +572,8 @@ int FileList::compareItems(GCI item1, GCI item2) ...@@ -573,8 +572,8 @@ int FileList::compareItems(GCI item1, GCI item2)
FileDef *f2=(FileDef *)item2; FileDef *f2=(FileDef *)item2;
ASSERT(f1!=0 && f2!=0); ASSERT(f1!=0 && f2!=0);
return Config::fullPathNameFlag ? return Config::fullPathNameFlag ?
strcasecmp(f1->absFilePath(),f2->absFilePath()) : stricmp(f1->absFilePath(),f2->absFilePath()) :
strcasecmp(f1->name(),f2->name()); stricmp(f1->name(),f2->name());
} }
/*! Create a file list iterator. */ /*! Create a file list iterator. */
......
...@@ -62,11 +62,13 @@ void FormulaList::generateBitmaps(const char *path) ...@@ -62,11 +62,13 @@ void FormulaList::generateBitmaps(const char *path)
FormulaListIterator fli(*this); FormulaListIterator fli(*this);
Formula *formula; Formula *formula;
QFile f(texName); QFile f(texName);
bool formulaError=FALSE;
if (f.open(IO_WriteOnly)) if (f.open(IO_WriteOnly))
{ {
QTextStream t(&f); QTextStream t(&f);
if (Config::latexBatchModeFlag) t << "\\batchmode" << endl;
t << "\\documentclass{article}" << endl; t << "\\documentclass{article}" << endl;
t << "\\usepackage{epsf}" << endl; // for those who want to include images t << "\\usepackage{epsfig}" << endl; // for those who want to include images
const char *s=Config::extraPackageList.first(); const char *s=Config::extraPackageList.first();
while (s) while (s)
{ {
...@@ -99,8 +101,9 @@ void FormulaList::generateBitmaps(const char *path) ...@@ -99,8 +101,9 @@ void FormulaList::generateBitmaps(const char *path)
//system("latex _formulas.tex </dev/null >/dev/null"); //system("latex _formulas.tex </dev/null >/dev/null");
if (system("latex _formulas.tex")!=0) if (system("latex _formulas.tex")!=0)
{ {
err("Problems running latex. Check your installation or look at _formulas.tex!\n"); err("Problems running latex. Check your installation or look for typos in _formulas.tex!\n");
return; formulaError=TRUE;
//return;
} }
//printf("Running dvips...\n"); //printf("Running dvips...\n");
QListIterator<int> pli(pagesToGenerate); QListIterator<int> pli(pagesToGenerate);
...@@ -281,7 +284,7 @@ void FormulaList::generateBitmaps(const char *path) ...@@ -281,7 +284,7 @@ void FormulaList::generateBitmaps(const char *path)
thisDir.remove("_formulas.aux"); thisDir.remove("_formulas.aux");
} }
// remove the latex file itself // remove the latex file itself
thisDir.remove("_formulas.tex"); if (!formulaError) thisDir.remove("_formulas.tex");
// write/update the formula repository so we know what text the // write/update the formula repository so we know what text the
// generated gifs represent (we use this next time to avoid regeneration // generated gifs represent (we use this next time to avoid regeneration
// of the gifs, and to avoid forcing the user to delete all gifs in order // of the gifs, and to avoid forcing the user to delete all gifs in order
......
...@@ -25,13 +25,18 @@ ...@@ -25,13 +25,18 @@
#include "namespacedef.h" #include "namespacedef.h"
#include "language.h" #include "language.h"
#include "util.h" #include "util.h"
#include "memberlist.h"
#include "message.h"
GroupDef::GroupDef(const char *na,const char *t) : Definition(na) GroupDef::GroupDef(const char *na,const char *t) :
Definition(na)
{ {
fileList = new FileList; fileList = new FileList;
classList = new ClassList; classList = new ClassList;
// groupList = new GroupList; // groupList = new GroupList;
// name = n;
allMemberList = new MemberList;
allMemberDict = new QDict<MemberDef>;
if (t) if (t)
title = t; title = t;
else else
...@@ -64,6 +69,28 @@ void GroupDef::addNamespace(const NamespaceDef *def) ...@@ -64,6 +69,28 @@ void GroupDef::addNamespace(const NamespaceDef *def)
namespaceList->append(def); namespaceList->append(def);
} }
void GroupDef::addMember(const MemberDef *md)
{
QCString funcDecl=md->name()+md->argsString();
if (allMemberDict->find(funcDecl)==0)
{
allMemberList->append(md);
allMemberDict->insert(funcDecl,md);
switch(md->memberType())
{
case MemberDef::Variable: varMembers.inSort(md); break;
case MemberDef::Function: funcMembers.inSort(md); break;
case MemberDef::Typedef: typedefMembers.inSort(md); break;
case MemberDef::Enumeration: enumMembers.inSort(md); break;
case MemberDef::EnumValue: enumValMembers.inSort(md); break;
case MemberDef::Prototype: protoMembers.inSort(md); break;
case MemberDef::Define: defineMembers.inSort(md); break;
default:
err("FileDef::insertMembers(): unexpected member insert in file!\n");
}
}
}
//void GroupDef::addGroup(const GroupDef *def) //void GroupDef::addGroup(const GroupDef *def)
//{ //{
// groupList->append(def); // groupList->append(def);
...@@ -71,7 +98,13 @@ void GroupDef::addNamespace(const NamespaceDef *def) ...@@ -71,7 +98,13 @@ void GroupDef::addNamespace(const NamespaceDef *def)
int GroupDef::countMembers() const int GroupDef::countMembers() const
{ {
return fileList->count()+classList->count(); return fileList->count()+classList->count()+allMemberList->count();
}
/*! Compute the HTML anchor names for all members in the class */
void GroupDef::computeAnchors()
{
setAnchors('a',allMemberList);
} }
void GroupDef::writeDocumentation(OutputList &ol) void GroupDef::writeDocumentation(OutputList &ol)
...@@ -100,20 +133,29 @@ void GroupDef::writeDocumentation(OutputList &ol) ...@@ -100,20 +133,29 @@ void GroupDef::writeDocumentation(OutputList &ol)
//ol.enable(OutputGenerator::Latex); //ol.enable(OutputGenerator::Latex);
ol.popGeneratorState(); ol.popGeneratorState();
} }
ol.startMemberSections();
if (fileList->count()>0) if (fileList->count()>0)
{ {
ol.startGroupHeader(); ol.startMemberHeader();
parseText(ol,theTranslator->trFiles()); parseText(ol,theTranslator->trFiles());
ol.endGroupHeader(); ol.endMemberHeader();
ol.startIndexList();
FileDef *fd=fileList->first(); FileDef *fd=fileList->first();
while (fd) while (fd)
{ {
ol.writeStartAnnoItem("file ",fd->getOutputFileBase(),0,fd->name()); ol.startMemberItem(FALSE,0);
ol.writeEndAnnoItem(fd->name()); ol.docify("file");
ol.insertMemberAlign();
ol.writeObjectLink(fd->getReference(),fd->getOutputFileBase(),0,fd->name());
ol.endMemberItem(FALSE,0,0,FALSE);
if (!fd->briefDescription().isEmpty() && Config::briefMemDescFlag)
{
ol.startMemberDescription();
parseDoc(ol,0,0,fd->briefDescription());
ol.endMemberDescription();
ol.newParagraph();
}
fd=fileList->next(); fd=fileList->next();
} }
ol.endIndexList();
} }
if (classList->count()>0) if (classList->count()>0)
{ {
...@@ -123,10 +165,9 @@ void GroupDef::writeDocumentation(OutputList &ol) ...@@ -123,10 +165,9 @@ void GroupDef::writeDocumentation(OutputList &ol)
{ {
if (!found) if (!found)
{ {
ol.startGroupHeader(); ol.startMemberHeader();
parseText(ol,theTranslator->trCompounds()); parseText(ol,theTranslator->trCompounds());
ol.endGroupHeader(); ol.endMemberHeader();
ol.startIndexList();
found=TRUE; found=TRUE;
} }
QCString type; QCString type;
...@@ -138,24 +179,35 @@ void GroupDef::writeDocumentation(OutputList &ol) ...@@ -138,24 +179,35 @@ void GroupDef::writeDocumentation(OutputList &ol)
case ClassDef::Interface: type="interface"; break; case ClassDef::Interface: type="interface"; break;
case ClassDef::Exception: type="exception"; break; case ClassDef::Exception: type="exception"; break;
} }
ol.writeStartAnnoItem(type,cd->getOutputFileBase(),0,cd->name()); ol.startMemberItem(FALSE,0);
ol.writeEndAnnoItem(cd->name()); ol.docify(type);
ol.insertMemberAlign();
ol.writeObjectLink(cd->getReference(),cd->getOutputFileBase(),0,cd->name());
ol.endMemberItem(FALSE,0,0,FALSE);
if (!cd->briefDescription().isEmpty() && Config::briefMemDescFlag)
{
ol.startMemberDescription();
parseDoc(ol,0,0,cd->briefDescription());
ol.endMemberDescription();
ol.newParagraph();
}
cd=classList->next(); cd=classList->next();
} }
ol.endIndexList();
} }
if (allMemberList->count()>0)
{
allMemberList->writeDeclarations(ol,0,0,0,this,0,0);
}
ol.endMemberSections();
//int dl=doc.length(); //int dl=doc.length();
//doc=doc.stripWhiteSpace(); //doc=doc.stripWhiteSpace();
if (!briefDescription().isEmpty() || !documentation().isEmpty()) if (!briefDescription().isEmpty() || !documentation().isEmpty())
{ {
ol.writeRuler(); ol.writeRuler();
ol.pushGeneratorState(); ol.pushGeneratorState();
//bool latexOn = ol.isEnabled(OutputGenerator::Latex);
//if (latexOn) ol.disable(OutputGenerator::Latex);
ol.disable(OutputGenerator::Latex); ol.disable(OutputGenerator::Latex);
ol.disable(OutputGenerator::RTF); ol.disable(OutputGenerator::RTF);
ol.writeAnchor("_details"); ol.writeAnchor("_details");
//if (latexOn) ol.enable(OutputGenerator::Latex);
ol.popGeneratorState(); ol.popGeneratorState();
ol.startGroupHeader(); ol.startGroupHeader();
parseText(ol,theTranslator->trDetailedDescription()); parseText(ol,theTranslator->trDetailedDescription());
...@@ -173,7 +225,76 @@ void GroupDef::writeDocumentation(OutputList &ol) ...@@ -173,7 +225,76 @@ void GroupDef::writeDocumentation(OutputList &ol)
} }
} }
defineMembers.countDocMembers();
if (defineMembers.totalCount()>0 )
{
ol.writeRuler();
ol.startGroupHeader();
parseText(ol,theTranslator->trDefineDocumentation());
ol.endGroupHeader();
defineMembers.writeDocumentation(ol,name());
}
protoMembers.countDocMembers();
if (protoMembers.totalCount()>0 )
{
ol.writeRuler();
ol.startGroupHeader();
parseText(ol,theTranslator->trFunctionPrototypeDocumentation());
ol.endGroupHeader();
protoMembers.writeDocumentation(ol,name());
}
typedefMembers.countDocMembers();
if (typedefMembers.totalCount()>0 )
{
ol.writeRuler();
ol.startGroupHeader();
parseText(ol,theTranslator->trTypedefDocumentation());
ol.endGroupHeader();
typedefMembers.writeDocumentation(ol,name());
}
enumMembers.countDocMembers();
if (enumMembers.totalCount()>0 )
{
ol.writeRuler();
ol.startGroupHeader();
parseText(ol,theTranslator->trEnumerationTypeDocumentation());
ol.endGroupHeader();
enumMembers.writeDocumentation(ol,name());
}
enumValMembers.countDocMembers();
if (enumValMembers.totalCount()>0 )
{
ol.writeRuler();
ol.startGroupHeader();
parseText(ol,theTranslator->trEnumerationValueDocumentation());
ol.endGroupHeader();
enumValMembers.writeDocumentation(ol,name());
}
funcMembers.countDocMembers();
if (funcMembers.totalCount()>0 )
{
ol.writeRuler();
ol.startGroupHeader();
parseText(ol,theTranslator->trFunctionDocumentation());
ol.endGroupHeader();
funcMembers.writeDocumentation(ol,name());
}
varMembers.countDocMembers();
if (varMembers.totalCount()>0 )
{
ol.writeRuler();
ol.startGroupHeader();
parseText(ol,theTranslator->trVariableDocumentation());
ol.endGroupHeader();
varMembers.writeDocumentation(ol,name());
}
endFile(ol); endFile(ol);
//ol.enable(OutputGenerator::Man);
ol.popGeneratorState(); ol.popGeneratorState();
} }
...@@ -19,7 +19,10 @@ ...@@ -19,7 +19,10 @@
#include "qtbc.h" #include "qtbc.h"
#include <qlist.h> #include <qlist.h>
#include <qdict.h>
#include "definition.h" #include "definition.h"
#include "memberlist.h"
#include "memberdef.h"
class FileList; class FileList;
class ClassList; class ClassList;
...@@ -41,6 +44,7 @@ class GroupDef : public Definition ...@@ -41,6 +44,7 @@ class GroupDef : public Definition
void addFile(const FileDef *def); void addFile(const FileDef *def);
void addClass(const ClassDef *def); void addClass(const ClassDef *def);
void addNamespace(const NamespaceDef *def); void addNamespace(const NamespaceDef *def);
void addMember(const MemberDef *def);
void writeDocumentation(OutputList &ol); void writeDocumentation(OutputList &ol);
int countMembers() const; int countMembers() const;
bool isLinkableInProject() bool isLinkableInProject()
...@@ -51,6 +55,7 @@ class GroupDef : public Definition ...@@ -51,6 +55,7 @@ class GroupDef : public Definition
{ {
return isLinkableInProject() || isReference(); return isLinkableInProject() || isReference();
} }
void computeAnchors();
private: private:
QCString title; // title of the group QCString title; // title of the group
...@@ -58,6 +63,17 @@ class GroupDef : public Definition ...@@ -58,6 +63,17 @@ class GroupDef : public Definition
FileList *fileList; // list of all files in the group FileList *fileList; // list of all files in the group
ClassList *classList; // list of all classes in the group ClassList *classList; // list of all classes in the group
NamespaceList *namespaceList; // list of all namespace in the group NamespaceList *namespaceList; // list of all namespace in the group
MemberList *allMemberList; // list of all members in the group
QDict<MemberDef> *allMemberDict;
// members sorted to type
MemberList defineMembers;
MemberList protoMembers;
MemberList typedefMembers;
MemberList enumMembers;
MemberList enumValMembers;
MemberList funcMembers;
MemberList varMembers;
}; };
class GroupList : public QList<GroupDef> class GroupList : public QList<GroupDef>
......
...@@ -300,9 +300,10 @@ void writeGraphicalClassHierarchy(OutputList &ol) ...@@ -300,9 +300,10 @@ void writeGraphicalClassHierarchy(OutputList &ol)
//---------------------------------------------------------------------------- //----------------------------------------------------------------------------
int countFiles() void countFiles(int &htmlFiles,int &files)
{ {
int count=0; htmlFiles=0;
files=0;
FileNameListIterator fnli(inputNameList); FileNameListIterator fnli(inputNameList);
FileName *fn; FileName *fn;
for (;(fn=fnli.current());++fnli) for (;(fn=fnli.current());++fnli)
...@@ -311,22 +312,28 @@ int countFiles() ...@@ -311,22 +312,28 @@ int countFiles()
FileDef *fd; FileDef *fd;
for (;(fd=fni.current());++fni) for (;(fd=fni.current());++fni)
{ {
if (fd->isLinkableInProject() || bool doc = fd->isLinkableInProject();
fd->generateSource() || bool src = fd->generateSource() || Config::sourceBrowseFlag;
(!fd->isReference() && Config::sourceBrowseFlag) if (doc || src)
) count++; {
htmlFiles++;
}
if (doc)
{
files++;
}
} }
} }
return count;
} }
//---------------------------------------------------------------------------- //----------------------------------------------------------------------------
void writeFileIndex(OutputList &ol) void writeFileIndex(OutputList &ol)
{ {
if (documentedFiles==0) return; if (documentedHtmlFiles==0) return;
ol.pushGeneratorState(); ol.pushGeneratorState();
ol.disable(OutputGenerator::Man); ol.disable(OutputGenerator::Man);
if (documentedFiles==0) ol.disableAllBut(OutputGenerator::Html);
startFile(ol,"files","File Index"); startFile(ol,"files","File Index");
startTitle(ol,0); startTitle(ol,0);
QCString title = theTranslator->trFileList(); QCString title = theTranslator->trFileList();
...@@ -366,7 +373,9 @@ void writeFileIndex(OutputList &ol) ...@@ -366,7 +373,9 @@ void writeFileIndex(OutputList &ol)
path=stripFromPath(fd->getPath().copy()); path=stripFromPath(fd->getPath().copy());
} }
// --------------- LaTeX only ----------------------------- // --------------- LaTeX/RTF only -------------------------
if (doc)
{
ol.pushGeneratorState(); ol.pushGeneratorState();
ol.disable(OutputGenerator::Html); ol.disable(OutputGenerator::Html);
ol.writeStartAnnoItem("file", ol.writeStartAnnoItem("file",
...@@ -383,15 +392,9 @@ void writeFileIndex(OutputList &ol) ...@@ -383,15 +392,9 @@ void writeFileIndex(OutputList &ol)
ol+=briefOutput; ol+=briefOutput;
ol.docify(")"); ol.docify(")");
} }
//else
//{
// ol.startEmphasis();
// parseText(ol,theTranslator->trNoDescriptionAvailable());
// ol.endEmphasis();
//}
ol.writeEndAnnoItem(fd->getOutputFileBase()); ol.writeEndAnnoItem(fd->getOutputFileBase());
//ol.enable(OutputGenerator::Html);
ol.popGeneratorState(); ol.popGeneratorState();
}
// -------------------------------------------------------- // --------------------------------------------------------
// ----------------- HTML only ---------------------------- // ----------------- HTML only ----------------------------
......
...@@ -65,7 +65,7 @@ void writeGraphicalClassHierarchy(OutputList &ol); ...@@ -65,7 +65,7 @@ void writeGraphicalClassHierarchy(OutputList &ol);
int countClassHierarchy(); int countClassHierarchy();
int countClassMembers(); int countClassMembers();
int countFileMembers(); int countFileMembers();
int countFiles(); void countFiles(int &htmlFiles,int &files);
int countGroups(); int countGroups();
int countNamespaces(); int countNamespaces();
int countAnnotatedClasses(); int countAnnotatedClasses();
......
...@@ -168,6 +168,7 @@ void LatexGenerator::startIndexSection(IndexSections is) ...@@ -168,6 +168,7 @@ void LatexGenerator::startIndexSection(IndexSections is)
{ {
if (Config::latexHeaderFile.isEmpty()) if (Config::latexHeaderFile.isEmpty())
{ {
if (Config::latexBatchModeFlag) t << "\\batchmode" << endl;
if (Config::paperType=="a4wide") paperName="a4"; else paperName=Config::paperType; if (Config::paperType=="a4wide") paperName="a4"; else paperName=Config::paperType;
t << "\\documentclass[" << paperName << "paper"; t << "\\documentclass[" << paperName << "paper";
if (Config::pdfHyperFlag) t << ",ps2pdf"; if (Config::pdfHyperFlag) t << ",ps2pdf";
...@@ -207,13 +208,6 @@ void LatexGenerator::startIndexSection(IndexSections is) ...@@ -207,13 +208,6 @@ void LatexGenerator::startIndexSection(IndexSections is)
"\\vspace*{7cm}\n" "\\vspace*{7cm}\n"
"\\begin{center}\n" "\\begin{center}\n"
"{\\Large "; "{\\Large ";
//docify(projectName);
//t << " Reference Manual";
//if (!projectNumber.isEmpty())
//{
// t << "\\\\[1ex]\\large ";
// docify(projectNumber);
//}
} }
else else
{ {
......
...@@ -27,6 +27,7 @@ ...@@ -27,6 +27,7 @@
#include "example.h" #include "example.h"
#include "membergroup.h" #include "membergroup.h"
#include "scanner.h" #include "scanner.h"
#include "groupdef.h"
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
...@@ -219,6 +220,7 @@ MemberDef::MemberDef(const char *t,const char *na,const char *a,const char *e, ...@@ -219,6 +220,7 @@ MemberDef::MemberDef(const char *t,const char *na,const char *a,const char *e,
nspace=0; nspace=0;
memDef=0; memDef=0;
memDec=0; memDec=0;
group=0;
exampleList=0; exampleList=0;
exampleDict=0; exampleDict=0;
enumFields=0; enumFields=0;
...@@ -426,24 +428,29 @@ void MemberDef::setGroupId(int groupId) ...@@ -426,24 +428,29 @@ void MemberDef::setGroupId(int groupId)
} }
void MemberDef::writeLink(OutputList &ol,ClassDef *cd,NamespaceDef *nd, void MemberDef::writeLink(OutputList &ol,ClassDef *cd,NamespaceDef *nd,
FileDef *fd,MemberGroup *mg) FileDef *fd,GroupDef *gd,MemberGroup *mg)
{ {
if (mg) Definition *d;
ol.writeObjectLink(0,mg->getOutputFileBase(), if (mg) d=mg; else if (cd) d=cd; else if (nd) d=nd; else if (fd) d=fd; else if (gd) d=gd;
anchor(),name()); //if (mg)
else if (nd) // ol.writeObjectLink(0,mg->getOutputFileBase(),
ol.writeObjectLink(nd->getReference(),nd->getOutputFileBase(), // anchor(),name());
anchor(),name()); //else if (cd)
else if (fd) // ol.writeObjectLink(cd->getReference(),cd->getOutputFileBase(),
ol.writeObjectLink(fd->getReference(),fd->getOutputFileBase(), // anchor(),name());
anchor(),name()); //else if (nd)
else // ol.writeObjectLink(nd->getReference(),nd->getOutputFileBase(),
ol.writeObjectLink(cd->getReference(),cd->getOutputFileBase(), // anchor(),name());
anchor(),name()); //else if (fd)
// ol.writeObjectLink(fd->getReference(),fd->getOutputFileBase(),
// anchor(),name());
//else
ol.writeObjectLink(d->getReference(),d->getOutputFileBase(),anchor(),name());
} }
void MemberDef::writeDeclaration(OutputList &ol,ClassDef *cd,NamespaceDef *nd,FileDef *fd, void MemberDef::writeDeclaration(OutputList &ol,
ClassDef *cd,NamespaceDef *nd,FileDef *fd,GroupDef *gd,
int prevGroupId,bool inGroup) int prevGroupId,bool inGroup)
{ {
int i,l; int i,l;
...@@ -481,7 +488,8 @@ void MemberDef::writeDeclaration(OutputList &ol,ClassDef *cd,NamespaceDef *nd,Fi ...@@ -481,7 +488,8 @@ void MemberDef::writeDeclaration(OutputList &ol,ClassDef *cd,NamespaceDef *nd,Fi
} }
Definition *d=0; Definition *d=0;
if (cd) d=cd; else if (nd) d=nd; else d=fd; ASSERT (cd!=0 || nd!=0 || fd!=0 || gd!=0); // member should belong to something
if (cd) d=cd; else if (nd) d=nd; else if (fd) d=fd; else d=gd;
QCString cname = d->name(); QCString cname = d->name();
QCString cfname = d->getOutputFileBase(); QCString cfname = d->getOutputFileBase();
...@@ -664,11 +672,11 @@ void MemberDef::writeDeclaration(OutputList &ol,ClassDef *cd,NamespaceDef *nd,Fi ...@@ -664,11 +672,11 @@ void MemberDef::writeDeclaration(OutputList &ol,ClassDef *cd,NamespaceDef *nd,Fi
if (annMemb) if (annMemb)
{ {
//printf("anchor=%s ann_anchor=%s\n",anchor(),annMemb->anchor()); //printf("anchor=%s ann_anchor=%s\n",anchor(),annMemb->anchor());
annMemb->writeLink(ol,cd,nd,fd,inGroup ? memberGroup : 0); annMemb->writeLink(ol,cd,nd,fd,gd,inGroup ? memberGroup : 0);
annMemb->annUsed=annUsed=TRUE; annMemb->annUsed=annUsed=TRUE;
} }
else else
writeLink(ol,0,0,0,memberGroup); writeLink(ol,0,0,0,0,memberGroup);
//ol.writeBoldString(name()); //ol.writeBoldString(name());
} }
else if (isLinkable()) else if (isLinkable())
...@@ -680,13 +688,14 @@ void MemberDef::writeDeclaration(OutputList &ol,ClassDef *cd,NamespaceDef *nd,Fi ...@@ -680,13 +688,14 @@ void MemberDef::writeDeclaration(OutputList &ol,ClassDef *cd,NamespaceDef *nd,Fi
annMemb->memberClass(), annMemb->memberClass(),
annMemb->getNamespace(), annMemb->getNamespace(),
annMemb->getFileDef(), annMemb->getFileDef(),
annMemb->groupDef(),
inGroup ? memberGroup : 0 inGroup ? memberGroup : 0
); );
annMemb->annUsed=annUsed=TRUE; annMemb->annUsed=annUsed=TRUE;
} }
else else
//printf("writeLink %s->%d\n",name.data(),hasDocumentation()); //printf("writeLink %s->%d\n",name.data(),hasDocumentation());
writeLink(ol,cd,nd,fd,inGroup ? memberGroup : 0); writeLink(ol,cd,nd,fd,gd,inGroup ? memberGroup : 0);
} }
else // there is a brief member description and brief member else // there is a brief member description and brief member
// descriptions are enabled or there is no detailed description. // descriptions are enabled or there is no detailed description.
...@@ -795,6 +804,8 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol, ...@@ -795,6 +804,8 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
if (isEnumValue() && (smd = getEnumScope()) if (isEnumValue() && (smd = getEnumScope())
&& r.match(smd->name(),0,&dummy)==-1) return; && r.match(smd->name(),0,&dummy)==-1) return;
ol.pushGeneratorState();
bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag; bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag;
HtmlHelp *htmlHelp = 0; HtmlHelp *htmlHelp = 0;
if (hasHtmlHelp) htmlHelp = HtmlHelp::getInstance(); if (hasHtmlHelp) htmlHelp = HtmlHelp::getInstance();
...@@ -1236,6 +1247,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol, ...@@ -1236,6 +1247,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
ol.endIndent(); ol.endIndent();
// enable LaTeX again // enable LaTeX again
//if (Config::extractAllFlag && !hasDocs) ol.enable(OutputGenerator::Latex); //if (Config::extractAllFlag && !hasDocs) ol.enable(OutputGenerator::Latex);
ol.popGeneratorState();
} }
} }
......
...@@ -24,14 +24,16 @@ ...@@ -24,14 +24,16 @@
#include "entry.h" #include "entry.h"
#include "definition.h" #include "definition.h"
class FileDef;
class ClassDef; class ClassDef;
class NamespaceDef; class NamespaceDef;
class GroupDef;
class FileDef;
class MemberList; class MemberList;
class MemberGroup; class MemberGroup;
class ExampleList; class ExampleList;
class ExampleDict; class ExampleDict;
class OutputList; class OutputList;
class GroupDef;
class MemberDef : public Definition class MemberDef : public Definition
{ {
...@@ -62,9 +64,11 @@ class MemberDef : public Definition ...@@ -62,9 +64,11 @@ class MemberDef : public Definition
const ArgumentList *al); const ArgumentList *al);
~MemberDef(); ~MemberDef();
void writeLink(OutputList &ol,ClassDef *cd,NamespaceDef *nd, void writeLink(OutputList &ol,
FileDef *fd,MemberGroup *mg); ClassDef *cd,NamespaceDef *nd,FileDef *fd,GroupDef *gd,
void writeDeclaration(OutputList &ol,ClassDef *cd,NamespaceDef *nd,FileDef *fd, MemberGroup *mg);
void writeDeclaration(OutputList &ol,
ClassDef *cd,NamespaceDef *nd,FileDef *fd,GroupDef *gd,
int prevGroupId,bool inGroup); int prevGroupId,bool inGroup);
void writeDocumentation(MemberList *ml,OutputList &ol, void writeDocumentation(MemberList *ml,OutputList &ol,
const char *scopeName/*,MemberType m*/); const char *scopeName/*,MemberType m*/);
...@@ -83,6 +87,12 @@ class MemberDef : public Definition ...@@ -83,6 +87,12 @@ class MemberDef : public Definition
Protection protection() const { return prot; } Protection protection() const { return prot; }
Specifier virtualness() const { return virt; } Specifier virtualness() const { return virt; }
MemberType memberType() const { return mtype; } MemberType memberType() const { return mtype; }
GroupDef *groupDef() const { return group; }
FileDef *getFileDef() { return fileDef; }
FileDef *getFileDec() { return fileDec; }
bool isRelated() const { return related; }
bool isStatic() const { return stat; }
bool isInline() const { return inLine; }
void setMemberType(MemberType t) { mtype=t; } void setMemberType(MemberType t) { mtype=t; }
void setDefinition(const char *d) { def=d; } void setDefinition(const char *d) { def=d; }
void setDefFile(const char *f) { defFile=f; } void setDefFile(const char *f) { defFile=f; }
...@@ -96,13 +106,9 @@ class MemberDef : public Definition ...@@ -96,13 +106,9 @@ class MemberDef : public Definition
init=init.stripWhiteSpace(); init=init.stripWhiteSpace();
initLines=init.contains('\n'); initLines=init.contains('\n');
} }
FileDef *getFileDef() { return fileDef; }
FileDef *getFileDec() { return fileDec; }
void setMemberClass(ClassDef *cd) { classDef=cd; } void setMemberClass(ClassDef *cd) { classDef=cd; }
void makeRelated() { related=TRUE; } void makeRelated() { related=TRUE; }
bool isRelated() const { return related; } void setGroupDef(GroupDef *gd) { group=gd; }
bool isStatic() const { return stat; }
bool isInline() const { return inLine; }
bool hasDocumentation() // overrides hasDocumentation in definition.h bool hasDocumentation() // overrides hasDocumentation in definition.h
{ return Definition::hasDocumentation(); } { return Definition::hasDocumentation(); }
...@@ -236,6 +242,7 @@ class MemberDef : public Definition ...@@ -236,6 +242,7 @@ class MemberDef : public Definition
int grpId; // group id int grpId; // group id
QCString grpHeader; // group header QCString grpHeader; // group header
MemberGroup *memberGroup; // group's member definition MemberGroup *memberGroup; // group's member definition
GroupDef *group; // group in which this member is in
// disable copying of member defs // disable copying of member defs
MemberDef(const MemberDef &); MemberDef(const MemberDef &);
......
...@@ -134,7 +134,7 @@ void MemberGroup::writeDocumentation(OutputList &ol) ...@@ -134,7 +134,7 @@ void MemberGroup::writeDocumentation(OutputList &ol)
ol.docify(">"); ol.docify(">");
} }
ol.startMemberSections(); ol.startMemberSections();
memberList->writeDeclarations(ol,cd,nd,fd,"Synopsis",0,TRUE); memberList->writeDeclarations(ol,cd,nd,fd,0,"Synopsis",0,TRUE);
ol.endMemberSections(); ol.endMemberSections();
if ((!briefDescription().isEmpty() && Config::repeatBriefFlag) || if ((!briefDescription().isEmpty() && Config::repeatBriefFlag) ||
......
...@@ -14,15 +14,17 @@ ...@@ -14,15 +14,17 @@
* *
*/ */
#include <qregexp.h>
#include "memberlist.h" #include "memberlist.h"
#include "classdef.h" #include "classdef.h"
#include "message.h" #include "message.h"
#include <qregexp.h>
#include "util.h" #include "util.h"
#include "language.h" #include "language.h"
#include "doxygen.h" #include "doxygen.h"
#include "outputlist.h" #include "outputlist.h"
#include "scanner.h" #include "scanner.h"
#include "groupdef.h"
MemberList::MemberList() : QList<MemberDef>() MemberList::MemberList() : QList<MemberDef>()
{ {
...@@ -36,7 +38,7 @@ int MemberList::compareItems(GCI item1, GCI item2) ...@@ -36,7 +38,7 @@ int MemberList::compareItems(GCI item1, GCI item2)
{ {
MemberDef *c1=(MemberDef *)item1; MemberDef *c1=(MemberDef *)item1;
MemberDef *c2=(MemberDef *)item2; MemberDef *c2=(MemberDef *)item2;
return strcasecmp(c1->name(),c2->name()); return stricmp(c1->name(),c2->name());
} }
void MemberList::countDecMembers() void MemberList::countDecMembers()
...@@ -187,17 +189,21 @@ MemberListIterator::MemberListIterator(const QList<MemberDef> &l) : ...@@ -187,17 +189,21 @@ MemberListIterator::MemberListIterator(const QList<MemberDef> &l) :
{ {
} }
void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd, void MemberList::writePlainDeclarations(OutputList &ol,
NamespaceDef *nd,FileDef *fd,bool inGroup) ClassDef *cd,NamespaceDef *nd,FileDef *fd,GroupDef *gd,
bool inGroup)
{ {
countDecMembers(); countDecMembers();
if (totalCount()==0) return; // no members in this list if (totalCount()==0) return; // no members in this list
ol.pushGeneratorState();
int prevGroupId = -1; int prevGroupId = -1;
if (!fd && !nd) ol.startMemberList(); bool sectionPerType = fd || nd || gd;
if (!sectionPerType) ol.startMemberList();
MemberDef *md; MemberDef *md;
if (fd && defineCount()>0) if (sectionPerType && defineCount()>0)
{ {
ol.startMemberHeader(); ol.startMemberHeader();
parseText(ol,theTranslator->trDefines()); parseText(ol,theTranslator->trDefines());
...@@ -210,14 +216,14 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd, ...@@ -210,14 +216,14 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd,
(md->argsString() || md->hasDocumentation() || Config::extractAllFlag) (md->argsString() || md->hasDocumentation() || Config::extractAllFlag)
) )
{ {
md->writeDeclaration(ol,cd,nd,fd,prevGroupId,inGroup); md->writeDeclaration(ol,cd,nd,fd,gd,prevGroupId,inGroup);
prevGroupId = md->groupId(); prevGroupId = md->groupId();
} }
} }
ol.endMemberList(); ol.endMemberList();
} }
if ((fd || nd) && protoCount()>0) if (sectionPerType && protoCount()>0)
{ {
ol.startMemberHeader(); ol.startMemberHeader();
parseText(ol,theTranslator->trFuncProtos()); parseText(ol,theTranslator->trFuncProtos());
...@@ -228,7 +234,7 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd, ...@@ -228,7 +234,7 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd,
{ {
if (md->isPrototype()) if (md->isPrototype())
{ {
md->writeDeclaration(ol,cd,nd,fd,prevGroupId,inGroup); md->writeDeclaration(ol,cd,nd,fd,gd,prevGroupId,inGroup);
prevGroupId = md->groupId(); prevGroupId = md->groupId();
} }
} }
...@@ -237,7 +243,7 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd, ...@@ -237,7 +243,7 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd,
if (typedefCount()>0) if (typedefCount()>0)
{ {
if (fd || nd) if (sectionPerType)
{ {
ol.startMemberHeader(); ol.startMemberHeader();
parseText(ol,theTranslator->trTypedefs()); parseText(ol,theTranslator->trTypedefs());
...@@ -250,17 +256,17 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd, ...@@ -250,17 +256,17 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd,
{ {
if (md->isTypedef()) if (md->isTypedef())
{ {
md->writeDeclaration(ol,cd,nd,fd,prevGroupId,inGroup); md->writeDeclaration(ol,cd,nd,fd,gd,prevGroupId,inGroup);
prevGroupId = md->groupId(); prevGroupId = md->groupId();
} }
} }
if (fd || nd) ol.endMemberList(); if (sectionPerType) ol.endMemberList();
} }
// write enums // write enums
if (enumCount()>0) if (enumCount()>0)
{ {
if (fd || nd) if (sectionPerType)
{ {
ol.startMemberHeader(); ol.startMemberHeader();
parseText(ol,theTranslator->trEnumerations()); parseText(ol,theTranslator->trEnumerations());
...@@ -302,7 +308,7 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd, ...@@ -302,7 +308,7 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd,
if (!Config::genTagFile.isEmpty()) if (!Config::genTagFile.isEmpty())
tagFile << md->name() << " " << md->anchor() tagFile << md->name() << " " << md->anchor()
<< " \"\"" << endl; << " \"\"" << endl;
md->writeLink(typeDecl,cd,nd,fd,0); md->writeLink(typeDecl,cd,nd,fd,gd,0);
} }
else else
{ {
...@@ -323,7 +329,7 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd, ...@@ -323,7 +329,7 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd,
if (!Config::genTagFile.isEmpty()) if (!Config::genTagFile.isEmpty())
tagFile << fmd->name() << " " << fmd->anchor() tagFile << fmd->name() << " " << fmd->anchor()
<< " \"" << fmd->argsString() << "\""; << " \"" << fmd->argsString() << "\"";
fmd->writeLink(typeDecl,cd,nd,fd,0); fmd->writeLink(typeDecl,cd,nd,fd,gd,0);
} }
else // no docs for this enum value else // no docs for this enum value
{ {
...@@ -395,13 +401,13 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd, ...@@ -395,13 +401,13 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd,
} }
} // md->isEnumerate() } // md->isEnumerate()
} // enum loop } // enum loop
if (fd || nd) ol.endMemberList(); if (sectionPerType) ol.endMemberList();
} // write enums } // write enums
// write functions // write functions
if (funcCount()>0) if (funcCount()>0)
{ {
if (fd || nd) if (sectionPerType)
{ {
ol.startMemberHeader(); ol.startMemberHeader();
parseText(ol,theTranslator->trFunctions()); parseText(ol,theTranslator->trFunctions());
...@@ -416,11 +422,11 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd, ...@@ -416,11 +422,11 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd,
( !md->isRelated() || md->memberClass() ) ( !md->isRelated() || md->memberClass() )
) )
{ {
md->writeDeclaration(ol,cd,nd,fd,prevGroupId,inGroup); md->writeDeclaration(ol,cd,nd,fd,gd,prevGroupId,inGroup);
prevGroupId = md->groupId(); prevGroupId = md->groupId();
} }
} }
if (fd || nd) ol.endMemberList(); if (sectionPerType) ol.endMemberList();
} }
if (friendCount()>0) if (friendCount()>0)
...@@ -434,7 +440,7 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd, ...@@ -434,7 +440,7 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd,
//printf("Friend: type=%s name=%s\n",type.data(),md->name().data()); //printf("Friend: type=%s name=%s\n",type.data(),md->name().data());
if (md->hasDocumentation() && type!="friend class") if (md->hasDocumentation() && type!="friend class")
{ {
md->writeDeclaration(ol,cd,nd,fd,prevGroupId,inGroup); md->writeDeclaration(ol,cd,nd,fd,gd,prevGroupId,inGroup);
prevGroupId = md->groupId(); prevGroupId = md->groupId();
} }
else // friend is undocumented as a member but it is a class, else // friend is undocumented as a member but it is a class,
...@@ -479,7 +485,7 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd, ...@@ -479,7 +485,7 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd,
// write variables // write variables
if (varCount()>0) if (varCount()>0)
{ {
if (fd || nd) if (sectionPerType)
{ {
ol.startMemberHeader(); ol.startMemberHeader();
parseText(ol,theTranslator->trVariables()); parseText(ol,theTranslator->trVariables());
...@@ -491,11 +497,11 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd, ...@@ -491,11 +497,11 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd,
{ {
if (md->isVariable()) if (md->isVariable())
{ {
md->writeDeclaration(ol,cd,nd,fd,prevGroupId,inGroup); md->writeDeclaration(ol,cd,nd,fd,gd,prevGroupId,inGroup);
prevGroupId = md->groupId(); prevGroupId = md->groupId();
} }
} }
if (fd || nd) ol.endMemberList(); if (sectionPerType) ol.endMemberList();
} }
// handle members that are inside annonymous compounds and for which // handle members that are inside annonymous compounds and for which
...@@ -508,24 +514,26 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd, ...@@ -508,24 +514,26 @@ void MemberList::writePlainDeclarations(OutputList &ol,ClassDef *cd,
if (md->fromAnnonymousScope() && !md->annonymousDeclShown()) if (md->fromAnnonymousScope() && !md->annonymousDeclShown())
{ {
md->setFromAnnonymousScope(FALSE); md->setFromAnnonymousScope(FALSE);
md->writeDeclaration(ol,cd,nd,fd,prevGroupId,inGroup); md->writeDeclaration(ol,cd,nd,fd,gd,prevGroupId,inGroup);
md->setFromAnnonymousScope(TRUE); md->setFromAnnonymousScope(TRUE);
prevGroupId = md->groupId(); prevGroupId = md->groupId();
} }
} }
} }
if (!fd && !nd) { ol.endMemberList(); /*ol.writeChar('\n');*/ } if (!sectionPerType) { ol.endMemberList(); /*ol.writeChar('\n');*/ }
if (prevGroupId!=-1 && !inGroup) if (prevGroupId!=-1 && !inGroup)
{ {
ol.memberGroupSpacing(TRUE); ol.memberGroupSpacing(TRUE);
ol.memberGroupSeparator(); ol.memberGroupSeparator();
} }
ol.popGeneratorState();
} }
void MemberList::writeDeclarations(OutputList &ol,ClassDef *cd,NamespaceDef *nd, void MemberList::writeDeclarations(OutputList &ol,
FileDef *fd,const char *title,const char *subtitle,bool inGroup) ClassDef *cd,NamespaceDef *nd,FileDef *fd,GroupDef *gd,
const char *title,const char *subtitle,bool inGroup)
{ {
countDecMembers(); countDecMembers();
if (totalCount()==0) return; if (totalCount()==0) return;
...@@ -542,7 +550,7 @@ void MemberList::writeDeclarations(OutputList &ol,ClassDef *cd,NamespaceDef *nd, ...@@ -542,7 +550,7 @@ void MemberList::writeDeclarations(OutputList &ol,ClassDef *cd,NamespaceDef *nd,
ol.endMemberSubtitle(); ol.endMemberSubtitle();
} }
writePlainDeclarations(ol,cd,nd,fd,inGroup); writePlainDeclarations(ol,cd,nd,fd,gd,inGroup);
} }
void MemberList::writeDocumentation(OutputList &ol, void MemberList::writeDocumentation(OutputList &ol,
......
...@@ -19,6 +19,7 @@ ...@@ -19,6 +19,7 @@
#include <qlist.h> #include <qlist.h>
#include "memberdef.h" #include "memberdef.h"
class GroupDef;
class MemberList : public QList<MemberDef> class MemberList : public QList<MemberDef>
{ {
...@@ -44,9 +45,11 @@ class MemberList : public QList<MemberDef> ...@@ -44,9 +45,11 @@ class MemberList : public QList<MemberDef>
//protoCnt+defCnt+friendCnt; //protoCnt+defCnt+friendCnt;
m_count; m_count;
} }
void writePlainDeclarations(OutputList &ol,ClassDef *cd, void writePlainDeclarations(OutputList &ol,
NamespaceDef *nd,FileDef *fd,bool inGroup=FALSE); ClassDef *cd,NamespaceDef *nd,FileDef *fd,GroupDef *gd,
void writeDeclarations(OutputList &ol,ClassDef *cd,NamespaceDef *nd,FileDef *fd, bool inGroup=FALSE);
void writeDeclarations(OutputList &ol,
ClassDef *cd,NamespaceDef *nd,FileDef *fd,GroupDef *gd,
const char *title,const char *subtitle,bool inGroup=FALSE); const char *title,const char *subtitle,bool inGroup=FALSE);
void writeDocumentation(OutputList &ol,const char *scopeName void writeDocumentation(OutputList &ol,const char *scopeName
/*,MemberDef::MemberType m*/); /*,MemberDef::MemberType m*/);
......
...@@ -163,7 +163,7 @@ void NamespaceDef::writeDocumentation(OutputList &ol) ...@@ -163,7 +163,7 @@ void NamespaceDef::writeDocumentation(OutputList &ol)
if (found) ol.endMemberList(); if (found) ol.endMemberList();
} }
/*memList->*/allMemberList.writeDeclarations(ol,0,this,0,0,0); allMemberList.writeDeclarations(ol,0,this,0,0,0,0);
ol.endMemberSections(); ol.endMemberSections();
if (!briefDescription().isEmpty() || !documentation().isEmpty()) if (!briefDescription().isEmpty() || !documentation().isEmpty())
......
...@@ -91,7 +91,7 @@ class NamespaceList : public QList<NamespaceDef> ...@@ -91,7 +91,7 @@ class NamespaceList : public QList<NamespaceDef>
~NamespaceList() {} ~NamespaceList() {}
int compareItems(GCI item1,GCI item2) int compareItems(GCI item1,GCI item2)
{ {
return strcasecmp(((NamespaceDef *)item1)->name(), return stricmp(((NamespaceDef *)item1)->name(),
((NamespaceDef *)item2)->name() ((NamespaceDef *)item2)->name()
); );
} }
......
...@@ -130,6 +130,7 @@ static bool inDeprecatedBlock; ...@@ -130,6 +130,7 @@ static bool inDeprecatedBlock;
static bool inVersionBlock; static bool inVersionBlock;
static bool inDateBlock; static bool inDateBlock;
static bool inBugBlock; static bool inBugBlock;
static bool inNoteBlock;
static bool inPreBlock; static bool inPreBlock;
static bool inPostBlock; static bool inPostBlock;
static bool inInvarBlock; static bool inInvarBlock;
...@@ -214,6 +215,7 @@ static void initParser() ...@@ -214,6 +215,7 @@ static void initParser()
inVersionBlock = FALSE; inVersionBlock = FALSE;
inDateBlock = FALSE; inDateBlock = FALSE;
inBugBlock = FALSE; inBugBlock = FALSE;
inNoteBlock = FALSE;
inPreBlock = FALSE; inPreBlock = FALSE;
inPostBlock = FALSE; inPostBlock = FALSE;
inInvarBlock = FALSE; inInvarBlock = FALSE;
...@@ -643,7 +645,7 @@ static void tryEndItemList() ...@@ -643,7 +645,7 @@ static void tryEndItemList()
static bool inBlock() static bool inBlock()
{ {
return inParamBlock || inRetValBlock || inSeeBlock || inReturnBlock || inAuthorBlock || return inParamBlock || inRetValBlock || inSeeBlock || inReturnBlock || inAuthorBlock ||
inVersionBlock || inDateBlock || inWarningBlock || inBugBlock || inVersionBlock || inDateBlock || inWarningBlock || inBugBlock || inNoteBlock ||
inParBlock || inExceptionBlock || inDeprecatedBlock || inPreBlock || inParBlock || inExceptionBlock || inDeprecatedBlock || inPreBlock ||
inPostBlock || inInvarBlock; inPostBlock || inInvarBlock;
} }
...@@ -657,7 +659,7 @@ static void endBlock() ...@@ -657,7 +659,7 @@ static void endBlock()
} }
outDoc->endDescList(); outDoc->endDescList();
inParamBlock=inRetValBlock=inSeeBlock=inReturnBlock=inAuthorBlock= inParamBlock=inRetValBlock=inSeeBlock=inReturnBlock=inAuthorBlock=
inVersionBlock=inDateBlock=inBugBlock=inWarningBlock= inVersionBlock=inDateBlock=inBugBlock=inNoteBlock=inWarningBlock=
inParBlock=inExceptionBlock=inDeprecatedBlock=inPreBlock=inPostBlock= inParBlock=inExceptionBlock=inDeprecatedBlock=inPreBlock=inPostBlock=
inInvarBlock=FALSE; inInvarBlock=FALSE;
} }
...@@ -899,6 +901,7 @@ TR [tT][rR] ...@@ -899,6 +901,7 @@ TR [tT][rR]
TT [tT][tT] TT [tT][tT]
UL [uU][lL] UL [uU][lL]
VAR [vV][aA][rR] VAR [vV][aA][rR]
DOCPARAM ([a-z_A-Z0-9:\.\-]+)|("\"".*"\"")
%option noyywrap %option noyywrap
...@@ -1039,6 +1042,7 @@ VAR [vV][aA][rR] ...@@ -1039,6 +1042,7 @@ VAR [vV][aA][rR]
%x CopyArgSharp %x CopyArgSharp
%x CopyArgComment %x CopyArgComment
%x CopyArgCommentLine %x CopyArgCommentLine
%x SkipUnionSwitch
%x ReadFuncArgType %x ReadFuncArgType
%x ReadTempArgs %x ReadTempArgs
%x Specialization %x Specialization
...@@ -1050,6 +1054,7 @@ VAR [vV][aA][rR] ...@@ -1050,6 +1054,7 @@ VAR [vV][aA][rR]
%x CopyString %x CopyString
%x CopyRound %x CopyRound
%x CopyCurly %x CopyCurly
%x IDLUnionCase
%% %%
...@@ -1297,7 +1302,25 @@ VAR [vV][aA][rR] ...@@ -1297,7 +1302,25 @@ VAR [vV][aA][rR]
outDoc->writeDescItem(); outDoc->writeDescItem();
} }
} }
<DocScan>{CMD}"pre"[s]?/{BN} { <DocScan>{CMD}"note"[s]?/{BN} {
endArgumentList();
if (!inNoteBlock)
{
if (inBlock()) endBlock();
inNoteBlock=TRUE;
outDoc->startDescList();
outDoc->startBold();
scanString(theTranslator->trNote()+": ");
outDoc->endBold();
outDoc->endDescTitle();
outDoc->writeDescItem();
}
else
{
outDoc->writeDescItem();
}
}
<DocScan>{CMD}"pre"/{BN} {
endArgumentList(); endArgumentList();
if (!inPreBlock) if (!inPreBlock)
{ {
...@@ -1315,7 +1338,7 @@ VAR [vV][aA][rR] ...@@ -1315,7 +1338,7 @@ VAR [vV][aA][rR]
outDoc->writeDescItem(); outDoc->writeDescItem();
} }
} }
<DocScan>{CMD}"post"[s]?/{BN} { <DocScan>{CMD}"post"/{BN} {
endArgumentList(); endArgumentList();
if (!inPostBlock) if (!inPostBlock)
{ {
...@@ -1333,7 +1356,7 @@ VAR [vV][aA][rR] ...@@ -1333,7 +1356,7 @@ VAR [vV][aA][rR]
outDoc->writeDescItem(); outDoc->writeDescItem();
} }
} }
<DocScan>{CMD}"invariant"[s]?/{BN} { <DocScan>{CMD}"invariant"/{BN} {
endArgumentList(); endArgumentList();
if (!inInvarBlock) if (!inInvarBlock)
{ {
...@@ -1516,7 +1539,7 @@ VAR [vV][aA][rR] ...@@ -1516,7 +1539,7 @@ VAR [vV][aA][rR]
BEGIN(DocException); BEGIN(DocException);
} }
<DocScan>"\\capt".* <DocScan>"\\capt".*
<DocParam>([a-z_A-Z0-9:\.\-]+)|("\"".*"\"") { <DocParam>({DOCPARAM}{BN}*","{BN}*)*{DOCPARAM} {
outDoc->startDescTableTitle(); outDoc->startDescTableTitle();
outDoc->startEmphasis(); outDoc->startEmphasis();
outDoc->docify(yytext); outDoc->docify(yytext);
...@@ -1746,7 +1769,7 @@ VAR [vV][aA][rR] ...@@ -1746,7 +1769,7 @@ VAR [vV][aA][rR]
<DocScan>{CMD}"b"{BN}+ { BEGIN( DocBold ); } <DocScan>{CMD}"b"{BN}+ { BEGIN( DocBold ); }
<DocScan>{CMD}"c"{BN}+ { BEGIN( DocCode ); } <DocScan>{CMD}"c"{BN}+ { BEGIN( DocCode ); }
<DocScan>{CMD}"l"{BN}+ <DocScan>{CMD}"l"{BN}+
<DocScan>{CMD}"n" { outDoc->lineBreak(); } <DocScan>"\\n"/[^a-z_A-Z0-9] { outDoc->lineBreak(); }
<DocScan>{CMD}"include"{BN}+ { BEGIN( DocInclude ); } <DocScan>{CMD}"include"{BN}+ { BEGIN( DocInclude ); }
<DocScan>{CMD}"dontinclude"{BN}+ { BEGIN( DocDontInclude ); } <DocScan>{CMD}"dontinclude"{BN}+ { BEGIN( DocDontInclude ); }
<DocScan>{CMD}"skip"{BN}+ { BEGIN( DocSkipKey ); } <DocScan>{CMD}"skip"{BN}+ { BEGIN( DocSkipKey ); }
...@@ -2422,6 +2445,10 @@ VAR [vV][aA][rR] ...@@ -2422,6 +2445,10 @@ VAR [vV][aA][rR]
{ {
BEGIN(CppQuote); BEGIN(CppQuote);
} }
else if (insideIDL && strcmp(yytext,"case")==0)
{
BEGIN(IDLUnionCase);
}
else else
{ {
lineCount(); lineCount();
...@@ -2445,6 +2472,10 @@ VAR [vV][aA][rR] ...@@ -2445,6 +2472,10 @@ VAR [vV][aA][rR]
insideCppQuote=TRUE; insideCppQuote=TRUE;
BEGIN(FindMembers); BEGIN(FindMembers);
} }
<IDLUnionCase>"::"
<IDLUnionCase>":" { BEGIN(FindMembers); }
<IDLUnionCase>\n { yyLineNr++; }
<IDLUnionCase>.
<EndCppQuote>")" { <EndCppQuote>")" {
insideCppQuote=FALSE; insideCppQuote=FALSE;
BEGIN(FindMembers); BEGIN(FindMembers);
...@@ -3581,6 +3612,14 @@ VAR [vV][aA][rR] ...@@ -3581,6 +3612,14 @@ VAR [vV][aA][rR]
BEGIN( ClassVar ); BEGIN( ClassVar );
} }
<ClassVar>{ID} { <ClassVar>{ID} {
if (insideIDL && strcmp(yytext,"switch")==0)
{
// Corba IDL style union
roundCount=0;
BEGIN(SkipUnionSwitch);
}
else
{
if (isTypedef) if (isTypedef)
{ {
// typedefDict.insert(yytext,new QCString(current->name)); // typedefDict.insert(yytext,new QCString(current->name));
...@@ -3595,6 +3634,7 @@ VAR [vV][aA][rR] ...@@ -3595,6 +3634,7 @@ VAR [vV][aA][rR]
current->name = yytext ; current->name = yytext ;
//BEGIN( FindMembers ); //BEGIN( FindMembers );
} }
}
<ClassVar>[(\[] { <ClassVar>[(\[] {
// probably a function anyway // probably a function anyway
unput(*yytext); unput(*yytext);
...@@ -3702,6 +3742,17 @@ VAR [vV][aA][rR] ...@@ -3702,6 +3742,17 @@ VAR [vV][aA][rR]
curlyCount=0; curlyCount=0;
BEGIN( Curly ) ; BEGIN( Curly ) ;
} }
<SkipUnionSwitch>"(" {
roundCount++;
}
<SkipUnionSwitch>")" {
if (--roundCount==0)
{
BEGIN(ClassVar);
}
}
<SkipUnionSwitch>\n { yyLineNr++; }
<SkipUnionSwitch>.
<Comment>{BN}+ { current->program += yytext ; <Comment>{BN}+ { current->program += yytext ;
lineCount() ; lineCount() ;
} }
...@@ -3797,7 +3848,7 @@ VAR [vV][aA][rR] ...@@ -3797,7 +3848,7 @@ VAR [vV][aA][rR]
} }
<JavaDoc>"@" { <JavaDoc>"@" {
unput(*yytext); unput(*yytext);
BEGIN(Doc); BEGIN(ClassDoc);
} }
<JavaDoc>^{B}*"*"+/[^/] { <JavaDoc>^{B}*"*"+/[^/] {
//printf("---> removing %s\n",yytext); //printf("---> removing %s\n",yytext);
...@@ -3820,7 +3871,7 @@ VAR [vV][aA][rR] ...@@ -3820,7 +3871,7 @@ VAR [vV][aA][rR]
current->brief+="."; current->brief+=".";
BEGIN( tmpDocType ); BEGIN( tmpDocType );
} }
<JavaDoc>{CMD}("image"|"author"|"internal"|"version"|"date"|"param"|"exception"|"return"[s]?|"retval"|"bug"|"warning"|"par"|"sa"|"see") { <JavaDoc>{CMD}("image"|"author"|"internal"|"version"|"date"|"param"|"exception"|"return"[s]?|"retval"|"bug"|"warning"|"par"|"sa"|"see"|"pre"|"post"|"invariant"|"note") {
current->doc+=yytext; current->doc+=yytext;
BEGIN( tmpDocType ); BEGIN( tmpDocType );
} }
......
...@@ -553,25 +553,25 @@ class Translator ...@@ -553,25 +553,25 @@ class Translator
* these are for the member sections of a class, struct or union * these are for the member sections of a class, struct or union
*/ */
virtual QCString trPublicMembers() virtual QCString trPublicMembers()
{ return "Public Members"; } { return "Public Methods"; }
virtual QCString trPublicSlots() virtual QCString trPublicSlots()
{ return "Public Slots"; } { return "Public Slots"; }
virtual QCString trSignals() virtual QCString trSignals()
{ return "Signals"; } { return "Signals"; }
virtual QCString trStaticPublicMembers() virtual QCString trStaticPublicMembers()
{ return "Static Public Members"; } { return "Static Public Methods"; }
virtual QCString trProtectedMembers() virtual QCString trProtectedMembers()
{ return "Protected Members"; } { return "Protected Methods"; }
virtual QCString trProtectedSlots() virtual QCString trProtectedSlots()
{ return "Protected Slots"; } { return "Protected Slots"; }
virtual QCString trStaticProtectedMembers() virtual QCString trStaticProtectedMembers()
{ return "Static Protected Members"; } { return "Static Protected Methods"; }
virtual QCString trPrivateMembers() virtual QCString trPrivateMembers()
{ return "Private Members"; } { return "Private Methods"; }
virtual QCString trPrivateSlots() virtual QCString trPrivateSlots()
{ return "Private Slots"; } { return "Private Slots"; }
virtual QCString trStaticPrivateMembers() virtual QCString trStaticPrivateMembers()
{ return "Static Private Members"; } { return "Static Private Methods"; }
/*! \endmgroup */ /*! \endmgroup */
/*! this function is used to produce a comma-separated list of items. /*! this function is used to produce a comma-separated list of items.
...@@ -815,6 +815,47 @@ class Translator ...@@ -815,6 +815,47 @@ class Translator
{ {
return "Page Index"; return "Page Index";
} }
virtual QCString trNote()
{
return "Note";
}
virtual QCString trPublicTypes()
{
return "Public Types";
}
virtual QCString trPublicAttribs()
{
return "Public Attributes";
}
virtual QCString trStaticPublicAttribs()
{
return "Static Public Attributes";
}
virtual QCString trProtectedTypes()
{
return "Protected Types";
}
virtual QCString trProtectedAttribs()
{
return "Protected Attributes";
}
virtual QCString trStaticProtectedAttribs()
{
return "Static Protected Attributes";
}
virtual QCString trPrivateTypes()
{
return "Private Types";
}
virtual QCString trPrivateAttribs()
{
return "Private Attributes";
}
virtual QCString trStaticPrivateAttribs()
{
return "Static Private Attributes";
}
}; };
#endif #endif
This diff is collapsed.
...@@ -34,6 +34,7 @@ ...@@ -34,6 +34,7 @@
#include "htmlhelp.h" #include "htmlhelp.h"
#include "example.h" #include "example.h"
#include "version.h" #include "version.h"
#include "groupdef.h"
// an inheritance tree of depth of 100000 should be enough for everyone :-) // an inheritance tree of depth of 100000 should be enough for everyone :-)
const int maxInheritanceDepth = 100000; const int maxInheritanceDepth = 100000;
...@@ -268,6 +269,7 @@ void linkifyText(OutputList &ol,const char *scName,const char *name,const char * ...@@ -268,6 +269,7 @@ void linkifyText(OutputList &ol,const char *scName,const char *name,const char *
FileDef *fd=0; FileDef *fd=0;
MemberDef *md=0; MemberDef *md=0;
NamespaceDef *nd=0; NamespaceDef *nd=0;
GroupDef *gd=0;
QCString scopeName=scName; QCString scopeName=scName;
QCString searchName=name; QCString searchName=name;
...@@ -314,14 +316,14 @@ void linkifyText(OutputList &ol,const char *scName,const char *name,const char * ...@@ -314,14 +316,14 @@ void linkifyText(OutputList &ol,const char *scName,const char *name,const char *
//if (!found) printf("Trying to link %s in %s\n",word.data(),scName); //if (!found) printf("Trying to link %s in %s\n",word.data(),scName);
if (!found && if (!found &&
getDefs(scName,word,0,md,cd,fd,nd) && getDefs(scName,word,0,md,cd,fd,nd,gd) &&
(md->isTypedef() || md->isEnumerate() || md->isReference()) && (md->isTypedef() || md->isEnumerate() || md->isReference()) &&
md->isLinkable() md->isLinkable()
) )
{ {
//printf("Found ref\n"); //printf("Found ref\n");
Definition *d=0; Definition *d=0;
if (cd) d=cd; else if (nd) d=nd; else d=fd; if (cd) d=cd; else if (nd) d=nd; else if (fd) d=fd; else d=gd;
if (d && d->isLinkable()) if (d && d->isLinkable())
{ {
result.writeObjectLink(d->getReference(),d->getOutputFileBase(), result.writeObjectLink(d->getReference(),d->getOutputFileBase(),
...@@ -527,7 +529,7 @@ void writeQuickLinks(OutputList &ol,bool compact,bool ext) ...@@ -527,7 +529,7 @@ void writeQuickLinks(OutputList &ol,bool compact,bool ext)
parseText(ol,theTranslator->trCompoundList()); parseText(ol,theTranslator->trCompoundList());
ol.endQuickIndexItem(); ol.endQuickIndexItem();
} }
if (documentedFiles>0) if (documentedHtmlFiles>0)
{ {
if (!compact) ol.writeListItem(); if (!compact) ol.writeListItem();
ol.startQuickIndexItem(extLink,absPath+"files.html"); ol.startQuickIndexItem(extLink,absPath+"files.html");
...@@ -723,7 +725,7 @@ QCString dateToString(bool includeTime) ...@@ -723,7 +725,7 @@ QCString dateToString(bool includeTime)
// recursive function that returns the number of branches in the // recursive function that returns the number of branches in the
// inheritance tree that the base class `bcd' is below the class `cd' // inheritance tree that the base class `bcd' is below the class `cd'
static int minClassDistance(ClassDef *cd,ClassDef *bcd,int level=0) int minClassDistance(ClassDef *cd,ClassDef *bcd,int level)
{ {
if (cd==bcd) return level; if (cd==bcd) return level;
BaseClassListIterator bcli(*cd->baseClasses()); BaseClassListIterator bcli(*cd->baseClasses());
...@@ -1190,9 +1192,10 @@ void mergeArguments(ArgumentList *srcAl,ArgumentList *dstAl) ...@@ -1190,9 +1192,10 @@ void mergeArguments(ArgumentList *srcAl,ArgumentList *dstAl)
*/ */
bool getDefs(const QCString &scName,const QCString &memberName, bool getDefs(const QCString &scName,const QCString &memberName,
const char *args, const char *args,
MemberDef *&md, ClassDef *&cd, FileDef *&fd,NamespaceDef *&nd) MemberDef *&md,
ClassDef *&cd, FileDef *&fd, NamespaceDef *&nd, GroupDef *&gd)
{ {
fd=0, md=0, cd=0, nd=0; fd=0, md=0, cd=0, nd=0, gd=0;
if (memberName.isEmpty()) return FALSE; /* empty name => nothing to link */ if (memberName.isEmpty()) return FALSE; /* empty name => nothing to link */
QCString scopeName=scName.copy(); QCString scopeName=scName.copy();
...@@ -1327,7 +1330,7 @@ bool getDefs(const QCString &scName,const QCString &memberName, ...@@ -1327,7 +1330,7 @@ bool getDefs(const QCString &scName,const QCString &memberName,
// unknown or undocumented scope // unknown or undocumented scope
} }
else // maybe an namespace or file member ? else // maybe an namespace, file or group member ?
{ {
//printf("Testing for global function scopeName=`%s' mScope=`%s' :: mName=`%s'\n", //printf("Testing for global function scopeName=`%s' mScope=`%s' :: mName=`%s'\n",
// scopeName.data(),mScope.data(),mName.data()); // scopeName.data(),mScope.data(),mName.data());
...@@ -1415,11 +1418,17 @@ bool getDefs(const QCString &scName,const QCString &memberName, ...@@ -1415,11 +1418,17 @@ bool getDefs(const QCString &scName,const QCString &memberName,
{ {
if (md->isLinkable()) if (md->isLinkable())
{ {
//printf("md->name()=`%s' md->args=`%s'\n",md->name().data(),args);
fd=md->getFileDef(); fd=md->getFileDef();
if (fd && fd->isLinkable()) gd=md->groupDef();
//printf("md->name()=`%s' md->args=`%s' fd=%p gd=%p\n",
// md->name().data(),args,fd,gd);
bool inGroup=FALSE;
if ((fd && fd->isLinkable()) ||
(inGroup=(gd && gd->isLinkable()))
)
{ {
//printf("fd->name()=`%s'\n",fd->name().data()); if (inGroup) fd=0;
//printf("fd=%p gd=%p inGroup=`%d' args=`%s'\n",fd,gd,inGroup,args);
bool match=TRUE; bool match=TRUE;
ArgumentList *argList=0; ArgumentList *argList=0;
if (args && !md->isDefine()) if (args && !md->isDefine())
...@@ -1429,7 +1438,11 @@ bool getDefs(const QCString &scName,const QCString &memberName, ...@@ -1429,7 +1438,11 @@ bool getDefs(const QCString &scName,const QCString &memberName,
match=matchArguments(md->argumentList(),argList); match=matchArguments(md->argumentList(),argList);
delete argList; argList=0; delete argList; argList=0;
} }
if (match) return TRUE; if (match)
{
//printf("Found match!\n");
return TRUE;
}
} }
} }
md=mn->next(); md=mn->next();
...@@ -1445,8 +1458,13 @@ bool getDefs(const QCString &scName,const QCString &memberName, ...@@ -1445,8 +1458,13 @@ bool getDefs(const QCString &scName,const QCString &memberName,
{ {
//printf("md->name()=`%s'\n",md->name().data()); //printf("md->name()=`%s'\n",md->name().data());
fd=md->getFileDef(); fd=md->getFileDef();
if (fd && fd->isLinkable()) gd=md->groupDef();
bool inGroup=FALSE;
if ((fd && fd->isLinkable()) |+
(inGroup=(gd && gd->isLinkable()))
)
{ {
if (inGroup) fd=0;
return TRUE; return TRUE;
} }
} }
...@@ -1625,7 +1643,7 @@ bool generateRef(OutputList &ol,const char *scName, ...@@ -1625,7 +1643,7 @@ bool generateRef(OutputList &ol,const char *scName,
// scopeStr.data(),nameStr.data(),argsStr.data()); // scopeStr.data(),nameStr.data(),argsStr.data());
// check if nameStr is a member or global. // check if nameStr is a member or global.
if (getDefs(scopeStr,nameStr,argsStr,md,cd,fd,nd)) if (getDefs(scopeStr,nameStr,argsStr,md,cd,fd,nd,gd))
{ {
//printf("after getDefs nd=%p\n",nd); //printf("after getDefs nd=%p\n",nd);
QCString anchor = md->isLinkable() ? md->anchor() : 0; QCString anchor = md->isLinkable() ? md->anchor() : 0;
...@@ -1656,6 +1674,15 @@ bool generateRef(OutputList &ol,const char *scName, ...@@ -1656,6 +1674,15 @@ bool generateRef(OutputList &ol,const char *scName,
cName=fd->name(); cName=fd->name();
aName=md->anchor(); aName=md->anchor();
} }
else if (gd)
{
//printf("addGroupLink(%s,%s,%s)\n",fd->getOutputFileBase().data(),anchor.data(),
// gd->name().data());
ol.writeObjectLink(gd->getReference(),gd->getOutputFileBase(),
anchor,linkText.stripWhiteSpace());
cName=gd->name();
aName=md->anchor();
}
else // should not be reached else // should not be reached
{ {
//printf("add no link fd=cd=0\n"); //printf("add no link fd=cd=0\n");
......
...@@ -33,6 +33,7 @@ class MemberDef; ...@@ -33,6 +33,7 @@ class MemberDef;
class ExampleList; class ExampleList;
class ClassList; class ClassList;
class BaseClassList; class BaseClassList;
class GroupDef;
extern void setAnchors(char id,MemberList *ml); extern void setAnchors(char id,MemberList *ml);
extern QCString fileToString(const char *name); extern QCString fileToString(const char *name);
...@@ -40,8 +41,10 @@ extern QCString dateToString(bool); ...@@ -40,8 +41,10 @@ extern QCString dateToString(bool);
extern void linkifyText(OutputList &ol,const char *clName,const char *name, extern void linkifyText(OutputList &ol,const char *clName,const char *name,
const char *text); const char *text);
extern bool getDefs(const QCString &scopeName,const QCString &memberName, extern bool getDefs(const QCString &scopeName,const QCString &memberName,
const char *, MemberDef *&md, ClassDef *&cd,FileDef *&fd, const char *, MemberDef *&md,
NamespaceDef *&nd); ClassDef *&cd,FileDef *&fd,
NamespaceDef *&nd,GroupDef *&gd
);
extern bool generateRef(OutputList &ol,const char *, extern bool generateRef(OutputList &ol,const char *,
const char *,bool inSeeBlock,const char * =0); const char *,bool inSeeBlock,const char * =0);
extern bool generateLink(OutputList &ol,const char *, extern bool generateLink(OutputList &ol,const char *,
...@@ -84,5 +87,6 @@ int getPrefixIndex(const QCString &name); ...@@ -84,5 +87,6 @@ int getPrefixIndex(const QCString &name);
QCString removeAnnonymousScopes(const QCString &s); QCString removeAnnonymousScopes(const QCString &s);
void initClassHierarchy(ClassList *cl); void initClassHierarchy(ClassList *cl);
bool hasVisibleRoot(BaseClassList *bcl); bool hasVisibleRoot(BaseClassList *bcl);
int minClassDistance(ClassDef *cd,ClassDef *bcd,int level=0);
#endif #endif
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment