Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
D
doxverilog
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
Elphel
doxverilog
Commits
e24e777d
Commit
e24e777d
authored
Jun 20, 2014
by
Dimitri van Heesch
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'docbook'
Conflicts: src/docbookvisitor.cpp
parents
d7ec9e85
12f5ee8a
Changes
16
Show whitespace changes
Inline
Side-by-side
Showing
16 changed files
with
380 additions
and
217 deletions
+380
-217
config.xml
src/config.xml
+10
-0
context.cpp
src/context.cpp
+6
-6
docbookgen.cpp
src/docbookgen.cpp
+107
-48
docbookvisitor.cpp
src/docbookvisitor.cpp
+64
-66
docparser.cpp
src/docparser.cpp
+10
-5
docparser.h
src/docparser.h
+1
-1
dot.cpp
src/dot.cpp
+148
-61
dot.h
src/dot.h
+9
-7
htmldocvisitor.cpp
src/htmldocvisitor.cpp
+1
-1
htmlgen.cpp
src/htmlgen.cpp
+5
-5
latexdocvisitor.cpp
src/latexdocvisitor.cpp
+1
-1
latexgen.cpp
src/latexgen.cpp
+5
-5
printdocvisitor.h
src/printdocvisitor.h
+4
-3
rtfdocvisitor.cpp
src/rtfdocvisitor.cpp
+1
-1
rtfgen.cpp
src/rtfgen.cpp
+4
-4
xmldocvisitor.cpp
src/xmldocvisitor.cpp
+4
-3
No files found.
src/config.xml
View file @
e24e777d
...
@@ -2760,6 +2760,16 @@ that can be used to generate PDF.
...
@@ -2760,6 +2760,16 @@ that can be used to generate PDF.
The \c DOCBOOK_OUTPUT tag is used to specify where the Docbook pages will be put.
The \c DOCBOOK_OUTPUT tag is used to specify where the Docbook pages will be put.
If a relative path is entered the value of \ref cfg_output_directory "OUTPUT_DIRECTORY" will be put in
If a relative path is entered the value of \ref cfg_output_directory "OUTPUT_DIRECTORY" will be put in
front of it.
front of it.
]]>
</docs>
</option>
<option
type=
'bool'
id=
'DOCBOOK_PROGRAMLISTING'
defval=
'0'
depends=
'GENERATE_DOCBOOK'
>
<docs>
<![CDATA[
If the \c DOCBOOK_PROGRAMLISTING tag is set to \c YES doxygen will
include the program listings (including syntax highlighting
and cross-referencing information) to the DOCBOOK output. Note that
enabling this will significantly increase the size of the DOCBOOK output.
]]>
]]>
</docs>
</docs>
</option>
</option>
...
...
src/context.cpp
View file @
e24e777d
...
@@ -1471,7 +1471,7 @@ class ClassContext::Private : public DefinitionContext<ClassContext::Private>
...
@@ -1471,7 +1471,7 @@ class ClassContext::Private : public DefinitionContext<ClassContext::Private>
{
{
DotClassGraph
*
cg
=
getClassGraph
();
DotClassGraph
*
cg
=
getClassGraph
();
FTextStream
t
(
&
result
);
FTextStream
t
(
&
result
);
cg
->
writeGraph
(
t
,
BITMAP
,
cg
->
writeGraph
(
t
,
GOF_BITMAP
,
EOF_Html
,
g_globals
.
outputDir
,
g_globals
.
outputDir
,
g_globals
.
outputDir
+
portable_pathSeparator
()
+
m_classDef
->
getOutputFileBase
()
+
Doxygen
::
htmlFileExtension
,
g_globals
.
outputDir
+
portable_pathSeparator
()
+
m_classDef
->
getOutputFileBase
()
+
Doxygen
::
htmlFileExtension
,
relPathAsString
(),
TRUE
,
TRUE
,
g_globals
.
dynSectionId
relPathAsString
(),
TRUE
,
TRUE
,
g_globals
.
dynSectionId
...
@@ -1516,7 +1516,7 @@ class ClassContext::Private : public DefinitionContext<ClassContext::Private>
...
@@ -1516,7 +1516,7 @@ class ClassContext::Private : public DefinitionContext<ClassContext::Private>
{
{
DotClassGraph
*
cg
=
getCollaborationGraph
();
DotClassGraph
*
cg
=
getCollaborationGraph
();
FTextStream
t
(
&
result
);
FTextStream
t
(
&
result
);
cg
->
writeGraph
(
t
,
BITMAP
,
cg
->
writeGraph
(
t
,
GOF_BITMAP
,
EOF_Html
,
g_globals
.
outputDir
,
g_globals
.
outputDir
,
g_globals
.
outputDir
+
portable_pathSeparator
()
+
m_classDef
->
getOutputFileBase
()
+
Doxygen
::
htmlFileExtension
,
g_globals
.
outputDir
+
portable_pathSeparator
()
+
m_classDef
->
getOutputFileBase
()
+
Doxygen
::
htmlFileExtension
,
relPathAsString
(),
TRUE
,
TRUE
,
g_globals
.
dynSectionId
relPathAsString
(),
TRUE
,
TRUE
,
g_globals
.
dynSectionId
...
@@ -2197,7 +2197,7 @@ class FileContext::Private : public DefinitionContext<FileContext::Private>
...
@@ -2197,7 +2197,7 @@ class FileContext::Private : public DefinitionContext<FileContext::Private>
{
{
DotInclDepGraph
*
cg
=
getIncludeGraph
();
DotInclDepGraph
*
cg
=
getIncludeGraph
();
FTextStream
t
(
&
result
);
FTextStream
t
(
&
result
);
cg
->
writeGraph
(
t
,
BITMAP
,
cg
->
writeGraph
(
t
,
GOF_BITMAP
,
EOF_Html
,
g_globals
.
outputDir
,
g_globals
.
outputDir
,
g_globals
.
outputDir
+
portable_pathSeparator
()
+
m_fileDef
->
getOutputFileBase
()
+
Doxygen
::
htmlFileExtension
,
g_globals
.
outputDir
+
portable_pathSeparator
()
+
m_fileDef
->
getOutputFileBase
()
+
Doxygen
::
htmlFileExtension
,
relPathAsString
(),
TRUE
,
g_globals
.
dynSectionId
relPathAsString
(),
TRUE
,
g_globals
.
dynSectionId
...
@@ -2228,7 +2228,7 @@ class FileContext::Private : public DefinitionContext<FileContext::Private>
...
@@ -2228,7 +2228,7 @@ class FileContext::Private : public DefinitionContext<FileContext::Private>
{
{
DotInclDepGraph
*
cg
=
getIncludedByGraph
();
DotInclDepGraph
*
cg
=
getIncludedByGraph
();
FTextStream
t
(
&
result
);
FTextStream
t
(
&
result
);
cg
->
writeGraph
(
t
,
BITMAP
,
cg
->
writeGraph
(
t
,
GOF_BITMAP
,
EOF_Html
,
g_globals
.
outputDir
,
g_globals
.
outputDir
,
g_globals
.
outputDir
+
portable_pathSeparator
()
+
m_fileDef
->
getOutputFileBase
()
+
Doxygen
::
htmlFileExtension
,
g_globals
.
outputDir
+
portable_pathSeparator
()
+
m_fileDef
->
getOutputFileBase
()
+
Doxygen
::
htmlFileExtension
,
relPathAsString
(),
TRUE
,
g_globals
.
dynSectionId
relPathAsString
(),
TRUE
,
g_globals
.
dynSectionId
...
@@ -3634,7 +3634,7 @@ class MemberContext::Private : public DefinitionContext<MemberContext::Private>
...
@@ -3634,7 +3634,7 @@ class MemberContext::Private : public DefinitionContext<MemberContext::Private>
DotCallGraph
*
cg
=
getCallGraph
();
DotCallGraph
*
cg
=
getCallGraph
();
QGString
result
;
QGString
result
;
FTextStream
t
(
&
result
);
FTextStream
t
(
&
result
);
cg
->
writeGraph
(
t
,
BITMAP
,
cg
->
writeGraph
(
t
,
GOF_BITMAP
,
EOF_Html
,
g_globals
.
outputDir
,
g_globals
.
outputDir
,
g_globals
.
outputDir
+
portable_pathSeparator
()
+
m_memberDef
->
getOutputFileBase
()
+
Doxygen
::
htmlFileExtension
,
g_globals
.
outputDir
+
portable_pathSeparator
()
+
m_memberDef
->
getOutputFileBase
()
+
Doxygen
::
htmlFileExtension
,
relPathAsString
(),
TRUE
,
g_globals
.
dynSectionId
relPathAsString
(),
TRUE
,
g_globals
.
dynSectionId
...
@@ -3674,7 +3674,7 @@ class MemberContext::Private : public DefinitionContext<MemberContext::Private>
...
@@ -3674,7 +3674,7 @@ class MemberContext::Private : public DefinitionContext<MemberContext::Private>
DotCallGraph
*
cg
=
getCallerGraph
();
DotCallGraph
*
cg
=
getCallerGraph
();
QGString
result
;
QGString
result
;
FTextStream
t
(
&
result
);
FTextStream
t
(
&
result
);
cg
->
writeGraph
(
t
,
BITMAP
,
cg
->
writeGraph
(
t
,
GOF_BITMAP
,
EOF_Html
,
g_globals
.
outputDir
,
g_globals
.
outputDir
,
g_globals
.
outputDir
+
portable_pathSeparator
()
+
m_memberDef
->
getOutputFileBase
()
+
Doxygen
::
htmlFileExtension
,
g_globals
.
outputDir
+
portable_pathSeparator
()
+
m_memberDef
->
getOutputFileBase
()
+
Doxygen
::
htmlFileExtension
,
relPathAsString
(),
TRUE
,
g_globals
.
dynSectionId
relPathAsString
(),
TRUE
,
g_globals
.
dynSectionId
...
...
src/docbookgen.cpp
View file @
e24e777d
...
@@ -210,7 +210,7 @@ class DocbookCodeGenerator : public CodeOutputInterface
...
@@ -210,7 +210,7 @@ class DocbookCodeGenerator : public CodeOutputInterface
{
{
m_t
<<
"<link linkend=
\"
"
<<
m_refId
<<
"
\"
>"
;
m_t
<<
"<link linkend=
\"
"
<<
m_refId
<<
"
\"
>"
;
}
}
m_t
<<
m_lineNumber
;
m_t
<<
m_lineNumber
<<
" "
;
if
(
!
m_refId
.
isEmpty
())
if
(
!
m_refId
.
isEmpty
())
{
{
m_t
<<
"</link>"
;
m_t
<<
"</link>"
;
...
@@ -228,10 +228,10 @@ class DocbookCodeGenerator : public CodeOutputInterface
...
@@ -228,10 +228,10 @@ class DocbookCodeGenerator : public CodeOutputInterface
m_external
.
resize
(
0
);
m_external
.
resize
(
0
);
m_insideCodeLine
=
FALSE
;
m_insideCodeLine
=
FALSE
;
}
}
void
startFontClass
(
const
char
*
/*colorClass*/
)
void
startFontClass
(
const
char
*
colorClass
)
{
{
Docbook_DB
((
"(startFontClass)
\n
"
));
Docbook_DB
((
"(startFontClass)
\n
"
));
m_t
<<
"<emphasis
>"
;
// non DocBook
m_t
<<
"<emphasis
class=
\"
"
<<
colorClass
<<
"
\"
>"
;
m_insideSpecialHL
=
TRUE
;
m_insideSpecialHL
=
TRUE
;
}
}
void
endFontClass
()
void
endFontClass
()
...
@@ -453,7 +453,7 @@ static void generateDocbookForMember(MemberDef *md,FTextStream &t,Definition *de
...
@@ -453,7 +453,7 @@ static void generateDocbookForMember(MemberDef *md,FTextStream &t,Definition *de
if
(
md
->
memberType
()
==
MemberType_Enumeration
)
if
(
md
->
memberType
()
==
MemberType_Enumeration
)
{
{
MemberList
*
enumFields
=
md
->
enumFieldList
();
MemberList
*
enumFields
=
md
->
enumFieldList
();
t
<<
" <para>"
<<
memType
<<
" <link linkend=
\"
"
;
t
<<
" <para>
<literallayout>
"
<<
memType
<<
" <link linkend=
\"
"
;
if
(
md
->
getGroupDef
()
&&
def
->
definitionType
()
==
Definition
::
TypeGroup
)
if
(
md
->
getGroupDef
()
&&
def
->
definitionType
()
==
Definition
::
TypeGroup
)
{
{
t
<<
md
->
getGroupDef
()
->
getOutputFileBase
();
t
<<
md
->
getGroupDef
()
->
getOutputFileBase
();
...
@@ -467,25 +467,25 @@ static void generateDocbookForMember(MemberDef *md,FTextStream &t,Definition *de
...
@@ -467,25 +467,25 @@ static void generateDocbookForMember(MemberDef *md,FTextStream &t,Definition *de
{
{
MemberListIterator
emli
(
*
enumFields
);
MemberListIterator
emli
(
*
enumFields
);
MemberDef
*
emd
;
MemberDef
*
emd
;
t
<<
"
{"
;
t
<<
"
{"
<<
endl
;
int
cnt
=
0
;
int
cnt
=
0
;
for
(
emli
.
toFirst
();(
emd
=
emli
.
current
());
++
emli
)
for
(
emli
.
toFirst
();(
emd
=
emli
.
current
());
++
emli
)
{
{
if
(
cnt
!=
0
)
if
(
cnt
!=
0
)
{
{
t
<<
",
"
;
t
<<
",
"
<<
endl
;
}
}
t
<<
"<link linkend=
\"
"
<<
memberOutputFileBase
(
emd
)
<<
"_1"
<<
emd
->
anchor
()
<<
"
\"
>"
;
t
<<
"<link linkend=
\"
"
<<
memberOutputFileBase
(
emd
)
<<
"_1"
<<
emd
->
anchor
()
<<
"
\"
>"
;
writeDocbookString
(
t
,
emd
->
name
());
writeDocbookString
(
t
,
emd
->
name
());
t
<<
"</link>"
;
t
<<
"</link>"
;
if
(
!
emd
->
initializer
().
isEmpty
())
if
(
!
emd
->
initializer
().
isEmpty
())
{
{
t
<<
"="
;
writeDocbookString
(
t
,
emd
->
initializer
());
writeDocbookString
(
t
,
emd
->
initializer
());
}
}
cnt
++
;
cnt
++
;
}
}
t
<<
"}"
;
t
<<
endl
<<
"}"
;
t
<<
"</literallayout>"
<<
endl
;
}
}
}
}
else
if
(
md
->
memberType
()
==
MemberType_Define
)
else
if
(
md
->
memberType
()
==
MemberType_Define
)
...
@@ -653,20 +653,19 @@ static void generateDocbookForMember(MemberDef *md,FTextStream &t,Definition *de
...
@@ -653,20 +653,19 @@ static void generateDocbookForMember(MemberDef *md,FTextStream &t,Definition *de
t
<<
" </formalpara>"
<<
endl
;
t
<<
" </formalpara>"
<<
endl
;
t
<<
" <para>"
;
t
<<
" <para>"
;
t
<<
"Definition at line "
<<
md
->
getDefLine
()
<<
" of file "
<<
stripPath
(
md
->
getDefFileName
())
<<
endl
;
t
<<
"Definition at line "
<<
md
->
getDefLine
()
<<
" of file "
<<
stripPath
(
md
->
getDefFileName
())
<<
endl
;
t
<<
" <
programlisting
>"
<<
endl
;
t
<<
" <
computeroutput><literallayout
>"
<<
endl
;
t
<<
"{"
<<
endl
;
t
<<
"{"
<<
endl
;
for
(
emli
.
toFirst
();(
emd
=
emli
.
current
());
++
emli
)
for
(
emli
.
toFirst
();(
emd
=
emli
.
current
());
++
emli
)
{
{
writeDocbookString
(
t
,
emd
->
name
());
writeDocbookString
(
t
,
emd
->
name
());
if
(
!
emd
->
initializer
().
isEmpty
())
if
(
!
emd
->
initializer
().
isEmpty
())
{
{
t
<<
"="
;
writeDocbookString
(
t
,
emd
->
initializer
());
writeDocbookString
(
t
,
emd
->
initializer
());
}
}
t
<<
", "
<<
endl
;
t
<<
", "
<<
endl
;
}
}
t
<<
"}"
<<
convertToXML
(
md
->
name
())
<<
";"
<<
endl
;
t
<<
"}"
<<
convertToXML
(
md
->
name
())
<<
";"
<<
endl
;
t
<<
" </
programlisting
>"
<<
endl
;
t
<<
" </
literallayout></computeroutput
>"
<<
endl
;
t
<<
" </para>"
<<
endl
;
t
<<
" </para>"
<<
endl
;
t
<<
" </section>"
<<
endl
;
t
<<
" </section>"
<<
endl
;
}
}
...
@@ -1127,6 +1126,7 @@ static void generateDocbookForClass(ClassDef *cd,FTextStream &ti)
...
@@ -1127,6 +1126,7 @@ static void generateDocbookForClass(ClassDef *cd,FTextStream &ti)
QCString
outputDirectory
=
Config_getString
(
"DOCBOOK_OUTPUT"
);
QCString
outputDirectory
=
Config_getString
(
"DOCBOOK_OUTPUT"
);
QCString
fileName
=
outputDirectory
+
"/"
+
classOutputFileBase
(
cd
)
+
".xml"
;
QCString
fileName
=
outputDirectory
+
"/"
+
classOutputFileBase
(
cd
)
+
".xml"
;
QCString
relPath
=
relativePathToRoot
(
fileName
);
QFile
f
(
fileName
);
QFile
f
(
fileName
);
if
(
!
f
.
open
(
IO_WriteOnly
))
if
(
!
f
.
open
(
IO_WriteOnly
))
{
{
...
@@ -1181,6 +1181,20 @@ static void generateDocbookForClass(ClassDef *cd,FTextStream &ti)
...
@@ -1181,6 +1181,20 @@ static void generateDocbookForClass(ClassDef *cd,FTextStream &ti)
}
}
}
}
if
(
Config_getBool
(
"HAVE_DOT"
)
&&
(
Config_getBool
(
"CLASS_DIAGRAMS"
)
||
Config_getBool
(
"CLASS_GRAPH"
)))
{
t
<<
"<para>Inheritance diagram for "
<<
convertToXML
(
cd
->
name
())
<<
"</para>"
<<
endl
;
DotClassGraph
inheritanceGraph
(
cd
,
DotNode
::
Inheritance
);
inheritanceGraph
.
writeGraph
(
t
,
GOF_BITMAP
,
EOF_DocBook
,
Config_getString
(
"DOCBOOK_OUTPUT"
),
fileName
,
relPath
,
TRUE
,
FALSE
);
}
if
(
Config_getBool
(
"HAVE_DOT"
)
&&
Config_getBool
(
"COLLABORATION_GRAPH"
))
{
t
<<
"<para>Collaboration diagram for "
<<
convertToXML
(
cd
->
name
())
<<
"</para>"
<<
endl
;
DotClassGraph
collaborationGraph
(
cd
,
DotNode
::
Collaboration
);
collaborationGraph
.
writeGraph
(
t
,
GOF_BITMAP
,
EOF_DocBook
,
Config_getString
(
"DOCBOOK_OUTPUT"
),
fileName
,
relPath
,
TRUE
,
FALSE
);
}
writeInnerClasses
(
cd
->
getClassSDict
(),
t
);
writeInnerClasses
(
cd
->
getClassSDict
(),
t
);
writeTemplateList
(
cd
,
t
);
writeTemplateList
(
cd
,
t
);
...
@@ -1369,6 +1383,7 @@ static void generateDocbookForFile(FileDef *fd,FTextStream &ti)
...
@@ -1369,6 +1383,7 @@ static void generateDocbookForFile(FileDef *fd,FTextStream &ti)
QCString
outputDirectory
=
Config_getString
(
"DOCBOOK_OUTPUT"
);
QCString
outputDirectory
=
Config_getString
(
"DOCBOOK_OUTPUT"
);
QCString
fileName
=
outputDirectory
+
"/"
+
fd
->
getOutputFileBase
()
+
".xml"
;
QCString
fileName
=
outputDirectory
+
"/"
+
fd
->
getOutputFileBase
()
+
".xml"
;
QCString
relPath
=
relativePathToRoot
(
fileName
);
QFile
f
(
fileName
);
QFile
f
(
fileName
);
if
(
!
f
.
open
(
IO_WriteOnly
))
if
(
!
f
.
open
(
IO_WriteOnly
))
...
@@ -1413,6 +1428,21 @@ static void generateDocbookForFile(FileDef *fd,FTextStream &ti)
...
@@ -1413,6 +1428,21 @@ static void generateDocbookForFile(FileDef *fd,FTextStream &ti)
t
<<
"</programlisting>"
<<
endl
;
t
<<
"</programlisting>"
<<
endl
;
}
}
}
}
if
(
Config_getBool
(
"HAVE_DOT"
))
{
if
(
Config_getBool
(
"INCLUDE_GRAPH"
))
{
t
<<
"<para>Include dependency diagram for "
<<
convertToXML
(
fd
->
name
())
<<
"</para>"
<<
endl
;
DotInclDepGraph
idepGraph
(
fd
,
FALSE
);
idepGraph
.
writeGraph
(
t
,
GOF_BITMAP
,
EOF_DocBook
,
Config_getString
(
"DOCBOOK_OUTPUT"
),
fileName
,
relPath
,
FALSE
);
}
if
(
Config_getBool
(
"INCLUDED_BY_GRAPH"
))
{
t
<<
"<para>Included by dependency diagram for "
<<
convertToXML
(
fd
->
name
())
<<
"</para>"
<<
endl
;
DotInclDepGraph
ibdepGraph
(
fd
,
TRUE
);
ibdepGraph
.
writeGraph
(
t
,
GOF_BITMAP
,
EOF_DocBook
,
Config_getString
(
"DOCBOOK_OUTPUT"
),
fileName
,
relPath
,
FALSE
);
}
}
if
(
fd
->
getClassSDict
())
if
(
fd
->
getClassSDict
())
{
{
...
@@ -1448,20 +1478,24 @@ static void generateDocbookForFile(FileDef *fd,FTextStream &ti)
...
@@ -1448,20 +1478,24 @@ static void generateDocbookForFile(FileDef *fd,FTextStream &ti)
t
<<
" <title>Detailed Description</title>"
<<
endl
;
t
<<
" <title>Detailed Description</title>"
<<
endl
;
writeDocbookDocBlock
(
t
,
fd
->
briefFile
(),
fd
->
briefLine
(),
fd
,
0
,
fd
->
briefDescription
());
writeDocbookDocBlock
(
t
,
fd
->
briefFile
(),
fd
->
briefLine
(),
fd
,
0
,
fd
->
briefDescription
());
writeDocbookDocBlock
(
t
,
fd
->
docFile
(),
fd
->
docLine
(),
fd
,
0
,
fd
->
documentation
());
writeDocbookDocBlock
(
t
,
fd
->
docFile
(),
fd
->
docLine
(),
fd
,
0
,
fd
->
documentation
());
if
(
Config_getBool
(
"FULL_PATH_NAMES"
))
{
t
<<
" <para>Definition in file "
<<
fd
->
getDefFileName
()
<<
"</para>"
<<
endl
;
t
<<
" <para>Definition in file "
<<
fd
->
getDefFileName
()
<<
"</para>"
<<
endl
;
}
else
{
t
<<
" <para>Definition in file "
<<
stripPath
(
fd
->
getDefFileName
())
<<
"</para>"
<<
endl
;
}
t
<<
" </simplesect>"
<<
endl
;
t
<<
" </simplesect>"
<<
endl
;
/*// TODO: Handling of Program listing for Docbook to be implemented
if
(
Config_getBool
(
"DOCBOOK_PROGRAMLISTING"
))
if
(
Config_getBool
(
"DOCBOOK_PROGRAMLISTING"
))
{
{
t << " <
programlisting
>" << endl;
t
<<
" <
literallayout><computeroutput
>"
<<
endl
;
writeDocbookCodeBlock
(
t
,
fd
);
writeDocbookCodeBlock
(
t
,
fd
);
t << " </
programlisting
>" << endl;
t
<<
" </
computeroutput></literallayout
>"
<<
endl
;
}
}
*/
t
<<
"</section>"
<<
endl
;
t
<<
"</section>"
<<
endl
;
}
}
static
void
generateDocbookForGroup
(
GroupDef
*
gd
,
FTextStream
&
ti
)
static
void
generateDocbookForGroup
(
GroupDef
*
gd
,
FTextStream
&
ti
)
...
@@ -1489,6 +1523,7 @@ static void generateDocbookForGroup(GroupDef *gd,FTextStream &ti)
...
@@ -1489,6 +1523,7 @@ static void generateDocbookForGroup(GroupDef *gd,FTextStream &ti)
QCString
outputDirectory
=
Config_getString
(
"DOCBOOK_OUTPUT"
);
QCString
outputDirectory
=
Config_getString
(
"DOCBOOK_OUTPUT"
);
QCString
fileName
=
outputDirectory
+
"/"
+
gd
->
getOutputFileBase
()
+
".xml"
;
QCString
fileName
=
outputDirectory
+
"/"
+
gd
->
getOutputFileBase
()
+
".xml"
;
QCString
relPath
=
relativePathToRoot
(
fileName
);
QFile
f
(
fileName
);
QFile
f
(
fileName
);
if
(
!
f
.
open
(
IO_WriteOnly
))
if
(
!
f
.
open
(
IO_WriteOnly
))
...
@@ -1503,6 +1538,13 @@ static void generateDocbookForGroup(GroupDef *gd,FTextStream &ti)
...
@@ -1503,6 +1538,13 @@ static void generateDocbookForGroup(GroupDef *gd,FTextStream &ti)
t
<<
" <title>"
<<
convertToXML
(
gd
->
groupTitle
())
<<
"</title>"
<<
endl
;
t
<<
" <title>"
<<
convertToXML
(
gd
->
groupTitle
())
<<
"</title>"
<<
endl
;
if
(
Config_getBool
(
"GROUP_GRAPHS"
)
&&
Config_getBool
(
"HAVE_DOT"
))
{
t
<<
"<para>Collaboration diagram for "
<<
convertToXML
(
gd
->
groupTitle
())
<<
"</para>"
<<
endl
;
DotGroupCollaboration
collaborationGraph
(
gd
);
collaborationGraph
.
writeGraph
(
t
,
GOF_BITMAP
,
EOF_DocBook
,
Config_getString
(
"DOCBOOK_OUTPUT"
),
fileName
,
relPath
,
FALSE
);
}
if
(
gd
->
briefDescription
())
if
(
gd
->
briefDescription
())
{
{
t
<<
" <simplesect>"
<<
endl
;
t
<<
" <simplesect>"
<<
endl
;
...
@@ -1570,6 +1612,8 @@ static void generateDocbookForDir(DirDef *dd,FTextStream &ti)
...
@@ -1570,6 +1612,8 @@ static void generateDocbookForDir(DirDef *dd,FTextStream &ti)
QCString
outputDirectory
=
Config_getString
(
"DOCBOOK_OUTPUT"
);
QCString
outputDirectory
=
Config_getString
(
"DOCBOOK_OUTPUT"
);
QCString
fileName
=
outputDirectory
+
"/"
+
dd
->
getOutputFileBase
()
+
".xml"
;
QCString
fileName
=
outputDirectory
+
"/"
+
dd
->
getOutputFileBase
()
+
".xml"
;
QFile
f
(
fileName
);
QFile
f
(
fileName
);
QCString
relPath
=
relativePathToRoot
(
fileName
);
if
(
!
f
.
open
(
IO_WriteOnly
))
if
(
!
f
.
open
(
IO_WriteOnly
))
{
{
err
(
"Cannot open file %s for writing!
\n
"
,
fileName
.
data
());
err
(
"Cannot open file %s for writing!
\n
"
,
fileName
.
data
());
...
@@ -1584,6 +1628,12 @@ static void generateDocbookForDir(DirDef *dd,FTextStream &ti)
...
@@ -1584,6 +1628,12 @@ static void generateDocbookForDir(DirDef *dd,FTextStream &ti)
writeDocbookString
(
t
,
dd
->
displayName
());
writeDocbookString
(
t
,
dd
->
displayName
());
t
<<
" Directory Reference"
;
t
<<
" Directory Reference"
;
t
<<
"</title>"
<<
endl
;
t
<<
"</title>"
<<
endl
;
if
(
Config_getBool
(
"DIRECTORY_GRAPH"
)
&&
Config_getBool
(
"HAVE_DOT"
))
{
t
<<
"<para>Directory dependency diagram for "
<<
convertToXML
(
dd
->
displayName
())
<<
"</para>"
<<
endl
;
DotDirDeps
dirdepGraph
(
dd
);
dirdepGraph
.
writeGraph
(
t
,
GOF_BITMAP
,
EOF_DocBook
,
Config_getString
(
"DOCBOOK_OUTPUT"
),
fileName
,
relPath
,
FALSE
);
}
writeInnerDirs
(
&
dd
->
subDirs
(),
t
);
writeInnerDirs
(
&
dd
->
subDirs
(),
t
);
writeInnerFiles
(
dd
->
getFiles
(),
t
);
writeInnerFiles
(
dd
->
getFiles
(),
t
);
...
@@ -1628,7 +1678,13 @@ static void generateDocbookForPage(PageDef *pd,FTextStream &ti,bool isExample)
...
@@ -1628,7 +1678,13 @@ static void generateDocbookForPage(PageDef *pd,FTextStream &ti,bool isExample)
FTextStream
t
(
&
f
);
FTextStream
t
(
&
f
);
//t.setEncoding(FTextStream::UnicodeUTF8);
//t.setEncoding(FTextStream::UnicodeUTF8);
if
(
!
pd
->
hasParentPage
())
if
(
isExample
)
{
QCString
fileDocbook
=
pageName
+
".xml"
;
ti
<<
" <xi:include href=
\"
"
<<
fileDocbook
<<
"
\"
xmlns:xi=
\"
http://www.w3.org/2001/XInclude
\"
/>"
<<
endl
;
}
if
(
!
pd
->
hasParentPage
()
&&
!
isExample
)
{
{
QCString
fileDocbook
=
pageName
+
".xml"
;
QCString
fileDocbook
=
pageName
+
".xml"
;
//Add the file Documentation info to index file
//Add the file Documentation info to index file
...
@@ -1654,7 +1710,7 @@ static void generateDocbookForPage(PageDef *pd,FTextStream &ti,bool isExample)
...
@@ -1654,7 +1710,7 @@ static void generateDocbookForPage(PageDef *pd,FTextStream &ti,bool isExample)
if
(
isExample
)
if
(
isExample
)
{
{
writeDocbookDocBlock
(
t
,
pd
->
docFile
(),
pd
->
docLine
(),
pd
,
0
,
writeDocbookDocBlock
(
t
,
pd
->
docFile
(),
pd
->
docLine
(),
pd
,
0
,
pd
->
documentation
()
+
"
\n
<include "
+
pd
->
name
()
+
">"
);
pd
->
documentation
()
+
"
\n
\\
include "
+
pd
->
name
()
);
}
}
else
else
{
{
...
@@ -1663,7 +1719,7 @@ static void generateDocbookForPage(PageDef *pd,FTextStream &ti,bool isExample)
...
@@ -1663,7 +1719,7 @@ static void generateDocbookForPage(PageDef *pd,FTextStream &ti,bool isExample)
}
}
writeInnerPages
(
pd
->
getSubPages
(),
t
);
writeInnerPages
(
pd
->
getSubPages
(),
t
);
if
(
!
pd
->
hasParentPage
()
)
if
(
!
pd
->
hasParentPage
()
&&
!
isExample
)
{
{
t
<<
endl
<<
"</chapter>"
<<
endl
;
t
<<
endl
<<
"</chapter>"
<<
endl
;
}
}
...
@@ -1744,7 +1800,6 @@ void generateDocbook()
...
@@ -1744,7 +1800,6 @@ void generateDocbook()
t
<<
" </info>"
<<
endl
;
t
<<
" </info>"
<<
endl
;
// NAMESPACE DOCUMENTATION
// NAMESPACE DOCUMENTATION
NamespaceSDict
::
Iterator
nli
(
*
Doxygen
::
namespaceSDict
);
NamespaceSDict
::
Iterator
nli
(
*
Doxygen
::
namespaceSDict
);
NamespaceDef
*
nd
;
NamespaceDef
*
nd
;
...
@@ -1838,6 +1893,9 @@ void generateDocbook()
...
@@ -1838,6 +1893,9 @@ void generateDocbook()
// FILE DOCUMENTATION
// FILE DOCUMENTATION
static
bool
showFiles
=
Config_getBool
(
"SHOW_FILES"
);
if
(
showFiles
)
{
FileNameListIterator
fnli
(
*
Doxygen
::
inputNameList
);
FileNameListIterator
fnli
(
*
Doxygen
::
inputNameList
);
FileName
*
fn
;
FileName
*
fn
;
...
@@ -1864,9 +1922,10 @@ void generateDocbook()
...
@@ -1864,9 +1922,10 @@ void generateDocbook()
{
{
t
<<
" </chapter>"
<<
endl
;
t
<<
" </chapter>"
<<
endl
;
}
}
}
// DIRECTORY DOCUMENTATION
// DIRECTORY DOCUMENTATION
if
(
Config_getBool
(
"DIRECTORY_GRAPH"
)
&&
Config_getBool
(
"HAVE_DOT"
))
{
{
DirDef
*
dir
;
DirDef
*
dir
;
DirSDict
::
Iterator
sdi
(
*
Doxygen
::
directories
);
DirSDict
::
Iterator
sdi
(
*
Doxygen
::
directories
);
...
...
src/docbookvisitor.cpp
View file @
e24e777d
...
@@ -160,16 +160,16 @@ void DocbookDocVisitor::visit(DocVerbatim *s)
...
@@ -160,16 +160,16 @@ void DocbookDocVisitor::visit(DocVerbatim *s)
switch
(
s
->
type
())
switch
(
s
->
type
())
{
{
case
DocVerbatim
:
:
Code
:
// fall though
case
DocVerbatim
:
:
Code
:
// fall though
m_t
<<
"<
programlisting
>"
;
m_t
<<
"<
literallayout><computeroutput
>"
;
Doxygen
::
parserManager
->
getParser
(
m_langExt
)
Doxygen
::
parserManager
->
getParser
(
m_langExt
)
->
parseCode
(
m_ci
,
s
->
context
(),
s
->
text
(),
langExt
,
->
parseCode
(
m_ci
,
s
->
context
(),
s
->
text
(),
langExt
,
s
->
isExample
(),
s
->
exampleFile
());
s
->
isExample
(),
s
->
exampleFile
());
m_t
<<
"</
programlisting
>"
;
m_t
<<
"</
computeroutput></literallayout
>"
;
break
;
break
;
case
DocVerbatim
:
:
Verbatim
:
case
DocVerbatim
:
:
Verbatim
:
m_t
<<
"<
programlisting><
literallayout>"
;
m_t
<<
"<literallayout>"
;
filter
(
s
->
text
());
filter
(
s
->
text
());
m_t
<<
"</literallayout>
</programlisting>
"
;
m_t
<<
"</literallayout>"
;
break
;
break
;
case
DocVerbatim
:
:
HtmlOnly
:
case
DocVerbatim
:
:
HtmlOnly
:
break
;
break
;
...
@@ -189,8 +189,10 @@ void DocbookDocVisitor::visit(DocVerbatim *s)
...
@@ -189,8 +189,10 @@ void DocbookDocVisitor::visit(DocVerbatim *s)
{
{
static
int
dotindex
=
1
;
static
int
dotindex
=
1
;
QCString
baseName
(
4096
);
QCString
baseName
(
4096
);
QCString
name
;
QCString
stext
=
s
->
text
();
QCString
stext
=
s
->
text
();
m_t
<<
"<para>"
<<
endl
;
m_t
<<
"<para>"
<<
endl
;
name
.
sprintf
(
"%s%d"
,
"dot_inline_dotgraph_"
,
dotindex
);
baseName
.
sprintf
(
"%s%d"
,
baseName
.
sprintf
(
"%s%d"
,
(
Config_getString
(
"DOCBOOK_OUTPUT"
)
+
"/inline_dotgraph_"
).
data
(),
(
Config_getString
(
"DOCBOOK_OUTPUT"
)
+
"/inline_dotgraph_"
).
data
(),
dotindex
++
dotindex
++
...
@@ -203,7 +205,7 @@ void DocbookDocVisitor::visit(DocVerbatim *s)
...
@@ -203,7 +205,7 @@ void DocbookDocVisitor::visit(DocVerbatim *s)
file
.
writeBlock
(
stext
,
stext
.
length
()
);
file
.
writeBlock
(
stext
,
stext
.
length
()
);
file
.
close
();
file
.
close
();
m_t
<<
" <figure>"
<<
endl
;
m_t
<<
" <figure>"
<<
endl
;
m_t
<<
" <title></title>"
<<
endl
;
m_t
<<
" <title>
"
<<
name
<<
"
</title>"
<<
endl
;
m_t
<<
" <mediaobject>"
<<
endl
;
m_t
<<
" <mediaobject>"
<<
endl
;
m_t
<<
" <imageobject>"
<<
endl
;
m_t
<<
" <imageobject>"
<<
endl
;
writeDotFile
(
baseName
);
writeDotFile
(
baseName
);
...
@@ -216,8 +218,10 @@ void DocbookDocVisitor::visit(DocVerbatim *s)
...
@@ -216,8 +218,10 @@ void DocbookDocVisitor::visit(DocVerbatim *s)
case
DocVerbatim
:
:
Msc
:
case
DocVerbatim
:
:
Msc
:
static
int
mscindex
=
1
;
static
int
mscindex
=
1
;
QCString
baseName
(
4096
);
QCString
baseName
(
4096
);
QCString
name
;
QCString
stext
=
s
->
text
();
QCString
stext
=
s
->
text
();
m_t
<<
"<para>"
<<
endl
;
m_t
<<
"<para>"
<<
endl
;
name
.
sprintf
(
"%s%d"
,
"msc_inline_mscgraph_"
,
mscindex
);
baseName
.
sprintf
(
"%s%d"
,
baseName
.
sprintf
(
"%s%d"
,
(
Config_getString
(
"DOCBOOK_OUTPUT"
)
+
"/inline_mscgraph_"
).
data
(),
(
Config_getString
(
"DOCBOOK_OUTPUT"
)
+
"/inline_mscgraph_"
).
data
(),
mscindex
++
mscindex
++
...
@@ -233,7 +237,7 @@ void DocbookDocVisitor::visit(DocVerbatim *s)
...
@@ -233,7 +237,7 @@ void DocbookDocVisitor::visit(DocVerbatim *s)
file
.
writeBlock
(
text
,
text
.
length
()
);
file
.
writeBlock
(
text
,
text
.
length
()
);
file
.
close
();
file
.
close
();
m_t
<<
" <figure>"
<<
endl
;
m_t
<<
" <figure>"
<<
endl
;
m_t
<<
" <title></title>"
<<
endl
;
m_t
<<
" <title>
"
<<
name
<<
"
</title>"
<<
endl
;
m_t
<<
" <mediaobject>"
<<
endl
;
m_t
<<
" <mediaobject>"
<<
endl
;
m_t
<<
" <imageobject>"
<<
endl
;
m_t
<<
" <imageobject>"
<<
endl
;
writeMscFile
(
baseName
);
writeMscFile
(
baseName
);
...
@@ -259,7 +263,7 @@ void DocbookDocVisitor::visit(DocInclude *inc)
...
@@ -259,7 +263,7 @@ void DocbookDocVisitor::visit(DocInclude *inc)
{
{
case
DocInclude
:
:
IncWithLines
:
case
DocInclude
:
:
IncWithLines
:
{
{
m_t
<<
"<
programlisting
>"
;
m_t
<<
"<
literallayout><computeroutput
>"
;
QFileInfo
cfi
(
inc
->
file
()
);
QFileInfo
cfi
(
inc
->
file
()
);
FileDef
fd
(
cfi
.
dirPath
().
utf8
(),
cfi
.
fileName
().
utf8
()
);
FileDef
fd
(
cfi
.
dirPath
().
utf8
(),
cfi
.
fileName
().
utf8
()
);
Doxygen
::
parserManager
->
getParser
(
inc
->
extension
())
Doxygen
::
parserManager
->
getParser
(
inc
->
extension
())
...
@@ -268,18 +272,18 @@ void DocbookDocVisitor::visit(DocInclude *inc)
...
@@ -268,18 +272,18 @@ void DocbookDocVisitor::visit(DocInclude *inc)
langExt
,
langExt
,
inc
->
isExample
(),
inc
->
isExample
(),
inc
->
exampleFile
(),
&
fd
);
inc
->
exampleFile
(),
&
fd
);
m_t
<<
"</
programlisting
>"
;
m_t
<<
"</
computeroutput></literallayout
>"
;
}
}
break
;
break
;
case
DocInclude
:
:
Include
:
case
DocInclude
:
:
Include
:
m_t
<<
"<
programlisting
>"
;
m_t
<<
"<
literallayout><computeroutput
>"
;
Doxygen
::
parserManager
->
getParser
(
inc
->
extension
())
Doxygen
::
parserManager
->
getParser
(
inc
->
extension
())
->
parseCode
(
m_ci
,
inc
->
context
(),
->
parseCode
(
m_ci
,
inc
->
context
(),
inc
->
text
(),
inc
->
text
(),
langExt
,
langExt
,
inc
->
isExample
(),
inc
->
isExample
(),
inc
->
exampleFile
());
inc
->
exampleFile
());
m_t
<<
"</
programlisting
>"
;
m_t
<<
"</
computeroutput></literallayout
>"
;
break
;
break
;
case
DocInclude
:
:
DontInclude
:
case
DocInclude
:
:
DontInclude
:
break
;
break
;
...
@@ -293,7 +297,7 @@ void DocbookDocVisitor::visit(DocInclude *inc)
...
@@ -293,7 +297,7 @@ void DocbookDocVisitor::visit(DocInclude *inc)
m_t
<<
"</verbatim>"
;
m_t
<<
"</verbatim>"
;
break
;
break
;
case
DocInclude
:
:
Snippet
:
case
DocInclude
:
:
Snippet
:
m_t
<<
"<
programlisting
>"
;
m_t
<<
"<
literallayout><computeroutput
>"
;
Doxygen
::
parserManager
->
getParser
(
inc
->
extension
())
Doxygen
::
parserManager
->
getParser
(
inc
->
extension
())
->
parseCode
(
m_ci
,
->
parseCode
(
m_ci
,
inc
->
context
(),
inc
->
context
(),
...
@@ -302,7 +306,7 @@ void DocbookDocVisitor::visit(DocInclude *inc)
...
@@ -302,7 +306,7 @@ void DocbookDocVisitor::visit(DocInclude *inc)
inc
->
isExample
(),
inc
->
isExample
(),
inc
->
exampleFile
()
inc
->
exampleFile
()
);
);
m_t
<<
"</
programlisting
>"
;
m_t
<<
"</
computeroutput></literallayout
>"
;
break
;
break
;
}
}
}
}
...
@@ -361,7 +365,7 @@ void DocbookDocVisitor::visit(DocIndexEntry *ie)
...
@@ -361,7 +365,7 @@ void DocbookDocVisitor::visit(DocIndexEntry *ie)
void
DocbookDocVisitor
::
visit
(
DocSimpleSectSep
*
)
void
DocbookDocVisitor
::
visit
(
DocSimpleSectSep
*
)
{
{
m_t
<<
"<simplesect
sep
/>"
;
m_t
<<
"<simplesect/>"
;
}
}
void
DocbookDocVisitor
::
visit
(
DocCite
*
cite
)
void
DocbookDocVisitor
::
visit
(
DocCite
*
cite
)
...
@@ -818,7 +822,7 @@ void DocbookDocVisitor::visitPost(DocHtmlHeader *)
...
@@ -818,7 +822,7 @@ void DocbookDocVisitor::visitPost(DocHtmlHeader *)
void
DocbookDocVisitor
::
visitPre
(
DocImage
*
img
)
void
DocbookDocVisitor
::
visitPre
(
DocImage
*
img
)
{
{
if
(
img
->
type
()
==
DocImage
::
Latex
)
if
(
img
->
type
()
==
DocImage
::
DocBook
)
{
{
if
(
m_hide
)
return
;
if
(
m_hide
)
return
;
m_t
<<
endl
;
m_t
<<
endl
;
...
@@ -834,7 +838,7 @@ void DocbookDocVisitor::visitPre(DocImage *img)
...
@@ -834,7 +838,7 @@ void DocbookDocVisitor::visitPre(DocImage *img)
void
DocbookDocVisitor
::
visitPost
(
DocImage
*
img
)
void
DocbookDocVisitor
::
visitPost
(
DocImage
*
img
)
{
{
if
(
img
->
type
()
==
DocImage
::
Latex
)
if
(
img
->
type
()
==
DocImage
::
DocBook
)
{
{
if
(
m_hide
)
return
;
if
(
m_hide
)
return
;
QCString
typevar
;
QCString
typevar
;
...
@@ -854,13 +858,17 @@ void DocbookDocVisitor::visitPost(DocImage *img)
...
@@ -854,13 +858,17 @@ void DocbookDocVisitor::visitPost(DocImage *img)
filter
(
img
->
width
());
filter
(
img
->
width
());
m_t
<<
"
\"
"
;
m_t
<<
"
\"
"
;
}
}
else
if
(
!
img
->
height
().
isEmpty
())
else
{
m_t
<<
" width=
\"
50%
\"
"
;
}
if
(
!
img
->
height
().
isEmpty
())
{
{
m_t
<<
" depth=
\"
"
;
m_t
<<
" depth=
\"
"
;
filter
(
img
->
height
());
filter
(
img
->
height
());
m_t
<<
"
\"
"
;
m_t
<<
"
\"
"
;
}
}
m_t
<<
" align=
\"
center
\"
fileref=
\"
"
<<
baseName
<<
"
\"
>"
;
m_t
<<
" align=
\"
center
\"
valign=
\"
middle
\"
scalefit=
\"
1
\"
fileref=
\"
"
<<
baseName
<<
"
\"
>"
;
m_t
<<
"</imagedata>"
<<
endl
;
m_t
<<
"</imagedata>"
<<
endl
;
m_t
<<
" </imageobject>"
<<
endl
;
m_t
<<
" </imageobject>"
<<
endl
;
m_t
<<
" </mediaobject>"
<<
endl
;
m_t
<<
" </mediaobject>"
<<
endl
;
...
@@ -980,46 +988,23 @@ void DocbookDocVisitor::visitPost(DocSecRefList *)
...
@@ -980,46 +988,23 @@ void DocbookDocVisitor::visitPost(DocSecRefList *)
void
DocbookDocVisitor
::
visitPre
(
DocParamSect
*
s
)
void
DocbookDocVisitor
::
visitPre
(
DocParamSect
*
s
)
{
{
if
(
m_hide
)
return
;
if
(
m_hide
)
return
;
switch
(
s
->
type
())
{
case
DocParamSect
:
:
Param
:
{
m_t
<<
endl
;
m_t
<<
endl
;
m_t
<<
" <formalpara>"
<<
endl
;
m_t
<<
" <formalpara>"
<<
endl
;
m_t
<<
" <title/>"
<<
endl
;
m_t
<<
" <title/>"
<<
endl
;
m_t
<<
" <table frame=
\"
all
\"
>"
<<
endl
;
m_t
<<
" <table frame=
\"
all
\"
>"
<<
endl
;
m_t
<<
" <title>Parameters</title>"
<<
endl
;
m_t
<<
" <title>"
;
m_t
<<
" <tgroup cols=
\"
2
\"
align=
\"
left
\"
colsep=
\"
1
\"
rowsep=
\"
1
\"
>"
<<
endl
;
switch
(
s
->
type
())
m_t
<<
" <tbody>"
<<
endl
;
break
;
}
case
DocParamSect
:
:
RetVal
:
{
m_t
<<
endl
;
m_t
<<
" <formalpara>"
<<
endl
;
m_t
<<
" <title/>"
<<
endl
;
m_t
<<
" <table frame=
\"
all
\"
>"
<<
endl
;
m_t
<<
" <title>Parameters</title>"
<<
endl
;
m_t
<<
" <tgroup cols=
\"
2
\"
align=
\"
left
\"
colsep=
\"
1
\"
rowsep=
\"
1
\"
>"
<<
endl
;
m_t
<<
" <tbody>"
<<
endl
;
break
;
}
case
DocParamSect
:
:
Exception
:
{
{
m_t
<<
endl
;
case
DocParamSect
:
:
Param
:
m_t
<<
theTranslator
->
trParameters
();
break
;
m_t
<<
" <formalpara>"
<<
endl
;
case
DocParamSect
:
:
RetVal
:
m_t
<<
theTranslator
->
trReturnValues
();
break
;
m_t
<<
" <title/>"
<<
endl
;
case
DocParamSect
:
:
Exception
:
m_t
<<
theTranslator
->
trExceptions
();
break
;
m_t
<<
" <table frame=
\"
all
\"
>"
<<
endl
;
case
DocParamSect
:
:
TemplateParam
:
m_t
<<
theTranslator
->
trTemplateParameters
();
break
;
m_t
<<
" <title>Exceptions</title>"
<<
endl
;
m_t
<<
" <tgroup cols=
\"
2
\"
align=
\"
left
\"
colsep=
\"
1
\"
rowsep=
\"
1
\"
>"
<<
endl
;
m_t
<<
" <tbody>"
<<
endl
;
break
;
}
case
DocParamSect
:
:
TemplateParam
:
m_t
<<
"templateparam"
;
break
;
default
:
default
:
ASSERT
(
0
);
ASSERT
(
0
);
}
}
m_t
<<
" </title>"
<<
endl
;
m_t
<<
" <tgroup cols=
\"
2
\"
align=
\"
left
\"
colsep=
\"
1
\"
rowsep=
\"
1
\"
>"
<<
endl
;
m_t
<<
" <tbody>"
<<
endl
;
}
}
void
DocbookDocVisitor
::
visitPost
(
DocParamSect
*
)
void
DocbookDocVisitor
::
visitPost
(
DocParamSect
*
)
...
@@ -1205,7 +1190,8 @@ void DocbookDocVisitor::writeMscFile(const QCString &baseName)
...
@@ -1205,7 +1190,8 @@ void DocbookDocVisitor::writeMscFile(const QCString &baseName)
QCString
outDir
=
Config_getString
(
"DOCBOOK_OUTPUT"
);
QCString
outDir
=
Config_getString
(
"DOCBOOK_OUTPUT"
);
writeMscGraphFromFile
(
baseName
+
".msc"
,
outDir
,
shortName
,
MSC_BITMAP
);
writeMscGraphFromFile
(
baseName
+
".msc"
,
outDir
,
shortName
,
MSC_BITMAP
);
m_t
<<
" <imagedata"
;
m_t
<<
" <imagedata"
;
m_t
<<
" align=
\"
center
\"
fileref=
\"
"
<<
shortName
<<
".png"
<<
"
\"
>"
;
m_t
<<
" width=
\"
50%
\"
"
;
m_t
<<
" align=
\"
center
\"
valign=
\"
middle
\"
scalefit=
\"
1
\"
fileref=
\"
"
<<
shortName
<<
".png"
<<
"
\"
>"
;
m_t
<<
"</imagedata>"
<<
endl
;
m_t
<<
"</imagedata>"
<<
endl
;
}
}
...
@@ -1240,13 +1226,17 @@ void DocbookDocVisitor::startMscFile(const QCString &fileName,
...
@@ -1240,13 +1226,17 @@ void DocbookDocVisitor::startMscFile(const QCString &fileName,
m_t
<<
width
;
m_t
<<
width
;
m_t
<<
"
\"
"
;
m_t
<<
"
\"
"
;
}
}
else
if
(
!
height
.
isEmpty
())
else
{
m_t
<<
" width=
\"
50%
\"
"
;
}
if
(
!
height
.
isEmpty
())
{
{
m_t
<<
" depth=
\"
"
;
m_t
<<
" depth=
\"
"
;
m_t
<<
height
;
m_t
<<
height
;
m_t
<<
"
\"
"
;
m_t
<<
"
\"
"
;
}
}
m_t
<<
" align=
\"
center
\"
fileref=
\"
"
<<
baseName
<<
".png"
<<
"
\"
>"
;
m_t
<<
" align=
\"
center
\"
valign=
\"
middle
\"
scalefit=
\"
1
\"
fileref=
\"
"
<<
baseName
<<
".png"
<<
"
\"
>"
;
m_t
<<
"</imagedata>"
<<
endl
;
m_t
<<
"</imagedata>"
<<
endl
;
m_t
<<
" </imageobject>"
<<
endl
;
m_t
<<
" </imageobject>"
<<
endl
;
if
(
hasCaption
)
if
(
hasCaption
)
...
@@ -1351,9 +1341,12 @@ void DocbookDocVisitor::writeDotFile(const QCString &baseName)
...
@@ -1351,9 +1341,12 @@ void DocbookDocVisitor::writeDotFile(const QCString &baseName)
shortName
=
shortName
.
right
(
shortName
.
length
()
-
i
-
1
);
shortName
=
shortName
.
right
(
shortName
.
length
()
-
i
-
1
);
}
}
QCString
outDir
=
Config_getString
(
"DOCBOOK_OUTPUT"
);
QCString
outDir
=
Config_getString
(
"DOCBOOK_OUTPUT"
);
writeDotGraphFromFile
(
baseName
+
".dot"
,
outDir
,
shortName
,
BITMAP
);
QCString
imgExt
=
Config_getEnum
(
"DOT_IMAGE_FORMAT"
);
writeDotGraphFromFile
(
baseName
+
".dot"
,
outDir
,
shortName
,
GOF_BITMAP
);
m_t
<<
" <imagedata"
;
m_t
<<
" <imagedata"
;
m_t
<<
" align=
\"
center
\"
fileref=
\"
"
<<
shortName
<<
".png"
<<
"
\"
>"
;
//If no width is specified use default value for PDF rendering
m_t
<<
" width=
\"
50%
\"
"
;
m_t
<<
" align=
\"
center
\"
valign=
\"
middle
\"
scalefit=
\"
1
\"
fileref=
\"
"
<<
shortName
<<
"."
<<
imgExt
<<
"
\"
>"
;
m_t
<<
"</imagedata>"
<<
endl
;
m_t
<<
"</imagedata>"
<<
endl
;
}
}
...
@@ -1375,7 +1368,8 @@ void DocbookDocVisitor::startDotFile(const QCString &fileName,
...
@@ -1375,7 +1368,8 @@ void DocbookDocVisitor::startDotFile(const QCString &fileName,
}
}
baseName
.
prepend
(
"dot_"
);
baseName
.
prepend
(
"dot_"
);
QCString
outDir
=
Config_getString
(
"DOCBOOK_OUTPUT"
);
QCString
outDir
=
Config_getString
(
"DOCBOOK_OUTPUT"
);
writeDotGraphFromFile
(
fileName
,
outDir
,
baseName
,
BITMAP
);
QCString
imgExt
=
Config_getEnum
(
"DOT_IMAGE_FORMAT"
);
writeDotGraphFromFile
(
fileName
,
outDir
,
baseName
,
GOF_BITMAP
);
m_t
<<
"<para>"
<<
endl
;
m_t
<<
"<para>"
<<
endl
;
m_t
<<
" <figure>"
<<
endl
;
m_t
<<
" <figure>"
<<
endl
;
m_t
<<
" <title></title>"
<<
endl
;
m_t
<<
" <title></title>"
<<
endl
;
...
@@ -1388,13 +1382,17 @@ void DocbookDocVisitor::startDotFile(const QCString &fileName,
...
@@ -1388,13 +1382,17 @@ void DocbookDocVisitor::startDotFile(const QCString &fileName,
m_t
<<
width
;
m_t
<<
width
;
m_t
<<
"
\"
"
;
m_t
<<
"
\"
"
;
}
}
else
if
(
!
height
.
isEmpty
())
else
{
m_t
<<
" width=
\"
50%
\"
"
;
}
if
(
!
height
.
isEmpty
())
{
{
m_t
<<
" depth=
\"
"
;
m_t
<<
" depth=
\"
"
;
m_t
<<
height
;
m_t
<<
height
;
m_t
<<
"
\"
"
;
m_t
<<
"
\"
"
;
}
}
m_t
<<
" align=
\"
center
\"
fileref=
\"
"
<<
baseName
<<
".png"
<<
"
\"
>"
;
m_t
<<
" align=
\"
center
\"
valign=
\"
middle
\"
scalefit=
\"
1
\"
fileref=
\"
"
<<
baseName
<<
"."
<<
imgExt
<<
"
\"
>"
;
m_t
<<
"</imagedata>"
<<
endl
;
m_t
<<
"</imagedata>"
<<
endl
;
m_t
<<
" </imageobject>"
<<
endl
;
m_t
<<
" </imageobject>"
<<
endl
;
if
(
hasCaption
)
if
(
hasCaption
)
...
...
src/docparser.cpp
View file @
e24e777d
...
@@ -265,6 +265,10 @@ static QCString findAndCopyImage(const char *fileName,DocImage::Type type)
...
@@ -265,6 +265,10 @@ static QCString findAndCopyImage(const char *fileName,DocImage::Type type)
if
(
!
Config_getBool
(
"GENERATE_LATEX"
))
return
result
;
if
(
!
Config_getBool
(
"GENERATE_LATEX"
))
return
result
;
outputDir
=
Config_getString
(
"LATEX_OUTPUT"
);
outputDir
=
Config_getString
(
"LATEX_OUTPUT"
);
break
;
break
;
case
DocImage
:
:
DocBook
:
if
(
!
Config_getBool
(
"GENERATE_DOCBOOK"
))
return
result
;
outputDir
=
Config_getString
(
"DOCBOOK_OUTPUT"
);
break
;
case
DocImage
:
:
Rtf
:
case
DocImage
:
:
Rtf
:
if
(
!
Config_getBool
(
"GENERATE_RTF"
))
return
result
;
if
(
!
Config_getBool
(
"GENERATE_RTF"
))
return
result
;
outputDir
=
Config_getString
(
"RTF_OUTPUT"
);
outputDir
=
Config_getString
(
"RTF_OUTPUT"
);
...
@@ -5027,6 +5031,7 @@ void DocPara::handleImage(const QCString &cmdName)
...
@@ -5027,6 +5031,7 @@ void DocPara::handleImage(const QCString &cmdName)
QCString
imgType
=
g_token
->
name
.
lower
();
QCString
imgType
=
g_token
->
name
.
lower
();
if
(
imgType
==
"html"
)
t
=
DocImage
::
Html
;
if
(
imgType
==
"html"
)
t
=
DocImage
::
Html
;
else
if
(
imgType
==
"latex"
)
t
=
DocImage
::
Latex
;
else
if
(
imgType
==
"latex"
)
t
=
DocImage
::
Latex
;
else
if
(
imgType
==
"docbook"
)
t
=
DocImage
::
DocBook
;
else
if
(
imgType
==
"rtf"
)
t
=
DocImage
::
Rtf
;
else
if
(
imgType
==
"rtf"
)
t
=
DocImage
::
Rtf
;
else
else
{
{
...
...
src/docparser.h
View file @
e24e777d
...
@@ -668,7 +668,7 @@ class DocXRefItem : public CompAccept<DocXRefItem>, public DocNode
...
@@ -668,7 +668,7 @@ class DocXRefItem : public CompAccept<DocXRefItem>, public DocNode
class
DocImage
:
public
CompAccept
<
DocImage
>
,
public
DocNode
class
DocImage
:
public
CompAccept
<
DocImage
>
,
public
DocNode
{
{
public
:
public
:
enum
Type
{
Html
,
Latex
,
Rtf
};
enum
Type
{
Html
,
Latex
,
Rtf
,
DocBook
};
DocImage
(
DocNode
*
parent
,
const
HtmlAttribList
&
attribs
,
DocImage
(
DocNode
*
parent
,
const
HtmlAttribList
&
attribs
,
const
QCString
&
name
,
Type
t
,
const
QCString
&
url
=
QCString
());
const
QCString
&
name
,
Type
t
,
const
QCString
&
url
=
QCString
());
Kind
kind
()
const
{
return
Kind_Image
;
}
Kind
kind
()
const
{
return
Kind_Image
;
}
...
...
src/dot.cpp
View file @
e24e777d
...
@@ -16,11 +16,6 @@
...
@@ -16,11 +16,6 @@
*
*
*/
*/
#ifdef _WIN32
#include <windows.h>
#define BITMAP W_BITMAP
#endif
#include <stdlib.h>
#include <stdlib.h>
#include <qdir.h>
#include <qdir.h>
...
@@ -1896,7 +1891,7 @@ void DotNode::writeArrow(FTextStream &t,
...
@@ -1896,7 +1891,7 @@ void DotNode::writeArrow(FTextStream &t,
t
<<
",arrowhead=
\"
"
<<
eProps
->
arrowStyleMap
[
ei
->
m_color
]
<<
"
\"
"
;
t
<<
",arrowhead=
\"
"
<<
eProps
->
arrowStyleMap
[
ei
->
m_color
]
<<
"
\"
"
;
}
}
if
(
format
==
BITMAP
)
t
<<
",fontname=
\"
"
<<
FONTNAME
<<
"
\"
"
;
if
(
format
==
GOF_
BITMAP
)
t
<<
",fontname=
\"
"
<<
FONTNAME
<<
"
\"
"
;
t
<<
"];"
<<
endl
;
t
<<
"];"
<<
endl
;
}
}
...
@@ -2313,7 +2308,7 @@ void DotGfxHierarchyTable::writeGraph(FTextStream &out,
...
@@ -2313,7 +2308,7 @@ void DotGfxHierarchyTable::writeGraph(FTextStream &out,
{
{
if
(
node
->
m_subgraphId
==
n
->
m_subgraphId
)
if
(
node
->
m_subgraphId
==
n
->
m_subgraphId
)
{
{
node
->
write
(
md5stream
,
DotNode
::
Hierarchy
,
BITMAP
,
FALSE
,
TRUE
,
TRUE
,
TRUE
);
node
->
write
(
md5stream
,
DotNode
::
Hierarchy
,
GOF_
BITMAP
,
FALSE
,
TRUE
,
TRUE
,
TRUE
);
}
}
}
}
writeGraphFooter
(
md5stream
);
writeGraphFooter
(
md5stream
);
...
@@ -3080,7 +3075,8 @@ QCString DotClassGraph::diskName() const
...
@@ -3080,7 +3075,8 @@ QCString DotClassGraph::diskName() const
}
}
QCString
DotClassGraph
::
writeGraph
(
FTextStream
&
out
,
QCString
DotClassGraph
::
writeGraph
(
FTextStream
&
out
,
GraphOutputFormat
format
,
GraphOutputFormat
graphFormat
,
EmbeddedOutputFormat
textFormat
,
const
char
*
path
,
const
char
*
path
,
const
char
*
fileName
,
const
char
*
fileName
,
const
char
*
relPath
,
const
char
*
relPath
,
...
@@ -3128,19 +3124,19 @@ QCString DotClassGraph::writeGraph(FTextStream &out,
...
@@ -3128,19 +3124,19 @@ QCString DotClassGraph::writeGraph(FTextStream &out,
if
(
updateDotGraph
(
m_startNode
,
if
(
updateDotGraph
(
m_startNode
,
m_graphType
,
m_graphType
,
absBaseName
,
absBaseName
,
f
ormat
,
graphF
ormat
,
m_lrRank
,
m_lrRank
,
m_graphType
==
DotNode
::
Inheritance
,
m_graphType
==
DotNode
::
Inheritance
,
TRUE
,
TRUE
,
m_startNode
->
label
()
m_startNode
->
label
()
)
||
)
||
!
checkDeliverables
(
format
==
BITMAP
?
absImgName
:
!
checkDeliverables
(
graphFormat
==
GOF_
BITMAP
?
absImgName
:
usePDFLatex
?
absPdfName
:
absEpsName
,
usePDFLatex
?
absPdfName
:
absEpsName
,
format
==
BITMAP
&&
generateImageMap
?
absMapName
:
QCString
())
graphFormat
==
GOF_
BITMAP
&&
generateImageMap
?
absMapName
:
QCString
())
)
)
{
{
regenerate
=
TRUE
;
regenerate
=
TRUE
;
if
(
format
==
BITMAP
)
// run dot to create a bitmap image
if
(
graphFormat
==
GOF_
BITMAP
)
// run dot to create a bitmap image
{
{
QCString
dotArgs
(
maxCmdLine
);
QCString
dotArgs
(
maxCmdLine
);
...
@@ -3151,7 +3147,7 @@ QCString DotClassGraph::writeGraph(FTextStream &out,
...
@@ -3151,7 +3147,7 @@ QCString DotClassGraph::writeGraph(FTextStream &out,
DotManager
::
instance
()
->
addRun
(
dotRun
);
DotManager
::
instance
()
->
addRun
(
dotRun
);
}
}
else
if
(
format
==
EPS
)
// run dot to create a .eps image
else
if
(
graphFormat
==
GOF_
EPS
)
// run dot to create a .eps image
{
{
DotRunner
*
dotRun
=
new
DotRunner
(
absDotName
,
d
.
absPath
().
data
(),
FALSE
);
DotRunner
*
dotRun
=
new
DotRunner
(
absDotName
,
d
.
absPath
().
data
(),
FALSE
);
if
(
usePDFLatex
)
if
(
usePDFLatex
)
...
@@ -3167,7 +3163,35 @@ QCString DotClassGraph::writeGraph(FTextStream &out,
...
@@ -3167,7 +3163,35 @@ QCString DotClassGraph::writeGraph(FTextStream &out,
}
}
Doxygen
::
indexList
->
addImageFile
(
baseName
+
"."
+
imgExt
);
Doxygen
::
indexList
->
addImageFile
(
baseName
+
"."
+
imgExt
);
if
(
format
==
BITMAP
&&
generateImageMap
)
// produce HTML to include the image
if
(
graphFormat
==
GOF_BITMAP
&&
textFormat
==
EOF_DocBook
)
{
out
<<
"<para>"
<<
endl
;
out
<<
" <figure>"
<<
endl
;
out
<<
" <title>"
;
switch
(
m_graphType
)
{
case
DotNode
:
:
Collaboration
:
out
<<
"Collaboration graph"
;
break
;
case
DotNode
:
:
Inheritance
:
out
<<
"Inheritance graph"
;
break
;
default
:
ASSERT
(
0
);
break
;
}
out
<<
"</title>"
<<
endl
;
out
<<
" <mediaobject>"
<<
endl
;
out
<<
" <imageobject>"
<<
endl
;
out
<<
" <imagedata"
;
out
<<
" width=
\"
50%
\"
align=
\"
center
\"
valign=
\"
middle
\"
scalefit=
\"
1
\"
fileref=
\"
"
<<
relPath
<<
baseName
<<
"."
<<
imgExt
<<
"
\"
>"
;
out
<<
"</imagedata>"
<<
endl
;
out
<<
" </imageobject>"
<<
endl
;
out
<<
" </mediaobject>"
<<
endl
;
out
<<
" </figure>"
<<
endl
;
out
<<
"</para>"
<<
endl
;
}
else
if
(
graphFormat
==
GOF_BITMAP
&&
generateImageMap
)
// produce HTML to include the image
{
{
QCString
mapLabel
=
escapeCharsInString
(
m_startNode
->
m_label
,
FALSE
)
+
"_"
+
QCString
mapLabel
=
escapeCharsInString
(
m_startNode
->
m_label
,
FALSE
)
+
"_"
+
escapeCharsInString
(
mapName
,
FALSE
);
escapeCharsInString
(
mapName
,
FALSE
);
...
@@ -3205,7 +3229,6 @@ QCString DotClassGraph::writeGraph(FTextStream &out,
...
@@ -3205,7 +3229,6 @@ QCString DotClassGraph::writeGraph(FTextStream &out,
}
}
out
<<
"
\"
/>"
;
out
<<
"
\"
/>"
;
out
<<
"</div>"
<<
endl
;
out
<<
"</div>"
<<
endl
;
if
(
regenerate
||
!
insertMapFile
(
out
,
absMapName
,
relPath
,
mapLabel
))
if
(
regenerate
||
!
insertMapFile
(
out
,
absMapName
,
relPath
,
mapLabel
))
{
{
int
mapId
=
DotManager
::
instance
()
->
addMap
(
fileName
,
absMapName
,
relPath
,
int
mapId
=
DotManager
::
instance
()
->
addMap
(
fileName
,
absMapName
,
relPath
,
...
@@ -3214,7 +3237,7 @@ QCString DotClassGraph::writeGraph(FTextStream &out,
...
@@ -3214,7 +3237,7 @@ QCString DotClassGraph::writeGraph(FTextStream &out,
}
}
}
}
}
}
else
if
(
format
==
EPS
)
// produce tex to include the .eps image
else
if
(
graphFormat
==
GOF_
EPS
)
// produce tex to include the .eps image
{
{
if
(
regenerate
||
!
writeVecGfxFigure
(
out
,
baseName
,
absBaseName
))
if
(
regenerate
||
!
writeVecGfxFigure
(
out
,
baseName
,
absBaseName
))
{
{
...
@@ -3423,7 +3446,8 @@ QCString DotInclDepGraph::diskName() const
...
@@ -3423,7 +3446,8 @@ QCString DotInclDepGraph::diskName() const
}
}
QCString
DotInclDepGraph
::
writeGraph
(
FTextStream
&
out
,
QCString
DotInclDepGraph
::
writeGraph
(
FTextStream
&
out
,
GraphOutputFormat
format
,
GraphOutputFormat
graphFormat
,
EmbeddedOutputFormat
textFormat
,
const
char
*
path
,
const
char
*
path
,
const
char
*
fileName
,
const
char
*
fileName
,
const
char
*
relPath
,
const
char
*
relPath
,
...
@@ -3458,19 +3482,19 @@ QCString DotInclDepGraph::writeGraph(FTextStream &out,
...
@@ -3458,19 +3482,19 @@ QCString DotInclDepGraph::writeGraph(FTextStream &out,
if
(
updateDotGraph
(
m_startNode
,
if
(
updateDotGraph
(
m_startNode
,
DotNode
::
Dependency
,
DotNode
::
Dependency
,
absBaseName
,
absBaseName
,
f
ormat
,
graphF
ormat
,
FALSE
,
// lrRank
FALSE
,
// lrRank
FALSE
,
// renderParents
FALSE
,
// renderParents
m_inverse
,
// backArrows
m_inverse
,
// backArrows
m_startNode
->
label
()
m_startNode
->
label
()
)
||
)
||
!
checkDeliverables
(
format
==
BITMAP
?
absImgName
:
!
checkDeliverables
(
graphFormat
==
GOF_
BITMAP
?
absImgName
:
usePDFLatex
?
absPdfName
:
absEpsName
,
usePDFLatex
?
absPdfName
:
absEpsName
,
format
==
BITMAP
&&
generateImageMap
?
absMapName
:
QCString
())
graphFormat
==
GOF_
BITMAP
&&
generateImageMap
?
absMapName
:
QCString
())
)
)
{
{
regenerate
=
TRUE
;
regenerate
=
TRUE
;
if
(
format
==
BITMAP
)
if
(
graphFormat
==
GOF_
BITMAP
)
{
{
// run dot to create a bitmap image
// run dot to create a bitmap image
QCString
dotArgs
(
maxCmdLine
);
QCString
dotArgs
(
maxCmdLine
);
...
@@ -3479,7 +3503,7 @@ QCString DotInclDepGraph::writeGraph(FTextStream &out,
...
@@ -3479,7 +3503,7 @@ QCString DotInclDepGraph::writeGraph(FTextStream &out,
if
(
generateImageMap
)
dotRun
->
addJob
(
MAP_CMD
,
absMapName
);
if
(
generateImageMap
)
dotRun
->
addJob
(
MAP_CMD
,
absMapName
);
DotManager
::
instance
()
->
addRun
(
dotRun
);
DotManager
::
instance
()
->
addRun
(
dotRun
);
}
}
else
if
(
format
==
EPS
)
else
if
(
graphFormat
==
GOF_
EPS
)
{
{
DotRunner
*
dotRun
=
new
DotRunner
(
absDotName
,
d
.
absPath
().
data
(),
FALSE
);
DotRunner
*
dotRun
=
new
DotRunner
(
absDotName
,
d
.
absPath
().
data
(),
FALSE
);
if
(
usePDFLatex
)
if
(
usePDFLatex
)
...
@@ -3491,12 +3515,27 @@ QCString DotInclDepGraph::writeGraph(FTextStream &out,
...
@@ -3491,12 +3515,27 @@ QCString DotInclDepGraph::writeGraph(FTextStream &out,
dotRun
->
addJob
(
"ps"
,
absEpsName
);
dotRun
->
addJob
(
"ps"
,
absEpsName
);
}
}
DotManager
::
instance
()
->
addRun
(
dotRun
);
DotManager
::
instance
()
->
addRun
(
dotRun
);
}
}
}
}
Doxygen
::
indexList
->
addImageFile
(
baseName
+
"."
+
imgExt
);
Doxygen
::
indexList
->
addImageFile
(
baseName
+
"."
+
imgExt
);
if
(
format
==
BITMAP
&&
generateImageMap
)
if
(
graphFormat
==
GOF_BITMAP
&&
textFormat
==
EOF_DocBook
)
{
out
<<
"<para>"
<<
endl
;
out
<<
" <figure>"
<<
endl
;
out
<<
" <title>Dependency diagram"
;
out
<<
"</title>"
<<
endl
;
out
<<
" <mediaobject>"
<<
endl
;
out
<<
" <imageobject>"
<<
endl
;
out
<<
" <imagedata"
;
out
<<
" width=
\"
50%
\"
align=
\"
center
\"
valign=
\"
middle
\"
scalefit=
\"
1
\"
fileref=
\"
"
<<
relPath
<<
baseName
<<
"."
<<
imgExt
<<
"
\"
>"
;
out
<<
"</imagedata>"
<<
endl
;
out
<<
" </imageobject>"
<<
endl
;
out
<<
" </mediaobject>"
<<
endl
;
out
<<
" </figure>"
<<
endl
;
out
<<
"</para>"
<<
endl
;
}
else
if
(
graphFormat
==
GOF_BITMAP
&&
generateImageMap
)
{
{
if
(
imgExt
==
"svg"
)
// Scalable vector graphics
if
(
imgExt
==
"svg"
)
// Scalable vector graphics
{
{
...
@@ -3514,9 +3553,7 @@ QCString DotInclDepGraph::writeGraph(FTextStream &out,
...
@@ -3514,9 +3553,7 @@ QCString DotInclDepGraph::writeGraph(FTextStream &out,
}
}
else
// bitmap graphics
else
// bitmap graphics
{
{
out
<<
"<div class=
\"
center
\"
><img src=
\"
"
<<
relPath
<<
baseName
<<
"."
out
<<
"<div class=
\"
center
\"
><img src=
\"
"
<<
relPath
<<
baseName
<<
"."
<<
imgExt
<<
"
\"
border=
\"
0
\"
usemap=
\"
#"
<<
mapName
<<
"
\"
alt=
\"\"
/>"
;
<<
imgExt
<<
"
\"
border=
\"
0
\"
usemap=
\"
#"
<<
mapName
<<
"
\"
alt=
\"\"
/>"
;
out
<<
"</div>"
<<
endl
;
out
<<
"</div>"
<<
endl
;
QCString
absMapName
=
absBaseName
+
".map"
;
QCString
absMapName
=
absBaseName
+
".map"
;
...
@@ -3528,7 +3565,7 @@ QCString DotInclDepGraph::writeGraph(FTextStream &out,
...
@@ -3528,7 +3565,7 @@ QCString DotInclDepGraph::writeGraph(FTextStream &out,
}
}
}
}
}
}
else
if
(
format
==
EPS
)
// encapsulated postscript
else
if
(
graphFormat
==
GOF_
EPS
)
// encapsulated postscript
{
{
if
(
regenerate
||
!
writeVecGfxFigure
(
out
,
baseName
,
absBaseName
))
if
(
regenerate
||
!
writeVecGfxFigure
(
out
,
baseName
,
absBaseName
))
{
{
...
@@ -3729,7 +3766,8 @@ DotCallGraph::~DotCallGraph()
...
@@ -3729,7 +3766,8 @@ DotCallGraph::~DotCallGraph()
delete
m_usedNodes
;
delete
m_usedNodes
;
}
}
QCString
DotCallGraph
::
writeGraph
(
FTextStream
&
out
,
GraphOutputFormat
format
,
QCString
DotCallGraph
::
writeGraph
(
FTextStream
&
out
,
GraphOutputFormat
graphFormat
,
EmbeddedOutputFormat
textFormat
,
const
char
*
path
,
const
char
*
fileName
,
const
char
*
path
,
const
char
*
fileName
,
const
char
*
relPath
,
bool
generateImageMap
,
int
const
char
*
relPath
,
bool
generateImageMap
,
int
graphId
)
const
graphId
)
const
...
@@ -3757,19 +3795,19 @@ QCString DotCallGraph::writeGraph(FTextStream &out, GraphOutputFormat format,
...
@@ -3757,19 +3795,19 @@ QCString DotCallGraph::writeGraph(FTextStream &out, GraphOutputFormat format,
if
(
updateDotGraph
(
m_startNode
,
if
(
updateDotGraph
(
m_startNode
,
DotNode
::
CallGraph
,
DotNode
::
CallGraph
,
absBaseName
,
absBaseName
,
f
ormat
,
graphF
ormat
,
TRUE
,
// lrRank
TRUE
,
// lrRank
FALSE
,
// renderParents
FALSE
,
// renderParents
m_inverse
,
// backArrows
m_inverse
,
// backArrows
m_startNode
->
label
()
m_startNode
->
label
()
)
||
)
||
!
checkDeliverables
(
format
==
BITMAP
?
absImgName
:
!
checkDeliverables
(
graphFormat
==
GOF_
BITMAP
?
absImgName
:
usePDFLatex
?
absPdfName
:
absEpsName
,
usePDFLatex
?
absPdfName
:
absEpsName
,
format
==
BITMAP
&&
generateImageMap
?
absMapName
:
QCString
())
graphFormat
==
GOF_
BITMAP
&&
generateImageMap
?
absMapName
:
QCString
())
)
)
{
{
regenerate
=
TRUE
;
regenerate
=
TRUE
;
if
(
format
==
BITMAP
)
if
(
graphFormat
==
GOF_
BITMAP
)
{
{
// run dot to create a bitmap image
// run dot to create a bitmap image
QCString
dotArgs
(
maxCmdLine
);
QCString
dotArgs
(
maxCmdLine
);
...
@@ -3779,7 +3817,7 @@ QCString DotCallGraph::writeGraph(FTextStream &out, GraphOutputFormat format,
...
@@ -3779,7 +3817,7 @@ QCString DotCallGraph::writeGraph(FTextStream &out, GraphOutputFormat format,
DotManager
::
instance
()
->
addRun
(
dotRun
);
DotManager
::
instance
()
->
addRun
(
dotRun
);
}
}
else
if
(
format
==
EPS
)
else
if
(
graphFormat
==
GOF_
EPS
)
{
{
// run dot to create a .eps image
// run dot to create a .eps image
DotRunner
*
dotRun
=
new
DotRunner
(
absDotName
,
d
.
absPath
().
data
(),
FALSE
);
DotRunner
*
dotRun
=
new
DotRunner
(
absDotName
,
d
.
absPath
().
data
(),
FALSE
);
...
@@ -3797,7 +3835,23 @@ QCString DotCallGraph::writeGraph(FTextStream &out, GraphOutputFormat format,
...
@@ -3797,7 +3835,23 @@ QCString DotCallGraph::writeGraph(FTextStream &out, GraphOutputFormat format,
}
}
Doxygen
::
indexList
->
addImageFile
(
baseName
+
"."
+
imgExt
);
Doxygen
::
indexList
->
addImageFile
(
baseName
+
"."
+
imgExt
);
if
(
format
==
BITMAP
&&
generateImageMap
)
if
(
graphFormat
==
GOF_BITMAP
&&
textFormat
==
EOF_DocBook
)
{
out
<<
"<para>"
<<
endl
;
out
<<
" <figure>"
<<
endl
;
out
<<
" <title>Call diagram"
;
out
<<
"</title>"
<<
endl
;
out
<<
" <mediaobject>"
<<
endl
;
out
<<
" <imageobject>"
<<
endl
;
out
<<
" <imagedata"
;
out
<<
" width=
\"
50%
\"
align=
\"
center
\"
valign=
\"
middle
\"
scalefit=
\"
1
\"
fileref=
\"
"
<<
relPath
<<
baseName
<<
"."
<<
imgExt
<<
"
\"
>"
;
out
<<
"</imagedata>"
<<
endl
;
out
<<
" </imageobject>"
<<
endl
;
out
<<
" </mediaobject>"
<<
endl
;
out
<<
" </figure>"
<<
endl
;
out
<<
"</para>"
<<
endl
;
}
else
if
(
graphFormat
==
GOF_BITMAP
&&
generateImageMap
)
{
{
if
(
imgExt
==
"svg"
)
// Scalable vector graphics
if
(
imgExt
==
"svg"
)
// Scalable vector graphics
{
{
...
@@ -3829,7 +3883,7 @@ QCString DotCallGraph::writeGraph(FTextStream &out, GraphOutputFormat format,
...
@@ -3829,7 +3883,7 @@ QCString DotCallGraph::writeGraph(FTextStream &out, GraphOutputFormat format,
}
}
}
}
}
}
else
if
(
format
==
EPS
)
// encapsulated postscript
else
if
(
graphFormat
==
GOF_
EPS
)
// encapsulated postscript
{
{
if
(
regenerate
||
!
writeVecGfxFigure
(
out
,
baseName
,
absBaseName
))
if
(
regenerate
||
!
writeVecGfxFigure
(
out
,
baseName
,
absBaseName
))
{
{
...
@@ -3865,7 +3919,8 @@ DotDirDeps::~DotDirDeps()
...
@@ -3865,7 +3919,8 @@ DotDirDeps::~DotDirDeps()
}
}
QCString
DotDirDeps
::
writeGraph
(
FTextStream
&
out
,
QCString
DotDirDeps
::
writeGraph
(
FTextStream
&
out
,
GraphOutputFormat
format
,
GraphOutputFormat
graphFormat
,
EmbeddedOutputFormat
textFormat
,
const
char
*
path
,
const
char
*
path
,
const
char
*
fileName
,
const
char
*
fileName
,
const
char
*
relPath
,
const
char
*
relPath
,
...
@@ -3901,9 +3956,9 @@ QCString DotDirDeps::writeGraph(FTextStream &out,
...
@@ -3901,9 +3956,9 @@ QCString DotDirDeps::writeGraph(FTextStream &out,
MD5SigToString
(
md5_sig
,
sigStr
.
data
(),
33
);
MD5SigToString
(
md5_sig
,
sigStr
.
data
(),
33
);
bool
regenerate
=
FALSE
;
bool
regenerate
=
FALSE
;
if
(
checkAndUpdateMd5Signature
(
absBaseName
,
sigStr
)
||
if
(
checkAndUpdateMd5Signature
(
absBaseName
,
sigStr
)
||
!
checkDeliverables
(
format
==
BITMAP
?
absImgName
:
!
checkDeliverables
(
graphFormat
==
GOF_
BITMAP
?
absImgName
:
usePDFLatex
?
absPdfName
:
absEpsName
,
usePDFLatex
?
absPdfName
:
absEpsName
,
format
==
BITMAP
&&
generateImageMap
?
absMapName
:
QCString
())
graphFormat
==
GOF_
BITMAP
&&
generateImageMap
?
absMapName
:
QCString
())
)
)
{
{
regenerate
=
TRUE
;
regenerate
=
TRUE
;
...
@@ -3917,7 +3972,7 @@ QCString DotDirDeps::writeGraph(FTextStream &out,
...
@@ -3917,7 +3972,7 @@ QCString DotDirDeps::writeGraph(FTextStream &out,
t
<<
theGraph
.
data
();
t
<<
theGraph
.
data
();
f
.
close
();
f
.
close
();
if
(
format
==
BITMAP
)
if
(
graphFormat
==
GOF_
BITMAP
)
{
{
// run dot to create a bitmap image
// run dot to create a bitmap image
QCString
dotArgs
(
maxCmdLine
);
QCString
dotArgs
(
maxCmdLine
);
...
@@ -3926,7 +3981,7 @@ QCString DotDirDeps::writeGraph(FTextStream &out,
...
@@ -3926,7 +3981,7 @@ QCString DotDirDeps::writeGraph(FTextStream &out,
if
(
generateImageMap
)
dotRun
->
addJob
(
MAP_CMD
,
absMapName
);
if
(
generateImageMap
)
dotRun
->
addJob
(
MAP_CMD
,
absMapName
);
DotManager
::
instance
()
->
addRun
(
dotRun
);
DotManager
::
instance
()
->
addRun
(
dotRun
);
}
}
else
if
(
format
==
EPS
)
else
if
(
graphFormat
==
GOF_
EPS
)
{
{
DotRunner
*
dotRun
=
new
DotRunner
(
absDotName
,
d
.
absPath
().
data
(),
FALSE
);
DotRunner
*
dotRun
=
new
DotRunner
(
absDotName
,
d
.
absPath
().
data
(),
FALSE
);
if
(
usePDFLatex
)
if
(
usePDFLatex
)
...
@@ -3942,7 +3997,23 @@ QCString DotDirDeps::writeGraph(FTextStream &out,
...
@@ -3942,7 +3997,23 @@ QCString DotDirDeps::writeGraph(FTextStream &out,
}
}
Doxygen
::
indexList
->
addImageFile
(
baseName
+
"."
+
imgExt
);
Doxygen
::
indexList
->
addImageFile
(
baseName
+
"."
+
imgExt
);
if
(
format
==
BITMAP
&&
generateImageMap
)
if
(
graphFormat
==
GOF_BITMAP
&&
textFormat
==
EOF_DocBook
)
{
out
<<
"<para>"
<<
endl
;
out
<<
" <figure>"
<<
endl
;
out
<<
" <title>Directory Dependency diagram"
;
out
<<
"</title>"
<<
endl
;
out
<<
" <mediaobject>"
<<
endl
;
out
<<
" <imageobject>"
<<
endl
;
out
<<
" <imagedata"
;
out
<<
" width=
\"
50%
\"
align=
\"
center
\"
valign=
\"
middle
\"
scalefit=
\"
1
\"
fileref=
\"
"
<<
relPath
<<
baseName
<<
"."
<<
imgExt
<<
"
\"
>"
;
out
<<
"</imagedata>"
<<
endl
;
out
<<
" </imageobject>"
<<
endl
;
out
<<
" </mediaobject>"
<<
endl
;
out
<<
" </figure>"
<<
endl
;
out
<<
"</para>"
<<
endl
;
}
else
if
(
graphFormat
==
GOF_BITMAP
&&
generateImageMap
)
{
{
if
(
imgExt
==
"svg"
)
// Scalable vector graphics
if
(
imgExt
==
"svg"
)
// Scalable vector graphics
{
{
...
@@ -3975,7 +4046,7 @@ QCString DotDirDeps::writeGraph(FTextStream &out,
...
@@ -3975,7 +4046,7 @@ QCString DotDirDeps::writeGraph(FTextStream &out,
}
}
}
}
}
}
else
if
(
format
==
EPS
)
else
if
(
graphFormat
==
GOF_
EPS
)
{
{
if
(
regenerate
||
!
writeVecGfxFigure
(
out
,
baseName
,
absBaseName
))
if
(
regenerate
||
!
writeVecGfxFigure
(
out
,
baseName
,
absBaseName
))
{
{
...
@@ -4085,9 +4156,9 @@ void writeDotGraphFromFile(const char *inFile,const char *outDir,
...
@@ -4085,9 +4156,9 @@ void writeDotGraphFromFile(const char *inFile,const char *outDir,
QCString
absOutFile
=
d
.
absPath
().
utf8
()
+
"/"
+
outFile
;
QCString
absOutFile
=
d
.
absPath
().
utf8
()
+
"/"
+
outFile
;
DotRunner
dotRun
(
inFile
,
d
.
absPath
().
data
(),
FALSE
,
absImgName
);
DotRunner
dotRun
(
inFile
,
d
.
absPath
().
data
(),
FALSE
,
absImgName
);
if
(
format
==
BITMAP
)
if
(
format
==
GOF_
BITMAP
)
dotRun
.
addJob
(
imgExt
,
absImgName
);
dotRun
.
addJob
(
imgExt
,
absImgName
);
else
// format==EPS
else
// format==
GOF_
EPS
{
{
if
(
Config_getBool
(
"USE_PDFLATEX"
))
if
(
Config_getBool
(
"USE_PDFLATEX"
))
{
{
...
@@ -4105,7 +4176,7 @@ void writeDotGraphFromFile(const char *inFile,const char *outDir,
...
@@ -4105,7 +4176,7 @@ void writeDotGraphFromFile(const char *inFile,const char *outDir,
return
;
return
;
}
}
if
(
format
==
BITMAP
)
checkDotResult
(
absImgName
);
if
(
format
==
GOF_
BITMAP
)
checkDotResult
(
absImgName
);
Doxygen
::
indexList
->
addImageFile
(
imgName
);
Doxygen
::
indexList
->
addImageFile
(
imgName
);
...
@@ -4384,7 +4455,8 @@ void DotGroupCollaboration::addCollaborationMember(
...
@@ -4384,7 +4455,8 @@ void DotGroupCollaboration::addCollaborationMember(
}
}
QCString
DotGroupCollaboration
::
writeGraph
(
FTextStream
&
t
,
GraphOutputFormat
format
,
QCString
DotGroupCollaboration
::
writeGraph
(
FTextStream
&
t
,
GraphOutputFormat
graphFormat
,
EmbeddedOutputFormat
textFormat
,
const
char
*
path
,
const
char
*
fileName
,
const
char
*
relPath
,
const
char
*
path
,
const
char
*
fileName
,
const
char
*
relPath
,
bool
writeImageMap
,
int
graphId
)
const
bool
writeImageMap
,
int
graphId
)
const
{
{
...
@@ -4411,7 +4483,7 @@ QCString DotGroupCollaboration::writeGraph( FTextStream &t, GraphOutputFormat fo
...
@@ -4411,7 +4483,7 @@ QCString DotGroupCollaboration::writeGraph( FTextStream &t, GraphOutputFormat fo
// write other nodes.
// write other nodes.
for
(
dni
.
toFirst
();(
pn
=
dni
.
current
());
++
dni
)
for
(
dni
.
toFirst
();(
pn
=
dni
.
current
());
++
dni
)
{
{
pn
->
write
(
md5stream
,
DotNode
::
Inheritance
,
f
ormat
,
TRUE
,
FALSE
,
FALSE
,
FALSE
);
pn
->
write
(
md5stream
,
DotNode
::
Inheritance
,
graphF
ormat
,
TRUE
,
FALSE
,
FALSE
,
FALSE
);
}
}
// write edges
// write edges
...
@@ -4441,9 +4513,9 @@ QCString DotGroupCollaboration::writeGraph( FTextStream &t, GraphOutputFormat fo
...
@@ -4441,9 +4513,9 @@ QCString DotGroupCollaboration::writeGraph( FTextStream &t, GraphOutputFormat fo
QCString
absEpsName
=
absBaseName
+
".eps"
;
QCString
absEpsName
=
absBaseName
+
".eps"
;
bool
regenerate
=
FALSE
;
bool
regenerate
=
FALSE
;
if
(
checkAndUpdateMd5Signature
(
absBaseName
,
sigStr
)
||
if
(
checkAndUpdateMd5Signature
(
absBaseName
,
sigStr
)
||
!
checkDeliverables
(
format
==
BITMAP
?
absImgName
:
!
checkDeliverables
(
graphFormat
==
GOF_
BITMAP
?
absImgName
:
usePDFLatex
?
absPdfName
:
absEpsName
,
usePDFLatex
?
absPdfName
:
absEpsName
,
format
==
BITMAP
/*&& generateImageMap*/
?
absMapName
:
QCString
())
graphFormat
==
GOF_
BITMAP
/*&& generateImageMap*/
?
absMapName
:
QCString
())
)
)
{
{
regenerate
=
TRUE
;
regenerate
=
TRUE
;
...
@@ -4456,7 +4528,7 @@ QCString DotGroupCollaboration::writeGraph( FTextStream &t, GraphOutputFormat fo
...
@@ -4456,7 +4528,7 @@ QCString DotGroupCollaboration::writeGraph( FTextStream &t, GraphOutputFormat fo
dotfile
.
close
();
dotfile
.
close
();
}
}
if
(
format
==
BITMAP
)
// run dot to create a bitmap image
if
(
graphFormat
==
GOF_
BITMAP
)
// run dot to create a bitmap image
{
{
QCString
dotArgs
(
maxCmdLine
);
QCString
dotArgs
(
maxCmdLine
);
...
@@ -4466,7 +4538,7 @@ QCString DotGroupCollaboration::writeGraph( FTextStream &t, GraphOutputFormat fo
...
@@ -4466,7 +4538,7 @@ QCString DotGroupCollaboration::writeGraph( FTextStream &t, GraphOutputFormat fo
DotManager
::
instance
()
->
addRun
(
dotRun
);
DotManager
::
instance
()
->
addRun
(
dotRun
);
}
}
else
if
(
format
==
EPS
)
else
if
(
graphFormat
==
GOF_
EPS
)
{
{
DotRunner
*
dotRun
=
new
DotRunner
(
absDotName
,
d
.
absPath
().
data
(),
FALSE
);
DotRunner
*
dotRun
=
new
DotRunner
(
absDotName
,
d
.
absPath
().
data
(),
FALSE
);
if
(
usePDFLatex
)
if
(
usePDFLatex
)
...
@@ -4481,7 +4553,23 @@ QCString DotGroupCollaboration::writeGraph( FTextStream &t, GraphOutputFormat fo
...
@@ -4481,7 +4553,23 @@ QCString DotGroupCollaboration::writeGraph( FTextStream &t, GraphOutputFormat fo
}
}
}
}
if
(
format
==
BITMAP
&&
writeImageMap
)
if
(
graphFormat
==
GOF_BITMAP
&&
textFormat
==
EOF_DocBook
)
{
t
<<
"<para>"
<<
endl
;
t
<<
" <figure>"
<<
endl
;
t
<<
" <title>Group Collaboration diagram"
;
t
<<
"</title>"
<<
endl
;
t
<<
" <mediaobject>"
<<
endl
;
t
<<
" <imageobject>"
<<
endl
;
t
<<
" <imagedata"
;
t
<<
" width=
\"
50%
\"
align=
\"
center
\"
valign=
\"
middle
\"
scalefit=
\"
1
\"
fileref=
\"
"
<<
relPath
<<
baseName
<<
"."
<<
imgExt
<<
"
\"
>"
;
t
<<
"</imagedata>"
<<
endl
;
t
<<
" </imageobject>"
<<
endl
;
t
<<
" </mediaobject>"
<<
endl
;
t
<<
" </figure>"
<<
endl
;
t
<<
"</para>"
<<
endl
;
}
else
if
(
graphFormat
==
GOF_BITMAP
&&
writeImageMap
)
{
{
QCString
mapLabel
=
escapeCharsInString
(
baseName
,
FALSE
);
QCString
mapLabel
=
escapeCharsInString
(
baseName
,
FALSE
);
t
<<
"<center><table><tr><td>"
;
t
<<
"<center><table><tr><td>"
;
...
@@ -4512,10 +4600,9 @@ QCString DotGroupCollaboration::writeGraph( FTextStream &t, GraphOutputFormat fo
...
@@ -4512,10 +4600,9 @@ QCString DotGroupCollaboration::writeGraph( FTextStream &t, GraphOutputFormat fo
t
<<
"<!-- MAP "
<<
mapId
<<
" -->"
<<
endl
;
t
<<
"<!-- MAP "
<<
mapId
<<
" -->"
<<
endl
;
}
}
}
}
t
<<
"</td></tr></table></center>"
<<
endl
;
t
<<
"</td></tr></table></center>"
<<
endl
;
}
}
else
if
(
format
==
EPS
)
else
if
(
graphFormat
==
GOF_
EPS
)
{
{
if
(
regenerate
||
!
writeVecGfxFigure
(
t
,
baseName
,
absBaseName
))
if
(
regenerate
||
!
writeVecGfxFigure
(
t
,
baseName
,
absBaseName
))
{
{
...
...
src/dot.h
View file @
e24e777d
...
@@ -39,7 +39,8 @@ class GroupDef;
...
@@ -39,7 +39,8 @@ class GroupDef;
class
DotGroupCollaboration
;
class
DotGroupCollaboration
;
class
DotRunnerQueue
;
class
DotRunnerQueue
;
enum
GraphOutputFormat
{
BITMAP
,
EPS
};
enum
GraphOutputFormat
{
GOF_BITMAP
,
GOF_EPS
};
enum
EmbeddedOutputFormat
{
EOF_Html
,
EOF_LaTeX
,
EOF_Rtf
,
EOF_DocBook
};
/** Attributes of an edge of a dot graph */
/** Attributes of an edge of a dot graph */
struct
EdgeInfo
struct
EdgeInfo
...
@@ -165,8 +166,8 @@ class DotClassGraph
...
@@ -165,8 +166,8 @@ class DotClassGraph
~
DotClassGraph
();
~
DotClassGraph
();
bool
isTrivial
()
const
;
bool
isTrivial
()
const
;
bool
isTooBig
()
const
;
bool
isTooBig
()
const
;
QCString
writeGraph
(
FTextStream
&
t
,
GraphOutputFormat
f
,
const
char
*
path
,
QCString
writeGraph
(
FTextStream
&
t
,
GraphOutputFormat
gf
,
EmbeddedOutputFormat
ef
,
const
char
*
fileName
,
const
char
*
relPath
,
const
char
*
path
,
const
char
*
fileName
,
const
char
*
relPath
,
bool
TBRank
=
TRUE
,
bool
imageMap
=
TRUE
,
int
graphId
=-
1
)
const
;
bool
TBRank
=
TRUE
,
bool
imageMap
=
TRUE
,
int
graphId
=-
1
)
const
;
void
writeXML
(
FTextStream
&
t
);
void
writeXML
(
FTextStream
&
t
);
...
@@ -196,7 +197,7 @@ class DotInclDepGraph
...
@@ -196,7 +197,7 @@ class DotInclDepGraph
public
:
public
:
DotInclDepGraph
(
FileDef
*
fd
,
bool
inverse
);
DotInclDepGraph
(
FileDef
*
fd
,
bool
inverse
);
~
DotInclDepGraph
();
~
DotInclDepGraph
();
QCString
writeGraph
(
FTextStream
&
t
,
GraphOutputFormat
f
,
QCString
writeGraph
(
FTextStream
&
t
,
GraphOutputFormat
gf
,
EmbeddedOutputFormat
e
f
,
const
char
*
path
,
const
char
*
fileName
,
const
char
*
relPath
,
const
char
*
path
,
const
char
*
fileName
,
const
char
*
relPath
,
bool
writeImageMap
=
TRUE
,
int
graphId
=-
1
)
const
;
bool
writeImageMap
=
TRUE
,
int
graphId
=-
1
)
const
;
bool
isTrivial
()
const
;
bool
isTrivial
()
const
;
...
@@ -222,7 +223,7 @@ class DotCallGraph
...
@@ -222,7 +223,7 @@ class DotCallGraph
public
:
public
:
DotCallGraph
(
MemberDef
*
md
,
bool
inverse
);
DotCallGraph
(
MemberDef
*
md
,
bool
inverse
);
~
DotCallGraph
();
~
DotCallGraph
();
QCString
writeGraph
(
FTextStream
&
t
,
GraphOutputFormat
f
,
QCString
writeGraph
(
FTextStream
&
t
,
GraphOutputFormat
gf
,
EmbeddedOutputFormat
e
f
,
const
char
*
path
,
const
char
*
fileName
,
const
char
*
path
,
const
char
*
fileName
,
const
char
*
relPath
,
bool
writeImageMap
=
TRUE
,
const
char
*
relPath
,
bool
writeImageMap
=
TRUE
,
int
graphId
=-
1
)
const
;
int
graphId
=-
1
)
const
;
...
@@ -249,7 +250,8 @@ class DotDirDeps
...
@@ -249,7 +250,8 @@ class DotDirDeps
~
DotDirDeps
();
~
DotDirDeps
();
bool
isTrivial
()
const
;
bool
isTrivial
()
const
;
QCString
writeGraph
(
FTextStream
&
out
,
QCString
writeGraph
(
FTextStream
&
out
,
GraphOutputFormat
format
,
GraphOutputFormat
gf
,
EmbeddedOutputFormat
ef
,
const
char
*
path
,
const
char
*
path
,
const
char
*
fileName
,
const
char
*
fileName
,
const
char
*
relPath
,
const
char
*
relPath
,
...
@@ -298,7 +300,7 @@ class DotGroupCollaboration
...
@@ -298,7 +300,7 @@ class DotGroupCollaboration
DotGroupCollaboration
(
GroupDef
*
gd
);
DotGroupCollaboration
(
GroupDef
*
gd
);
~
DotGroupCollaboration
();
~
DotGroupCollaboration
();
QCString
writeGraph
(
FTextStream
&
t
,
GraphOutputFormat
format
,
QCString
writeGraph
(
FTextStream
&
t
,
GraphOutputFormat
gf
,
EmbeddedOutputFormat
ef
,
const
char
*
path
,
const
char
*
fileName
,
const
char
*
relPath
,
const
char
*
path
,
const
char
*
fileName
,
const
char
*
relPath
,
bool
writeImageMap
=
TRUE
,
int
graphId
=-
1
)
const
;
bool
writeImageMap
=
TRUE
,
int
graphId
=-
1
)
const
;
void
buildGraph
(
GroupDef
*
gd
);
void
buildGraph
(
GroupDef
*
gd
);
...
...
src/htmldocvisitor.cpp
View file @
e24e777d
...
@@ -1906,7 +1906,7 @@ void HtmlDocVisitor::writeDotFile(const QCString &fn,const QCString &relPath,
...
@@ -1906,7 +1906,7 @@ void HtmlDocVisitor::writeDotFile(const QCString &fn,const QCString &relPath,
}
}
baseName
.
prepend
(
"dot_"
);
baseName
.
prepend
(
"dot_"
);
QCString
outDir
=
Config_getString
(
"HTML_OUTPUT"
);
QCString
outDir
=
Config_getString
(
"HTML_OUTPUT"
);
writeDotGraphFromFile
(
fn
,
outDir
,
baseName
,
BITMAP
);
writeDotGraphFromFile
(
fn
,
outDir
,
baseName
,
GOF_
BITMAP
);
writeDotImageMapFromFile
(
m_t
,
fn
,
outDir
,
relPath
,
baseName
,
context
);
writeDotImageMapFromFile
(
m_t
,
fn
,
outDir
,
relPath
,
baseName
,
context
);
}
}
...
...
src/htmlgen.cpp
View file @
e24e777d
...
@@ -2516,7 +2516,7 @@ void HtmlGenerator::endDotGraph(const DotClassGraph &g)
...
@@ -2516,7 +2516,7 @@ void HtmlGenerator::endDotGraph(const DotClassGraph &g)
endSectionSummary
(
t
);
endSectionSummary
(
t
);
startSectionContent
(
t
,
m_sectionCount
);
startSectionContent
(
t
,
m_sectionCount
);
g
.
writeGraph
(
t
,
BITMAP
,
dir
,
fileName
,
relPath
,
TRUE
,
TRUE
,
m_sectionCount
);
g
.
writeGraph
(
t
,
GOF_BITMAP
,
EOF_Html
,
dir
,
fileName
,
relPath
,
TRUE
,
TRUE
,
m_sectionCount
);
if
(
generateLegend
&&
!
umlLook
)
if
(
generateLegend
&&
!
umlLook
)
{
{
t
<<
"<center><span class=
\"
legend
\"
>["
;
t
<<
"<center><span class=
\"
legend
\"
>["
;
...
@@ -2542,7 +2542,7 @@ void HtmlGenerator::endInclDepGraph(const DotInclDepGraph &g)
...
@@ -2542,7 +2542,7 @@ void HtmlGenerator::endInclDepGraph(const DotInclDepGraph &g)
endSectionSummary
(
t
);
endSectionSummary
(
t
);
startSectionContent
(
t
,
m_sectionCount
);
startSectionContent
(
t
,
m_sectionCount
);
g
.
writeGraph
(
t
,
BITMAP
,
dir
,
fileName
,
relPath
,
TRUE
,
m_sectionCount
);
g
.
writeGraph
(
t
,
GOF_BITMAP
,
EOF_Html
,
dir
,
fileName
,
relPath
,
TRUE
,
m_sectionCount
);
endSectionContent
(
t
);
endSectionContent
(
t
);
m_sectionCount
++
;
m_sectionCount
++
;
...
@@ -2560,7 +2560,7 @@ void HtmlGenerator::endGroupCollaboration(const DotGroupCollaboration &g)
...
@@ -2560,7 +2560,7 @@ void HtmlGenerator::endGroupCollaboration(const DotGroupCollaboration &g)
endSectionSummary
(
t
);
endSectionSummary
(
t
);
startSectionContent
(
t
,
m_sectionCount
);
startSectionContent
(
t
,
m_sectionCount
);
g
.
writeGraph
(
t
,
BITMAP
,
dir
,
fileName
,
relPath
,
TRUE
,
m_sectionCount
);
g
.
writeGraph
(
t
,
GOF_BITMAP
,
EOF_Html
,
dir
,
fileName
,
relPath
,
TRUE
,
m_sectionCount
);
endSectionContent
(
t
);
endSectionContent
(
t
);
m_sectionCount
++
;
m_sectionCount
++
;
...
@@ -2578,7 +2578,7 @@ void HtmlGenerator::endCallGraph(const DotCallGraph &g)
...
@@ -2578,7 +2578,7 @@ void HtmlGenerator::endCallGraph(const DotCallGraph &g)
endSectionSummary
(
t
);
endSectionSummary
(
t
);
startSectionContent
(
t
,
m_sectionCount
);
startSectionContent
(
t
,
m_sectionCount
);
g
.
writeGraph
(
t
,
BITMAP
,
dir
,
fileName
,
relPath
,
TRUE
,
m_sectionCount
);
g
.
writeGraph
(
t
,
GOF_BITMAP
,
EOF_Html
,
dir
,
fileName
,
relPath
,
TRUE
,
m_sectionCount
);
endSectionContent
(
t
);
endSectionContent
(
t
);
m_sectionCount
++
;
m_sectionCount
++
;
...
@@ -2596,7 +2596,7 @@ void HtmlGenerator::endDirDepGraph(const DotDirDeps &g)
...
@@ -2596,7 +2596,7 @@ void HtmlGenerator::endDirDepGraph(const DotDirDeps &g)
endSectionSummary
(
t
);
endSectionSummary
(
t
);
startSectionContent
(
t
,
m_sectionCount
);
startSectionContent
(
t
,
m_sectionCount
);
g
.
writeGraph
(
t
,
BITMAP
,
dir
,
fileName
,
relPath
,
TRUE
,
m_sectionCount
);
g
.
writeGraph
(
t
,
GOF_BITMAP
,
EOF_Html
,
dir
,
fileName
,
relPath
,
TRUE
,
m_sectionCount
);
endSectionContent
(
t
);
endSectionContent
(
t
);
m_sectionCount
++
;
m_sectionCount
++
;
...
...
src/latexdocvisitor.cpp
View file @
e24e777d
...
@@ -1587,7 +1587,7 @@ void LatexDocVisitor::startDotFile(const QCString &fileName,
...
@@ -1587,7 +1587,7 @@ void LatexDocVisitor::startDotFile(const QCString &fileName,
baseName
.
prepend
(
"dot_"
);
baseName
.
prepend
(
"dot_"
);
QCString
outDir
=
Config_getString
(
"LATEX_OUTPUT"
);
QCString
outDir
=
Config_getString
(
"LATEX_OUTPUT"
);
QCString
name
=
fileName
;
QCString
name
=
fileName
;
writeDotGraphFromFile
(
name
,
outDir
,
baseName
,
EPS
);
writeDotGraphFromFile
(
name
,
outDir
,
baseName
,
GOF_
EPS
);
if
(
hasCaption
)
if
(
hasCaption
)
{
{
m_t
<<
"
\n\\
begin{DoxyImage}
\n
"
;
m_t
<<
"
\n\\
begin{DoxyImage}
\n
"
;
...
...
src/latexgen.cpp
View file @
e24e777d
...
@@ -1814,7 +1814,7 @@ void LatexGenerator::startDotGraph()
...
@@ -1814,7 +1814,7 @@ void LatexGenerator::startDotGraph()
void
LatexGenerator
::
endDotGraph
(
const
DotClassGraph
&
g
)
void
LatexGenerator
::
endDotGraph
(
const
DotClassGraph
&
g
)
{
{
g
.
writeGraph
(
t
,
EPS
,
Config_getString
(
"LATEX_OUTPUT"
),
fileName
,
relPath
);
g
.
writeGraph
(
t
,
GOF_EPS
,
EOF_LaTeX
,
Config_getString
(
"LATEX_OUTPUT"
),
fileName
,
relPath
);
}
}
void
LatexGenerator
::
startInclDepGraph
()
void
LatexGenerator
::
startInclDepGraph
()
...
@@ -1823,7 +1823,7 @@ void LatexGenerator::startInclDepGraph()
...
@@ -1823,7 +1823,7 @@ void LatexGenerator::startInclDepGraph()
void
LatexGenerator
::
endInclDepGraph
(
const
DotInclDepGraph
&
g
)
void
LatexGenerator
::
endInclDepGraph
(
const
DotInclDepGraph
&
g
)
{
{
g
.
writeGraph
(
t
,
EPS
,
Config_getString
(
"LATEX_OUTPUT"
),
fileName
,
relPath
);
g
.
writeGraph
(
t
,
GOF_EPS
,
EOF_LaTeX
,
Config_getString
(
"LATEX_OUTPUT"
),
fileName
,
relPath
);
}
}
void
LatexGenerator
::
startGroupCollaboration
()
void
LatexGenerator
::
startGroupCollaboration
()
...
@@ -1832,7 +1832,7 @@ void LatexGenerator::startGroupCollaboration()
...
@@ -1832,7 +1832,7 @@ void LatexGenerator::startGroupCollaboration()
void
LatexGenerator
::
endGroupCollaboration
(
const
DotGroupCollaboration
&
g
)
void
LatexGenerator
::
endGroupCollaboration
(
const
DotGroupCollaboration
&
g
)
{
{
g
.
writeGraph
(
t
,
EPS
,
Config_getString
(
"LATEX_OUTPUT"
),
fileName
,
relPath
);
g
.
writeGraph
(
t
,
GOF_EPS
,
EOF_LaTeX
,
Config_getString
(
"LATEX_OUTPUT"
),
fileName
,
relPath
);
}
}
void
LatexGenerator
::
startCallGraph
()
void
LatexGenerator
::
startCallGraph
()
...
@@ -1841,7 +1841,7 @@ void LatexGenerator::startCallGraph()
...
@@ -1841,7 +1841,7 @@ void LatexGenerator::startCallGraph()
void
LatexGenerator
::
endCallGraph
(
const
DotCallGraph
&
g
)
void
LatexGenerator
::
endCallGraph
(
const
DotCallGraph
&
g
)
{
{
g
.
writeGraph
(
t
,
EPS
,
Config_getString
(
"LATEX_OUTPUT"
),
fileName
,
relPath
);
g
.
writeGraph
(
t
,
GOF_EPS
,
EOF_LaTeX
,
Config_getString
(
"LATEX_OUTPUT"
),
fileName
,
relPath
);
}
}
void
LatexGenerator
::
startDirDepGraph
()
void
LatexGenerator
::
startDirDepGraph
()
...
@@ -1850,7 +1850,7 @@ void LatexGenerator::startDirDepGraph()
...
@@ -1850,7 +1850,7 @@ void LatexGenerator::startDirDepGraph()
void
LatexGenerator
::
endDirDepGraph
(
const
DotDirDeps
&
g
)
void
LatexGenerator
::
endDirDepGraph
(
const
DotDirDeps
&
g
)
{
{
g
.
writeGraph
(
t
,
EPS
,
Config_getString
(
"LATEX_OUTPUT"
),
fileName
,
relPath
);
g
.
writeGraph
(
t
,
GOF_EPS
,
EOF_LaTeX
,
Config_getString
(
"LATEX_OUTPUT"
),
fileName
,
relPath
);
}
}
void
LatexGenerator
::
startDescription
()
void
LatexGenerator
::
startDescription
()
...
...
src/printdocvisitor.h
View file @
e24e777d
...
@@ -479,6 +479,7 @@ class PrintDocVisitor : public DocVisitor
...
@@ -479,6 +479,7 @@ class PrintDocVisitor : public DocVisitor
case
DocImage
:
:
Html
:
printf
(
"html"
);
break
;
case
DocImage
:
:
Html
:
printf
(
"html"
);
break
;
case
DocImage
:
:
Latex
:
printf
(
"latex"
);
break
;
case
DocImage
:
:
Latex
:
printf
(
"latex"
);
break
;
case
DocImage
:
:
Rtf
:
printf
(
"rtf"
);
break
;
case
DocImage
:
:
Rtf
:
printf
(
"rtf"
);
break
;
case
DocImage
:
:
DocBook
:
printf
(
"docbook"
);
break
;
}
}
printf
(
"
\"
width=%s height=%s>
\n
"
,
img
->
width
().
data
(),
img
->
height
().
data
());
printf
(
"
\"
width=%s height=%s>
\n
"
,
img
->
width
().
data
(),
img
->
height
().
data
());
}
}
...
...
src/rtfdocvisitor.cpp
View file @
e24e777d
...
@@ -1653,7 +1653,7 @@ void RTFDocVisitor::writeDotFile(const QCString &fileName)
...
@@ -1653,7 +1653,7 @@ void RTFDocVisitor::writeDotFile(const QCString &fileName)
baseName
=
baseName
.
right
(
baseName
.
length
()
-
i
-
1
);
baseName
=
baseName
.
right
(
baseName
.
length
()
-
i
-
1
);
}
}
QCString
outDir
=
Config_getString
(
"RTF_OUTPUT"
);
QCString
outDir
=
Config_getString
(
"RTF_OUTPUT"
);
writeDotGraphFromFile
(
fileName
,
outDir
,
baseName
,
BITMAP
);
writeDotGraphFromFile
(
fileName
,
outDir
,
baseName
,
GOF_
BITMAP
);
if
(
!
m_lastIsPara
)
m_t
<<
"
\\
par"
<<
endl
;
if
(
!
m_lastIsPara
)
m_t
<<
"
\\
par"
<<
endl
;
m_t
<<
"{"
<<
endl
;
m_t
<<
"{"
<<
endl
;
m_t
<<
rtf_Style_Reset
;
m_t
<<
rtf_Style_Reset
;
...
...
src/rtfgen.cpp
View file @
e24e777d
...
@@ -2409,7 +2409,7 @@ void RTFGenerator::endDotGraph(const DotClassGraph &g)
...
@@ -2409,7 +2409,7 @@ void RTFGenerator::endDotGraph(const DotClassGraph &g)
newParagraph
();
newParagraph
();
QCString
fn
=
QCString
fn
=
g
.
writeGraph
(
t
,
BITMAP
,
Config_getString
(
"RTF_OUTPUT"
),
fileName
,
relPath
,
TRUE
,
FALSE
);
g
.
writeGraph
(
t
,
GOF_BITMAP
,
EOF_Rtf
,
Config_getString
(
"RTF_OUTPUT"
),
fileName
,
relPath
,
TRUE
,
FALSE
);
// display the file
// display the file
t
<<
"{"
<<
endl
;
t
<<
"{"
<<
endl
;
...
@@ -2431,7 +2431,7 @@ void RTFGenerator::endInclDepGraph(const DotInclDepGraph &g)
...
@@ -2431,7 +2431,7 @@ void RTFGenerator::endInclDepGraph(const DotInclDepGraph &g)
{
{
newParagraph
();
newParagraph
();
QCString
fn
=
g
.
writeGraph
(
t
,
BITMAP
,
Config_getString
(
"RTF_OUTPUT"
),
QCString
fn
=
g
.
writeGraph
(
t
,
GOF_BITMAP
,
EOF_Rtf
,
Config_getString
(
"RTF_OUTPUT"
),
fileName
,
relPath
,
FALSE
);
fileName
,
relPath
,
FALSE
);
// display the file
// display the file
...
@@ -2461,7 +2461,7 @@ void RTFGenerator::endCallGraph(const DotCallGraph &g)
...
@@ -2461,7 +2461,7 @@ void RTFGenerator::endCallGraph(const DotCallGraph &g)
{
{
newParagraph
();
newParagraph
();
QCString
fn
=
g
.
writeGraph
(
t
,
BITMAP
,
Config_getString
(
"RTF_OUTPUT"
),
QCString
fn
=
g
.
writeGraph
(
t
,
GOF_BITMAP
,
EOF_Rtf
,
Config_getString
(
"RTF_OUTPUT"
),
fileName
,
relPath
,
FALSE
);
fileName
,
relPath
,
FALSE
);
// display the file
// display the file
...
@@ -2483,7 +2483,7 @@ void RTFGenerator::endDirDepGraph(const DotDirDeps &g)
...
@@ -2483,7 +2483,7 @@ void RTFGenerator::endDirDepGraph(const DotDirDeps &g)
{
{
newParagraph
();
newParagraph
();
QCString
fn
=
g
.
writeGraph
(
t
,
BITMAP
,
Config_getString
(
"RTF_OUTPUT"
),
QCString
fn
=
g
.
writeGraph
(
t
,
GOF_BITMAP
,
EOF_Rtf
,
Config_getString
(
"RTF_OUTPUT"
),
fileName
,
relPath
,
FALSE
);
fileName
,
relPath
,
FALSE
);
// display the file
// display the file
...
...
src/xmldocvisitor.cpp
View file @
e24e777d
...
@@ -681,6 +681,7 @@ void XmlDocVisitor::visitPre(DocImage *img)
...
@@ -681,6 +681,7 @@ void XmlDocVisitor::visitPre(DocImage *img)
case
DocImage
:
:
Html
:
m_t
<<
"html"
;
break
;
case
DocImage
:
:
Html
:
m_t
<<
"html"
;
break
;
case
DocImage
:
:
Latex
:
m_t
<<
"latex"
;
break
;
case
DocImage
:
:
Latex
:
m_t
<<
"latex"
;
break
;
case
DocImage
:
:
Rtf
:
m_t
<<
"rtf"
;
break
;
case
DocImage
:
:
Rtf
:
m_t
<<
"rtf"
;
break
;
case
DocImage
:
:
DocBook
:
m_t
<<
"docbook"
;
break
;
}
}
m_t
<<
"
\"
"
;
m_t
<<
"
\"
"
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment