summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authordimitri <dimitri@afe2bf4a-e733-0410-8a33-86f594647bc7>2007-03-15 10:14:23 (GMT)
committerdimitri <dimitri@afe2bf4a-e733-0410-8a33-86f594647bc7>2007-03-15 10:14:23 (GMT)
commit97a3911e2682bfebeebbb8999c9e3844c414c3e0 (patch)
tree5300b179faf00eea740dda6ee3be5343c70b1c79 /src
parentf7f03d9491454ddc9b855b8637d482df6bd622c2 (diff)
downloadDoxygen-97a3911e2682bfebeebbb8999c9e3844c414c3e0.zip
Doxygen-97a3911e2682bfebeebbb8999c9e3844c414c3e0.tar.gz
Doxygen-97a3911e2682bfebeebbb8999c9e3844c414c3e0.tar.bz2
Release-1.5.1-20070315
Diffstat (limited to 'src')
-rw-r--r--src/cmdmapper.cpp2
-rw-r--r--src/cmdmapper.h10
-rw-r--r--src/commentcnv.l6
-rw-r--r--src/commentscan.l5
-rw-r--r--src/config.l53
-rw-r--r--src/docparser.cpp12
-rw-r--r--src/docparser.h4
-rw-r--r--src/doctokenizer.h1
-rw-r--r--src/doctokenizer.l33
-rw-r--r--src/ftvhelp.cpp3
-rw-r--r--src/htmldocvisitor.cpp46
-rw-r--r--src/htmldocvisitor.h1
-rw-r--r--src/latexdocvisitor.cpp48
-rw-r--r--src/latexdocvisitor.h1
-rw-r--r--src/latexgen.cpp13
-rw-r--r--src/libdoxygen.pro.in2
-rw-r--r--src/mandocvisitor.cpp1
-rw-r--r--src/memberdef.cpp5
-rw-r--r--src/msc.cpp172
-rw-r--r--src/msc.h32
-rw-r--r--src/perlmodgen.cpp1
-rw-r--r--src/portable.cpp11
-rw-r--r--src/portable.h2
-rw-r--r--src/printdocvisitor.h2
-rw-r--r--src/pyscanner.l2
-rw-r--r--src/rtfdocvisitor.cpp45
-rw-r--r--src/rtfdocvisitor.h1
-rw-r--r--src/scanner.l40
-rw-r--r--src/translator_br.h5
-rw-r--r--src/translator_ca.h2
-rw-r--r--src/translator_cn.h5
-rw-r--r--src/translator_de.h2
-rw-r--r--src/translator_dk.h2
-rw-r--r--src/translator_en.h2
-rw-r--r--src/translator_es.h4
-rw-r--r--src/translator_fr.h2
-rw-r--r--src/translator_gr.h5
-rw-r--r--src/translator_hr.h5
-rw-r--r--src/translator_hu.h2
-rw-r--r--src/translator_id.h2
-rw-r--r--src/translator_it.h5
-rw-r--r--src/translator_jp.h5
-rw-r--r--src/translator_kr.h2
-rw-r--r--src/translator_lt.h2
-rw-r--r--src/translator_nl.h5
-rw-r--r--src/translator_no.h4
-rw-r--r--src/translator_pl.h5
-rw-r--r--src/translator_pt.h5
-rw-r--r--src/translator_ro.h5
-rw-r--r--src/translator_se.h2
-rw-r--r--src/translator_si.h5
-rw-r--r--src/translator_sk.h9
-rw-r--r--src/translator_sr.h2
-rw-r--r--src/translator_tw.h2
-rw-r--r--src/translator_ua.h5
-rw-r--r--src/translator_za.h2
-rw-r--r--src/translatordecoder.h2
-rw-r--r--src/util.cpp8
-rw-r--r--src/xmldocvisitor.cpp5
59 files changed, 582 insertions, 90 deletions
diff --git a/src/cmdmapper.cpp b/src/cmdmapper.cpp
index da66f45..352095c 100644
--- a/src/cmdmapper.cpp
+++ b/src/cmdmapper.cpp
@@ -102,7 +102,9 @@ CommandMap cmdMap[] =
{ "%", CMD_PERCENT },
{ "_internalref", CMD_INTERNALREF },
{ "dot", CMD_DOT },
+ { "msc", CMD_MSC },
{ "enddot", CMD_ENDDOT },
+ { "endmsc", CMD_ENDMSC },
{ "manonly", CMD_MANONLY },
{ "endmanonly", CMD_ENDMANONLY },
{ "includelineno", CMD_INCWITHLINES },
diff --git a/src/cmdmapper.h b/src/cmdmapper.h
index 1ef3053..586e766 100644
--- a/src/cmdmapper.h
+++ b/src/cmdmapper.h
@@ -104,10 +104,12 @@ enum CommandType
CMD_XMLONLY = 70,
CMD_DOT = 71,
CMD_ENDDOT = 72,
- CMD_MANONLY = 73,
- CMD_ENDMANONLY = 74,
- CMD_INCWITHLINES = 75,
- CMD_INHERITDOC = 76
+ CMD_MSC = 73,
+ CMD_ENDMSC = 74,
+ CMD_MANONLY = 75,
+ CMD_ENDMANONLY = 76,
+ CMD_INCWITHLINES = 77,
+ CMD_INHERITDOC = 78
};
enum HtmlTagType
diff --git a/src/commentcnv.l b/src/commentcnv.l
index 25a0f1a..238e56b 100644
--- a/src/commentcnv.l
+++ b/src/commentcnv.l
@@ -323,7 +323,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^' \\\n]{1,4}"'"))
copyToOutput(yytext,yyleng);
BEGIN(CComment);
}
-<CComment,ReadLine>[\\@]("dot"|"code")/[^a-z_A-Z0-9] { /* start of a verbatim block */
+<CComment,ReadLine>[\\@]("dot"|"code"|"msc")/[^a-z_A-Z0-9] { /* start of a verbatim block */
copyToOutput(yytext,yyleng);
g_lastCommentContext = YY_START;
g_blockName=&yytext[1];
@@ -352,7 +352,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^' \\\n]{1,4}"'"))
<Scan>. { /* any other character */
copyToOutput(yytext,yyleng);
}
-<Verbatim>[\\@]("endverbatim"|"endlatexonly"|"endhtmlonly"|"endxmlonly"|"endrtfonly"|"endmanonly"|"enddot"|"endcode"|"f$"|"f]"|"f}") { /* end of verbatim block */
+<Verbatim>[\\@]("endverbatim"|"endlatexonly"|"endhtmlonly"|"endxmlonly"|"endrtfonly"|"endmanonly"|"f$"|"f]"|"f}") { /* end of verbatim block */
copyToOutput(yytext,yyleng);
if (yytext[1]=='f') // end of formula
{
@@ -363,7 +363,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^' \\\n]{1,4}"'"))
BEGIN(g_lastCommentContext);
}
}
-<VerbatimCode>[\\@]("enddot"|"endcode") { /* end of verbatim block */
+<VerbatimCode>[\\@]("enddot"|"endcode"|"endmsc") { /* end of verbatim block */
copyToOutput(yytext,yyleng);
if (&yytext[4]==g_blockName)
{
diff --git a/src/commentscan.l b/src/commentscan.l
index ec58264..105d512 100644
--- a/src/commentscan.l
+++ b/src/commentscan.l
@@ -170,6 +170,7 @@ static DocCmdMap docCmdMap[] =
{ "rtfonly", &handleFormatBlock, FALSE },
{ "manonly", &handleFormatBlock, FALSE },
{ "dot", &handleFormatBlock, TRUE },
+ { "msc", &handleFormatBlock, TRUE },
{ "code", &handleFormatBlock, TRUE },
{ "addindex", &handleAddIndex, TRUE },
{ "if", &handleIf, FALSE },
@@ -742,7 +743,7 @@ static int yyread(char *buf,int max_size)
/* start command character */
CMD ("\\"|"@")
DCMD1 ("arg"|"attention"|"author"|"code")
-DCMD2 ("date"|"dot"|"dotfile"|"example")
+DCMD2 ("date"|"dot"|"msc"|"dotfile"|"example")
DCMD3 ("htmlinclude"|"htmlonly"|"image"|"include")
DCMD4 ("includelineno"|"internal"|"invariant")
DCMD5 ("latexonly"|"li"|"line"|"manonly"|"name")
@@ -1488,7 +1489,7 @@ MAILADR [a-z_A-Z0-9.+\-]+"@"[a-z_A-Z0-9\-]+("."[a-z_A-Z0-9\-]+)+[a-z_A-Z0-9\-]
/* ----- handle arguments of the preformatted block commands ------- */
-<FormatBlock>{CMD}("endverbatim"|"endlatexonly"|"endhtmlonly"|"endxmlonly"|"endrtfonly"|"endmanonly"|"enddot"|"endcode")/{NW} { // possible ends
+<FormatBlock>{CMD}("endverbatim"|"endlatexonly"|"endhtmlonly"|"endxmlonly"|"endrtfonly"|"endmanonly"|"enddot"|"endcode"|"endmsc")/{NW} { // possible ends
addOutput(yytext);
if (&yytext[4]==blockName) // found end of the block
{
diff --git a/src/config.l b/src/config.l
index 2818b0a..b1ea378 100644
--- a/src/config.l
+++ b/src/config.l
@@ -363,7 +363,7 @@ static QCString configStringRecode(
{
outputSize-=oLeft;
output.resize(outputSize+1);
- output.at(outputSize+1)='\0';
+ output.at(outputSize)='\0';
//printf("iconv: input size=%d output size=%d\n[%s]\n",size,newSize,srcBuf.data());
}
else
@@ -1089,21 +1089,7 @@ void Config::check()
QCString &dotPath = Config_getString("DOT_PATH");
if (!dotPath.isEmpty())
{
- if (dotPath.find('\\')!=-1)
- {
- if (dotPath.at(dotPath.length()-1)!='\\')
- {
- dotPath+='\\';
- }
- }
- else if (dotPath.find('/')!=-1)
- {
- if (dotPath.at(dotPath.length()-1)!='/')
- {
- dotPath+='/';
- }
- }
- QFileInfo dp(dotPath+portable_dotCommand());
+ QFileInfo dp(dotPath+"/dot"+portable_commandExtension());
if (!dp.exists() || !dp.isFile())
{
config_err("Warning: the dot tool could not be found at %s\n",dotPath.data());
@@ -1122,6 +1108,31 @@ void Config::check()
{
dotPath="";
}
+
+ // check mscgen path
+ QCString &mscgenPath = Config_getString("MSCGEN_PATH");
+ if (!mscgenPath.isEmpty())
+ {
+ QFileInfo dp(mscgenPath+"/mscgen"+portable_commandExtension());
+ if (!dp.exists() || !dp.isFile())
+ {
+ config_err("Warning: the mscgen tool could not be found at %s\n",mscgenPath.data());
+ mscgenPath="";
+ }
+ else
+ {
+ mscgenPath=dp.dirPath(TRUE)+"/";
+#if defined(_WIN32) // convert slashes
+ uint i=0,l=mscgenPath.length();
+ for (i=0;i<l;i++) if (mscgenPath.at(i)=='/') mscgenPath.at(i)='\\';
+#endif
+ }
+ }
+ else // make sure the string is empty but not null!
+ {
+ mscgenPath="";
+ }
+
// check input
QStrList &inputSources=Config_getList("INPUT");
@@ -1138,8 +1149,7 @@ void Config::check()
QFileInfo fi(s);
if (!fi.exists())
{
- config_err("Error: tag INPUT: input source `%s' does not exist\n",s);
- exit(1);
+ config_err("Warning: tag INPUT: input source `%s' does not exist\n",s);
}
s=inputSources.next();
}
@@ -2711,6 +2721,13 @@ void Config::create()
"powerful graphs. \n",
TRUE
);
+ cs = addString( "MSCGEN_PATH",
+ "You can define message sequence charts within doxygen comments using the \\msc \n"
+ "command. Doxygen will then run the mscgen tool (see http://www.mcternan.me.uk/mscgen/) to \n"
+ "produce the chart and insert it in the documentation. The MSCGEN_PATH tag allows you to \n"
+ "specify the directory where the mscgen tool resides. If left empty the tool is assumed to \n"
+ "be found in the default search path. \n"
+ );
cb = addBool(
"HIDE_UNDOC_RELATIONS",
"If set to YES, the inheritance and collaboration graphs will hide \n"
diff --git a/src/docparser.cpp b/src/docparser.cpp
index 090c67f..2dc29a5 100644
--- a/src/docparser.cpp
+++ b/src/docparser.cpp
@@ -4392,6 +4392,15 @@ int DocPara::handleCommand(const QString &cmdName)
doctokenizerYYsetStatePara();
}
break;
+ case CMD_MSC:
+ {
+ doctokenizerYYsetStateMsc();
+ retval = doctokenizerYYlex();
+ m_children.append(new DocVerbatim(this,g_context,g_token->verb,DocVerbatim::Msc,g_isExample,g_exampleName));
+ if (retval==0) warn_doc_error(g_fileName,doctokenizerYYlineno,"Warning: msc section ended without end marker");
+ doctokenizerYYsetStatePara();
+ }
+ break;
case CMD_ENDCODE:
case CMD_ENDHTMLONLY:
case CMD_ENDMANONLY:
@@ -4402,6 +4411,9 @@ int DocPara::handleCommand(const QString &cmdName)
case CMD_ENDDOT:
warn_doc_error(g_fileName,doctokenizerYYlineno,"Warning: unexpected command %s",g_token->name.data());
break;
+ case CMD_ENDMSC:
+ warn_doc_error(g_fileName,doctokenizerYYlineno,"Warning: unexpected command %s",g_token->name.data());
+ break;
case CMD_PARAM:
retval = handleParamSection(cmdName,DocParamSect::Param,FALSE,g_token->paramDir);
break;
diff --git a/src/docparser.h b/src/docparser.h
index 7f074e4..7d09ac5 100644
--- a/src/docparser.h
+++ b/src/docparser.h
@@ -362,7 +362,7 @@ class DocWhiteSpace : public DocNode
class DocVerbatim : public DocNode
{
public:
- enum Type { Code, HtmlOnly, ManOnly, LatexOnly, XmlOnly, Verbatim, Dot };
+ enum Type { Code, HtmlOnly, ManOnly, LatexOnly, XmlOnly, Verbatim, Dot, Msc };
DocVerbatim(DocNode *parent,const QString &context,
const QString &text, Type t,bool isExample,
const QString &exampleFile);
@@ -374,7 +374,7 @@ class DocVerbatim : public DocNode
void accept(DocVisitor *v) { v->visit(this); }
bool isExample() const { return m_isExample; }
QString exampleFile() const { return m_exampleFile; }
- QString relPath() const { return m_relPath; }
+ QString relPath() const { return m_relPath; }
private:
DocNode *m_parent;
diff --git a/src/doctokenizer.h b/src/doctokenizer.h
index 301f79b..7e6e521 100644
--- a/src/doctokenizer.h
+++ b/src/doctokenizer.h
@@ -133,6 +133,7 @@ void doctokenizerYYsetStateLatexOnly();
void doctokenizerYYsetStateXmlOnly();
void doctokenizerYYsetStateVerbatim();
void doctokenizerYYsetStateDot();
+void doctokenizerYYsetStateMsc();
void doctokenizerYYsetStateParam();
void doctokenizerYYsetStateXRefItem();
void doctokenizerYYsetStateFile();
diff --git a/src/doctokenizer.l b/src/doctokenizer.l
index d26db37..8fd3856 100644
--- a/src/doctokenizer.l
+++ b/src/doctokenizer.l
@@ -358,6 +358,7 @@ REFWORD ("#"|"::")?({ID}("."|"#"|"::"|"-"|"/"))*({ID}(":")?){FUNCARG}?
%x St_XmlOnly
%x St_Verbatim
%x St_Dot
+%x St_Msc
%x St_Param
%x St_XRefItem
%x St_XRefItem2
@@ -602,17 +603,25 @@ REFWORD ("#"|"::")?({ID}("."|"#"|"::"|"-"|"/"))*({ID}(":")?){FUNCARG}?
g_token->verb=stripEmptyLines(g_token->verb);
return RetVal_OK;
}
-<St_Verbatim>[^\\@\n]+ |
-<St_Verbatim>\n |
-<St_Verbatim>. { /* Verbatim text */
+<St_Verbatim>[^\\@\n]+ |
+<St_Verbatim>\n |
+<St_Verbatim>. { /* Verbatim text */
g_token->verb+=yytext;
}
-<St_Dot>{CMD}"enddot" {
+<St_Dot>{CMD}"enddot" {
return RetVal_OK;
}
-<St_Dot>[^\\@\n]+ |
-<St_Dot>\n |
-<St_Dot>. { /* dot text */
+<St_Dot>[^\\@\n]+ |
+<St_Dot>\n |
+<St_Dot>. { /* dot text */
+ g_token->verb+=yytext;
+ }
+<St_Msc>{CMD}"endmsc" {
+ return RetVal_OK;
+ }
+<St_Msc>[^\\@\n]+ |
+<St_Msc>\n |
+<St_Msc>. { /* msc text */
g_token->verb+=yytext;
}
<St_Title>"\"" { // quoted title
@@ -844,6 +853,10 @@ REFWORD ("#"|"::")?({ID}("."|"#"|"::"|"-"|"/"))*({ID}(":")?){FUNCARG}?
g_endMarker="enddot";
BEGIN(St_SecSkip);
}
+<St_Sections>{CMD}"msc"/[^a-z_A-Z0-9] {
+ g_endMarker="endmsc";
+ BEGIN(St_SecSkip);
+ }
<St_Sections>{CMD}"htmlonly"/[^a-z_A-Z0-9] {
g_endMarker="endhtmlonly";
BEGIN(St_SecSkip);
@@ -1006,6 +1019,12 @@ void doctokenizerYYsetStateDot()
BEGIN(St_Dot);
}
+void doctokenizerYYsetStateMsc()
+{
+ g_token->verb="";
+ BEGIN(St_Msc);
+}
+
void doctokenizerYYsetStateParam()
{
BEGIN(St_Param);
diff --git a/src/ftvhelp.cpp b/src/ftvhelp.cpp
index e72da91..5be662d 100644
--- a/src/ftvhelp.cpp
+++ b/src/ftvhelp.cpp
@@ -611,6 +611,9 @@ void FTVHelp::generateTreeView()
t << "<frameset cols=\"" << Config_getInt("TREEVIEW_WIDTH") << ",*\">" << endl;
t << " <frame src=\"tree" << Doxygen::htmlFileExtension << "\" name=\"treefrm\">" << endl;
t << " <frame src=\"main" << Doxygen::htmlFileExtension << "\" name=\"basefrm\">" << endl;
+ t << " <noframes>" << endl;
+ t << " <a href=\"main.html\">Frames are disabled. Click here to go to the main page.</a>" << endl;
+ t << " </noframes>" << endl;
t << "</frameset>" << endl;
t << "</html>" << endl;
f.close();
diff --git a/src/htmldocvisitor.cpp b/src/htmldocvisitor.cpp
index 4f1034f..e7910b5 100644
--- a/src/htmldocvisitor.cpp
+++ b/src/htmldocvisitor.cpp
@@ -27,6 +27,7 @@
#include "config.h"
#include "htmlgen.h"
#include "parserintf.h"
+#include "msc.h"
static const int NUM_HTML_LIST_TYPES = 4;
@@ -248,6 +249,33 @@ void HtmlDocVisitor::visit(DocVerbatim *s)
if (Config_getBool("DOT_CLEANUP")) file.remove();
}
break;
+ case DocVerbatim::Msc:
+ {
+ static int mscindex = 1;
+ QCString baseName(4096);
+
+ baseName.sprintf("%s%d",
+ (Config_getString("HTML_OUTPUT")+"/inline_mscgraph_").data(),
+ mscindex++
+ );
+ QFile file(baseName+".msc");
+ if (!file.open(IO_WriteOnly))
+ {
+ err("Could not open file %s.msc for writing\n",baseName.data());
+ }
+ QCString text = "msc {";
+ text+=s->text();
+ text+="}";
+ file.writeBlock( text, text.length() );
+ file.close();
+
+ m_t << "<div align=\"center\">" << endl;
+ writeMscFile(baseName,s->relPath());
+ m_t << "</div>" << endl;
+
+ if (Config_getBool("DOT_CLEANUP")) file.remove();
+ }
+ break;
}
}
@@ -1131,3 +1159,21 @@ void HtmlDocVisitor::writeDotFile(const QString &fileName,const QString &relPath
m_t << "<map name=\"" << mapName << "\">" << imap << "</map>" << endl;
}
+void HtmlDocVisitor::writeMscFile(const QString &fileName,const QString &relPath)
+{
+ QString baseName=fileName;
+ int i;
+ if ((i=baseName.findRev('/'))!=-1)
+ {
+ baseName=baseName.right(baseName.length()-i-1);
+ }
+ QString outDir = Config_getString("HTML_OUTPUT");
+ writeMscGraphFromFile(fileName,outDir,baseName,MSC_BITMAP);
+ QString mapName = baseName+".map";
+ QString mapFile = fileName+".map";
+ m_t << "<img src=\"" << relPath << baseName << ".png\" alt=\""
+ << baseName << "\" border=\"0\" usemap=\"#" << mapName << "\">" << endl;
+ QString imap = getMscImageMapFromFile(fileName,outDir,relPath.data());
+ m_t << "<map name=\"" << mapName << "\">" << imap << "</map>" << endl;
+}
+
diff --git a/src/htmldocvisitor.h b/src/htmldocvisitor.h
index 7dedf88..db4d6fc 100644
--- a/src/htmldocvisitor.h
+++ b/src/htmldocvisitor.h
@@ -136,6 +136,7 @@ class HtmlDocVisitor : public DocVisitor
const QString &tooltip = QString::null);
void endLink();
void writeDotFile(const QString &fileName,const QString &relPath);
+ void writeMscFile(const QString &fileName,const QString &relPath);
void pushEnabled();
void popEnabled();
diff --git a/src/latexdocvisitor.cpp b/src/latexdocvisitor.cpp
index 9426a1e..76bff77 100644
--- a/src/latexdocvisitor.cpp
+++ b/src/latexdocvisitor.cpp
@@ -25,6 +25,7 @@
#include "util.h"
#include "message.h"
#include "parserintf.h"
+#include "msc.h"
static QString escapeLabelName(const char *s)
{
@@ -302,6 +303,33 @@ void LatexDocVisitor::visit(DocVerbatim *s)
if (Config_getBool("DOT_CLEANUP")) file.remove();
}
break;
+ case DocVerbatim::Msc:
+ {
+ static int mscindex = 1;
+ QCString baseName(4096);
+
+ baseName.sprintf("%s%d",
+ (Config_getString("LATEX_OUTPUT")+"/inline_mscgraph_").data(),
+ mscindex++
+ );
+ QFile file(baseName+".msc");
+ if (!file.open(IO_WriteOnly))
+ {
+ err("Could not open file %s.msc for writing\n",baseName.data());
+ }
+ QCString text = "msc {";
+ text+=s->text();
+ text+="}";
+ file.writeBlock( text, text.length() );
+ file.close();
+
+ m_t << "\\begin{center}\n";
+ writeMscFile(baseName);
+ m_t << "\\end{center}\n";
+
+ if (Config_getBool("DOT_CLEANUP")) file.remove();
+ }
+ break;
}
}
@@ -1141,3 +1169,23 @@ void LatexDocVisitor::endDotFile(bool hasCaption)
}
}
+void LatexDocVisitor::writeMscFile(const QString &baseName)
+{
+ QString outDir = Config_getString("LATEX_OUTPUT");
+ writeMscGraphFromFile(baseName,outDir,baseName,MSC_EPS);
+ m_t << "\\begin{ImageNoCaption}\\mbox{";
+ m_t << "\\includegraphics";
+ //if (!width.isEmpty())
+ //{
+ // m_t << "[width=" << width << "]";
+ //}
+ //else if (!height.isEmpty())
+ //{
+ // m_t << "[height=" << height << "]";
+ //}
+ m_t << "{" << baseName << "}";
+
+ m_t << "}" << endl; // end mbox
+ m_t << "\\end{ImageNoCaption}" << endl;
+}
+
diff --git a/src/latexdocvisitor.h b/src/latexdocvisitor.h
index 62f1011..562d299 100644
--- a/src/latexdocvisitor.h
+++ b/src/latexdocvisitor.h
@@ -143,6 +143,7 @@ class LatexDocVisitor : public DocVisitor
void startDotFile(const QString &fileName,const QString &width,
const QString &height, bool hasCaption);
void endDotFile(bool hasCaption);
+ void writeMscFile(const QString &fileName);
void pushEnabled();
void popEnabled();
diff --git a/src/latexgen.cpp b/src/latexgen.cpp
index 385c7bc..d93b503 100644
--- a/src/latexgen.cpp
+++ b/src/latexgen.cpp
@@ -1142,13 +1142,12 @@ void LatexGenerator::startMemberDoc(const char *clname,
t << "}" << endl;
}
if (Config_getBool("COMPACT_LATEX")) t << "\\paragraph"; else t << "\\subsubsection";
- if (Config_getBool("PDF_HYPERLINKS") && memname)
- {
- t << "[";
- escapeMakeIndexChars(this,t,memname);
- //filterTitle(title)
- t << "]";
- }
+ //if (Config_getBool("PDF_HYPERLINKS") && memname)
+ //{
+ // t << "[";
+ // escapeMakeIndexChars(this,t,memname);
+ // t << "]";
+ //}
t << "{\\setlength{\\rightskip}{0pt plus 5cm}";
}
diff --git a/src/libdoxygen.pro.in b/src/libdoxygen.pro.in
index 656c75f..12dfbd7 100644
--- a/src/libdoxygen.pro.in
+++ b/src/libdoxygen.pro.in
@@ -70,6 +70,7 @@ HEADERS = bufstr.h \
memberlist.h \
membername.h \
message.h \
+ msc.h \
namespacedef.h \
objcache.h \
outputgen.h \
@@ -178,6 +179,7 @@ SOURCES = ce_lex.cpp \
memberlist.cpp \
membername.cpp \
message.cpp \
+ msc.cpp \
namespacedef.cpp \
objcache.cpp \
outputgen.cpp \
diff --git a/src/mandocvisitor.cpp b/src/mandocvisitor.cpp
index 3f305a9..8a63d5d 100644
--- a/src/mandocvisitor.cpp
+++ b/src/mandocvisitor.cpp
@@ -219,6 +219,7 @@ void ManDocVisitor::visit(DocVerbatim *s)
case DocVerbatim::XmlOnly:
case DocVerbatim::LatexOnly:
case DocVerbatim::Dot:
+ case DocVerbatim::Msc:
/* nothing */
break;
}
diff --git a/src/memberdef.cpp b/src/memberdef.cpp
index 155e10d..e149cc9 100644
--- a/src/memberdef.cpp
+++ b/src/memberdef.cpp
@@ -1549,7 +1549,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
QCString cfiname = container->getOutputFileBase();
static bool hasHtmlHelp = Config_getBool("GENERATE_HTML") && Config_getBool("GENERATE_HTMLHELP");
- HtmlHelp *htmlHelp = 0;
+ HtmlHelp *htmlHelp = HtmlHelp::getInstance();
if (hasHtmlHelp)
{
if (isEnumerate() && name().at(0)=='@')
@@ -1558,7 +1558,6 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
}
else
{
- htmlHelp = HtmlHelp::getInstance();
htmlHelp->addIndexItem(ciname, // level1
name(), // level2
separateMemPages ? cfname : cfiname, // contRef
@@ -1876,7 +1875,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
}
/* write detailed description */
- if (!detailed.isEmpty())
+ if (!detailed.isEmpty() || !m_impl->inbodyDocs.isEmpty())
{
ol.parseDoc(docFile(),docLine(),getOuterScope()?getOuterScope():container,this,detailed+"\n",TRUE,FALSE);
if (!m_impl->inbodyDocs.isEmpty())
diff --git a/src/msc.cpp b/src/msc.cpp
new file mode 100644
index 0000000..afde2ed
--- /dev/null
+++ b/src/msc.cpp
@@ -0,0 +1,172 @@
+/******************************************************************************
+ *
+ *
+ *
+ * Copyright (C) 1997-2007 by Dimitri van Heesch.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation under the terms of the GNU General Public License is hereby
+ * granted. No representations are made about the suitability of this software
+ * for any purpose. It is provided "as is" without express or implied warranty.
+ * See the GNU General Public License for more details.
+ *
+ * Documents produced by Doxygen are derivative works derived from the
+ * input used in their production; they are not affected by this license.
+ *
+ */
+
+#include "msc.h"
+#include "portable.h"
+#include "config.h"
+#include "message.h"
+#include "docparser.h"
+#include "doxygen.h"
+
+#include <qdir.h>
+
+static const int maxCmdLine = 40960;
+
+static bool convertMapFile(QTextStream &t,const char *mapName,const QCString relPath)
+{
+ QFile f(mapName);
+ if (!f.open(IO_ReadOnly))
+ {
+ err("Error opening map file %s for inclusion in the docs!\n",mapName);
+ return FALSE;
+ }
+ const int maxLineLen=1024;
+ char buf[maxLineLen];
+ char url[maxLineLen];
+ char ref[maxLineLen];
+ int x1,y1,x2,y2;
+ while (!f.atEnd())
+ {
+ bool isRef = FALSE;
+ int numBytes = f.readLine(buf,maxLineLen);
+ buf[numBytes-1]='\0';
+ //printf("ReadLine `%s'\n",buf);
+ if (strncmp(buf,"rect",4)==0)
+ {
+ // obtain the url and the coordinates in the order used by graphviz-1.5
+ sscanf(buf,"rect %s %d,%d %d,%d",url,&x1,&y1,&x2,&y2);
+
+ if ( strcmp(url,"\\ref") == 0 )
+ {
+ isRef = TRUE;
+ sscanf(buf,"rect %s %s %d,%d %d,%d",ref,url,&x1,&y1,&x2,&y2);
+ }
+
+ // sanity checks
+ if (y2<y1) { int temp=y2; y2=y1; y1=temp; }
+ if (x2<x1) { int temp=x2; x2=x1; x1=temp; }
+
+ t << "<area href=\"";
+
+ if ( isRef )
+ {
+ // handle doxygen \ref tag URL reference
+ QCString *dest;
+ DocRef *df = new DocRef( (DocNode*) 0, url );
+ if (!df->ref().isEmpty())
+ {
+ if ((dest=Doxygen::tagDestinationDict[df->ref()])) t << *dest << "/";
+ }
+ if (!df->file().isEmpty()) t << relPath << df->file() << Doxygen::htmlFileExtension;
+ if (!df->anchor().isEmpty()) t << "#" << df->anchor();
+ }
+ else
+ {
+ t << url;
+ }
+ t << "\" shape=\"rect\" coords=\""
+ << x1 << "," << y1 << "," << x2 << "," << y2 << "\""
+ << " alt=\"\">" << endl;
+ }
+ }
+
+ return TRUE;
+}
+void writeMscGraphFromFile(const char *inFile,const char *outDir,
+ const char *outFile,MscOutputFormat format)
+{
+ QCString absOutFile = outDir;
+ absOutFile+=portable_pathSeparator();
+ absOutFile+=outFile;
+
+ // chdir to the output dir, so dot can find the font file.
+ QCString oldDir = convertToQCString(QDir::currentDirPath());
+ // go to the html output directory (i.e. path)
+ QDir::setCurrent(outDir);
+ //printf("Going to dir %s\n",QDir::currentDirPath().data());
+ QCString mscExe = /*Config_getString("MSC_PATH")+*/ "mscgen";
+ QCString mscArgs;
+ QCString extension;
+ if (format==MSC_BITMAP)
+ {
+ mscArgs+="-T png";
+ extension=".png";
+ }
+ else if (format==MSC_EPS)
+ {
+ mscArgs+="-T eps";
+ extension=".eps";
+ }
+ mscArgs+=" -i \"";
+ mscArgs+=inFile;
+ mscArgs+=".msc\" -o \"";
+ mscArgs+=outFile;
+ mscArgs+=extension+"\"";
+ int exitCode;
+ //printf("*** running: %s %s\n",mscExe.data(),mscArgs.data());
+ if ((exitCode=portable_system(mscExe,mscArgs,FALSE))!=0)
+ {
+ goto error;
+ }
+ if ( (format==MSC_EPS) && (Config_getBool("USE_PDFLATEX")) )
+ {
+ QCString epstopdfArgs(maxCmdLine);
+ epstopdfArgs.sprintf("\"%s.eps\" --outfile=\"%s.pdf\"",
+ outFile,outFile);
+ if (portable_system("epstopdf",epstopdfArgs)!=0)
+ {
+ err("Error: Problems running epstopdf. Check your TeX installation!\n");
+ }
+ }
+
+error:
+ QDir::setCurrent(oldDir);
+}
+
+QString getMscImageMapFromFile(const QString& inFile, const QString& outDir,
+ const QCString& relPath)
+{
+ QString outFile = inFile + ".map";
+
+ // chdir to the output dir, so dot can find the font file.
+ QCString oldDir = convertToQCString(QDir::currentDirPath());
+ // go to the html output directory (i.e. path)
+ QDir::setCurrent(outDir);
+ //printf("Going to dir %s\n",QDir::currentDirPath().data());
+
+ QCString mscExe = "mscgen";
+ QCString mscArgs = "-T ismap -i \"";
+ mscArgs+=inFile + ".msc\" -o \"";
+ mscArgs+=outFile + ".map\"";
+
+ int exitCode;
+ if ((exitCode=portable_system(mscExe,mscArgs,FALSE))!=0)
+ {
+ QDir::setCurrent(oldDir);
+ return "";
+ }
+
+ QString result;
+ QTextOStream tmpout(&result);
+ convertMapFile(tmpout, outFile+".map", relPath);
+ QDir().remove(outFile);
+
+ QDir::setCurrent(oldDir);
+ return result;
+}
+
+
diff --git a/src/msc.h b/src/msc.h
new file mode 100644
index 0000000..74a15ea
--- /dev/null
+++ b/src/msc.h
@@ -0,0 +1,32 @@
+/******************************************************************************
+ *
+ *
+ *
+ * Copyright (C) 1997-2007 by Dimitri van Heesch.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation under the terms of the GNU General Public License is hereby
+ * granted. No representations are made about the suitability of this software
+ * for any purpose. It is provided "as is" without express or implied warranty.
+ * See the GNU General Public License for more details.
+ *
+ * Documents produced by Doxygen are derivative works derived from the
+ * input used in their production; they are not affected by this license.
+ *
+ */
+
+#ifndef _MSC_H
+#define _MSC_H
+
+#include "qtbc.h"
+
+enum MscOutputFormat { MSC_BITMAP , MSC_EPS };
+
+void writeMscGraphFromFile(const char *inFile,const char *outDir,
+ const char *outFile,MscOutputFormat format);
+
+QString getMscImageMapFromFile(const QString& inFile, const QString& outDir,
+ const QCString& relPath);
+
+#endif
+
diff --git a/src/perlmodgen.cpp b/src/perlmodgen.cpp
index 73f25db..dadc439 100644
--- a/src/perlmodgen.cpp
+++ b/src/perlmodgen.cpp
@@ -629,6 +629,7 @@ void PerlModDocVisitor::visit(DocVerbatim *s)
case DocVerbatim::LatexOnly: type = "latexonly"; break;
case DocVerbatim::XmlOnly: type = "xmlonly"; break;
case DocVerbatim::Dot: type = "dot"; break;
+ case DocVerbatim::Msc: type = "msc"; break;
}
openItem(type);
m_output.addFieldQuotedString("content", s->text());
diff --git a/src/portable.cpp b/src/portable.cpp
index 94f8c20..8a0d6e5 100644
--- a/src/portable.cpp
+++ b/src/portable.cpp
@@ -127,7 +127,10 @@ int portable_system(const char *command,const char *args,bool commandHasConsole
SHELLEXECUTEINFO sInfo = {
sizeof(SHELLEXECUTEINFO), /* structure size */
- SEE_MASK_NOCLOSEPROCESS | SEE_MASK_FLAG_NO_UI, /* leave the process running */
+ SEE_MASK_NOCLOSEPROCESS | SEE_MASK_FLAG_NO_UI, /* tell us the process
+ * handle so we can wait till it's done |
+ * do not display msg box if error
+ */
NULL, /* window handle */
NULL, /* action to perform: open */
command, /* file to execute */
@@ -334,12 +337,12 @@ const char *portable_ghostScriptCommand()
#endif
}
-const char *portable_dotCommand()
+const char *portable_commandExtension()
{
#if defined(_WIN32) && !defined(__CYGWIN__)
- return "dot.exe";
+ return ".exe";
#else
- return "dot";
+ return "";
#endif
}
diff --git a/src/portable.h b/src/portable.h
index 0a88079..cf21902 100644
--- a/src/portable.h
+++ b/src/portable.h
@@ -24,7 +24,7 @@ portable_off_t portable_ftell(FILE *f);
char portable_pathSeparator();
char portable_pathListSeparator();
const char * portable_ghostScriptCommand();
-const char * portable_dotCommand();
+const char * portable_commandExtension();
bool portable_fileSystemIsCaseSensitive();
FILE * portable_popen(const char *name,const char *type);
int portable_pclose(FILE *stream);
diff --git a/src/printdocvisitor.h b/src/printdocvisitor.h
index faf9b16..27db658 100644
--- a/src/printdocvisitor.h
+++ b/src/printdocvisitor.h
@@ -151,6 +151,7 @@ class PrintDocVisitor : public DocVisitor
case DocVerbatim::LatexOnly: printf("<latexonly>"); break;
case DocVerbatim::XmlOnly: printf("<xmlonly>"); break;
case DocVerbatim::Dot: printf("<dot>"); break;
+ case DocVerbatim::Msc: printf("<msc>"); break;
}
printf("%s",s->text().data());
switch(s->type())
@@ -162,6 +163,7 @@ class PrintDocVisitor : public DocVisitor
case DocVerbatim::LatexOnly: printf("</latexonly>"); break;
case DocVerbatim::XmlOnly: printf("</xmlonly>"); break;
case DocVerbatim::Dot: printf("</dot>"); break;
+ case DocVerbatim::Msc: printf("</msc>"); break;
}
}
void visit(DocAnchor *a)
diff --git a/src/pyscanner.l b/src/pyscanner.l
index bdd4f71..e6bacc5 100644
--- a/src/pyscanner.l
+++ b/src/pyscanner.l
@@ -606,7 +606,7 @@ STARTDOCSYMS ^{B}"##"/[^#]
<FromModItem>{
"*" { // import all
- QCString item=g_packageName+"."+yytext;
+ QCString item=g_packageName;
current->name=removeRedundantWhiteSpace(substitute(item,".","::"));
current->fileName = yyFileName;
//printf("Adding using directive: found:%s:%d name=%s\n",yyFileName.data(),yyLineNr,current->name.data());
diff --git a/src/rtfdocvisitor.cpp b/src/rtfdocvisitor.cpp
index fb0b1e1..05fe40d 100644
--- a/src/rtfdocvisitor.cpp
+++ b/src/rtfdocvisitor.cpp
@@ -27,6 +27,7 @@
#include "message.h"
#include <qfileinfo.h>
#include "parserintf.h"
+#include "msc.h"
//#define DBG_RTF(x) m_t << x
@@ -372,6 +373,31 @@ void RTFDocVisitor::visit(DocVerbatim *s)
if (Config_getBool("DOT_CLEANUP")) file.remove();
}
break;
+ case DocVerbatim::Msc:
+ {
+ static int mscindex = 1;
+ QCString baseName(4096);
+
+ baseName.sprintf("%s%d",
+ (Config_getString("RTF_OUTPUT")+"/inline_mscgraph_").data(),
+ mscindex++
+ );
+ QFile file(baseName+".msc");
+ if (!file.open(IO_WriteOnly))
+ {
+ err("Could not open file %s for writing\n",baseName.data());
+ }
+ QCString text = "msc {";
+ text+=s->text();
+ text+="}";
+ file.writeBlock( text, text.length() );
+ file.close();
+ m_t << "\\par{\\qc "; // center picture
+ writeMscFile(baseName);
+ m_t << "} ";
+ if (Config_getBool("DOT_CLEANUP")) file.remove();
+ }
+ break;
}
m_lastIsPara=FALSE;
}
@@ -1420,4 +1446,23 @@ void RTFDocVisitor::writeDotFile(const QString &fileName)
m_lastIsPara=TRUE;
}
+void RTFDocVisitor::writeMscFile(const QString &fileName)
+{
+ QString baseName=fileName;
+ int i;
+ if ((i=baseName.findRev('/'))!=-1)
+ {
+ baseName=baseName.right(baseName.length()-i-1);
+ }
+ QString outDir = Config_getString("RTF_OUTPUT");
+ writeMscGraphFromFile(fileName,outDir,baseName,MSC_BITMAP);
+ if (!m_lastIsPara) m_t << "\\par" << endl;
+ m_t << "{" << endl;
+ m_t << rtf_Style_Reset;
+ m_t << "\\pard \\qc {\\field\\flddirty {\\*\\fldinst INCLUDEPICTURE \"";
+ m_t << baseName << ".png";
+ m_t << "\" \\\\d \\\\*MERGEFORMAT}{\\fldrslt IMAGE}}\\par" << endl;
+ m_t << "}" << endl;
+ m_lastIsPara=TRUE;
+}
diff --git a/src/rtfdocvisitor.h b/src/rtfdocvisitor.h
index 63aa662..02bc904 100644
--- a/src/rtfdocvisitor.h
+++ b/src/rtfdocvisitor.h
@@ -144,6 +144,7 @@ class RTFDocVisitor : public DocVisitor
void pushEnabled();
void popEnabled();
void writeDotFile(const QString &fileName);
+ void writeMscFile(const QString &fileName);
//--------------------------------------
// state variables
diff --git a/src/scanner.l b/src/scanner.l
index ec6ff31..e4180dc 100644
--- a/src/scanner.l
+++ b/src/scanner.l
@@ -1070,6 +1070,29 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?)
<FindMembers>{BN}{1,80} {
lineCount();
}
+<FindMembers>"@"{ID}{BN}*"(" {
+ if (insideJava) // Java annotation
+ {
+ lineCount();
+ lastSkipRoundContext = YY_START;
+ roundCount=1;
+ BEGIN( SkipRound );
+ }
+ else
+ {
+ REJECT;
+ }
+ }
+<FindMembers>"@"{ID} {
+ if (insideJava) // Java annotation
+ {
+ // skip annotation
+ }
+ else
+ {
+ REJECT;
+ }
+ }
<PackageName>{ID}("."{ID})* {
isTypedef=FALSE;
current->name = yytext;
@@ -1186,7 +1209,7 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?)
current->name = QCString(yytext).stripWhiteSpace();
}
}
-<FindMembers>{B}*((("disp")?"interface")|"valuetype"){BN}+ { // M$/Corba IDL interface
+<FindMembers>{B}*((("disp")?"interface")|"valuetype"){BN}+ { // M$/Corba IDL/Java interface
lineCount();
if (insideIDL || insideJava || insideCS || insideD || insidePHP)
{
@@ -1219,12 +1242,12 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?)
current->bodyLine = yyLineNr;
BEGIN( CompoundName );
}
-<FindMembers>{B}*"@interface"{BN}+ { // Objective-C class interface
+<FindMembers>{B}*"@interface"{BN}+ { // Objective-C class interface, or Java attribute
lineCount();
isTypedef=FALSE;
current->section = Entry::CLASS_SEC;
current->spec = Entry::Interface;
- current->objc = insideObjC = TRUE;
+ current->objc = insideObjC = !insideJava;
current->protection = protection = Public ;
addType( current ) ;
current->type += " interface" ;
@@ -1593,7 +1616,16 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?)
sharpCount++;
}
<EndTemplate>">>" {
- current->name+=yytext;
+ if (insideJava || insideCS)
+ {
+ unput('>');
+ unput(' ');
+ unput('>');
+ }
+ else
+ {
+ current->name+=yytext;
+ }
// *currentTemplateSpec+=yytext;
}
<EndTemplate>">" {
diff --git a/src/translator_br.h b/src/translator_br.h
index da6bdbd..2a0eade 100644
--- a/src/translator_br.h
+++ b/src/translator_br.h
@@ -1016,6 +1016,8 @@ class TranslatorBrazilian : public Translator
"class Undocumented { };\n\n"
"/*! Class that is inherited using public inheritance */\n"
"class PublicBase : public Truncated { };\n\n"
+ "/*! A template class */\n"
+ "template<class T> class Templ { };\n\n"
"/*! Class that is inherited using protected inheritance */\n"
"class ProtectedBase { };\n\n"
"/*! Class that is inherited using private inheritance */\n"
@@ -1026,7 +1028,8 @@ class TranslatorBrazilian : public Translator
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
+ " public Templ<int>\n"
"{\n"
" private:\n"
" Used *m_usedClass;\n"
diff --git a/src/translator_ca.h b/src/translator_ca.h
index 5380d0a..03a6fa6 100644
--- a/src/translator_ca.h
+++ b/src/translator_ca.h
@@ -1038,7 +1038,7 @@ class TranslatorCatalan : public Translator
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
" public Templ<int>\n"
"{\n"
" private:\n"
diff --git a/src/translator_cn.h b/src/translator_cn.h
index ac2bb6d..4c3168b 100644
--- a/src/translator_cn.h
+++ b/src/translator_cn.h
@@ -912,6 +912,8 @@ class TranslatorChinese : public Translator
"class Undocumented { };\n\n"
"/*! ±»¹«Óм̳еÄÀà */\n"
"class PublicBase : public Truncated { };\n\n"
+ "/*! A template class */\n"
+ "template<class T> class Templ { };\n\n"
"/*! ±»±£»¤¼Ì³ÐµÄÀà */\n"
"class ProtectedBase { };\n\n"
"/*! ±»Ë½Óм̳еÄÀà */\n"
@@ -922,7 +924,8 @@ class TranslatorChinese : public Translator
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
+ " public Templ<int>\n"
"{\n"
" private:\n"
" Used *m_usedClass;\n"
diff --git a/src/translator_de.h b/src/translator_de.h
index f36c971..fd1313d 100644
--- a/src/translator_de.h
+++ b/src/translator_de.h
@@ -1126,7 +1126,7 @@ class TranslatorGerman : public Translator
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
" public Templ<int>\n"
"{\n"
" private:\n"
diff --git a/src/translator_dk.h b/src/translator_dk.h
index c6fe415..70ff479 100644
--- a/src/translator_dk.h
+++ b/src/translator_dk.h
@@ -1002,7 +1002,7 @@ class TranslatorDanish : public Translator
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
" public Templ<int>\n"
"{\n"
" private:\n"
diff --git a/src/translator_en.h b/src/translator_en.h
index b53a355..c6fde5b 100644
--- a/src/translator_en.h
+++ b/src/translator_en.h
@@ -1039,7 +1039,7 @@ class TranslatorEnglish : public Translator
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
" public Templ<int>\n"
"{\n"
" private:\n"
diff --git a/src/translator_es.h b/src/translator_es.h
index 996665d..d145f69 100644
--- a/src/translator_es.h
+++ b/src/translator_es.h
@@ -1013,7 +1013,7 @@ class TranslatorSpanish : public Translator
"class PublicBase : public Truncated { };\n\n"
"/*! Clase plantilla */\n"
"template<class T> class Templ { };\n\n"
- "/*! Clase que es heredera usando herencia protegida */\n"
+ "/*! Clase que es heredera usando herencia protegida */\n"
"class ProtectedBase { };\n\n"
"/*! Clase que es heredera usando herencia privada */\n"
"class PrivateBase { };\n\n"
@@ -1023,7 +1023,7 @@ class TranslatorSpanish : public Translator
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
" public Templ<int>\n"
"{\n"
" private:\n"
diff --git a/src/translator_fr.h b/src/translator_fr.h
index f79b0cc..0ee59b5 100644
--- a/src/translator_fr.h
+++ b/src/translator_fr.h
@@ -1184,7 +1184,7 @@ class TranslatorFrench : public Translator
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
" public Templ<int>\n"
"{\n"
" private:\n"
diff --git a/src/translator_gr.h b/src/translator_gr.h
index 3faae08..224fe99 100644
--- a/src/translator_gr.h
+++ b/src/translator_gr.h
@@ -1027,6 +1027,8 @@ class TranslatorGreek : public Translator
"class Undocumented { };\n\n"
"/*! Class that is inherited using public inheritance */\n"
"class PublicBase : public Truncated { };\n\n"
+ "/*! A template class */\n"
+ "template<class T> class Templ { };\n\n"
"/*! Class that is inherited using protected inheritance */\n"
"class ProtectedBase { };\n\n"
"/*! Class that is inherited using private inheritance */\n"
@@ -1037,7 +1039,8 @@ class TranslatorGreek : public Translator
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
+ " public Templ<int>\n"
"{\n"
" private:\n"
" Used *m_usedClass;\n"
diff --git a/src/translator_hr.h b/src/translator_hr.h
index 7779087..81d29f1 100644
--- a/src/translator_hr.h
+++ b/src/translator_hr.h
@@ -757,6 +757,8 @@ class TranslatorCroatian : public Translator
"class Undocumented { };\n\n"
"/*! Klasa koja je naslijeðena public */\n"
"class PublicBase : public Truncated { };\n\n"
+ "/*! A template class */\n"
+ "template<class T> class Templ { };\n\n"
"/*! Klasa koje je naslijeðena protected */\n"
"class ProtectedBase { };\n\n"
"/*! Klasa koje je naslijeðena private */\n"
@@ -767,7 +769,8 @@ class TranslatorCroatian : public Translator
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
+ " public Templ<int>\n"
"{\n"
" private:\n"
" Used *m_usedClass;\n"
diff --git a/src/translator_hu.h b/src/translator_hu.h
index 3325125..dd3e405 100644
--- a/src/translator_hu.h
+++ b/src/translator_hu.h
@@ -1018,7 +1018,7 @@ class TranslatorHungarian : public TranslatorAdapter_1_4_6
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
" public Templ<int>\n"
"{\n"
" private:\n"
diff --git a/src/translator_id.h b/src/translator_id.h
index 053f0d6..311e0a8 100644
--- a/src/translator_id.h
+++ b/src/translator_id.h
@@ -1049,7 +1049,7 @@ class TranslatorIndonesian : public TranslatorAdapter_1_4_6
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
" public Templ<int>\n"
"{\n"
" private:\n"
diff --git a/src/translator_it.h b/src/translator_it.h
index c289807..edaba52 100644
--- a/src/translator_it.h
+++ b/src/translator_it.h
@@ -1029,6 +1029,8 @@ class TranslatorItalian : public Translator
"class Undocumented { };\n\n"
"/*! Classe che utilizza una ereditarietà pubblica */\n"
"class PublicBase : public Truncated { };\n\n"
+ "/*! A template class */\n"
+ "template<class T> class Templ { };\n\n"
"/*! Classe che utilizza una ereditarietà protetta*/\n"
"class ProtectedBase { };\n\n"
"/*! Classe che utilizza una ereditarietà privata*/\n"
@@ -1039,7 +1041,8 @@ class TranslatorItalian : public Translator
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
+ " public Templ<int>\n"
"{\n"
" private:\n"
" Used *m_usedClass;\n"
diff --git a/src/translator_jp.h b/src/translator_jp.h
index 1b509b4..ff226d8 100644
--- a/src/translator_jp.h
+++ b/src/translator_jp.h
@@ -1001,6 +1001,8 @@ class TranslatorJapanese : public Translator
"class Undocumented { };\n\n"
"/*! public ¤Ç·Ñ¾µ¤µ¤ì¤¿¥¯¥é¥¹ */\n"
"class PublicBase : public Truncated { };\n\n"
+ "/*! A template class */\n"
+ "template<class T> class Templ { };\n\n"
"/*! protected ¤Ç·Ñ¾µ¤µ¤ì¤¿¥¯¥é¥¹ */\n"
"class ProtectedBase { };\n\n"
"/*! private ¤Ç·Ñ¾µ¤µ¤ì¤¿¥¯¥é¥¹ */\n"
@@ -1011,7 +1013,8 @@ class TranslatorJapanese : public Translator
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
+ " public Templ<int>\n"
"{\n"
" private:\n"
" Used *m_usedClass;\n"
diff --git a/src/translator_kr.h b/src/translator_kr.h
index 2593e02..7125c40 100644
--- a/src/translator_kr.h
+++ b/src/translator_kr.h
@@ -1008,7 +1008,7 @@ class TranslatorKorean : public TranslatorAdapter_1_4_6
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
" public Templ<int>\n"
"{\n"
" private:\n"
diff --git a/src/translator_lt.h b/src/translator_lt.h
index 72c4199..35ec74f 100644
--- a/src/translator_lt.h
+++ b/src/translator_lt.h
@@ -1027,7 +1027,7 @@ class TranslatorLithuanian : public TranslatorAdapter_1_4_6
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
" public Templ<int>\n"
"{\n"
" private:\n"
diff --git a/src/translator_nl.h b/src/translator_nl.h
index fcf821cb..e2f1e1a 100644
--- a/src/translator_nl.h
+++ b/src/translator_nl.h
@@ -655,6 +655,8 @@ class TranslatorDutch : public Translator
"class Undocumented { };\n\n"
"/*! Klasse met public inheritance */\n"
"class PublicBase : public Truncated { };\n\n"
+ "/*! A template class */\n"
+ "template<class T> class Templ { };\n\n"
"/*! Klasse met protected inheritance */\n"
"class ProtectedBase { };\n\n"
"/*! Klasse met private inheritance */\n"
@@ -665,7 +667,8 @@ class TranslatorDutch : public Translator
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
+ " public Templ<int>\n"
"{\n"
" private:\n"
" Used *m_usedClass;\n"
diff --git a/src/translator_no.h b/src/translator_no.h
index 35df614..761afc2 100644
--- a/src/translator_no.h
+++ b/src/translator_no.h
@@ -1057,6 +1057,8 @@ class TranslatorNorwegian : public TranslatorAdapter_1_4_6
"class Undocumented { };\n\n"
"/*! Klasse med public-arv */\n"
"class PublicBase : public Truncated { };\n\n"
+ "/*! A template class */\n"
+ "template<class T> class Templ { };\n\n"
"/*! Klasse med protected-arv */\n"
"class ProtectedBase { };\n\n"
"/*! Klasse med private-arv */\n"
@@ -1067,7 +1069,7 @@ class TranslatorNorwegian : public TranslatorAdapter_1_4_6
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
" public Templ<int>\n"
"{\n"
" private:\n"
diff --git a/src/translator_pl.h b/src/translator_pl.h
index 71af4c8..c911b5d 100644
--- a/src/translator_pl.h
+++ b/src/translator_pl.h
@@ -1044,6 +1044,8 @@ class TranslatorPolish : public TranslatorAdapter_1_4_6
"class Nieudokumentowana { };\n\n"
"/*! Klasa, która jest dziedziczona publicznie */\n"
"class PublicznaBaza : public Okrojona { };\n\n"
+ "/*! A template class */\n"
+ "template<class T> class Templ { };\n\n"
"/*! Klasa, która jest dziedziczona przy u¿yciu dziedziczenia chronionego */\n"
"class ChronionaBaza { };\n\n"
"/*! Klasa, która jest dziedziczona prywatnie */\n"
@@ -1054,7 +1056,8 @@ class TranslatorPolish : public TranslatorAdapter_1_4_6
"class Dziedziczona : public PublicznaBaza,\n"
" protected ChronionaBaza,\n"
" private PrywatnaBaza,\n"
- " public Nieudokumentowana\n"
+ " public Nieudokumentowana,\n"
+ " public Templ<int>\n"
"{\n"
" private:\n"
" Uzyta *m_usedClass;\n"
diff --git a/src/translator_pt.h b/src/translator_pt.h
index ebe8ce9..657460f 100644
--- a/src/translator_pt.h
+++ b/src/translator_pt.h
@@ -1043,6 +1043,8 @@ class TranslatorPortuguese : public TranslatorAdapter_1_3_3
"class Undocumented { };\n\n"
"/*! Classe derivada usando derivação pública */\n"
"class PublicBase : public Truncated { };\n\n"
+ "/*! A template class */\n"
+ "template<class T> class Templ { };\n\n"
"/*! Classe derivada usando derivação protegida */\n"
"class ProtectedBase { };\n\n"
"/*! Classe derivada usando derivação privada */\n"
@@ -1053,7 +1055,8 @@ class TranslatorPortuguese : public TranslatorAdapter_1_3_3
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
+ " public Templ<int>\n"
"{\n"
" private:\n"
" Used *m_usedClass;\n"
diff --git a/src/translator_ro.h b/src/translator_ro.h
index 32fb99c..b2e5e46 100644
--- a/src/translator_ro.h
+++ b/src/translator_ro.h
@@ -1073,6 +1073,8 @@ class TranslatorRomanian : public TranslatorAdapter_1_4_1
"class Undocumented { };\n\n"
"/*! Clasã care este moºtenitã în mod public */\n"
"class PublicBase : public Truncated { };\n\n"
+ "/*! A template class */\n"
+ "template<class T> class Templ { };\n\n"
"/*! Clasã care este moºtenitã în mod protejat */\n"
"class ProtectedBase { };\n\n"
"/*! Clasã care este moºtenitã în mod privat */\n"
@@ -1083,7 +1085,8 @@ class TranslatorRomanian : public TranslatorAdapter_1_4_1
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
+ " public Templ<int>\n"
"{\n"
" private:\n"
" Used *m_usedClass;\n"
diff --git a/src/translator_se.h b/src/translator_se.h
index a474915..ee50224 100644
--- a/src/translator_se.h
+++ b/src/translator_se.h
@@ -917,7 +917,7 @@ class TranslatorSwedish : public TranslatorAdapter_1_4_6
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
" public Templ<int>\n"
"{\n"
" private:\n"
diff --git a/src/translator_si.h b/src/translator_si.h
index d5fb31e..0549d5e 100644
--- a/src/translator_si.h
+++ b/src/translator_si.h
@@ -684,6 +684,8 @@ class TranslatorSlovene : public TranslatorAdapter_1_4_6
"class Undocumented { };\n\n"
"/*! Razred, ki ga dedujemo s pomoèjo javnega dedovanja */\n"
"class PublicBase : public Truncated { };\n\n"
+ "/*! A template class */\n"
+ "template<class T> class Templ { };\n\n"
"/*! Razred, ki ga dedujemo s pomoèjo za¹èitenega dedovanja */\n"
"class ProtectedBase { };\n\n"
"/*! Razred, ki ga dedujemo s pomoèjo skritega dedovanja */\n"
@@ -694,7 +696,8 @@ class TranslatorSlovene : public TranslatorAdapter_1_4_6
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
+ " public Templ<int>\n"
"{\n"
" private:\n"
" Used *m_usedClass;\n"
diff --git a/src/translator_sk.h b/src/translator_sk.h
index 20bf1d1..f696620 100644
--- a/src/translator_sk.h
+++ b/src/translator_sk.h
@@ -1055,6 +1055,8 @@ class TranslatorSlovak : public TranslatorAdapter_1_2_18
"/*! Odvodená trieda s verejným (public) dedením bázovej triedy. */\n"
"class PublicBase : public Truncated { };\n\n"
"/*! Odvodená trieda s chráneným (protected) dedením bázovej triedy. */\n"
+ "/*! A template class */\n"
+ "template<class T> class Templ { };\n\n"
"class ProtectedBase { };\n\n"
"/*! Odvodená trieda s privátnym dedením bázovej triedy. */\n"
"class PrivateBase { };\n\n"
@@ -1063,9 +1065,10 @@ class TranslatorSlovak : public TranslatorAdapter_1_2_18
"/*! Odvodená trieda, ktorá rôznym spôsobom dedí od viacerých bázových "
"tried. */\n"
"class Inherited : public PublicBase,\n"
- " protected ProtectedBase,\n"
- " private PrivateBase,\n"
- " public Undocumented\n"
+ " protected ProtectedBase,\n"
+ " private PrivateBase,\n"
+ " public Undocumented,\n"
+ " public Templ<int>\n"
"{\n"
" private:\n"
" Used *m_usedClass;\n"
diff --git a/src/translator_sr.h b/src/translator_sr.h
index 6445d1e..b951e5c 100644
--- a/src/translator_sr.h
+++ b/src/translator_sr.h
@@ -1071,7 +1071,7 @@ private:
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
" public Templ<int>\n"
"{\n"
" private:\n"
diff --git a/src/translator_tw.h b/src/translator_tw.h
index 1fcedba..0ec19d2 100644
--- a/src/translator_tw.h
+++ b/src/translator_tw.h
@@ -1068,7 +1068,7 @@ class TranslatorChinesetraditional : public TranslatorAdapter_1_4_6
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
" public Templ<int>\n"
"{\n"
" private:\n"
diff --git a/src/translator_ua.h b/src/translator_ua.h
index c9460de..7ba2235 100644
--- a/src/translator_ua.h
+++ b/src/translator_ua.h
@@ -1056,6 +1056,8 @@ class TranslatorUkrainian : public TranslatorAdapter_1_4_1
"class Undocumented { };\n\n"
"/*! úÁÇÁÌØÎÏÄÏÓÔÕÐÎÅ ÕÓÐÁÄËÕ×ÁÎÎÑ */\n"
"class PublicBase : public Truncated { };\n\n"
+ "/*! A template class */\n"
+ "template<class T> class Templ { };\n\n"
"/*! úÁÈÉÝÅÎÅ ÕÓÐÁÄËÕ×ÁÎÎÑ */\n"
"class ProtectedBase { };\n\n"
"/*! ðÒÉ×ÁÔÎÅ ÕÓÐÁÄËÕ×ÁÎÎÑ */\n"
@@ -1066,7 +1068,8 @@ class TranslatorUkrainian : public TranslatorAdapter_1_4_1
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Undocumented\n"
+ " public Undocumented,\n"
+ " public Templ<int>\n"
"{\n"
" private:\n"
" Used *m_usedClass;\n"
diff --git a/src/translator_za.h b/src/translator_za.h
index 75e0a09..3745d1a 100644
--- a/src/translator_za.h
+++ b/src/translator_za.h
@@ -1021,7 +1021,7 @@ class TranslatorAfrikaans : public TranslatorAdapter_1_4_6
"class Inherited : public PublicBase,\n"
" protected ProtectedBase,\n"
" private PrivateBase,\n"
- " public Ongedokumenteer\n"
+ " public Ongedokumenteer,\n"
" public Templ<int>\n"
"{\n"
" private:\n"
diff --git a/src/translatordecoder.h b/src/translatordecoder.h
index 71610eb..b29ced2 100644
--- a/src/translatordecoder.h
+++ b/src/translatordecoder.h
@@ -71,7 +71,7 @@ class TranslatorDecoder : public Translator
{
oSize -= oLeft;
output.resize(oSize+1);
- output.at(oSize+1)='\0';
+ output.at(oSize)='\0';
return output;
}
else
diff --git a/src/util.cpp b/src/util.cpp
index 985718a..866b555 100644
--- a/src/util.cpp
+++ b/src/util.cpp
@@ -395,6 +395,10 @@ QCString resolveTypeDef(Definition *context,const QCString &qualifiedName,
// qualifiedName.data(),context->name().data(),md->typeString()
// );
result=md->typeString();
+ if (result.find("*)")!=-1) // typedef of a function/member pointer
+ {
+ result+=md->argsString();
+ }
if (typedefContext) *typedefContext=md->getOuterScope();
}
else
@@ -1929,7 +1933,7 @@ QCString recodeString(const QCString &str,const char *fromEncoding,const char *t
{
outputSize-=oLeft;
output.resize(outputSize+1);
- output.at(outputSize+1)='\0';
+ output.at(outputSize)='\0';
//printf("iconv: input size=%d output size=%d\n[%s]\n",size,newSize,srcBuf.data());
}
else
@@ -1966,7 +1970,7 @@ QCString transcodeCharacterStringToUTF8(const QCString &input)
{
outputSize-=oLeft;
output.resize(outputSize+1);
- output.at(outputSize+1)='\0';
+ output.at(outputSize)='\0';
//printf("iconv: input size=%d output size=%d\n[%s]\n",size,newSize,srcBuf.data());
}
else
diff --git a/src/xmldocvisitor.cpp b/src/xmldocvisitor.cpp
index 2fd186a..564438d 100644
--- a/src/xmldocvisitor.cpp
+++ b/src/xmldocvisitor.cpp
@@ -208,6 +208,11 @@ void XmlDocVisitor::visit(DocVerbatim *s)
filter(s->text());
m_t << "</dot>";
break;
+ case DocVerbatim::Msc:
+ m_t << "<msc>";
+ filter(s->text());
+ m_t << "</msc>";
+ break;
}
}