diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/config.l | 20 | ||||
-rw-r--r-- | src/defargs.l | 1 | ||||
-rw-r--r-- | src/diagram.cpp | 2 | ||||
-rw-r--r-- | src/doc.l | 66 | ||||
-rw-r--r-- | src/dot.cpp | 8 | ||||
-rw-r--r-- | src/doxygen.cpp | 48 | ||||
-rw-r--r-- | src/formula.cpp | 2 | ||||
-rw-r--r-- | src/index.cpp | 26 | ||||
-rw-r--r-- | src/mangen.cpp | 61 | ||||
-rw-r--r-- | src/memberdef.cpp | 39 | ||||
-rw-r--r-- | src/memberdef.h | 3 | ||||
-rw-r--r-- | src/memberlist.cpp | 12 | ||||
-rw-r--r-- | src/rtfgen.cpp | 2 | ||||
-rw-r--r-- | src/scanner.l | 6 | ||||
-rw-r--r-- | src/translator.h | 2 | ||||
-rw-r--r-- | src/translator_adapter.h | 17 | ||||
-rw-r--r-- | src/translator_br.h | 159 | ||||
-rw-r--r-- | src/translator_cz.h | 8 | ||||
-rw-r--r-- | src/translator_de.h | 8 | ||||
-rw-r--r-- | src/translator_dk.h | 2 | ||||
-rw-r--r-- | src/translator_es.h | 13 | ||||
-rw-r--r-- | src/translator_it.h | 2 | ||||
-rw-r--r-- | src/translator_nl.h | 188 | ||||
-rw-r--r-- | src/translator_sk.h | 13 | ||||
-rw-r--r-- | src/util.cpp | 20 |
25 files changed, 542 insertions, 186 deletions
diff --git a/src/config.l b/src/config.l index 061aa93..dd704b0 100644 --- a/src/config.l +++ b/src/config.l @@ -453,6 +453,7 @@ static void readIncludeFile(const char *incName) break; case ConfigOption::O_Bool: s = ((ConfigBool *)option)->valueStringRef(); + s->resize(0); BEGIN(GetString); break; } @@ -1212,28 +1213,31 @@ void Config::create() "documentation generated by doxygen is written. Doxygen will use this \n" "information to generate all constant output in the proper language. \n" "The default language is English, other supported languages are: \n" - "Dutch, French, Italian, Czech, Swedish, German, Finnish, Japanese, \n" - "Korean, Hungarian, Norwegian, Spanish, Romanian, Russian, Croatian, \n" - "Polish, Portuguese, Brazilian and Slovene.\n", - "English" + "Brazilian, Chinese, Croatian, Czech, Danish, Dutch, Finnish, French, \n" + "German, Hungarian, Italian, Japanese, Korean, Norwegian, Polish, \n" + "Portuguese, Romanian, Russian, Slovak, Slovene, Spanish and Swedish.\n", + "English" ); ce->addValue("Brazilian"); + ce->addValue("Chinese"); ce->addValue("Croatian"); ce->addValue("Czech"); + ce->addValue("Danish"); ce->addValue("Dutch"); ce->addValue("English"); - ce->addValue("French"); ce->addValue("Finnish"); + ce->addValue("French"); ce->addValue("German"); ce->addValue("Hungarian"); ce->addValue("Italian"); ce->addValue("Japanese"); ce->addValue("Korean"); ce->addValue("Norwegian"); - ce->addValue("Romanian"); - ce->addValue("Russian"); ce->addValue("Polish"); ce->addValue("Portuguese"); + ce->addValue("Romanian"); + ce->addValue("Russian"); + ce->addValue("Slovak"); ce->addValue("Slovene"); ce->addValue("Spanish"); ce->addValue("Swedish"); @@ -1857,7 +1861,7 @@ void Config::create() "If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated \n" "will contain hyperlink fields. The RTF file will \n" "contain links (just like the HTML output) instead of page references. \n" - "This makes the output suitable for online browsing using WORD or other. \n" + "This makes the output suitable for online browsing using WORD or other \n" "programs which support those fields. \n" "Note: wordpad (write) and others do not support links. \n", FALSE diff --git a/src/defargs.l b/src/defargs.l index e04d2ec..68eaa91 100644 --- a/src/defargs.l +++ b/src/defargs.l @@ -272,7 +272,6 @@ ID [a-z_A-Z][a-z_A-Z0-9]* a->array = removeRedundantWhiteSpace(g_curArgArray); a->defval = g_curArgDefValue.copy(); a->docs = g_curArgDocs.stripWhiteSpace(); - a->docs += "\n"; // for commands that need termination in doc.l (like \verbatim) //printf("Argument `%s' `%s' adding docs=`%s'\n",a->type.data(),a->name.data(),a->docs.data()); g_argList->append(a); } diff --git a/src/diagram.cpp b/src/diagram.cpp index aeb78df..e50766e 100644 --- a/src/diagram.cpp +++ b/src/diagram.cpp @@ -1008,7 +1008,7 @@ void ClassDiagram::writeFigure(QTextStream &output,const char *path, //printf("writeEPS() rows=%d cols=%d\n",rows,cols); - // generate EPS header and postscipt variables and procedures + // generate EPS header and postscript variables and procedures t << "%!PS-Adobe-2.0 EPSF-2.0\n"; t << "%%Title: ClassName\n"; @@ -817,6 +817,7 @@ static int yyread(char *buf,int max_size) CMD ("\\"|"@") BN [ \t\n\r] BL [ \t\r]*"\n" +BSEP [ \t\r]*([ \t\r]|"\n")({BL}{0,100}) B [ \t] BS ^(({B}*"//")?)(({B}*"*"+)?){B}* FILESCHAR [a-z_A-Z0-9\\:\\\/\-\+] @@ -946,7 +947,11 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG}) addListItemMarker(yytext+1,dashPos,isEnumerated); } <DocScan,Text>"©" { outDoc->writeCopyright(); } -<DocScan,Text>""" { outDoc->writeQuote(); } +<DocScan,Text>"<" { outDoc->docify("<"); } +<DocScan,Text>">" { outDoc->docify(">"); } +<DocScan,Text>"&" { outDoc->docify("&"); } +<DocScan,Text>"'" { outDoc->docify("'"); } +<DocScan,Text>""" { outDoc->docify("\""); } <DocScan,Text>"&"[AEIOUYaeiouy]"uml;" { outDoc->writeUmlaut(yytext[1]); } <DocScan,Text>"&"[AEIOUYaeiouy]"acute;" { outDoc->writeAcute(yytext[1]); } <DocScan,Text>"&"[AEIOUaeiou]"grave;" { outDoc->writeGrave(yytext[1]); } @@ -1115,7 +1120,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG}) } BEGIN(DocPar); } -<DocPar>[^\n]*{BN}+ { +<DocPar>[^\n]*{BSEP} { QCString title=QCString(yytext).stripWhiteSpace(); bool b = inBlock(); if (!title.isEmpty()) @@ -1137,7 +1142,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG}) } BEGIN(DocScan); } -<DocScan>{CMD}"warning"{BN}+ { +<DocScan>{CMD}"warning"{BSEP} { endArgumentList(); if (!inWarningBlock) { @@ -1156,7 +1161,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG}) outDoc->writeDescItem(); } } -<DocScan>{CMD}"remark"[s]?{BN}+ { +<DocScan>{CMD}"remark"[s]?{BSEP} { endArgumentList(); if (!inRemarkBlock) { @@ -1175,7 +1180,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG}) outDoc->writeDescItem(); } } -<DocScan>{CMD}"attention"{BN}+ { +<DocScan>{CMD}"attention"{BSEP} { endArgumentList(); if (!inAttentionBlock) { @@ -1194,28 +1199,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG}) outDoc->writeDescItem(); } } - /* -<DocScan>{CMD}"bug"[s]?{BN}+ { - endArgumentList(); - if (!inBugBlock) - { - if (inBlock()) endBlock(); - inBugBlock=TRUE; - currentListIndent.push("D"); - outDoc->startDescList(); - outDoc->startBold(); - scanString(theTranslator->trBugsAndLimitations()+": "); - outDoc->endBold(); - outDoc->endDescTitle(); - outDoc->writeDescItem(); - } - else - { - outDoc->writeDescItem(); - } - } - */ -<DocScan>{CMD}"note"[s]?{BN}+ { +<DocScan>{CMD}"note"[s]?{BSEP} { endArgumentList(); if (!inNoteBlock) { @@ -1234,7 +1218,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG}) outDoc->writeDescItem(); } } -<DocScan>{CMD}"pre"{BN}+ { +<DocScan>{CMD}"pre"{BSEP} { endArgumentList(); if (!inPreBlock) { @@ -1253,7 +1237,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG}) outDoc->writeDescItem(); } } -<DocScan>{CMD}"post"{BN}+ { +<DocScan>{CMD}"post"{BSEP} { endArgumentList(); if (!inPostBlock) { @@ -1272,7 +1256,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG}) outDoc->writeDescItem(); } } -<DocScan>{CMD}"invariant"{BN}+ { +<DocScan>{CMD}"invariant"{BSEP} { endArgumentList(); if (!inInvarBlock) { @@ -1291,7 +1275,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG}) outDoc->writeDescItem(); } } -<DocScan>{CMD}"version"{BN}+ { +<DocScan>{CMD}"version"{BSEP} { endArgumentList(); if (!inVersionBlock) { @@ -1310,7 +1294,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG}) outDoc->writeDescItem(); } } -<DocScan>{CMD}"since"{BN}+ { +<DocScan>{CMD}"since"{BSEP} { endArgumentList(); if (!inSinceBlock) { @@ -1329,7 +1313,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG}) outDoc->writeDescItem(); } } -<DocScan>{CMD}"date"{BN}+ { +<DocScan>{CMD}"date"{BSEP} { endArgumentList(); if (!inDateBlock) { @@ -1414,7 +1398,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG}) currentListIndent.pop(); } } -<DocScan>{CMD}"deprecated"{BN}+ { +<DocScan>{CMD}"deprecated"{BSEP} { endArgumentList(); if (!inDeprecatedBlock) { @@ -1452,7 +1436,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG}) outDoc->endDescList(); currentListIndent.pop(); } -<DocScan>{CMD}"author"[s]?{BN}+ { +<DocScan>{CMD}"author"[s]?{BSEP} { endArgumentList(); if (!inAuthorBlock) { @@ -1472,7 +1456,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG}) outDoc->docify(", "); } } -<DocScan>{CMD}("return"([s])?|"result"){BN}+ { +<DocScan>{CMD}("return"([s])?|"result"){BSEP} { endArgumentList(); if (!inReturnBlock) { @@ -1487,7 +1471,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG}) outDoc->writeDescItem(); } } -<DocScan>{CMD}("sa"|"see"){BN}+ { +<DocScan>{CMD}("sa"|"see"){BSEP} { endArgumentList(); if (!inSeeBlock) { @@ -1506,7 +1490,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG}) outDoc->docify(", "); } } -<DocScan>(({B}*"\n"){2,}{B}*)?{CMD}"param"{BN}+ { +<DocScan>(({B}*"\n"){2,}{B}*)?{CMD}"param"{BSEP} { QCString t=yytext; if (t.contains('\n')>1 && insideItemList) { @@ -1532,7 +1516,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG}) } BEGIN(DocParam); } -<DocScan>(({B}*"\n"){2,}{B}*)?{CMD}"retval"{BN}+ { +<DocScan>(({B}*"\n"){2,}{B}*)?{CMD}"retval"{BSEP} { QCString t=yytext; if (t.contains('\n')>1 && insideItemList) { @@ -1558,7 +1542,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG}) } BEGIN(DocParam); } -<DocScan>(({B}*"\n"){2,}{B}*)?{CMD}("exception"|"throw")s?{BN}+ { +<DocScan>(({B}*"\n"){2,}{B}*)?{CMD}("exception"|"throw")s?{BSEP} { QCString t=yytext; if (t.contains('\n')>1 && insideItemList) { @@ -1585,7 +1569,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG}) BEGIN(DocException); } <DocScan>"\\capt".* -<DocParam>({DOCPARAM}{BN}*","{BN}*)*{DOCPARAM}{BN}* { +<DocParam>({DOCPARAM}{BN}*","{BN}*)*{DOCPARAM}{BSEP}* { outDoc->startDescTableTitle(); outDoc->startEmphasis(); outDoc->docify(substitute(yytext,"\"","").stripWhiteSpace()); diff --git a/src/dot.cpp b/src/dot.cpp index 69dc041..d5b6b96 100644 --- a/src/dot.cpp +++ b/src/dot.cpp @@ -685,7 +685,7 @@ void DotGfxHierarchyTable::writeGraph(QTextStream &out,const char *path) err("Error: Output dir %s does not exist!\n",path); exit(1); } QCString oldDir = convertToQCString(QDir::currentDirPath()); - // goto the html output directory (i.e. path) + // go to the html output directory (i.e. path) QDir::setCurrent(d.absPath()); QDir thisDir; @@ -1263,7 +1263,7 @@ void DotClassGraph::writeGraph(QTextStream &out, err("Error: Output dir %s does not exist!\n",path); exit(1); } QCString oldDir = convertToQCString(QDir::currentDirPath()); - // goto the html output directory (i.e. path) + // go to the html output directory (i.e. path) QDir::setCurrent(d.absPath()); QDir thisDir; @@ -1474,7 +1474,7 @@ void DotInclDepGraph::writeGraph(QTextStream &out, err("Error: Output dir %s does not exist!\n",path); exit(1); } QCString oldDir = convertToQCString(QDir::currentDirPath()); - // goto the html output directory (i.e. path) + // go to the html output directory (i.e. path) QDir::setCurrent(d.absPath()); QDir thisDir; @@ -1615,7 +1615,7 @@ void generateGraphLegend(const char *path) err("Error: Output dir %s does not exist!\n",path); exit(1); } QCString oldDir = convertToQCString(QDir::currentDirPath()); - // goto the html output directory (i.e. path) + // go to the html output directory (i.e. path) QDir::setCurrent(d.absPath()); // run dot to generate the a .gif image from the graph diff --git a/src/doxygen.cpp b/src/doxygen.cpp index 1ae907e..070a088 100644 --- a/src/doxygen.cpp +++ b/src/doxygen.cpp @@ -1204,6 +1204,7 @@ static void findUsingDeclarations(Entry *root) } else if (fd) { + //printf("Inside file %s\n",nd->name().data()); fd->addUsingDeclaration(usingCd); } } @@ -3231,6 +3232,35 @@ static void substituteTemplateArgNames(ArgumentList *src, } +static QCString mergeScopes(const QCString &leftScope,const QCString &rightScope) +{ + // case leftScope=="A" rightScope=="A::B" => result = "A::B" + if (leftScopeMatch(rightScope,leftScope)) return rightScope; + QCString result; + int i=0,p=leftScope.length(); + + // case leftScope=="A::B" rightScope=="B::C" => result = "A::B::C" + // case leftScope=="A::B" rightScope=="B" => result = "A::B" + bool found=FALSE; + while ((i=leftScope.findRev("::",p))!=-1) + { + if (leftScopeMatch(rightScope,leftScope.right(leftScope.length()-i-2))) + { + result = leftScope.left(i+2)+rightScope; + found=TRUE; + } + p=i-1; + } + if (found) return result; + + // case leftScope=="A" rightScope=="B" => result = "A::B" + result=leftScope.copy(); + if (!result.isEmpty() && !rightScope.isEmpty()) result+="::"; + result+=rightScope; + return result; +} + + /*! This function tries to find a member (in a documented class/file/namespace) * that corresponds to the function/variable declaration given in \a funcDecl. * @@ -3366,11 +3396,17 @@ static void findMember(Entry *root, scopeName=related.copy(); } + if (related.isEmpty() && root->parent && !root->parent->name.isEmpty()) + { + scopeName = mergeScopes(root->parent->name,scopeName); + } + // split scope into a namespace and a class part extractNamespaceName(scopeName,className,namespaceName); //printf("scopeName=`%s' className=`%s' namespaceName=`%s'\n", // scopeName.data(),className.data(),namespaceName.data()); +#if 0 if (related.isEmpty() && root->parent && !root->parent->name.isEmpty() @@ -3423,6 +3459,7 @@ static void findMember(Entry *root, //printf("3. scopeName=`%s'\n",scopeName.data()); //printf("result: scope=%s\n",scopeName.data()); } +#endif namespaceName=removeAnonymousScopes(namespaceName); //printf("namespaceName=`%s' className=`%s'\n",namespaceName.data(),className.data()); @@ -3691,13 +3728,18 @@ static void findMember(Entry *root, bool ambig; FileDef *fd=findFileDef(Doxygen::inputNameDict,root->fileName,ambig); // list of namespaces using in the file that this member definition is part of - NamespaceList *nl = fd ? fd->getUsedNamespaces() : 0; - ClassList *cl = fd ? fd->getUsedClasses() : 0; + NamespaceList *nl = 0; + if (nd) nl = nd->getUsedNamespaces(); + else if (fd) nl = fd->getUsedNamespaces(); + ClassList *cl = 0; + if (nd) cl = nd->getUsedClasses(); + else if (fd) cl = fd->getUsedClasses(); bool matching= md->isVariable() || md->isTypedef() || // needed for function pointers (md->argumentList()==0 && root->argList->count()==0) || - matchArguments(argList, root->argList,className,namespaceName,TRUE,nl,cl); + matchArguments(argList, root->argList,className,namespaceName, + TRUE,nl,cl); Debug::print(Debug::FindMembers,0, diff --git a/src/formula.cpp b/src/formula.cpp index 1c1bfc7..f7c77b8 100644 --- a/src/formula.cpp +++ b/src/formula.cpp @@ -56,7 +56,7 @@ void FormulaList::generateBitmaps(const char *path) // store the original directory if (!d.exists()) { err("Error: Output dir %s does not exist!\n",path); exit(1); } QCString oldDir = convertToQCString(QDir::currentDirPath()); - // goto the html output directory (i.e. path) + // go to the html output directory (i.e. path) QDir::setCurrent(d.absPath()); QDir thisDir; // generate a latex file containing one formula per page. diff --git a/src/index.cpp b/src/index.cpp index 5fc1431..9ce2f94 100644 --- a/src/index.cpp +++ b/src/index.cpp @@ -145,13 +145,9 @@ QCString abbreviate(const char *s,const char *name) void writeQuickLinks(OutputList &ol,bool compact ,bool ext=FALSE) { ol.pushGeneratorState(); - //bool manEnabled = ol.isEnabled(OutputGenerator::Man); - //bool texEnabled = ol.isEnabled(OutputGenerator::Latex); ol.disableAllBut(OutputGenerator::Html); QCString extLink; if (ext) { extLink="_doc"; } - //if (manEnabled) ol.disable(OutputGenerator::Man); - //if (texEnabled) ol.disable(OutputGenerator::Latex); if (compact) ol.startCenter(); else ol.startItemList(); if (!compact) ol.writeListItem(); @@ -280,23 +276,19 @@ void writeQuickLinks(OutputList &ol,bool compact ,bool ext=FALSE) { ol.endItemList(); } - //if (manEnabled) ol.enable(OutputGenerator::Man); - //if (texEnabled) ol.enable(OutputGenerator::Latex); ol.popGeneratorState(); } -static bool manIsEnabled; - void startTitle(OutputList &ol,const char *fileName) { ol.startTitleHead(fileName); - manIsEnabled=ol.isEnabled(OutputGenerator::Man); - if (manIsEnabled) ol.disable(OutputGenerator::Man); + ol.pushGeneratorState(); + ol.disable(OutputGenerator::Man); } void endTitle(OutputList &ol,const char *fileName,const char *name) { - if (manIsEnabled) ol.enable(OutputGenerator::Man); + ol.popGeneratorState(); ol.endTitleHead(fileName,name); } @@ -675,7 +667,6 @@ void writeHierarchicalIndex(OutputList &ol) ol.endTextBlock(); writeClassHierarchy(ol); endFile(ol); - //ol.enable(OutputGenerator::Man); ol.popGeneratorState(); } @@ -959,7 +950,6 @@ void writeFileIndex(OutputList &ol) ftvHelp->decContentsDepth(); } endFile(ol); - //ol.enable(OutputGenerator::Man); ol.popGeneratorState(); } @@ -1059,7 +1049,6 @@ void writeNamespaceIndex(OutputList &ol) ftvHelp->decContentsDepth(); } endFile(ol); - //ol.enable(OutputGenerator::Man); ol.popGeneratorState(); } @@ -1984,7 +1973,6 @@ void writeExampleIndex(OutputList &ol) ftvHelp->decContentsDepth(); } endFile(ol); - //ol.enable(OutputGenerator::Man); ol.popGeneratorState(); } @@ -2102,7 +2090,6 @@ void writePageIndex(OutputList &ol) ftvHelp->decContentsDepth(); } endFile(ol); - //ol.enable(OutputGenerator::Man); ol.popGeneratorState(); } @@ -2797,13 +2784,6 @@ void writeIndex(OutputList &ol) ol.enable(OutputGenerator::Man); } - // restore generator state - //if (manEnabled) ol.enable(OutputGenerator::Man); - // else ol.disable(OutputGenerator::Man); - //if (texEnabled) ol.enable(OutputGenerator::Latex); - // else ol.disable(OutputGenerator::Latex); - //if (htmEnabled) ol.enable(OutputGenerator::Html); - // else ol.disable(OutputGenerator::Html); ol.popGeneratorState(); } diff --git a/src/mangen.cpp b/src/mangen.cpp index ad3e63a..d4bd0aa 100644 --- a/src/mangen.cpp +++ b/src/mangen.cpp @@ -97,45 +97,38 @@ void ManGenerator::init() static QCString buildFileName(const char *name) { - QCString fileName=name; + QCString fileName; -#if 0 - // TODO: do something sensible here. - if (fileName.left(6)=="class_") + const char *p=name; + char c; + while ((c=*p++)) { - fileName=fileName.right(fileName.length()-6); - } - else if (fileName.left(10)=="interface_") - { - fileName=fileName.right(fileName.length()-10); - } - else if (fileName.left(7)=="struct_") - { - fileName=fileName.right(fileName.length()-7); - } - else if (fileName.left(6)=="union_") - { - fileName=fileName.right(fileName.length()-6); - } - else if (fileName.left(10)=="exception_") - { - fileName=fileName.right(fileName.length()-10); - } - else if (fileName.left(6)=="group_") - { - fileName=fileName.right(fileName.length()-6); - } - - int i; - if ((i=fileName.findRev('.'))!=-1) - { - fileName=fileName.left(i); + switch (c) + { + case ':': + fileName+="_"; + if (*p==':') p++; + break; + case '<': + case '>': + case '&': + case '*': + case '!': + case '^': + case '~': + case '%': + case '+': + fileName+="_"; + break; + default: + fileName+=c; + } } -#endif - if (convertToQCString(fileName.right(2))!=Config_getString("MAN_EXTENSION")) + QCString &manExtension = Config_getString("MAN_EXTENSION"); + if (convertToQCString(fileName.right(2))!=manExtension) { - fileName+=Config_getString("MAN_EXTENSION"); + fileName+=manExtension; } return fileName; diff --git a/src/memberdef.cpp b/src/memberdef.cpp index cff02af..519e65c 100644 --- a/src/memberdef.cpp +++ b/src/memberdef.cpp @@ -504,7 +504,7 @@ bool MemberDef::isBriefSectionVisible() const hasDocumentation() ); - // hide members with no detailed desciption and brief descriptions + // hide members with no detailed description and brief descriptions // explicitly disabled. bool visibleIfEnabled = !(Config_getBool("HIDE_UNDOC_MEMBERS") && documentation().isEmpty() && @@ -592,7 +592,7 @@ void MemberDef::writeDeclaration(OutputList &ol, ol.startMemberItem((annoClassDef || annMemb || annEnumType) ? 1 : 0); // If there is no detailed description we need to write the anchor here. - bool detailsVisible = isDetailedSectionVisible(); + bool detailsVisible = isDetailedSectionLinkable(); if (!detailsVisible && !annMemb) { QCString doxyName=name().copy(); @@ -779,7 +779,9 @@ void MemberDef::writeDeclaration(OutputList &ol, //ol.endMemberItem(gId!=-1,gFile,gHeader,annoClassDef || annMemb); // write brief description - if (!briefDescription().isEmpty() && Config_getBool("BRIEF_MEMBER_DESC") && !annMemb) + if (!briefDescription().isEmpty() && + Config_getBool("BRIEF_MEMBER_DESC") && + !annMemb) { ol.startMemberDescription(); parseDoc(ol,m_defFileName,m_defLine,cname,name(),briefDescription()); @@ -808,7 +810,7 @@ void MemberDef::writeDeclaration(OutputList &ol, warnIfUndocumented(); } -bool MemberDef::isDetailedSectionVisible(bool inGroup) const +bool MemberDef::isDetailedSectionLinkable() const { // the member has details documentation for any of the following reasons bool docFilter = @@ -835,16 +837,19 @@ bool MemberDef::isDetailedSectionVisible(bool inGroup) const // this is not a global static or global statics should be extracted bool staticFilter = getClassDef()!=0 || !isStatic() || Config_getBool("EXTRACT_STATIC"); - // details are not part of a group or this is for a group documentation page - // TODO: FIX THIS!!! This should made such that it is always TRUE. - bool groupFilter = getGroupDef()==0 || inGroup; - // member is part of an anonymous scope that is the type of // another member in the list. // bool inAnonymousScope = !briefDescription().isEmpty() && annUsed; - return ((docFilter && staticFilter) || inAnonymousScope) && groupFilter; + return ((docFilter && staticFilter) || inAnonymousScope); +} + +bool MemberDef::isDetailedSectionVisible(bool inGroup) const +{ + bool groupFilter = getGroupDef()==0 || inGroup; + + return isDetailedSectionLinkable() && groupFilter; } /*! Writes the "detailed documentation" section of this member to @@ -1147,7 +1152,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol, ol.endEmphasis(); ol.endDescTableTitle(); ol.startDescTableData(); - parseDoc(ol,m_defFileName,m_defLine,scopeName,name(),a->docs); + parseDoc(ol,m_defFileName,m_defLine,scopeName,name(),a->docs+"\n"); ol.endDescTableData(); } } @@ -1477,3 +1482,17 @@ void MemberDef::setGroupDef(GroupDef *gd,Grouping::GroupPri_t pri,const QCString groupStartLine=startLine; groupHasDocs=hasDocs; } + +void MemberDef::setEnumScope(MemberDef *md) +{ + enumScope=md; + if (md->group) + { + group=md->group; + grouppri=md->grouppri; + groupFileName=md->groupFileName; + groupStartLine=md->groupStartLine; + groupHasDocs=md->groupHasDocs; + } +} + diff --git a/src/memberdef.h b/src/memberdef.h index bf8b446..45713a0 100644 --- a/src/memberdef.h +++ b/src/memberdef.h @@ -126,6 +126,7 @@ class MemberDef : public Definition bool hasDocumentation() const; // overrides hasDocumentation in definition.h bool isBriefSectionVisible() const; bool isDetailedSectionVisible(bool inGroup=FALSE) const; + bool isDetailedSectionLinkable() const; // set functions void setMemberType(MemberType t) { mtype=t; } @@ -167,7 +168,7 @@ class MemberDef : public Definition // enumeration specific members void insertEnumField(MemberDef *md); - void setEnumScope(MemberDef *md) { enumScope=md; } + void setEnumScope(MemberDef *md); MemberDef *getEnumScope() const { return enumScope; } void setEnumDecl(OutputList &ed); //void setEnumUsed() { eUsed=TRUE; } diff --git a/src/memberlist.cpp b/src/memberlist.cpp index bc8ee03..715effd 100644 --- a/src/memberlist.cpp +++ b/src/memberlist.cpp @@ -320,12 +320,20 @@ void MemberList::writePlainDeclarations(OutputList &ol, cd?cd->name().data():0,md->name().data(), md->briefDescription() ); - if (!md->documentation().isEmpty() || md->hasDocumentedEnumValues()) + if (md->isDetailedSectionLinkable()) { ol.disableAllBut(OutputGenerator::Html); ol.endEmphasis(); ol.docify(" "); - ol.startTextLink(0,md->anchor()); + if (md->getGroupDef()!=0 && gd==0) // forward link to group + { + ol.startTextLink(md->getGroupDef()->getOutputFileBase(), + md->anchor()); + } + else + { + ol.startTextLink(0,md->anchor()); + } parseText(ol,theTranslator->trMore()); ol.endTextLink(); ol.startEmphasis(); diff --git a/src/rtfgen.cpp b/src/rtfgen.cpp index 9e2213e..441c1f3 100644 --- a/src/rtfgen.cpp +++ b/src/rtfgen.cpp @@ -2588,7 +2588,7 @@ bool RTFGenerator::preProcessFileInplace(const char *path,const char *name) } QCString oldDir = convertToQCString(QDir::currentDirPath()); - // goto the html output directory (i.e. path) + // go to the html output directory (i.e. path) QDir::setCurrent(d.absPath()); QDir thisDir; diff --git a/src/scanner.l b/src/scanner.l index cb158bb..087c258 100644 --- a/src/scanner.l +++ b/src/scanner.l @@ -3388,6 +3388,10 @@ TITLE [tT][iI][tT][lL][eE] yyLineNr++; BEGIN( lastGroupContext ); } +<GroupName>"*/" { + unput('/');unput('*'); + BEGIN( lastGroupContext ); + } <ClassDoc,Doc>{B}*{CMD}("brief"|"short") { lastBriefContext=YY_START; BEGIN( ClassDocBrief ); @@ -3628,7 +3632,7 @@ TITLE [tT][iI][tT][lL][eE] unput(afterDocTerminator); BEGIN(lastAfterDocContext); } -<ClassDocRelates,ClassDocFunc,ClassDocDefine,GroupDocArg1,ClassDocArg1,SectionTitle,EnumDocArg1,PageDocArg1,ExampleDocArg1,ClassDefineArgs,GroupName>"*/" { +<ClassDocRelates,ClassDocFunc,ClassDocDefine,GroupDocArg1,ClassDocArg1,SectionTitle,EnumDocArg1,PageDocArg1,ExampleDocArg1,ClassDefineArgs>"*/" { // defer "*/" to a later time unput('/'); unput('*'); diff --git a/src/translator.h b/src/translator.h index a77bd28..1119118 100644 --- a/src/translator.h +++ b/src/translator.h @@ -567,7 +567,7 @@ class Translator virtual QCString trStaticPrivateMembers() = 0; /*! this function is used to produce a comma-separated list of items. - * use generateMarker(i) to indicate where item i should be put. + * Use generateMarker(i) to indicate where item i should be put. */ virtual QCString trWriteList(int numEntries) = 0; diff --git a/src/translator_adapter.h b/src/translator_adapter.h index 4ef420a..a38307e 100644 --- a/src/translator_adapter.h +++ b/src/translator_adapter.h @@ -45,12 +45,24 @@ class TranslatorAdapterCVS : public Translator // The first five lines below should be uncommented, and the // release number at the fifth of those lines should be set. -// class TranslatorAdapter_1_2_7 : public TranslatorAdapterCVS +// class TranslatorAdapter_1_2_8 : public TranslatorAdapterCVS // { // public: // virtual QCString updateNeededMessage() // { return createUpdateNeededMessage(idLanguage(),"release 1.2.7"); } + // Put new adapter methods below... + // + +}; + + +class TranslatorAdapter_1_2_7 : public TranslatorAdapterCVS +{ + public: + virtual QCString updateNeededMessage() + { return createUpdateNeededMessage(idLanguage(),"release 1.2.7"); } + /*! These are the default implementations of the obsolete methods * for introducing author/authors (possibly localized). */ @@ -72,12 +84,13 @@ class TranslatorAdapterCVS : public Translator } }; + /*! \brief Translator adapter class for release 1.2.6 * * Translator adapter for dealing with translator changes since * release 1.2.6 */ -class TranslatorAdapter_1_2_6 : public TranslatorAdapterCVS +class TranslatorAdapter_1_2_6 : public TranslatorAdapter_1_2_7 { public: virtual QCString updateNeededMessage() diff --git a/src/translator_br.h b/src/translator_br.h index 2bb1855..3d1e30f 100644 --- a/src/translator_br.h +++ b/src/translator_br.h @@ -18,9 +18,7 @@ #ifndef TRANSLATOR_BR_H #define TRANSLATOR_BR_H -#include "translator_adapter.h" - -class TranslatorBrazilian: public TranslatorAdapter_1_2_6 +class TranslatorBrazilian: public Translator { public: @@ -1170,5 +1168,160 @@ class TranslatorBrazilian: public TranslatorAdapter_1_2_6 return "Lista de Bug"; } +////////////////////////////////////////////////////////////////////////// +// new since 1.2.6 +////////////////////////////////////////////////////////////////////////// + + /*! Used as ansicpg for RTF file + * + * The following table shows the correlation of Charset name, Charset Value +and + * <pre> + * Codepage number: + * Charset Name Charset Value(hex) Codepage number + * ------------------------------------------------------ + * DEFAULT_CHARSET 1 (x01) + * SYMBOL_CHARSET 2 (x02) + * OEM_CHARSET 255 (xFF) + * ANSI_CHARSET 0 (x00) 1252 + * RUSSIAN_CHARSET 204 (xCC) 1251 + * EE_CHARSET 238 (xEE) 1250 + * GREEK_CHARSET 161 (xA1) 1253 + * TURKISH_CHARSET 162 (xA2) 1254 + * BALTIC_CHARSET 186 (xBA) 1257 + * HEBREW_CHARSET 177 (xB1) 1255 + * ARABIC _CHARSET 178 (xB2) 1256 + * SHIFTJIS_CHARSET 128 (x80) 932 + * HANGEUL_CHARSET 129 (x81) 949 + * GB2313_CHARSET 134 (x86) 936 + * CHINESEBIG5_CHARSET 136 (x88) 950 + * </pre> + * + */ + virtual QCString trRTFansicp() + { + return "1252"; + } + + + /*! Used as ansicpg for RTF fcharset + * \see trRTFansicp() for a table of possible values. + */ + virtual QCString trRTFCharSet() + { + return "0"; + } + + /*! Used as header RTF general index */ + virtual QCString trRTFGeneralIndex() + { + return "Índice"; + } + + /*! This is used for translation of the word that will possibly + * be followed by a single name or by a list of names + * of the category. + */ + virtual QCString trClass(bool first_capital, bool singular) + { + QCString result((first_capital ? "Classe" : "classe")); + if (!singular) result+="s"; + return result; + } + + /*! This is used for translation of the word that will possibly + * be followed by a single name or by a list of names + * of the category. + */ + virtual QCString trFile(bool first_capital, bool singular) + { + QCString result((first_capital ? "Arquivo": "arquivo")); + if (!singular) result+="s"; + return result; + } + + /*! This is used for translation of the word that will possibly + * be followed by a single name or by a list of names + * of the category. + */ + virtual QCString trNamespace(bool first_capital, bool singular) + { + QCString result((first_capital ? "Namespace" : "namespace")); + if (!singular) result+="s"; + return result; + } + + /*! This is used for translation of the word that will possibly + * be followed by a single name or by a list of names + * of the category. + */ + virtual QCString trGroup(bool first_capital, bool singular) + { + QCString result((first_capital ? "Grupo" : "grupo")); + if (!singular) result+="s"; + return result; + } + + /*! This is used for translation of the word that will possibly + * be followed by a single name or by a list of names + * of the category. + */ + virtual QCString trPage(bool first_capital, bool singular) + { + QCString result((first_capital ? "Página" : "página")); + if (!singular) result+="s"; + return result; + } + + /*! This is used for translation of the word that will possibly + * be followed by a single name or by a list of names + * of the category. + */ + virtual QCString trMember(bool first_capital, bool singular) + { + QCString result((first_capital ? "Membro" : "membro")); + if (!singular) result+="s"; + return result; + } + + /*! This is used for translation of the word that will possibly + * be followed by a single name or by a list of names + * of the category. + */ + virtual QCString trField(bool first_capital, bool singular) + { + QCString result((first_capital ? "Campo" : "campo")); + if (!singular) result+="s"; + return result; + } + + /*! This is used for translation of the word that will possibly + * be followed by a single name or by a list of names + * of the category. + */ + virtual QCString trGlobal(bool first_capital, bool singular) + { + QCString result((first_capital ? "Globa" : "globa")); + if (!singular){ + result+="is"; + }else{ + result+="l"; + } + return result; + } + +////////////////////////////////////////////////////////////////////////// +// new since 1.2.7 +////////////////////////////////////////////////////////////////////////// + + /*! This text is generated when the \\author command is used and + * for the author section in man pages. */ + virtual QCString trAuthor(bool first_capital, bool singular) + { + QCString result((first_capital ? "Autor" : "autor")); + if (!singular) result+="es"; + return result; + } + }; #endif diff --git a/src/translator_cz.h b/src/translator_cz.h index 551b6e8..7fc8f1a 100644 --- a/src/translator_cz.h +++ b/src/translator_cz.h @@ -769,7 +769,7 @@ class TranslatorCzech : public Translator return decode(result); } - /*! + /* * these are for the member sections of a class, struct or union */ virtual QCString trPublicMembers() @@ -1006,17 +1006,17 @@ class TranslatorCzech : public Translator { return decode("Zobrazit dokumentaci tohoto souboru."); } - /*! Text for the \pre command */ + /*! Text for the \\pre command */ virtual QCString trPrecondition() { return decode("Precondition"); } - /*! Text for the \post command */ + /*! Text for the \\post command */ virtual QCString trPostcondition() { return decode("Postcondition"); } - /*! Text for the \invariant command */ + /*! Text for the \\invariant command */ virtual QCString trInvariant() { return decode("Invariant"); diff --git a/src/translator_de.h b/src/translator_de.h index b3d26dd..65a5fe6 100644 --- a/src/translator_de.h +++ b/src/translator_de.h @@ -51,7 +51,7 @@ // // Todo: // - translation of all Config_getBool("OPTIMIZE_OUTPUT_FOR_C") -// strings (see translator.h) +// strings (see translator_en.h) // - translation of "compound" // - see FIXME // - was ist richtig: "Liste aller dokumentierter Elemente" oder @@ -1287,9 +1287,9 @@ class TranslatorGerman : public Translator return result; } - ////////////////////////////////////////////////////////////////////////// - // new since 1.2.7-20010524 - ////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////// +// new since 1.2.7-20010524 +////////////////////////////////////////////////////////////////////////// /* This text is generated when the \author command is used and * for the author section in man pages. diff --git a/src/translator_dk.h b/src/translator_dk.h index b5a14d2..9eda890 100644 --- a/src/translator_dk.h +++ b/src/translator_dk.h @@ -37,7 +37,7 @@ #ifndef TRANSLATOR_DK_H #define TRANSLATOR_DK_H -class TranslatorDanish : public TranslatorAdapterCVS +class TranslatorDanish : public TranslatorAdapter_1_2_7 { public: diff --git a/src/translator_es.h b/src/translator_es.h index 7ba37f4..88f4fb7 100644 --- a/src/translator_es.h +++ b/src/translator_es.h @@ -25,7 +25,7 @@ #ifndef TRANSLATOR_ES_H #define TRANSLATOR_ES_H -class TranslatorSpanish : public TranslatorAdapterCVS +class TranslatorSpanish : public TranslatorAdapter_1_2_7 { public: virtual QCString idLanguage() @@ -554,9 +554,7 @@ class TranslatorSpanish : public TranslatorAdapterCVS return result; } - /*! \mgroup Class sections - * 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() { return "Métodos públicos"; } virtual QCString trPublicSlots() @@ -577,7 +575,6 @@ class TranslatorSpanish : public TranslatorAdapterCVS { return "Slots privados"; } virtual QCString trStaticPrivateMembers() { return "Métodos privados estáticos"; } - /*! \endmgroup */ /*! this function is used to produce a comma-separated list of items. * use generateMarker(i) to indicate where item i should be put. @@ -779,17 +776,17 @@ class TranslatorSpanish : public TranslatorAdapterCVS { return "Ir a la documentación de este archivo."; } - /*! Text for the \pre command */ + /*! Text for the \\pre command */ virtual QCString trPrecondition() { return "Precondición"; } - /*! Text for the \post command */ + /*! Text for the \\post command */ virtual QCString trPostcondition() { return "Postcondición"; } - /*! Text for the \invariant command */ + /*! Text for the \\invariant command */ virtual QCString trInvariant() { return "Invariante"; diff --git a/src/translator_it.h b/src/translator_it.h index 33e9eac..169998f 100644 --- a/src/translator_it.h +++ b/src/translator_it.h @@ -57,7 +57,7 @@ #ifndef TRANSLATOR_IT_H #define TRANSLATOR_IT_H -class TranslatorItalian : public TranslatorAdapterCVS +class TranslatorItalian : public TranslatorAdapter_1_2_7 { public: diff --git a/src/translator_nl.h b/src/translator_nl.h index c5f9372..7f014ea 100644 --- a/src/translator_nl.h +++ b/src/translator_nl.h @@ -18,15 +18,35 @@ #ifndef TRANSLATOR_NL_H #define TRANSLATOR_NL_H -#include "translator_adapter.h" - -class TranslatorDutch : public TranslatorAdapter_1_2_6 +class TranslatorDutch : public Translator { public: QCString idLanguage() { return "dutch"; } - QCString latexBabelPackage() - { return "dutch"; } + /*! Used to get the LaTeX command(s) for the language support. + * This method should return string with commands that switch + * LaTeX to the desired language. For example + * <pre>"\\usepackage[german]{babel}\n" + * </pre> + * or + * <pre>"\\usepackage{polski}\n" + * "\\usepackage[latin2]{inputenc}\n" + * "\\usepackage[T1]{fontenc}\n" + * </pre> + * + * The Dutch LaTeX does not use such commands. Because of this + * the empty string is returned in this implementation. + */ + QCString latexLanguageSupportCommand() + { + return "\\usepackage[dutch]{babel}\n"; + } + /*! return the language charset. This will be used for the HTML output */ + QCString idLanguageCharset() + { + return "iso-8859-1"; + } + QCString trRelatedFunctions() { return "Gerelateerde functies"; } QCString trRelatedSubscript() @@ -63,8 +83,6 @@ class TranslatorDutch : public TranslatorAdapter_1_2_6 { return "enum waarde"; } QCString trDefinedIn() { return "gedefinieerd in"; } - QCString trVerbatimText(const char *f) - { return (QCString)"Dit is de letterlijke tekst van de include file "+f+"."; } QCString trModules() { return "Modules"; } QCString trClassHierarchy() @@ -166,8 +184,6 @@ class TranslatorDutch : public TranslatorAdapter_1_2_6 { return "Variabelen"; } QCString trEnumerationValues() { return "Enumeratie waarden"; } - QCString trAuthor() - { return "auteur"; } QCString trDefineDocumentation() { return "Documentatie van defines"; } QCString trFunctionPrototypeDocumentation() @@ -184,8 +200,6 @@ class TranslatorDutch : public TranslatorAdapter_1_2_6 { return "Documentatie van variabelen"; } QCString trCompounds() { return "Compounds"; } - QCString trFiles() - { return "Files"; } QCString trGeneratedAt(const char *date,const char *projName) { QCString result=(QCString)"Gegenereerd op "+date; @@ -215,8 +229,6 @@ class TranslatorDutch : public TranslatorAdapter_1_2_6 { return "Versie"; } QCString trDate() { return "Datum"; } - QCString trAuthors() - { return "Auteur(s)"; } QCString trReturns() { return "Retourneert"; } QCString trSeeAlso() @@ -802,6 +814,156 @@ class TranslatorDutch : public TranslatorAdapter_1_2_6 return "Bug Lijst"; } +////////////////////////////////////////////////////////////////////////// +// new since 1.2.6 +////////////////////////////////////////////////////////////////////////// + + /*! Used as ansicpg for RTF file + * + * The following table shows the correlation of Charset name, Charset Value and + * <pre> + * Codepage number: + * Charset Name Charset Value(hex) Codepage number + * ------------------------------------------------------ + * DEFAULT_CHARSET 1 (x01) + * SYMBOL_CHARSET 2 (x02) + * OEM_CHARSET 255 (xFF) + * ANSI_CHARSET 0 (x00) 1252 + * RUSSIAN_CHARSET 204 (xCC) 1251 + * EE_CHARSET 238 (xEE) 1250 + * GREEK_CHARSET 161 (xA1) 1253 + * TURKISH_CHARSET 162 (xA2) 1254 + * BALTIC_CHARSET 186 (xBA) 1257 + * HEBREW_CHARSET 177 (xB1) 1255 + * ARABIC _CHARSET 178 (xB2) 1256 + * SHIFTJIS_CHARSET 128 (x80) 932 + * HANGEUL_CHARSET 129 (x81) 949 + * GB2313_CHARSET 134 (x86) 936 + * CHINESEBIG5_CHARSET 136 (x88) 950 + * </pre> + * + */ + virtual QCString trRTFansicp() + { + return "1252"; + } + + + /*! Used as ansicpg for RTF fcharset + * \see trRTFansicp() for a table of possible values. + */ + virtual QCString trRTFCharSet() + { + return "0"; + } + + /*! Used as header RTF general index */ + virtual QCString trRTFGeneralIndex() + { + return "Index"; + } + + /*! This is used for translation of the word that will possibly + * be followed by a single name or by a list of names + * of the category. + */ + virtual QCString trClass(bool first_capital, bool singular) + { + QCString result((first_capital ? "Klasse" : "klass")); + if (!singular) result+="n"; + return result; + } + + /*! This is used for translation of the word that will possibly + * be followed by a single name or by a list of names + * of the category. + */ + virtual QCString trFile(bool first_capital, bool singular) + { + QCString result((first_capital ? "File" : "file")); + if (!singular) result+="s"; + return result; + } + + /*! This is used for translation of the word that will possibly + * be followed by a single name or by a list of names + * of the category. + */ + virtual QCString trNamespace(bool first_capital, bool singular) + { + QCString result((first_capital ? "Namespace" : "namespace")); + if (!singular) result+="s"; + return result; + } + + /*! This is used for translation of the word that will possibly + * be followed by a single name or by a list of names + * of the category. + */ + virtual QCString trGroup(bool first_capital, bool singular) + { + QCString result((first_capital ? "Groep" : "groep")); + if (!singular) result+="en"; + return result; + } + + /*! This is used for translation of the word that will possibly + * be followed by a single name or by a list of names + * of the category. + */ + virtual QCString trPage(bool first_capital, bool singular) + { + QCString result((first_capital ? "Pagina" : "pagina")); + if (!singular) result+="s"; + return result; + } + + /*! This is used for translation of the word that will possibly + * be followed by a single name or by a list of names + * of the category. + */ + virtual QCString trMember(bool first_capital, bool singular) + { + QCString result((first_capital ? "Member" : "member")); + if (!singular) result+="s"; + return result; + } + + /*! This is used for translation of the word that will possibly + * be followed by a single name or by a list of names + * of the category. + */ + virtual QCString trField(bool first_capital, bool singular) + { + QCString result((first_capital ? "Veld" : "veld")); + if (!singular) result+="en"; + return result; + } + + /*! This is used for translation of the word that will possibly + * be followed by a single name or by a list of names + * of the category. + */ + virtual QCString trGlobal(bool first_capital, bool singular) + { + QCString result((first_capital ? "Globale member" : "globale member")); + if (!singular) result+="s"; + return result; + } + +////////////////////////////////////////////////////////////////////////// +// new since 1.2.7 +////////////////////////////////////////////////////////////////////////// + + /*! This text is generated when the \\author command is used and + * for the author section in man pages. */ + virtual QCString trAuthor(bool first_capital, bool singular) + { + QCString result((first_capital ? "Auteur" : "auteur")); + if (!singular) result+="s"; + return result; + } + }; #endif diff --git a/src/translator_sk.h b/src/translator_sk.h index 2f1b2b1..4cb840f 100644 --- a/src/translator_sk.h +++ b/src/translator_sk.h @@ -18,7 +18,7 @@ #ifndef TRANSLATOR_SK_H #define TRANSLATOR_SK_H -class TranslatorSlovak : public TranslatorAdapterCVS +class TranslatorSlovak : public TranslatorAdapter_1_2_7 { private: /*! The Decode() inline assumes the source written in the @@ -659,9 +659,7 @@ class TranslatorSlovak : public TranslatorAdapterCVS return Decode(result); } - /*! \mgroup Class sections - * 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() { return Decode("Verejné metódy"); } virtual QCString trPublicSlots() @@ -682,7 +680,6 @@ class TranslatorSlovak : public TranslatorAdapterCVS { return Decode("Privátne sloty"); } virtual QCString trStaticPrivateMembers() { return Decode("Statické privátne metódy"); } - /*! \endmgroup */ /*! this function is used to produce a comma-separated list of items. * use generateMarker(i) to indicate where item i should be put. @@ -899,17 +896,17 @@ class TranslatorSlovak : public TranslatorAdapterCVS { return Decode("Zobrazi dokumentáciu tohoto súboru."); } - /*! Text for the \pre command */ + /*! Text for the \\pre command */ virtual QCString trPrecondition() { return Decode("Prepodmienka"); } - /*! Text for the \post command */ + /*! Text for the \\post command */ virtual QCString trPostcondition() { return Decode("Postpodmienka"); } - /*! Text for the \invariant command */ + /*! Text for the \\invariant command */ virtual QCString trInvariant() { return Decode("Invariant"); diff --git a/src/util.cpp b/src/util.cpp index cf8ab4c..c4b2606 100644 --- a/src/util.cpp +++ b/src/util.cpp @@ -1830,7 +1830,7 @@ bool getDefs(const QCString &scName,const QCString &memberName, return TRUE; /* found match */ } } - /* goto the parent scope */ + /* go to the parent scope */ if (scopeOffset==0) { @@ -2650,18 +2650,16 @@ QCString convertNameToFile(const char *name,bool allowDots) void extractNamespaceName(const QCString &scopeName, QCString &className,QCString &namespaceName) { - QCString clName=scopeName.copy(); - //QCString nsName; + int i,p; + QCString clName=scopeName; NamespaceDef *nd = 0; if (!clName.isEmpty() && (nd=getResolvedNamespace(clName)) && getClass(clName)==0) { // the whole name is a namespace (and not a class) namespaceName=nd->name().copy(); className.resize(0); - //printf("extractNamespace `%s' => `%s|%s'\n",scopeName.data(), - // className.data(),namespaceName.data()); - return; + goto done; } - int i,p=clName.length()-2; + p=clName.length()-2; while (p>=0 && (i=clName.findRev("::",p))!=-1) // see if the first part is a namespace (and not a class) { @@ -2669,14 +2667,16 @@ void extractNamespaceName(const QCString &scopeName, { namespaceName=nd->name().copy(); className=clName.right(clName.length()-i-2); - //printf("extractNamespace `%s' => `%s|%s'\n",scopeName.data(), - // className.data(),namespaceName.data()); - return; + goto done; } p=i-2; // try a smaller piece of the scope } + + // not found, so we just have to guess. className=scopeName.copy(); namespaceName.resize(0); + +done: //printf("extractNamespace `%s' => `%s|%s'\n",scopeName.data(), // className.data(),namespaceName.data()); return; |