diff options
-rw-r--r-- | src/classdef.cpp | 4 | ||||
-rw-r--r-- | src/dirdef.cpp | 6 | ||||
-rw-r--r-- | src/filedef.cpp | 6 | ||||
-rw-r--r-- | src/groupdef.cpp | 20 | ||||
-rw-r--r-- | src/mangen.cpp | 2 | ||||
-rw-r--r-- | src/namespacedef.cpp | 4 | ||||
-rw-r--r-- | src/pagedef.cpp | 10 |
7 files changed, 43 insertions, 9 deletions
diff --git a/src/classdef.cpp b/src/classdef.cpp index c987d98..51fb8c6 100644 --- a/src/classdef.cpp +++ b/src/classdef.cpp @@ -954,6 +954,10 @@ void ClassDef::writeBriefDescription(OutputList &ol,bool exampleFlag) if (hasBriefDescription()) { ol.startParagraph(); + ol.pushGeneratorState(); + ol.disableAllBut(OutputGenerator::Man); + ol.writeString(" - "); + ol.popGeneratorState(); ol.generateDoc(briefFile(),briefLine(),this,0, briefDescription(),TRUE,FALSE,0,TRUE,FALSE); ol.pushGeneratorState(); diff --git a/src/dirdef.cpp b/src/dirdef.cpp index d6f4f55..0a63c1e 100644 --- a/src/dirdef.cpp +++ b/src/dirdef.cpp @@ -170,13 +170,17 @@ void DirDef::writeDetailedDescription(OutputList &ol,const QCString &title) void DirDef::writeBriefDescription(OutputList &ol) { - if (!briefDescription().isEmpty() && Config_getBool(BRIEF_MEMBER_DESC)) + if (hasBriefDescription()) { DocRoot *rootNode = validatingParseDoc( briefFile(),briefLine(),this,0,briefDescription(),TRUE,FALSE); if (rootNode && !rootNode->isEmpty()) { ol.startParagraph(); + ol.pushGeneratorState(); + ol.disableAllBut(OutputGenerator::Man); + ol.writeString(" - "); + ol.popGeneratorState(); ol.writeDoc(rootNode,this,0); ol.pushGeneratorState(); ol.disable(OutputGenerator::RTF); diff --git a/src/filedef.cpp b/src/filedef.cpp index 0a1e6e2..9c04dc8 100644 --- a/src/filedef.cpp +++ b/src/filedef.cpp @@ -365,7 +365,7 @@ void FileDef::writeDetailedDescription(OutputList &ol,const QCString &title) void FileDef::writeBriefDescription(OutputList &ol) { - if (!briefDescription().isEmpty() && Config_getBool(BRIEF_MEMBER_DESC)) + if (hasBriefDescription()) { DocRoot *rootNode = validatingParseDoc(briefFile(),briefLine(),this,0, briefDescription(),TRUE,FALSE,0,TRUE,FALSE); @@ -373,6 +373,10 @@ void FileDef::writeBriefDescription(OutputList &ol) if (rootNode && !rootNode->isEmpty()) { ol.startParagraph(); + ol.pushGeneratorState(); + ol.disableAllBut(OutputGenerator::Man); + ol.writeString(" - "); + ol.popGeneratorState(); ol.writeDoc(rootNode,this,0); ol.pushGeneratorState(); ol.disable(OutputGenerator::RTF); diff --git a/src/groupdef.cpp b/src/groupdef.cpp index 6b6d659..ccfa0df 100644 --- a/src/groupdef.cpp +++ b/src/groupdef.cpp @@ -711,6 +711,7 @@ void GroupDef::writeDetailedDescription(OutputList &ol,const QCString &title) || !documentation().isEmpty() || !inbodyDocumentation().isEmpty() ) { + ol.pushGeneratorState(); if (pageDict->count()!=countMembers()) // not only pages -> classical layout { ol.pushGeneratorState(); @@ -721,10 +722,15 @@ void GroupDef::writeDetailedDescription(OutputList &ol,const QCString &title) ol.disableAllBut(OutputGenerator::Html); ol.writeAnchor(0,"details"); ol.popGeneratorState(); - ol.startGroupHeader(); - ol.parseText(title); - ol.endGroupHeader(); } + else + { + ol.disableAllBut(OutputGenerator::Man); // always print title for man page + } + ol.startGroupHeader(); + ol.parseText(title); + ol.endGroupHeader(); + ol.popGeneratorState(); // repeat brief description if (!briefDescription().isEmpty() && Config_getBool(REPEAT_BRIEF)) @@ -762,13 +768,17 @@ void GroupDef::writeDetailedDescription(OutputList &ol,const QCString &title) void GroupDef::writeBriefDescription(OutputList &ol) { - if (!briefDescription().isEmpty() && Config_getBool(BRIEF_MEMBER_DESC)) + if (hasBriefDescription()) { DocRoot *rootNode = validatingParseDoc(briefFile(),briefLine(),this,0, briefDescription(),TRUE,FALSE,0,TRUE,FALSE); if (rootNode && !rootNode->isEmpty()) { ol.startParagraph(); + ol.pushGeneratorState(); + ol.disableAllBut(OutputGenerator::Man); + ol.writeString(" - "); + ol.popGeneratorState(); ol.writeDoc(rootNode,this,0); ol.pushGeneratorState(); ol.disable(OutputGenerator::RTF); @@ -789,6 +799,7 @@ void GroupDef::writeBriefDescription(OutputList &ol) } delete rootNode; } + ol.writeSynopsis(); } void GroupDef::writeGroupGraph(OutputList &ol) @@ -1091,7 +1102,6 @@ void GroupDef::writeDocumentation(OutputList &ol) ol.pushGeneratorState(); ol.disableAllBut(OutputGenerator::Man); ol.endTitleHead(getOutputFileBase(),name()); - ol.parseText(title); ol.popGeneratorState(); ol.endHeaderSection(); ol.startContents(); diff --git a/src/mangen.cpp b/src/mangen.cpp index 963f66c..2f4d3ae 100644 --- a/src/mangen.cpp +++ b/src/mangen.cpp @@ -191,7 +191,7 @@ void ManGenerator::endTitleHead(const char *,const char *name) t << ".ad l" << endl; t << ".nh" << endl; t << ".SH NAME" << endl; - t << name << " \\- "; + t << name; firstCol=FALSE; paragraph=TRUE; inHeader=TRUE; diff --git a/src/namespacedef.cpp b/src/namespacedef.cpp index c04fa7b..29f68a4 100644 --- a/src/namespacedef.cpp +++ b/src/namespacedef.cpp @@ -408,6 +408,10 @@ void NamespaceDef::writeBriefDescription(OutputList &ol) if (rootNode && !rootNode->isEmpty()) { ol.startParagraph(); + ol.pushGeneratorState(); + ol.disableAllBut(OutputGenerator::Man); + ol.writeString(" - "); + ol.popGeneratorState(); ol.writeDoc(rootNode,this,0); ol.pushGeneratorState(); ol.disable(OutputGenerator::RTF); diff --git a/src/pagedef.cpp b/src/pagedef.cpp index 6146a3c..1210305 100644 --- a/src/pagedef.cpp +++ b/src/pagedef.cpp @@ -229,12 +229,20 @@ void PageDef::writePageDocumentation(OutputList &ol) } ol.startTextBlock(); + QCString docStr = documentation()+inbodyDocumentation(); + if (!docStr.isEmpty()) + { + ol.pushGeneratorState(); + ol.disableAllBut(OutputGenerator::Man); + ol.writeString(" - "); + ol.popGeneratorState(); + } ol.generateDoc( docFile(), // fileName docLine(), // startLine this, // context 0, // memberdef - documentation()+inbodyDocumentation(), // docStr + docStr, // docStr TRUE, // index words FALSE // not an example ); |