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
75fed736
Commit
75fed736
authored
May 17, 2001
by
dimitri
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Release-20010517
parent
f5f5db18
Changes
49
Show whitespace changes
Inline
Side-by-side
Showing
49 changed files
with
4161 additions
and
766 deletions
+4161
-766
INSTALL
INSTALL
+1
-1
README
README
+1
-1
Makefile.in
doc/Makefile.in
+5
-2
commands.doc
doc/commands.doc
+11
-0
htmlcmds.doc
doc/htmlcmds.doc
+2
-0
language.tpl
doc/language.tpl
+130
-0
translator.bat
doc/translator.bat
+4
-0
translator.pl
doc/translator.pl
+752
-0
Makefile.in
src/Makefile.in
+1
-1
classdef.cpp
src/classdef.cpp
+304
-202
classdef.h
src/classdef.h
+126
-53
classlist.cpp
src/classlist.cpp
+13
-7
classlist.h
src/classlist.h
+11
-2
definition.cpp
src/definition.cpp
+90
-50
definition.h
src/definition.h
+43
-29
diagram.cpp
src/diagram.cpp
+1
-1
doc.l
src/doc.l
+3
-0
dot.cpp
src/dot.cpp
+183
-11
doxygen.cpp
src/doxygen.cpp
+210
-70
doxygen.h
src/doxygen.h
+10
-3
example.h
src/example.h
+21
-10
filedef.cpp
src/filedef.cpp
+5
-5
filedef.h
src/filedef.h
+3
-2
groupdef.cpp
src/groupdef.cpp
+22
-61
groupdef.h
src/groupdef.h
+3
-3
index.cpp
src/index.cpp
+60
-34
language.cpp
src/language.cpp
+5
-0
latexgen.cpp
src/latexgen.cpp
+7
-8
libdoxygen.pro.in
src/libdoxygen.pro.in
+0
-3
mangen.cpp
src/mangen.cpp
+70
-8
mangen.h
src/mangen.h
+3
-2
memberdef.cpp
src/memberdef.cpp
+43
-51
memberdef.h
src/memberdef.h
+12
-8
memberlist.cpp
src/memberlist.cpp
+1
-1
membername.h
src/membername.h
+14
-0
namespacedef.cpp
src/namespacedef.cpp
+36
-15
namespacedef.h
src/namespacedef.h
+32
-4
packagedef.cpp
src/packagedef.cpp
+9
-9
packagedef.h
src/packagedef.h
+2
-2
rtfgen.cpp
src/rtfgen.cpp
+7
-8
scanner.l
src/scanner.l
+11
-12
sortdict.h
src/sortdict.h
+29
-0
translator_cz.h
src/translator_cz.h
+2
-2
translator_dk.h
src/translator_dk.h
+1309
-0
translator_en.h
src/translator_en.h
+26
-2
translator_it.h
src/translator_it.h
+337
-62
translator_ru.h
src/translator_ru.h
+106
-2
util.cpp
src/util.cpp
+79
-15
util.h
src/util.h
+6
-4
No files found.
INSTALL
View file @
75fed736
...
@@ -3,4 +3,4 @@ DOXYGEN Version 1.2.7
...
@@ -3,4 +3,4 @@ DOXYGEN Version 1.2.7
Please read the installation section of the manual for instructions.
Please read the installation section of the manual for instructions.
--------
--------
Dimitri van Heesch (
30 April
2001)
Dimitri van Heesch (
17 May
2001)
README
View file @
75fed736
...
@@ -7,4 +7,4 @@ The latest version of doxygen can be obtained at
...
@@ -7,4 +7,4 @@ The latest version of doxygen can be obtained at
Enjoy,
Enjoy,
Dimitri van Heesch (
30 April
2001)
Dimitri van Heesch (
17 May
2001)
doc/Makefile.in
View file @
75fed736
...
@@ -12,7 +12,7 @@
...
@@ -12,7 +12,7 @@
# Documents produced by Doxygen are derivative works derived from the
# Documents produced by Doxygen are derivative works derived from the
# input used in their production; they are not affected by this license.
# input used in their production; they are not affected by this license.
all
:
FORCE
all
:
language.doc
FORCE
DOXYGEN_DOCDIR
=
$(DOXYDOCS)
;
\
DOXYGEN_DOCDIR
=
$(DOXYDOCS)
;
\
export
DOXYGEN_DOCDIR
;
\
export
DOXYGEN_DOCDIR
;
\
VERSION
=
$(VERSION)
;
\
VERSION
=
$(VERSION)
;
\
...
@@ -26,6 +26,9 @@ all: FORCE
...
@@ -26,6 +26,9 @@ all: FORCE
@
cp
doxygen_logo.eps ../latex
@
cp
doxygen_logo.eps ../latex
clean
:
clean
:
rm
-rf
../html ../latex
rm
-rf
../html ../latex language.doc
language.doc
:
language.tpl FORCE
$(PERL)
translator.pl
FORCE
:
FORCE
:
doc/commands.doc
View file @
75fed736
...
@@ -86,6 +86,7 @@ documentation:
...
@@ -86,6 +86,7 @@ documentation:
<li> \refitem cmdingroup \ingroup
<li> \refitem cmdingroup \ingroup
<li> \refitem cmdinternal \internal
<li> \refitem cmdinternal \internal
<li> \refitem cmdinvariant \invariant
<li> \refitem cmdinvariant \invariant
<li> \refitem cmdinterface \interface
<li> \refitem cmdlatexonly \latexonly
<li> \refitem cmdlatexonly \latexonly
<li> \refitem cmdli \li
<li> \refitem cmdli \li
<li> \refitem cmdline \line
<li> \refitem cmdline \line
...
@@ -349,6 +350,16 @@ Doxygen. Unrecognized commands are treated as normal text.
...
@@ -349,6 +350,16 @@ Doxygen. Unrecognized commands are treated as normal text.
\sa section \ref cmddefgroup "\\defgroup".
\sa section \ref cmddefgroup "\\defgroup".
<hr>
\subsection cmdinterface \interface
\addindex \interface
Indicates that a comment block contains documentation for an
interface with name \<name\>. The arguments are equal to the \\class
command.
\sa section \ref cmdclass "\\class".
<hr>
<hr>
\subsection cmdinternal \internal
\subsection cmdinternal \internal
...
...
doc/htmlcmds.doc
View file @
75fed736
...
@@ -83,6 +83,8 @@ documentation. Note that all attributes of a HTML tag are ignored
...
@@ -83,6 +83,8 @@ documentation. Note that all attributes of a HTML tag are ignored
<li>\c </TR> Does not generate any output.
<li>\c </TR> Does not generate any output.
<li>\c <TT> Starts a piece of text displayed in a typewriter font.
<li>\c <TT> Starts a piece of text displayed in a typewriter font.
<li>\c </TT> Ends a \c <TT> section.
<li>\c </TT> Ends a \c <TT> section.
<li>\c <KBD> Starts a piece of text displayed in a typewriter font.
<li>\c </KBD> Ends a \c <KBD> section.
<li>\c <UL> Starts an unnumbered item list.
<li>\c <UL> Starts an unnumbered item list.
<li>\c </UL> Ends an unnumbered item list.
<li>\c </UL> Ends an unnumbered item list.
<li>\c <VAR> Starts a piece of text displayed in an italic font.
<li>\c <VAR> Starts a piece of text displayed in an italic font.
...
...
doc/language.tpl
0 → 100644
View file @
75fed736
/******************************************************************************
*
<notice>
This is the template for generating language.doc. Edit this file,
* not the language.doc.
</notice>
*
*
* Copyright (C) 1997-2001 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.
*
*/
/*! \page langhowto Internationalization
<h3>
Support for multiple languages
</h3>
Doxygen has support for multiple languages. This means
that the text fragments that doxygen generates can changed into languages
other than English (the default) at configuration time.
<p>
Currently, $numlang languages are supported (sorted alphabetically):
$languages.
The table of information related to the supported languages follows.
It is sorted by language alphabetically. The
<B>
Status
</B>
column
was generated from sources and shows approximately the last version
when the translator was updated.
<p>
$information_table
Have a look at
<code>
doxygen/doc/translator.txt
</code>
for more details.
<p>
Most people on the list have indicated that they were also busy
doing other things, so if you want to help to speed things up please
let them (or me) know.
If you want to add support for a language that is not yet listed
please see the next section.
<h3>
Adding a new language to doxygen
</h3>
This short HOWTO explains how to add support for a new language to Doxygen:
Just follow these steps:
<ol>
<li>
Tell me for which language you want to add support. If no one else
is already working on support for that language, you will be
assigned as the maintainer for the language.
<li>
Create a copy of translator_en.h and name it
translator_
<your
_2_letter_counter_code
>
.h
I'll use xx in the rest of this document.
<li>
Edit language.cpp:
Add a
\verbatim
#include
<translator
_xx
.
h
>
\endverbatim
in
<code>
setTranslator()
</code>
add
\verbatim
else if (L_EQUAL("your_language_name"))
{
theTranslator = new TranslatorYourLanguage;
}
\endverbatim
after the
<code>
if { ... }
</code>
<li>
Edit libdoxygen.pro.in and add \c translator_xx.h to
the \c HEADERS line in the file doxygen.pro.
<li>
Edit
<code>
translator_xx.h
</code>
:
<ul>
<li>
Rename
<code>
TRANSLATOR_EN_H
</code>
to
<code>
TRANSLATOR_XX_H
</code>
twice.
<li>
Rename TranslatorEnglish to TranslatorYourLanguage
<li>
In the member
<code>
idLanguage()
</code>
change "english" into the
name of the your language (use lower case characters only). Depending
on the language you may also wish to change the member functions
latexLanguageSupportCommand() and idLanguageCharset().
<li>
Edit all the strings that are returned by the member functions that
start with tr.
Try to match punctuation and capitals!
To enter special characters (with accents) you can:
<ul>
<li>
Enter them directly if your keyboard supports that and you are
using a Latin-1 font.
Doxygen will translate the characters to proper Latex and
leave the Html and man output for what it is (which is fine, if
idLanguageCharset() is set correctly).
<li>
Use html codes like \
ä
for an a with an umlaut (i.e.
ä
).
See the HTML specification for the codes.
</ul>
</ul>
<li>
Run configure and make again from the root of the distribution,
in order to regenerated the Makefiles.
<li>
Now you can use
<code>
OUTPUT_LANGUAGE = your_language_name
</code>
in the config file to generate output in your language.
<li>
Send
<code>
translator_xx.h
</code>
to me so I can add it to doxygen.
</ol>
<h3>
Maintaining a language
</h3>
As new versions of doxygen appear, new sentences will be
added to the Translator interface class. Of course these need to be translated
as well (otherwise doxygen wouldn't even compile!).
Waiting until all language maintainers have translated these new sentences
and sent the results would not be very practical for me.
Instead, a new class TranslatorAdapter_x_y_z will be added to
translator_adapter.h (here x,y, and z correspond to the current
version of doxygen). And all translators that previous derived from
Translator will now derive from this adapter class.
The Adapter class contains the new sentences with
default translations using the English translator (which is always up to date).
Instead of deriving your TranslatorXX class directly from Translator it will
derive from the intermediate class TranslatorAdapter_x_y_z.
Thus, if a translator class inherits from a adapter class
maintenance is needed. By looking at the adapter class itself (and its base
classes) you can easily see which methods need to be updated.
To update a language simply make your translator class derive from
the abstract class Translator and provide translations for the methods that
were previously provided by the adapter class (and its base classes).
*/
doc/translator.bat
0 → 100644
View file @
75fed736
:start
call perl -w translator.pl
pause
goto start
\ No newline at end of file
doc/translator.pl
0 → 100644
View file @
75fed736
#! /usr/bin/perl -w
# -*- mode: perl; mode: fold -*-
# This is a Perl script for Doxygen developers.
# Its main purpose is to extract the information from sources
# related to internationalization (the translator classes).
#
# Petr Prikryl (prikrylp@skil.cz)
# History:
# --------
# 2001/04/27
# - First version of the script.
#
# 2002/05/02
# - Update to accept updateNeededMessage() in the Translator class.
# - First version that generates doc/language.doc.
#
################################################################
require
5.005
;
use
strict
;
use
Carp
;
# Global variables
#
my
$doxygenrootdir
=
".."
;
my
$srcdir
=
"$doxygenrootdir/src"
;
my
$docdir
=
"$doxygenrootdir/doc"
;
# Names of the output files.
#
my
$ftxt
=
"translator_report.txt"
;
my
$fdoc
=
"language.doc"
;
################################################################
# GetPureVirtual returns a hash of pure virtual method prototypes
# in a hash where the key is the method prototype, and the value
# is 1. The input argument is the full name of the source file.
#
sub
GetPureVirtualFrom
##{{{
{
my
$fin
=
shift
;
# Get the file name.
# Let's open the file and read it into a single string.
#
open
(
FIN
,
"< $fin"
)
or
die
"\nError when open < $fin: $!"
;
my
@content
=
<
FIN
>
;
close
FIN
;
my
$cont
=
join
(
""
,
@content
);
# Remove comments and empty lines.
#
$cont
=~
s{\s*//.*$}{}mg
;
# remove one-line comments
while
(
$cont
=~
s{/\*.+?\*/}{}sg
)
{}
# remove C comments
$cont
=~
s{\n\s*\n}{\n}sg
;
# remove empty lines
# Remove the beginning up to the first virtual method.
# Remove also the text behind the class.
#
$cont
=~
s/^.*?virtual/virtual/s
;
$cont
=~
s/\n\};.*$//s
;
# Erase anything between "=0;" and "virtual". Only the pure
# virtual methods will remain. Remove also the text behind
# the last "= 0;"
#
$cont
=~
s{(=\s*0\s*;).*?(virtual)}{$1 $2}sg
;
$cont
=~
s{^(.+=\s*0\s*;).*?$}{$1}s
;
# Remove the empty implementation of the updateNeededMessage()
# method which is to be implemented by adapters only, not by
# translators.
#
$cont
=~
s{\s*virtual
\s+QCString
\s+updateNeededMessage\(\)
\s+\{\s*return\s+"";\s*\}
}
{}xs
;
# Replace all consequent white spaces (including \n) by a single
# space. Trim also the leading and the trailing space.
#
$cont
=~
s{\s+}{ }sg
;
$cont
=~
s{^\s+}{}s
;
$cont
=~
s{\s+$}{}s
;
# Split the result to the lines again. Remove the "= 0;".
#
$cont
=~
s{\s*=\s*0\s*;\s*}{\n}sg
;
# Remove the keyword "virtual" because the derived classes
# may not use it.
#
$cont
=~
s{^virtual\s+}{}mg
;
# Split the string into array of lines and fill the output hash.
#
my
%
result
=
();
foreach
(
split
(
/\n/
,
$cont
))
{
$result
{
$_
}
=
1
;
}
return
%
result
;
}
##}}}
################################################################
# GetInfoFrom returns the list of information related to the
# parsed source file. The input argument is the name of the
# translator_xx.h file including path.
#
# The output list contains the following items:
# - class identifier
# - base class identifier
# - method prototypes (each in a separate item)
#
sub
GetInfoFrom
##{{{
{
# Get the file name.
#
my
$fin
=
shift
;
# Let's open the file and read it into a single string.
#
open
(
FIN
,
"< $fin"
)
or
die
"\nError when open < $fin: $!"
;
my
@content
=
<
FIN
>
;
close
FIN
;
my
$cont
=
join
(
""
,
@content
);
# Remove comments and empty lines.
#
$cont
=~
s{\s*//.*$}{}mg
;
# remove one-line comments
$cont
=~
s{/\*.+?\*/}{}sg
;
# remove C comments
$cont
=~
s{\n\s*\n}{\n}sg
;
# remove empty lines
# Extract the class and base class identifiers. Remove the
# opening curly brace. Remove also the first "public:"
# Put the class and the base class into the output list.
#
$cont
=~
s{^.*class\s+(Translator\w+)[^:]*:
\s*public\s+(\w+)\b.*?\{\s*
(public\s*:\s+)?
}
{}sx
;
@content
=
(
$1
,
$2
);
# Cut the things after the class.
#
$cont
=~
s{\}\s*;\s*#endif\s*$}{}s
;
# Remove the "virtual" keyword, because some the derived class
# is not forced to use it.
#
$cont
=~
s{^\s*virtual\s+}{}mg
;
# Remove all strings from lines.
#
$cont
=~
s{".*?"}{}mg
;
# Remove all bodies of methods;
#
while
(
$cont
=~
s/{[^{}]+?}//sg
)
{}
# Remove all private methods, i.e. from "private:" to "public:"
# included. Later, remove also all from "private:" to the end.
#
$cont
=~
s{private\s*:.*?public\s*:}{}sg
;
$cont
=~
s{private\s*:.*$}{}s
;
# Some of the translators use conditional compilation where
# the branches define the body of the method twice. Remove
# the ifdef/endif block content.
#
$cont
=~
s{#ifdef.*?#endif}{}sg
;
# Now the string should containt only method prototypes.
# Let's unify their format by removing all spaces that
# are not necessary. Then let's put all of them on separate
# lines (one protototype -- one line; no empty lines).
#
$cont
=~
s{\s+}{ }sg
;
$cont
=~
s{^\s+}{}s
;
$cont
=~
s{\s+$}{}s
;
$cont
=~
s{\)\s*}{)\n}g
;
# Split the string and add it to the ouptut list.
#
@content
=
(
@content
,
split
(
/\n/
,
$cont
));
return
@content
;
}
##}}}
################################################################
# GenerateLanguageDoc takes document templates and code sources
# generates the content as expected in the language.doc file (the
# part of the Doxygen documentation), and returns the result as a
# string.
#
sub
GenerateLanguageDoc
##{{{
{
# Get the references to the hash of class/base class.
#
my
$rcb
=
shift
;
# Define templates for HTML table parts of the documentation. #{{{
#
my
$htmlTableHead
=
<<'xxxTABLE_HEADxxx';
\htmlonly
<TABLE ALIGN=center CELLSPACING=0 CELLPADDING=0 BORDER=0>
<TR BGCOLOR="#000000">
<TD>
<TABLE CELLSPACING=1 CELLPADDING=2 BORDER=0>
<TR BGCOLOR="#4040c0">
<TD ><b><font size=+1 color="#ffffff"> Language </font></b></TD>
<TD ><b><font size=+1 color="#ffffff"> Maintainer </font></b></TD>
<TD ><b><font size=+1 color="#ffffff"> Contact address </font>
<font size=-2 color="#ffffff">(remove the NOSPAM.)</font></b></TD>
<TD ><b><font size=+1 color="#ffffff"> Status </font></b></TD>
</TR>
xxxTABLE_HEADxxx
my
$htmlTableRow
=
<<'xxxTABLE_ROWxxx';
<TR BGCOLOR="#ffffff">
<TD>$lang</TD>
<TD>$maintainer</TD>
<TD>$email</TD>
<TD>$status</TD>
</TR>
xxxTABLE_ROWxxx
my
$htmlTableFoot
=
<<'xxxTABLE_FOOTxxx';
</TABLE>
</TD>
</TR>
</TABLE>
\endhtmlonly
xxxTABLE_FOOTxxx
##}}}
# Define templates for LaTeX table parts of the documentation. #{{{
#
my
$latexTableHead
=
<<'xxxTABLE_HEADxxx';
\latexonly
\begin{tabular}{|l|l|l|l|}
\hline
{\bf Language} & {\bf Maintainer} & {Contact address} & {Status} \\
xxxTABLE_HEADxxx
my
$latexTableRow
=
<<'xxxTABLE_ROWxxx';
$lang & $maintainer & {\tt $email} & $status \\
xxxTABLE_ROWxxx
my
$latexTableFoot
=
<<'xxxTABLE_FOOTxxx';
\hline
\end{tabular}
\endlatexonly
xxxTABLE_FOOTxxx
##}}}
# Read the template of the documentation, and join the content
# to a single string. #{{{
#
my
$fin
=
"$docdir/language.tpl"
;
open
(
FIN
,
"< $fin"
)
or
die
"\nError when open < $fin: $!"
;
my
@content
=
<
FIN
>
;
close
FIN
;
my
$output
=
join
(
""
,
@content
);
##}}}
# Make and substitute the list of supported languages and their
# number. #{{{
#
my
@languages
=
sort
grep
{
s{^Translator}{}
}
keys
%
{
$rcb
};
my
$numlang
=
@languages
;
$output
=~
s{\$numlang}{$numlang}
;
my
$languages
=
join
(
", "
,
@languages
);
$languages
=~
s{((\w+,\s){5}
)}
{$1\n}g
;
$languages
=~
s{Brazilian}{Brazilian Portuguese}
;
$languages
=~
s{(,\s+)(\w+)$}{$1and $2}s
;
$output
=~
s{\$languages}{$languages}
;
##}}}
# Create the hash of languages with the initial info. #{{{
#
my
%
language
=
();
foreach
(
@languages
)
{
$language
{
$_
}
=
$$rcb
{
"Translator$_"
}
.
"<msep/>unknown: unknown"
;
}
##}}}
# Read the information related to maintainers into the
# string using suitable separators -- one line, one language. #{{{
#
$fin
=
"$docdir/maintainers.txt"
;
open
(
FIN
,
"< $fin"
)
or
die
"\nError when open < $fin: $!"
;
my
@maintainers
=
<
FIN
>
;
close
FIN
;
my
$maintainers
=
join
(
""
,
@maintainers
);
# Trim the spaces on the lines. Strip the comment lines that
# start with % sign.
#
$maintainers
=~
s{^[ \t]+}{}mg
;
$maintainers
=~
s{[ \t]+$}{}mg
;
$maintainers
=~
s{^%.*$}{}mg
;
# Join the information for one language into one line,
# and remove empty lines.
#
$maintainers
=~
s{\b\n\b}{<sep/>}sg
;
$maintainers
=~
s{\n{2,}
}
{\n}sg
;
$maintainers
=~
s{^\n+}{}s
;
$maintainers
=~
s{\n+$}{}s
;
##}}}
# Split the string back to the list, and update the information
# in the hash with information for languages. #{{{
#
foreach
my
$line
(
sort
split
(
/\n/
,
$maintainers
))
{
# Split the line for one language to separate lines for
# the language and one or more maintainers.
#
my
@info
=
split
(
/<sep\/>/
,
$line
);
my
$lang
=
shift
@info
;
# Ensure that the language starts with uppercase and
# continues with lowercase.
#
$lang
=~
s{^(\w)(\w+)}{\U$1\L$2\E}
;
# Add information to the %language hash. If the language
# was not defined in sources, add the question mark to the
# language identifier.
#
if
(
defined
$language
{
$lang
})
{
$language
{
$lang
}
=
$$rcb
{
"Translator$lang"
}
.
'<msep/>'
.
join
(
"<sep/>"
,
@info
);
}
else
{
$lang
.=
" (?)"
;
$language
{
$lang
}
=
"unknown<msep/>"
.
join
(
"<sep/>"
,
@info
);
}
}
##}}}
# Now, the %language hash contains all the information needed for
# generating the tables (HTML and LaTeX). Define string variables
# for each of the tables, and initialize them. #{{{
#
my
$tableHTML
=
$htmlTableHead
;
my
$tableLATEX
=
$latexTableHead
;
##}}}
# Loop through sorted keys for the languages, parse the
# information, and add it to the tables. #{{{
#
foreach
my
$lang
(
sort
keys
%
language
)
{
# Read the line with info for the language and separate
# the information of status. #{{{
#
my
@list
=
split
(
/<msep\/>/
,
$language
{
$lang
});
my
$status
=
shift
@list
;
my
$i
=
$status
=~
s{^Translator$}{up-to-date}
;
if
(
$i
==
0
)
{
$i
=
$status
=~
s{^TranslatorAdapter_(\d)_(\d)_(\d)}
{$1.$2.$3}x
;
}
if
(
$i
==
0
)
{
$status
=
'?'
;
}
##}}}
# Split the rest of the list (should be a single item) into
# the list with one or more maintainers -- one line, one
# maintainer. #{{{
#
my
$rest
=
shift
@list
;
@list
=
split
(
/<sep\/>/
,
$rest
);
##}}}
# In HTML table, maintainer names are placed in the same
# cell. Also their e-mails are placed in a single cell.
# Extract the string with concatenated names and the string
# with concatenated e-mails. Add the row to the HTML
# table. #{{{
#
my
$name
=
''
;
my
$email
=
''
;
foreach
my
$maintainer
(
@list
)
{
if
(
$name
ne
''
)
{
$name
.=
'<br>'
;
}
if
(
$email
ne
''
)
{
$email
.=
'<br>'
;
}
$maintainer
=~
m{^\s*(.+?)\s*:\s*(.+?)\s*$}
;
$name
.=
$1
;
$email
.=
$2
;
}
# Prepare the HTML row template, modify it, and add the
# result to the HTML table.
#
my
$item
=
$htmlTableRow
;
$item
=~
s{\$lang}{$lang}
;
$item
=~
s{\$maintainer}{$name}
;
$item
=~
s{\$email}{$email}
;
$item
=~
s{\$status}{$status}
;
$tableHTML
.=
$item
;
##}}}
# For LaTeX, more maintainers for the same language are
# placed on separate rows in the table. The line separator
# in the table is placed explicitly above the first
# maintainer. Add rows for all maintainers to the LaTeX
# table. #{{{
#
# Prepare the LATEX row template, modify it, and add the
# result to the LATEX table.
#
$item
=
$latexTableRow
;
my
$first
=
shift
@list
;
# the first maintainer.
$first
=~
m{^\s*(.+?)\s*:\s*(.+?)\s*$}
;
$name
=
$1
;
$email
=
$2
;
$item
=~
s{\$lang}{$lang}
;
$item
=~
s{\$maintainer}{$name}
;
$item
=~
s{\$email}{$email}
;
$item
=~
s{\$status}{$status}
;
$tableLATEX
.=
" \\hline\n"
.
$item
;
# List the other maintainers for the language. Do not set
# lang and status for them.
#
while
(
@list
)
{
my
$next
=
shift
@list
;
$next
=~
m{^\s*(.+?)\s*:\s*(.+?)\s*$}
;
my
$name
=
$1
;
my
$email
=
$2
;
my
$item
=
$latexTableRow
;
$item
=~
s{\$lang}{}
;
$item
=~
s{\$maintainer}{$name}
;
$item
=~
s{\$email}{$email}
;
$item
=~
s{\$status}{}
;
$tableLATEX
.=
$item
;
}
##}}}
}
##}}}
# Finish the tables, and substitute the mark in the doc
# template by the contatenation of the tables. Add NOSPAM to
# email addresses in the HTML table. Replace the special
# character sequences. #{{{
#
$tableHTML
.=
$htmlTableFoot
;
$tableLATEX
.=
$latexTableFoot
;
$tableHTML
=~
s{@}{\@NOSPAM.}sg
;
$tableHTML
=~
s{ř}{ř}sg
;
$tableLATEX
=~
s/ř/\\v{r}/sg
;
$tableLATEX
=~
s/á/\\'{a}/sg
;
$tableLATEX
=~
s/ä/\\"{a}/sg
;
$tableLATEX
=~
s/ö/\\"{o}/sg
;
$tableLATEX
=~
s/_/\\_/sg
;
$output
=~
s{\$information_table}{$tableHTML$tableLATEX}
;
##}}}
# Replace the introduction notice in the output. #{{{
#
$output
=~
s{<notice>.+?</notice>}
{Warning: this file was generated from the language.tpl template
* Do not edit this file. Edit the template!}sx
;
##}}}
# Return the content of the generated output file.
#
return
$output
;
}
##}}}
################################################################
# Body
#
{
# The translator base class must be present. Exit otherwise. #{{{
#
if
(
!-
f
"$srcdir/translator.h"
)
{
print
STDERR
"\n\nThe translator.h not found in $srcdir.\n\n\a"
;
exit
1
;
}
##}}}
# Find all translator_xx.h files. #{{{
#
my
@entries
=
();
# init
opendir
DIR
,
$srcdir
or
confess
"opendir error for $srcdir: $!"
;
foreach
(
readdir
(
DIR
))
{
if
(
!
/^\./
)
{
push
@entries
,
$_
;
}
}
closedir
DIR
;
# ignore names with dot at the beginning
my
@files
=
sort
grep
{
-
f
"$srcdir/$_"
&&
m{^translator_..\.h$}i
}
@entries
;
##}}}
# Get only the pure virtual methods from the Translator class
# into a hash structure for later testing present/not present.
#
my
%
required
=
GetPureVirtualFrom
(
"$srcdir/translator.h"
);
# Collect base classes of translators the hash.
#
my
%
cb
=
();
# The details for translators will be collected into the output
# string.
#
my
$output
=
''
;
# Loop through all translator files. Extract the implemented
# virtual methods and compare it with the requirements. Prepare
# the output.
#
foreach
(
@files
)
{
# Get the information from the sources. Remember the base
# class for each of the classes. #{{{
#
my
@info
=
GetInfoFrom
(
"$srcdir/$_"
);
my
$class
=
shift
@info
;
my
$base
=
shift
@info
;
$cb
{
$class
}
=
$base
;
##}}}
# Set the value of the required methods to 1 (true). Let
# this indicate that the method was not defined in the
# translator class.
#
foreach
(
keys
%
required
)
{
$required
{
$_
}
=
1
;
}
# Loop through all items and compare the prototypes. Mark
# the implemented method and collect the old ones. #{{{
#
my
@old_methods
=
();
foreach
my
$method
(
@info
)
{
if
(
defined
$required
{
$method
})
{
$required
{
$method
}
=
0
;
}
else
{
push
(
@old_methods
,
$method
);
}
}
##}}}
# Loop through the required hash and collect the missing
# (new) methods. Do this only when it derives from
# Translator or TranslatorAdapter classes. #{{{
#
my
@missing_methods
=
();
if
(
$base
=~
m/^Translator(Adapter.*)?$/
)
{
foreach
(
keys
%
required
)
{
if
(
$required
{
$_
})
{
push
(
@missing_methods
,
$_
);
}
}
}
##}}}
# The detailed output will be produced only when it is
# needed. #{{{
#
if
(
@old_methods
||
@missing_methods
||
$base
!~
m/^Translator(Adapter.*)?$/
)
{
$output
.=
"\n\n\n"
;
$output
.=
$class
.
" ($base)\n"
.
'-'
x
length
(
$class
)
.
"\n"
;
if
(
$base
!~
m/^Translator(Adapter.*)?$/
)
{
$output
.=
"\nThis is the unusual implementation of the "
.
"translator. Its class is derived\n"
.
"from the $base base class. The usual translator"
.
"class derives\n"
.
"or from the Translator class or from some "
.
"TranslatorAdapter_x_x_x classes.\n"
.
"Because of that, nothing can be guessed about "
.
"missing methods.\n"
;
}
if
(
@missing_methods
)
{
$output
.=
"\nMissing methods (should be implemented):\n\n"
;
foreach
(
@missing_methods
)
{
$output
.=
" $_\n"
;
}
}
if
(
@old_methods
)
{
$output
.=
"\nObsolete methods (should be removed):\n\n"
;
foreach
(
sort
@old_methods
)
{
$output
.=
" $_\n"
;
}
}
}
##}}}
}
# Generate the textual output file.
#
my
$fout
=
"$docdir/$ftxt"
;
# Open it first.
#
open
(
FOUT
,
"> $fout"
)
or
die
"\nError when open > $fout: $!"
;
# List the supported languages. #{{{
#
my
@all_translators
=
keys
%
cb
;
print
FOUT
"Doxygen supports the following ("
.
@all_translators
.
") languages (sorted alphabetically):\n\n"
;
foreach
(
sort
grep
{
s/^Translator(\w+)\b.*$/$1/
}
@all_translators
)
{
print
FOUT
" $_\n"
;
}
##}}}
# If there are up-to-date translators, list them. #{{{
#
my
@list
=
sort
grep
{
$cb
{
$_
}
=~
m/^Translator$/
}
keys
%
cb
;
if
(
@list
)
{
print
FOUT
"\n"
.
'-'
x
70
.
"\n"
;
print
FOUT
"The following translator classes are up-to-date "
.
"(sorted alphabetically).\n"
.
"This means that they derive from the Translator class. "
.
"However, there still\n"
.
"may be some details listed below "
.
"for them. Please, check it.\n\n"
;
foreach
(
@list
)
{
print
FOUT
" $_\n"
;
}
}
##}}}
# If there are obsolete translators, list them. #{{{
#
@list
=
sort
grep
{
$cb
{
$_
}
=~
m/^TranslatorAdapter/
}
keys
%
cb
;
if
(
@list
)
{
print
FOUT
"\n"
.
'-'
x
70
.
"\n"
;
print
FOUT
"The following translator classes are obsolete "
.
"(sorted alphabetically).\n"
.
"This means that they derive from some of "
.
"the adapter classes.\n\n"
;
foreach
(
@list
)
{
print
FOUT
" $_\t($cb{$_})\n"
;
}
}
##}}}
# If there are other translators, list them. #{{{
#
@list
=
sort
grep
{
$cb
{
$_
}
!~
m/^Translator$/
}
grep
{
$cb
{
$_
}
!~
m/^TranslatorAdapter/
}
keys
%
cb
;
if
(
@list
)
{
print
FOUT
"\n"
.
'-'
x
70
.
"\n"
;
print
FOUT
"The following translator classes are somehow different\n"
.
"(sorted alphabetically). This means that they "
.
"do not derive from\n"
.
"the Translator class, nor from some of the adapter classes.\n\n"
;
foreach
(
@list
)
{
print
FOUT
" $_\t($cb{$_})\n"
;
}
}
##}}}
# List the methods that are expected to be implemented. #{{{
print
FOUT
"\n\n"
.
'-'
x
70
.
"\n"
;
print
FOUT
"Localized translators are expected to implement "
.
"the following methods\n"
.
"(prototypes sorted aplhabetically):\n\n"
;
foreach
(
sort
keys
(
%
required
))
{
print
FOUT
"$_\n"
;
}
##}}}
# If there are some details for the translators, show them. #{{{
#
if
(
$output
!~
m/^\s*$/
)
{
print
FOUT
"\n\n"
.
'-'
x
70
.
"\n"
;
print
FOUT
"Details related to specific translator classes follows.\n"
.
"Notice that the prototypes are recognized only when they\n"
.
"are the same as in the Translator class."
;
print
FOUT
$output
.
"\n"
;
}
##}}}
# Close the output file
#
close
FOUT
;
# Generate the language.doc file.
#
$fout
=
"$docdir/$fdoc"
;
# Open it first for the output.
#
open
(
FOUT
,
"> $fout"
)
or
die
"\nError when open > $fout: $!"
;
print
FOUT
GenerateLanguageDoc
(
\%
cb
);
# Close the output file
#
close
FOUT
;
exit
0
;
}
# end of body
################################################################
src/Makefile.in
View file @
75fed736
#
#
#
$Id$
#
#
#
# Copyright (C) 1997-2001 by Dimitri van Heesch.
# Copyright (C) 1997-2001 by Dimitri van Heesch.
#
#
...
...
src/classdef.cpp
View file @
75fed736
...
@@ -49,76 +49,73 @@ ClassDef::ClassDef(
...
@@ -49,76 +49,73 @@ ClassDef::ClassDef(
const
char
*
lref
,
const
char
*
fName
)
const
char
*
lref
,
const
char
*
fName
)
:
Definition
(
defFileName
,
defLine
,
removeRedundantWhiteSpace
(
nm
))
:
Definition
(
defFileName
,
defLine
,
removeRedundantWhiteSpace
(
nm
))
{
{
//name=n;
m_compType
=
ct
;
compType
=
ct
;
QCString
compoundName
=
compoundTypeString
();
QCString
compoundName
=
compoundTypeString
();
if
(
fName
)
if
(
fName
)
{
{
fileName
=
stripExtension
(
fName
);
m_
fileName
=
stripExtension
(
fName
);
}
}
else
else
{
{
fileName
=
compoundName
+
nm
;
m_fileName
=
compoundName
+
m_name
;
}
}
if
(
lref
)
if
(
lref
)
{
{
//url=(QCString)"doxygen=\""+lref+":\" href=\""+fileName;
m_exampleSDict
=
0
;
exampleList
=
0
;
exampleDict
=
0
;
}
}
else
else
{
{
//url="href=\""+fileName;
m_exampleSDict
=
new
ExampleSDict
(
17
);
exampleList
=
new
ExampleList
;
}
exampleDict
=
new
ExampleDict
(
17
);
m_memListFileName
=
convertNameToFile
(
compoundName
+
m_name
+
"-members"
);
}
m_inherits
=
new
BaseClassList
;
memListFileName
=
convertNameToFile
(
compoundName
+
nm
+
"-members"
);
m_inherits
->
setAutoDelete
(
TRUE
);
inherits
=
new
BaseClassList
;
m_inheritedBy
=
new
BaseClassList
;
inherits
->
setAutoDelete
(
TRUE
);
m_inheritedBy
->
setAutoDelete
(
TRUE
);
inheritedBy
=
new
BaseClassList
;
m_allMemberNameInfoSDict
=
new
MemberNameInfoSDict
(
257
);
inheritedBy
->
setAutoDelete
(
TRUE
);
m_allMemberNameInfoSDict
->
setAutoDelete
(
TRUE
);
allMemberNameInfoList
=
new
MemberNameInfoList
;
allMemberNameInfoList
->
setAutoDelete
(
TRUE
);
allMemberNameInfoDict
=
new
MemberNameInfoDict
(
257
);
visited
=
FALSE
;
visited
=
FALSE
;
setReference
(
lref
);
setReference
(
lref
);
incInfo
=
0
;
m_incInfo
=
0
;
tempArgs
=
0
;
m_tempArgs
=
0
;
prot
=
Public
;
m_prot
=
Public
;
nspace
=
0
;
m_nspace
=
0
;
fileDef
=
0
;
m_fileDef
=
0
;
usesImplClassDict
=
0
;
m_usesImplClassDict
=
0
;
usesIntfClassDict
=
0
;
m_usesIntfClassDict
=
0
;
memberGroupList
=
new
MemberGroupList
;
m_memberGroupList
=
new
MemberGroupList
;
memberGroupList
->
setAutoDelete
(
TRUE
);
m_memberGroupList
->
setAutoDelete
(
TRUE
);
memberGroupDict
=
new
MemberGroupDict
(
17
);
m_memberGroupDict
=
new
MemberGroupDict
(
17
);
m_innerClasses
=
new
ClassSDict
(
17
);
int
i
=
name
().
findRev
(
"::"
);
int
i
=
name
().
findRev
(
"::"
);
if
(
i
==-
1
)
if
(
i
==-
1
)
{
{
scopelessName
=
name
();
m_
scopelessName
=
name
();
}
}
else
else
{
{
scopelessName
=
name
().
right
(
name
().
length
()
-
i
-
2
);
m_
scopelessName
=
name
().
right
(
name
().
length
()
-
i
-
2
);
}
}
subGrouping
=
TRUE
;
m_subGrouping
=
TRUE
;
m_isTemplBaseClass
=-
1
;
m_templateMapping
=
new
StringDict
;
m_templateMapping
->
setAutoDelete
(
TRUE
);
}
}
// destroy the class definition
// destroy the class definition
ClassDef
::~
ClassDef
()
ClassDef
::~
ClassDef
()
{
{
delete
inherits
;
delete
m_
inherits
;
delete
inheritedBy
;
delete
m_
inheritedBy
;
delete
allMemberNameInfoLis
t
;
delete
m_allMemberNameInfoSDic
t
;
delete
allMemberNameInfo
Dict
;
delete
m_exampleS
Dict
;
delete
exampleLis
t
;
delete
m_usesImplClassDic
t
;
delete
example
Dict
;
delete
m_usesIntfClass
Dict
;
delete
usesImplClassDict
;
delete
m_incInfo
;
delete
usesIntfClassDic
t
;
delete
m_memberGroupLis
t
;
delete
incInfo
;
delete
m_memberGroupDict
;
delete
m
emberGroupList
;
delete
m
_innerClasses
;
delete
m
emberGroupDict
;
delete
m
_templateMapping
;
}
}
QCString
ClassDef
::
displayName
()
const
QCString
ClassDef
::
displayName
()
const
...
@@ -139,7 +136,7 @@ void ClassDef::insertBaseClass(ClassDef *cd,const char *n,Protection p,
...
@@ -139,7 +136,7 @@ void ClassDef::insertBaseClass(ClassDef *cd,const char *n,Protection p,
{
{
//printf("*** insert base class %s into %s\n",cd->name().data(),name().data());
//printf("*** insert base class %s into %s\n",cd->name().data(),name().data());
//inherits->inSort(new BaseClassDef(cd,p,s,t));
//inherits->inSort(new BaseClassDef(cd,p,s,t));
inherits
->
append
(
new
BaseClassDef
(
cd
,
n
,
p
,
s
,
t
));
m_
inherits
->
append
(
new
BaseClassDef
(
cd
,
n
,
p
,
s
,
t
));
}
}
// inserts a sub class in the inherited list
// inserts a sub class in the inherited list
...
@@ -147,34 +144,34 @@ void ClassDef::insertSubClass(ClassDef *cd,Protection p,
...
@@ -147,34 +144,34 @@ void ClassDef::insertSubClass(ClassDef *cd,Protection p,
Specifier
s
,
const
char
*
t
)
Specifier
s
,
const
char
*
t
)
{
{
//printf("*** insert sub class %s into %s\n",cd->name().data(),name().data());
//printf("*** insert sub class %s into %s\n",cd->name().data(),name().data());
inheritedBy
->
inSort
(
new
BaseClassDef
(
cd
,
0
,
p
,
s
,
t
));
m_
inheritedBy
->
inSort
(
new
BaseClassDef
(
cd
,
0
,
p
,
s
,
t
));
}
}
void
ClassDef
::
addMembersToMemberGroup
()
void
ClassDef
::
addMembersToMemberGroup
()
{
{
::
addMembersToMemberGroup
(
&
pubTypes
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
pubTypes
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
pubMembers
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
pubMembers
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
pubAttribs
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
pubAttribs
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
pubSlots
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
pubSlots
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
signals
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
signals
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
dcopMethods
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
dcopMethods
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
pubStaticMembers
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
pubStaticMembers
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
pubStaticAttribs
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
pubStaticAttribs
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
proTypes
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
proTypes
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
proMembers
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
proMembers
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
proAttribs
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
proAttribs
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
proSlots
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
proSlots
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
proStaticMembers
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
proStaticMembers
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
proStaticAttribs
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
proStaticAttribs
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
priTypes
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
priTypes
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
priMembers
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
priMembers
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
priAttribs
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
priAttribs
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
priSlots
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
priSlots
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
priStaticMembers
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
priStaticMembers
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
priStaticAttribs
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
priStaticAttribs
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
friends
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
friends
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
related
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
related
,
m
_memberGroupDict
,
m_
memberGroupList
);
::
addMembersToMemberGroup
(
&
properties
,
m
emberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
properties
,
m
_memberGroupDict
,
m_
memberGroupList
);
}
}
// adds new member definition to the class
// adds new member definition to the class
...
@@ -410,7 +407,7 @@ void ClassDef::insertMember(MemberDef *md)
...
@@ -410,7 +407,7 @@ void ClassDef::insertMember(MemberDef *md)
enumValMembers
.
append
(
md
);
enumValMembers
.
append
(
md
);
break
;
break
;
case
MemberDef
:
:
Function
:
case
MemberDef
:
:
Function
:
if
(
md
->
name
()
==
scopelessName
||
// constructor
if
(
md
->
name
()
==
m_
scopelessName
||
// constructor
(
md
->
name
().
find
(
'~'
)
!=-
1
&&
// hack to detect destructor
(
md
->
name
().
find
(
'~'
)
!=-
1
&&
// hack to detect destructor
md
->
name
().
find
(
"operator"
)
==-
1
md
->
name
().
find
(
"operator"
)
==-
1
)
)
...
@@ -452,7 +449,7 @@ void ClassDef::insertMember(MemberDef *md)
...
@@ -452,7 +449,7 @@ void ClassDef::insertMember(MemberDef *md)
MemberInfo
*
mi
=
new
MemberInfo
((
MemberDef
*
)
md
,
MemberInfo
*
mi
=
new
MemberInfo
((
MemberDef
*
)
md
,
md
->
protection
(),
md
->
virtualness
(),
FALSE
);
md
->
protection
(),
md
->
virtualness
(),
FALSE
);
MemberNameInfo
*
mni
=
0
;
MemberNameInfo
*
mni
=
0
;
if
((
mni
=
(
*
allMemberNameInfoDict
)[
md
->
name
()]
))
if
((
mni
=
m_allMemberNameInfoSDict
->
find
(
md
->
name
())
))
{
{
mni
->
append
(
mi
);
mni
->
append
(
mi
);
}
}
...
@@ -460,15 +457,14 @@ void ClassDef::insertMember(MemberDef *md)
...
@@ -460,15 +457,14 @@ void ClassDef::insertMember(MemberDef *md)
{
{
mni
=
new
MemberNameInfo
(
md
->
name
());
mni
=
new
MemberNameInfo
(
md
->
name
());
mni
->
append
(
mi
);
mni
->
append
(
mi
);
allMemberNameInfoList
->
inSort
(
mni
);
m_allMemberNameInfoSDict
->
inSort
(
mni
->
memberName
(),
mni
);
allMemberNameInfoDict
->
insert
(
mni
->
memberName
(),
mni
);
}
}
}
}
//void ClassDef::computeMemberGroups()
//void ClassDef::computeMemberGroups()
//{
//{
// MemberNameInfoListIterator mnili(*allMemberNameInfoList);
// MemberNameInfoListIterator mnili(*
m_
allMemberNameInfoList);
// MemberNameInfo *mni;
// MemberNameInfo *mni;
// for (;(mni=mnili.current());++mnili)
// for (;(mni=mnili.current());++mnili)
// {
// {
...
@@ -478,10 +474,10 @@ void ClassDef::insertMember(MemberDef *md)
...
@@ -478,10 +474,10 @@ void ClassDef::insertMember(MemberDef *md)
// {
// {
// MemberDef *md=mi->memberDef;
// MemberDef *md=mi->memberDef;
// MemberGroup *mg = md->getMemberGroup();
// MemberGroup *mg = md->getMemberGroup();
// if (mg && memberGroupDict->find(mg->groupId())==0)
// if (mg && m
_m
emberGroupDict->find(mg->groupId())==0)
// {
// {
// memberGroupDict->insert(mg->groupId(),mg);
// m
_m
emberGroupDict->insert(mg->groupId(),mg);
// memberGroupList->append(mg);
// m
_m
emberGroupList->append(mg);
// }
// }
// }
// }
// }
// }
...
@@ -517,7 +513,7 @@ void ClassDef::computeAnchors()
...
@@ -517,7 +513,7 @@ void ClassDef::computeAnchors()
void
ClassDef
::
distributeMemberGroupDocumentation
()
void
ClassDef
::
distributeMemberGroupDocumentation
()
{
{
MemberGroupListIterator
mgli
(
*
memberGroupList
);
MemberGroupListIterator
mgli
(
*
m
_m
emberGroupList
);
MemberGroup
*
mg
;
MemberGroup
*
mg
;
for
(;(
mg
=
mgli
.
current
());
++
mgli
)
for
(;(
mg
=
mgli
.
current
());
++
mgli
)
{
{
...
@@ -529,7 +525,7 @@ void ClassDef::distributeMemberGroupDocumentation()
...
@@ -529,7 +525,7 @@ void ClassDef::distributeMemberGroupDocumentation()
// add a file name to the used files set
// add a file name to the used files set
void
ClassDef
::
insertUsedFile
(
const
char
*
f
)
void
ClassDef
::
insertUsedFile
(
const
char
*
f
)
{
{
if
(
files
.
find
(
f
)
==-
1
)
files
.
append
(
f
);
if
(
m_files
.
find
(
f
)
==-
1
)
m_
files
.
append
(
f
);
}
}
static
void
writeInheritanceSpecifier
(
OutputList
&
ol
,
BaseClassDef
*
bcd
)
static
void
writeInheritanceSpecifier
(
OutputList
&
ol
,
BaseClassDef
*
bcd
)
...
@@ -557,15 +553,15 @@ static void writeInheritanceSpecifier(OutputList &ol,BaseClassDef *bcd)
...
@@ -557,15 +553,15 @@ static void writeInheritanceSpecifier(OutputList &ol,BaseClassDef *bcd)
void
ClassDef
::
setIncludeFile
(
FileDef
*
fd
,
const
char
*
includeName
,
bool
local
)
void
ClassDef
::
setIncludeFile
(
FileDef
*
fd
,
const
char
*
includeName
,
bool
local
)
{
{
//printf("ClassDef::setInclude(%p,%s,%d)\n",fd,includeName,local);
//printf("ClassDef::setInclude(%p,%s,%d)\n",fd,includeName,local);
if
(
!
incInfo
)
incInfo
=
new
IncludeInfo
;
if
(
!
m_incInfo
)
m_
incInfo
=
new
IncludeInfo
;
if
((
includeName
&&
incInfo
->
includeName
.
isEmpty
())
||
if
((
includeName
&&
m_
incInfo
->
includeName
.
isEmpty
())
||
(
fd
!=
0
&&
incInfo
->
fileDef
==
0
)
(
fd
!=
0
&&
m_
incInfo
->
fileDef
==
0
)
)
)
{
{
//printf("Setting file info\n");
//printf("Setting file info\n");
incInfo
->
fileDef
=
fd
;
m_
incInfo
->
fileDef
=
fd
;
incInfo
->
includeName
=
includeName
;
m_
incInfo
->
includeName
=
includeName
;
incInfo
->
local
=
local
;
m_
incInfo
->
local
=
local
;
}
}
}
}
...
@@ -574,7 +570,7 @@ ArgumentList *ClassDef::outerTemplateArguments() const
...
@@ -574,7 +570,7 @@ ArgumentList *ClassDef::outerTemplateArguments() const
int
ti
;
int
ti
;
ClassDef
*
pcd
=
0
;
ClassDef
*
pcd
=
0
;
int
pi
=
0
;
int
pi
=
0
;
if
(
tempArgs
)
return
tempArgs
;
if
(
m_tempArgs
)
return
m_
tempArgs
;
// find the outer most class scope
// find the outer most class scope
while
((
ti
=
name
().
find
(
"::"
,
pi
))
!=-
1
&&
while
((
ti
=
name
().
find
(
"::"
,
pi
))
!=-
1
&&
(
pcd
=
getClass
(
name
().
left
(
ti
)))
==
0
(
pcd
=
getClass
(
name
().
left
(
ti
)))
==
0
...
@@ -632,7 +628,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
...
@@ -632,7 +628,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
if
(
outerTempArgList
)
pageTitle
.
prepend
(
" Template"
);
if
(
outerTempArgList
)
pageTitle
.
prepend
(
" Template"
);
startFile
(
ol
,
getOutputFileBase
(),
pageTitle
);
startFile
(
ol
,
getOutputFileBase
(),
pageTitle
);
startTitle
(
ol
,
getOutputFileBase
());
startTitle
(
ol
,
getOutputFileBase
());
parseText
(
ol
,
theTranslator
->
trCompoundReference
(
name
(),
compType
,
outerTempArgList
!=
0
));
parseText
(
ol
,
theTranslator
->
trCompoundReference
(
name
(),
m_
compType
,
outerTempArgList
!=
0
));
endTitle
(
ol
,
getOutputFileBase
(),
name
());
endTitle
(
ol
,
getOutputFileBase
(),
name
());
ol
.
startTextBlock
();
ol
.
startTextBlock
();
...
@@ -643,7 +639,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
...
@@ -643,7 +639,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
OutputList
briefOutput
(
&
ol
);
OutputList
briefOutput
(
&
ol
);
if
(
!
briefDescription
().
isEmpty
())
if
(
!
briefDescription
().
isEmpty
())
{
{
parseDoc
(
briefOutput
,
defFileName
,
defLine
,
name
(),
0
,
briefDescription
());
parseDoc
(
briefOutput
,
m_defFileName
,
m_
defLine
,
name
(),
0
,
briefDescription
());
ol
+=
briefOutput
;
ol
+=
briefOutput
;
ol
.
writeString
(
"
\n
"
);
ol
.
writeString
(
"
\n
"
);
ol
.
pushGeneratorState
();
ol
.
pushGeneratorState
();
...
@@ -658,18 +654,18 @@ void ClassDef::writeDocumentation(OutputList &ol)
...
@@ -658,18 +654,18 @@ void ClassDef::writeDocumentation(OutputList &ol)
}
}
ol
.
writeSynopsis
();
ol
.
writeSynopsis
();
if
(
incInfo
)
if
(
m_
incInfo
)
{
{
QCString
nm
=
incInfo
->
includeName
.
isEmpty
()
?
QCString
nm
=
m_
incInfo
->
includeName
.
isEmpty
()
?
(
incInfo
->
fileDef
?
(
m_
incInfo
->
fileDef
?
incInfo
->
fileDef
->
docName
().
data
()
:
""
m_
incInfo
->
fileDef
->
docName
().
data
()
:
""
)
:
)
:
incInfo
->
includeName
.
data
();
m_
incInfo
->
includeName
.
data
();
if
(
!
nm
.
isEmpty
())
if
(
!
nm
.
isEmpty
())
{
{
ol
.
startTypewriter
();
ol
.
startTypewriter
();
ol
.
docify
(
"#include "
);
ol
.
docify
(
"#include "
);
if
(
incInfo
->
local
)
if
(
m_
incInfo
->
local
)
ol
.
docify
(
"
\"
"
);
ol
.
docify
(
"
\"
"
);
else
else
ol
.
docify
(
"<"
);
ol
.
docify
(
"<"
);
...
@@ -678,16 +674,16 @@ void ClassDef::writeDocumentation(OutputList &ol)
...
@@ -678,16 +674,16 @@ void ClassDef::writeDocumentation(OutputList &ol)
ol
.
docify
(
nm
);
ol
.
docify
(
nm
);
ol
.
disableAllBut
(
OutputGenerator
::
Html
);
ol
.
disableAllBut
(
OutputGenerator
::
Html
);
ol
.
enable
(
OutputGenerator
::
Html
);
ol
.
enable
(
OutputGenerator
::
Html
);
if
(
incInfo
->
fileDef
)
if
(
m_
incInfo
->
fileDef
)
{
{
ol
.
writeObjectLink
(
0
,
incInfo
->
fileDef
->
includeName
(),
0
,
nm
);
ol
.
writeObjectLink
(
0
,
m_
incInfo
->
fileDef
->
includeName
(),
0
,
nm
);
}
}
else
else
{
{
ol
.
docify
(
nm
);
ol
.
docify
(
nm
);
}
}
ol
.
popGeneratorState
();
ol
.
popGeneratorState
();
if
(
incInfo
->
local
)
if
(
m_
incInfo
->
local
)
ol
.
docify
(
"
\"
"
);
ol
.
docify
(
"
\"
"
);
else
else
ol
.
docify
(
">"
);
ol
.
docify
(
">"
);
...
@@ -711,11 +707,11 @@ void ClassDef::writeDocumentation(OutputList &ol)
...
@@ -711,11 +707,11 @@ void ClassDef::writeDocumentation(OutputList &ol)
// write subclasses
// write subclasses
int
count
;
int
count
;
if
((
count
=
inherits
->
count
())
>
0
)
if
((
count
=
m_
inherits
->
count
())
>
0
)
{
{
//parseText(ol,theTranslator->trInherits()+" ");
//parseText(ol,theTranslator->trInherits()+" ");
QCString
inheritLine
=
theTranslator
->
trInheritsList
(
inherits
->
count
());
QCString
inheritLine
=
theTranslator
->
trInheritsList
(
m_
inherits
->
count
());
QRegExp
marker
(
"@[0-9]+"
);
QRegExp
marker
(
"@[0-9]+"
);
int
index
=
0
,
newIndex
,
matchLen
;
int
index
=
0
,
newIndex
,
matchLen
;
// now replace all markers in inheritLine with links to the classes
// now replace all markers in inheritLine with links to the classes
...
@@ -724,7 +720,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
...
@@ -724,7 +720,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
parseText
(
ol
,
inheritLine
.
mid
(
index
,
newIndex
-
index
));
parseText
(
ol
,
inheritLine
.
mid
(
index
,
newIndex
-
index
));
bool
ok
;
bool
ok
;
uint
entryIndex
=
inheritLine
.
mid
(
newIndex
+
1
,
matchLen
-
1
).
toUInt
(
&
ok
);
uint
entryIndex
=
inheritLine
.
mid
(
newIndex
+
1
,
matchLen
-
1
).
toUInt
(
&
ok
);
BaseClassDef
*
bcd
=
inherits
->
at
(
entryIndex
);
BaseClassDef
*
bcd
=
m_
inherits
->
at
(
entryIndex
);
if
(
ok
&&
bcd
)
if
(
ok
&&
bcd
)
{
{
ClassDef
*
cd
=
bcd
->
classDef
;
ClassDef
*
cd
=
bcd
->
classDef
;
...
@@ -765,9 +761,9 @@ void ClassDef::writeDocumentation(OutputList &ol)
...
@@ -765,9 +761,9 @@ void ClassDef::writeDocumentation(OutputList &ol)
}
}
// write subclasses
// write subclasses
if
((
count
=
inheritedBy
->
count
())
>
0
)
if
((
count
=
m_
inheritedBy
->
count
())
>
0
)
{
{
QCString
inheritLine
=
theTranslator
->
trInheritedByList
(
inheritedBy
->
count
());
QCString
inheritLine
=
theTranslator
->
trInheritedByList
(
m_
inheritedBy
->
count
());
QRegExp
marker
(
"@[0-9]+"
);
QRegExp
marker
(
"@[0-9]+"
);
int
index
=
0
,
newIndex
,
matchLen
;
int
index
=
0
,
newIndex
,
matchLen
;
// now replace all markers in inheritLine with links to the classes
// now replace all markers in inheritLine with links to the classes
...
@@ -776,7 +772,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
...
@@ -776,7 +772,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
parseText
(
ol
,
inheritLine
.
mid
(
index
,
newIndex
-
index
));
parseText
(
ol
,
inheritLine
.
mid
(
index
,
newIndex
-
index
));
bool
ok
;
bool
ok
;
uint
entryIndex
=
inheritLine
.
mid
(
newIndex
+
1
,
matchLen
-
1
).
toUInt
(
&
ok
);
uint
entryIndex
=
inheritLine
.
mid
(
newIndex
+
1
,
matchLen
-
1
).
toUInt
(
&
ok
);
BaseClassDef
*
bcd
=
inheritedBy
->
at
(
entryIndex
);
BaseClassDef
*
bcd
=
m_
inheritedBy
->
at
(
entryIndex
);
if
(
ok
&&
bcd
)
if
(
ok
&&
bcd
)
{
{
ClassDef
*
cd
=
bcd
->
classDef
;
ClassDef
*
cd
=
bcd
->
classDef
;
...
@@ -801,19 +797,19 @@ void ClassDef::writeDocumentation(OutputList &ol)
...
@@ -801,19 +797,19 @@ void ClassDef::writeDocumentation(OutputList &ol)
count
=
0
;
count
=
0
;
BaseClassDef
*
ibcd
;
BaseClassDef
*
ibcd
;
ibcd
=
inheritedBy
->
first
();
ibcd
=
m_
inheritedBy
->
first
();
while
(
ibcd
)
while
(
ibcd
)
{
{
ClassDef
*
icd
=
ibcd
->
classDef
;
ClassDef
*
icd
=
ibcd
->
classDef
;
if
(
icd
->
isVisibleInHierarchy
())
count
++
;
if
(
icd
->
isVisibleInHierarchy
())
count
++
;
ibcd
=
inheritedBy
->
next
();
ibcd
=
m_
inheritedBy
->
next
();
}
}
ibcd
=
inherits
->
first
();
ibcd
=
m_
inherits
->
first
();
while
(
ibcd
)
while
(
ibcd
)
{
{
ClassDef
*
icd
=
ibcd
->
classDef
;
ClassDef
*
icd
=
ibcd
->
classDef
;
if
(
icd
->
isVisibleInHierarchy
())
count
++
;
if
(
icd
->
isVisibleInHierarchy
())
count
++
;
ibcd
=
inherits
->
next
();
ibcd
=
m_
inherits
->
next
();
}
}
...
@@ -879,10 +875,11 @@ void ClassDef::writeDocumentation(OutputList &ol)
...
@@ -879,10 +875,11 @@ void ClassDef::writeDocumentation(OutputList &ol)
}
}
// write link to list of all members (HTML only)
// write link to list of all members (HTML only)
if
(
allMemberNameInfoList
->
count
()
>
0
&&
!
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
if
(
m_allMemberNameInfoSDict
->
count
()
>
0
&&
!
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
{
ol
.
disableAllBut
(
OutputGenerator
::
Html
);
ol
.
disableAllBut
(
OutputGenerator
::
Html
);
ol
.
startTextLink
(
memListFileName
,
0
);
ol
.
startTextLink
(
m
_m
emListFileName
,
0
);
parseText
(
ol
,
theTranslator
->
trListOfAllMembers
());
parseText
(
ol
,
theTranslator
->
trListOfAllMembers
());
ol
.
endTextLink
();
ol
.
endTextLink
();
ol
.
enableAll
();
ol
.
enableAll
();
...
@@ -894,11 +891,11 @@ void ClassDef::writeDocumentation(OutputList &ol)
...
@@ -894,11 +891,11 @@ void ClassDef::writeDocumentation(OutputList &ol)
ol
.
startMemberSections
();
ol
.
startMemberSections
();
// write user defined member groups
// write user defined member groups
MemberGroupListIterator
mgli
(
*
memberGroupList
);
MemberGroupListIterator
mgli
(
*
m
_m
emberGroupList
);
MemberGroup
*
mg
;
MemberGroup
*
mg
;
for
(;(
mg
=
mgli
.
current
());
++
mgli
)
for
(;(
mg
=
mgli
.
current
());
++
mgli
)
{
{
if
(
!
mg
->
allMembersInSameSection
()
||
!
subGrouping
)
// group is in its own section
if
(
!
mg
->
allMembersInSameSection
()
||
!
m_
subGrouping
)
// group is in its own section
{
{
mg
->
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
);
mg
->
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
);
}
}
...
@@ -908,40 +905,52 @@ void ClassDef::writeDocumentation(OutputList &ol)
...
@@ -908,40 +905,52 @@ void ClassDef::writeDocumentation(OutputList &ol)
}
}
}
}
//
non static public member
s
//
public type
s
pubTypes
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trPublicTypes
(),
0
);
pubTypes
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trPublicTypes
(),
0
);
pubMembers
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trPublicMembers
(),
0
);
pubAttribs
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trPublicAttribs
(),
0
);
// public methods
pubSlots
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trPublicSlots
(),
0
);
pubSlots
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trPublicSlots
(),
0
);
signals
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trSignals
(),
0
);
signals
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trSignals
(),
0
);
dcopMethods
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trDCOPMethods
(),
0
);
dcopMethods
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trDCOPMethods
(),
0
);
properties
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trProperties
(),
0
);
properties
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trProperties
(),
0
);
pubMembers
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trPublicMembers
(),
0
);
// static public members
pubStaticMembers
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trStaticPublicMembers
(),
0
);
pubStaticMembers
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trStaticPublicMembers
(),
0
);
// public attribs
pubAttribs
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trPublicAttribs
(),
0
);
pubStaticAttribs
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trStaticPublicAttribs
(),
0
);
pubStaticAttribs
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trStaticPublicAttribs
(),
0
);
// protected
non-static member
s
// protected
type
s
proTypes
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trProtectedTypes
(),
0
);
proTypes
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trProtectedTypes
(),
0
);
proMembers
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trProtectedMembers
(),
0
);
proAttribs
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trProtectedAttribs
(),
0
);
// protected methods
proSlots
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trProtectedSlots
(),
0
);
proSlots
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trProtectedSlots
(),
0
);
// protected static members
proMembers
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trProtectedMembers
(),
0
);
proStaticMembers
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trStaticProtectedMembers
(),
0
);
proStaticMembers
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trStaticProtectedMembers
(),
0
);
// protected attribs
proAttribs
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trProtectedAttribs
(),
0
);
proStaticAttribs
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trStaticProtectedAttribs
(),
0
);
proStaticAttribs
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trStaticProtectedAttribs
(),
0
);
if
(
Config_getBool
(
"EXTRACT_PRIVATE"
))
if
(
Config_getBool
(
"EXTRACT_PRIVATE"
))
{
{
// private
non-static member
s
// private
type
s
priTypes
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trPrivateTypes
(),
0
);
priTypes
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trPrivateTypes
(),
0
);
priMembers
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trPrivateMembers
(),
0
);
priAttribs
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trPrivateAttribs
(),
0
);
// private members
priSlots
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trPrivateSlots
(),
0
);
priSlots
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trPrivateSlots
(),
0
);
// private static members
priMembers
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trPrivateMembers
(),
0
);
priStaticMembers
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trStaticPrivateMembers
(),
0
);
priStaticMembers
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trStaticPrivateMembers
(),
0
);
// private attribs
priAttribs
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trPrivateAttribs
(),
0
);
priStaticAttribs
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trStaticPrivateAttribs
(),
0
);
priStaticAttribs
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trStaticPrivateAttribs
(),
0
);
}
}
// friends
friends
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trFriends
(),
0
);
friends
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trFriends
(),
0
);
// related functions
related
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
related
.
writeDeclarations
(
ol
,
this
,
0
,
0
,
0
,
theTranslator
->
trRelatedFunctions
(),
theTranslator
->
trRelatedFunctions
(),
theTranslator
->
trRelatedSubscript
()
theTranslator
->
trRelatedSubscript
()
...
@@ -985,7 +994,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
...
@@ -985,7 +994,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
ol
.
disableAllBut
(
OutputGenerator
::
RTF
);
ol
.
disableAllBut
(
OutputGenerator
::
RTF
);
ol
.
newParagraph
();
ol
.
newParagraph
();
ol
.
popGeneratorState
();
ol
.
popGeneratorState
();
parseDoc
(
ol
,
defFileName
,
defLine
,
name
(),
0
,
documentation
()
+
"
\n
"
);
parseDoc
(
ol
,
m_defFileName
,
m_
defLine
,
name
(),
0
,
documentation
()
+
"
\n
"
);
}
}
// write examples
// write examples
if
(
exampleFlag
)
if
(
exampleFlag
)
...
@@ -997,7 +1006,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
...
@@ -997,7 +1006,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
ol
.
endDescTitle
();
ol
.
endDescTitle
();
ol
.
writeDescItem
();
ol
.
writeDescItem
();
ol
.
newParagraph
();
ol
.
newParagraph
();
writeExample
(
ol
,
exampleLis
t
);
writeExample
(
ol
,
m_exampleSDic
t
);
//ol.endDescItem();
//ol.endDescItem();
ol
.
endDescList
();
ol
.
endDescList
();
}
}
...
@@ -1040,10 +1049,10 @@ void ClassDef::writeDocumentation(OutputList &ol)
...
@@ -1040,10 +1049,10 @@ void ClassDef::writeDocumentation(OutputList &ol)
{
{
ol
.
disable
(
OutputGenerator
::
Man
);
ol
.
disable
(
OutputGenerator
::
Man
);
ol
.
writeRuler
();
ol
.
writeRuler
();
parseText
(
ol
,
theTranslator
->
trGeneratedFromFiles
(
compType
,
files
.
count
()
==
1
));
parseText
(
ol
,
theTranslator
->
trGeneratedFromFiles
(
m_compType
,
m_
files
.
count
()
==
1
));
bool
first
=
TRUE
;
bool
first
=
TRUE
;
const
char
*
file
=
files
.
first
();
const
char
*
file
=
m_
files
.
first
();
while
(
file
)
while
(
file
)
{
{
bool
ambig
;
bool
ambig
;
...
@@ -1077,7 +1086,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
...
@@ -1077,7 +1086,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
ol
.
docify
(
fd
->
name
());
ol
.
docify
(
fd
->
name
());
}
}
}
}
file
=
files
.
next
();
file
=
m_
files
.
next
();
}
}
if
(
!
first
)
ol
.
endItemList
();
if
(
!
first
)
ol
.
endItemList
();
}
}
...
@@ -1106,12 +1115,13 @@ void ClassDef::writeDocumentation(OutputList &ol)
...
@@ -1106,12 +1115,13 @@ void ClassDef::writeDocumentation(OutputList &ol)
// write the list of all (inherited) members for this class
// write the list of all (inherited) members for this class
void
ClassDef
::
writeMemberList
(
OutputList
&
ol
)
void
ClassDef
::
writeMemberList
(
OutputList
&
ol
)
{
{
if
(
allMemberNameInfoList
->
count
()
==
0
||
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
return
;
if
(
m_allMemberNameInfoSDict
->
count
()
==
0
||
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
return
;
// only for HTML
// only for HTML
ol
.
pushGeneratorState
();
ol
.
pushGeneratorState
();
ol
.
disableAllBut
(
OutputGenerator
::
Html
);
ol
.
disableAllBut
(
OutputGenerator
::
Html
);
startFile
(
ol
,
memListFileName
,
theTranslator
->
trMemberList
());
startFile
(
ol
,
m
_m
emListFileName
,
theTranslator
->
trMemberList
());
startTitle
(
ol
,
0
);
startTitle
(
ol
,
0
);
parseText
(
ol
,
name
()
+
" "
+
theTranslator
->
trMemberList
());
parseText
(
ol
,
name
()
+
" "
+
theTranslator
->
trMemberList
());
endTitle
(
ol
,
0
,
0
);
endTitle
(
ol
,
0
,
0
);
...
@@ -1121,8 +1131,10 @@ void ClassDef::writeMemberList(OutputList &ol)
...
@@ -1121,8 +1131,10 @@ void ClassDef::writeMemberList(OutputList &ol)
ol
.
startItemList
();
ol
.
startItemList
();
MemberNameInfo
*
mni
=
allMemberNameInfoList
->
first
();
//MemberNameInfo *mni=m_allMemberNameInfoList->first();
while
(
mni
)
MemberNameInfoSDict
::
Iterator
mnii
(
*
m_allMemberNameInfoSDict
);
MemberNameInfo
*
mni
;
for
(
mnii
.
toFirst
();(
mni
=
mnii
.
current
());
++
mnii
)
{
{
MemberInfo
*
mi
=
mni
->
first
();
MemberInfo
*
mi
=
mni
->
first
();
while
(
mi
)
while
(
mi
)
...
@@ -1253,7 +1265,6 @@ void ClassDef::writeMemberList(OutputList &ol)
...
@@ -1253,7 +1265,6 @@ void ClassDef::writeMemberList(OutputList &ol)
}
}
mi
=
mni
->
next
();
mi
=
mni
->
next
();
}
}
mni
=
allMemberNameInfoList
->
next
();
}
}
ol
.
endItemList
();
ol
.
endItemList
();
endFile
(
ol
);
endFile
(
ol
);
...
@@ -1265,14 +1276,13 @@ void ClassDef::writeMemberList(OutputList &ol)
...
@@ -1265,14 +1276,13 @@ void ClassDef::writeMemberList(OutputList &ol)
bool
ClassDef
::
addExample
(
const
char
*
anchor
,
const
char
*
nameStr
,
bool
ClassDef
::
addExample
(
const
char
*
anchor
,
const
char
*
nameStr
,
const
char
*
file
)
const
char
*
file
)
{
{
if
(
exampleDict
&&
!
example
Dict
->
find
(
nameStr
))
if
(
m_exampleSDict
&&
!
m_exampleS
Dict
->
find
(
nameStr
))
{
{
Example
*
e
=
new
Example
;
Example
*
e
=
new
Example
;
e
->
anchor
=
anchor
;
e
->
anchor
=
anchor
;
e
->
name
=
nameStr
;
e
->
name
=
nameStr
;
e
->
file
=
file
;
e
->
file
=
file
;
exampleDict
->
insert
(
nameStr
,
e
);
m_exampleSDict
->
inSort
(
nameStr
,
e
);
exampleList
->
inSort
(
e
);
return
TRUE
;
return
TRUE
;
}
}
return
FALSE
;
return
FALSE
;
...
@@ -1281,24 +1291,24 @@ bool ClassDef::addExample(const char *anchor,const char *nameStr,
...
@@ -1281,24 +1291,24 @@ bool ClassDef::addExample(const char *anchor,const char *nameStr,
// returns TRUE if this class is used in an example
// returns TRUE if this class is used in an example
bool
ClassDef
::
hasExamples
()
bool
ClassDef
::
hasExamples
()
{
{
if
(
exampleLis
t
==
0
)
if
(
m_exampleSDic
t
==
0
)
return
FALSE
;
return
FALSE
;
else
else
return
exampleLis
t
->
count
()
>
0
;
return
m_exampleSDic
t
->
count
()
>
0
;
}
}
void
ClassDef
::
setTemplateArguments
(
ArgumentList
*
al
)
void
ClassDef
::
setTemplateArguments
(
ArgumentList
*
al
)
{
{
if
(
al
==
0
)
return
;
if
(
al
==
0
)
return
;
if
(
!
tempArgs
)
delete
tempArgs
;
// delete old list if needed
if
(
!
m_tempArgs
)
delete
m_
tempArgs
;
// delete old list if needed
tempArgs
=
new
ArgumentList
;
m_
tempArgs
=
new
ArgumentList
;
tempArgs
->
setAutoDelete
(
TRUE
);
m_
tempArgs
->
setAutoDelete
(
TRUE
);
ArgumentListIterator
ali
(
*
al
);
ArgumentListIterator
ali
(
*
al
);
Argument
*
a
;
Argument
*
a
;
for
(;(
a
=
ali
.
current
());
++
ali
)
for
(;(
a
=
ali
.
current
());
++
ali
)
{
{
tempArgs
->
append
(
new
Argument
(
*
a
));
m_
tempArgs
->
append
(
new
Argument
(
*
a
));
}
}
}
}
...
@@ -1306,7 +1316,7 @@ void ClassDef::setTemplateArguments(ArgumentList *al)
...
@@ -1306,7 +1316,7 @@ void ClassDef::setTemplateArguments(ArgumentList *al)
bool
ClassDef
::
hasNonReferenceSuperClass
()
bool
ClassDef
::
hasNonReferenceSuperClass
()
{
{
bool
found
=!
isReference
();
bool
found
=!
isReference
();
BaseClassListIterator
bcli
(
*
inheritedBy
);
BaseClassListIterator
bcli
(
*
m_
inheritedBy
);
for
(
;
bcli
.
current
()
&&
!
found
;
++
bcli
)
for
(
;
bcli
.
current
()
&&
!
found
;
++
bcli
)
found
=
found
||
bcli
.
current
()
->
classDef
->
hasNonReferenceSuperClass
();
found
=
found
||
bcli
.
current
()
->
classDef
->
hasNonReferenceSuperClass
();
return
found
;
return
found
;
...
@@ -1329,13 +1339,22 @@ void ClassDef::writeDeclaration(OutputList &ol,MemberDef *md,bool inGroup)
...
@@ -1329,13 +1339,22 @@ void ClassDef::writeDeclaration(OutputList &ol,MemberDef *md,bool inGroup)
if
(
!
cn
.
isEmpty
()
&&
cn
.
at
(
0
)
!=
'@'
&&
md
)
if
(
!
cn
.
isEmpty
()
&&
cn
.
at
(
0
)
!=
'@'
&&
md
)
{
{
ol
.
docify
(
" "
);
ol
.
docify
(
" "
);
if
(
isLinkable
())
{
ol
.
writeObjectLink
(
0
,
0
,
md
->
anchor
(),
cn
);
ol
.
writeObjectLink
(
0
,
0
,
md
->
anchor
(),
cn
);
}
}
else
{
ol
.
startBold
();
ol
.
docify
(
cn
);
ol
.
endBold
();
}
}
ol
.
docify
(
" {"
);
ol
.
docify
(
" {"
);
ol
.
endMemberItem
(
FALSE
);
ol
.
endMemberItem
(
FALSE
);
// write user defined member groups
// write user defined member groups
MemberGroupListIterator
mgli
(
*
memberGroupList
);
MemberGroupListIterator
mgli
(
*
m
_m
emberGroupList
);
MemberGroup
*
mg
;
MemberGroup
*
mg
;
for
(;(
mg
=
mgli
.
current
());
++
mgli
)
for
(;(
mg
=
mgli
.
current
());
++
mgli
)
{
{
...
@@ -1397,9 +1416,12 @@ void ClassDef::writeDeclaration(OutputList &ol,MemberDef *md,bool inGroup)
...
@@ -1397,9 +1416,12 @@ void ClassDef::writeDeclaration(OutputList &ol,MemberDef *md,bool inGroup)
/*! a link to this class is possible within this project */
/*! a link to this class is possible within this project */
bool
ClassDef
::
isLinkableInProject
()
bool
ClassDef
::
isLinkableInProject
()
{
{
return
!
name
().
isEmpty
()
&&
name
().
find
(
'@'
)
==-
1
&&
return
!
name
().
isEmpty
()
&&
/* no name */
(
prot
!=
Private
||
Config_getBool
(
"EXTRACT_PRIVATE"
))
&&
m_isTemplBaseClass
==-
1
&&
/* template base class */
hasDocumentation
()
&&
!
isReference
();
name
().
find
(
'@'
)
==-
1
&&
/* anonymous compound */
(
m_prot
!=
Private
||
Config_getBool
(
"EXTRACT_PRIVATE"
))
&&
/* private */
hasDocumentation
()
&&
/* documented */
!
isReference
();
/* not an external reference */
}
}
/*! the class is visible in a class diagram, or class hierarchy */
/*! the class is visible in a class diagram, or class hierarchy */
...
@@ -1408,8 +1430,10 @@ bool ClassDef::isVisibleInHierarchy()
...
@@ -1408,8 +1430,10 @@ bool ClassDef::isVisibleInHierarchy()
(
Config_getBool
(
"ALLEXTERNALS"
)
||
hasNonReferenceSuperClass
())
&&
(
Config_getBool
(
"ALLEXTERNALS"
)
||
hasNonReferenceSuperClass
())
&&
// and not an annonymous compound
// and not an annonymous compound
name
().
find
(
'@'
)
==-
1
&&
name
().
find
(
'@'
)
==-
1
&&
// and not an inherited template argument
m_isTemplBaseClass
==-
1
&&
// and not privately inherited
// and not privately inherited
(
prot
!=
Private
||
Config_getBool
(
"EXTRACT_PRIVATE"
))
&&
(
m_
prot
!=
Private
||
Config_getBool
(
"EXTRACT_PRIVATE"
))
&&
// documented or show anyway or documentation is external
// documented or show anyway or documentation is external
(
hasDocumentation
()
||
!
Config_getBool
(
"HIDE_UNDOC_CLASSES"
)
||
isReference
());
(
hasDocumentation
()
||
!
Config_getBool
(
"HIDE_UNDOC_CLASSES"
)
||
isReference
());
}
}
...
@@ -1459,11 +1483,11 @@ void ClassDef::mergeMembers()
...
@@ -1459,11 +1483,11 @@ void ClassDef::mergeMembers()
// merge the members in the base class of this inheritance branch first
// merge the members in the base class of this inheritance branch first
bClass
->
mergeMembers
();
bClass
->
mergeMembers
();
MemberNameInfo
List
*
srcMnl
=
bClass
->
memberNameInfoLis
t
();
MemberNameInfo
SDict
*
srcMnd
=
bClass
->
memberNameInfoSDic
t
();
MemberNameInfo
Dict
*
dstMnd
=
memberNameInfo
Dict
();
MemberNameInfo
SDict
*
dstMnd
=
memberNameInfoS
Dict
();
MemberNameInfoList
*
dstMnl
=
memberNameInfoList
();
//
MemberNameInfoList *dstMnl = memberNameInfoList();
MemberNameInfo
ListIterator
srcMnili
(
*
srcMnl
);
MemberNameInfo
SDict
::
Iterator
srcMnili
(
*
srcMnd
);
MemberNameInfo
*
srcMni
;
MemberNameInfo
*
srcMni
;
for
(
;
(
srcMni
=
srcMnili
.
current
())
;
++
srcMnili
)
for
(
;
(
srcMni
=
srcMnili
.
current
())
;
++
srcMnili
)
{
{
...
@@ -1624,15 +1648,16 @@ void ClassDef::mergeMembers()
...
@@ -1624,15 +1648,16 @@ void ClassDef::mergeMembers()
}
}
}
}
// add it to the
list and
dictionary
// add it to the dictionary
dstMnl
->
append
(
newMni
);
//
dstMnl->append(newMni);
dstMnd
->
insert
(
newMni
->
memberName
(),
newMni
);
dstMnd
->
append
(
newMni
->
memberName
(),
newMni
);
}
}
}
}
}
}
}
}
//----------------------------------------------------------------------------
//----------------------------------------------------------------------------
/*! Builds up a dictionary of all classes that are used by the state of this
/*! Builds up a dictionary of all classes that are used by the state of this
* class (the "implementation").
* class (the "implementation").
* Must be called before mergeMembers() is called!
* Must be called before mergeMembers() is called!
...
@@ -1640,7 +1665,7 @@ void ClassDef::mergeMembers()
...
@@ -1640,7 +1665,7 @@ void ClassDef::mergeMembers()
void
ClassDef
::
determineImplUsageRelation
()
void
ClassDef
::
determineImplUsageRelation
()
{
{
MemberNameInfo
ListIterator
mnili
(
*
allMemberNameInfoLis
t
);
MemberNameInfo
SDict
::
Iterator
mnili
(
*
m_allMemberNameInfoSDic
t
);
MemberNameInfo
*
mni
;
MemberNameInfo
*
mni
;
for
(;(
mni
=
mnili
.
current
());
++
mnili
)
for
(;(
mni
=
mnili
.
current
());
++
mnili
)
{
{
...
@@ -1652,42 +1677,47 @@ void ClassDef::determineImplUsageRelation()
...
@@ -1652,42 +1677,47 @@ void ClassDef::determineImplUsageRelation()
if
(
md
->
isVariable
())
// for each member variable in this class
if
(
md
->
isVariable
())
// for each member variable in this class
{
{
QCString
type
=
removeRedundantWhiteSpace
(
md
->
typeString
());
QCString
type
=
removeRedundantWhiteSpace
(
md
->
typeString
());
int
typeLen
=
type
.
length
();
static
const
QRegExp
re
(
"[a-z_A-Z][a-z_A-Z0-9:]*"
);
//printf("in class %s found var type=`%s' name=`%s'\n",
//printf("in class %s found var type=`%s' name=`%s'\n",
// name().data(),type.data(),md->name().data());
// name().data(),type.data(),md->name().data());
int
p
=
0
,
i
,
l
;
int
pos
=
0
;
QCString
usedClassName
;
QCString
templSpec
;
bool
found
=
FALSE
;
bool
found
=
FALSE
;
if
(
typeLen
>
0
)
while
(
extractClassNameFromType
(
type
,
pos
,
usedClassName
,
templSpec
)
&&
!
found
)
{
while
((
i
=
re
.
match
(
type
,
p
,
&
l
))
!=-
1
&&
!
found
)
// for each class name in the type
{
int
ts
=
i
+
l
;
int
te
=
ts
;
while
(
type
.
at
(
ts
)
==
' '
&&
ts
<
typeLen
)
ts
++
;
// skip any whitespace
if
(
type
.
at
(
ts
)
==
'<'
)
// assume template instance
{
{
// locate end of template
//printf("usedClassName=`%s' templSpec=%s\n",usedClassName.data(),templSpec.data());
te
=
ts
+
1
;
// check if usedClassName is a template argument of its class
int
brCount
=
1
;
ClassDef
*
cd
=
md
->
getClassDef
()
;
while
(
te
<
typeLen
&&
brCount
!=
0
)
if
(
cd
&&
cd
->
templateArguments
()
)
{
{
if
(
type
.
at
(
te
)
==
'<'
)
ArgumentListIterator
ali
(
*
cd
->
templateArguments
());
Argument
*
arg
;
int
count
=
0
;
for
(
ali
.
toFirst
();(
arg
=
ali
.
current
());
++
ali
,
++
count
)
{
{
if
(
te
<
typeLen
-
1
&&
type
.
at
(
te
+
1
)
==
'<'
)
te
++
;
else
brCount
++
;
if
(
arg
->
name
==
usedClassName
)
// type is a template argument
}
if
(
type
.
at
(
te
)
==
'>'
)
{
{
if
(
te
<
typeLen
-
1
&&
type
.
at
(
te
+
1
)
==
'>'
)
te
++
;
else
brCount
--
;
found
=
TRUE
;
if
(
m_usesImplClassDict
==
0
)
m_usesImplClassDict
=
new
UsesClassDict
(
257
);
cd
=
new
ClassDef
(
cd
->
getDefFileName
(),
cd
->
getDefLine
(),
usedClassName
,
ClassDef
::
Class
);
cd
->
setIsTemplateBaseClass
(
count
);
UsesClassDef
*
ucd
=
new
UsesClassDef
(
cd
);
m_usesImplClassDict
->
insert
(
cd
->
name
(),
ucd
);
ucd
->
templSpecifiers
=
templSpec
;
ucd
->
addAccessor
(
md
->
name
());
Doxygen
::
hiddenClasses
.
append
(
cd
);
//printf("Adding used template argument %s to class %s\n",
// cd->name().data(),name().data());
//printf("Adding accessor %s to class %s\n",
// md->name().data(),ucd->classDef->name().data());
}
}
te
++
;
}
}
}
}
QCString
templSpec
;
if
(
te
>
ts
)
templSpec
=
type
.
mid
(
ts
,
te
-
ts
);
if
(
!
found
)
// TODO: also check using Nx::Cx cases here!
{
QCString
usedClassName
=
type
.
mid
(
i
,
l
);
cd
=
0
;
ClassDef
*
cd
=
0
;
if
(
getNamespaceDef
()
!=
0
)
if
(
getNamespaceDef
()
!=
0
)
{
{
cd
=
getResolvedClass
(
getNamespaceDef
()
->
name
()
+
"::"
+
usedClassName
,
0
,
&
templSpec
);
cd
=
getResolvedClass
(
getNamespaceDef
()
->
name
()
+
"::"
+
usedClassName
,
0
,
&
templSpec
);
...
@@ -1698,12 +1728,12 @@ void ClassDef::determineImplUsageRelation()
...
@@ -1698,12 +1728,12 @@ void ClassDef::determineImplUsageRelation()
if
(
cd
)
// class exists
if
(
cd
)
// class exists
{
{
found
=
TRUE
;
found
=
TRUE
;
if
(
usesImplClassDict
==
0
)
usesImplClassDict
=
new
UsesClassDict
(
257
);
if
(
m_usesImplClassDict
==
0
)
m_
usesImplClassDict
=
new
UsesClassDict
(
257
);
UsesClassDef
*
ucd
=
usesImplClassDict
->
find
(
cd
->
name
());
UsesClassDef
*
ucd
=
m_
usesImplClassDict
->
find
(
cd
->
name
());
if
(
ucd
==
0
||
ucd
->
templSpecifiers
!=
templSpec
)
if
(
ucd
==
0
||
ucd
->
templSpecifiers
!=
templSpec
)
{
{
ucd
=
new
UsesClassDef
(
cd
);
ucd
=
new
UsesClassDef
(
cd
);
usesImplClassDict
->
insert
(
cd
->
name
(),
ucd
);
m_
usesImplClassDict
->
insert
(
cd
->
name
(),
ucd
);
ucd
->
templSpecifiers
=
templSpec
;
ucd
->
templSpecifiers
=
templSpec
;
//printf("Adding used class %s to class %s\n",
//printf("Adding used class %s to class %s\n",
// cd->name().data(),name().data());
// cd->name().data(),name().data());
...
@@ -1712,17 +1742,16 @@ void ClassDef::determineImplUsageRelation()
...
@@ -1712,17 +1742,16 @@ void ClassDef::determineImplUsageRelation()
//printf("Adding accessor %s to class %s\n",
//printf("Adding accessor %s to class %s\n",
// md->name().data(),ucd->classDef->name().data());
// md->name().data(),ucd->classDef->name().data());
}
}
p
=
i
+
l
;
}
}
}
}
}
}
}
}
}
}
#ifdef DUMP
#ifdef DUMP
if
(
usesClassDict
)
if
(
m_
usesClassDict
)
{
{
msg
(
"Class %s uses the following classes:
\n
"
,
name
().
data
());
msg
(
"Class %s uses the following classes:
\n
"
,
name
().
data
());
UsesClassDictIterator
ucdi
(
*
usesClassDict
);
UsesClassDictIterator
ucdi
(
*
m_
usesClassDict
);
UsesClassDef
*
ucd
;
UsesClassDef
*
ucd
;
for
(;(
ucd
=
ucdi
.
current
());
++
ucdi
)
for
(;(
ucd
=
ucdi
.
current
());
++
ucdi
)
{
{
...
@@ -1756,15 +1785,15 @@ void ClassDef::addUsedInterfaceClasses(MemberDef *md,const char *typeStr)
...
@@ -1756,15 +1785,15 @@ void ClassDef::addUsedInterfaceClasses(MemberDef *md,const char *typeStr)
if (cd==0) cd=getClass(type.mid(i,l)); // TODO: also try inbetween scopes!
if (cd==0) cd=getClass(type.mid(i,l)); // TODO: also try inbetween scopes!
if (cd && cd!=this && !isBaseClass(cd))
if (cd && cd!=this && !isBaseClass(cd))
{
{
if (usesIntfClassDict==0)
if (
m_
usesIntfClassDict==0)
{
{
usesIntfClassDict = new UsesClassDict(257);
m_
usesIntfClassDict = new UsesClassDict(257);
}
}
UsesClassDef *ucd=usesIntfClassDict->find(cd->name());
UsesClassDef *ucd=
m_
usesIntfClassDict->find(cd->name());
if (ucd==0)
if (ucd==0)
{
{
ucd = new UsesClassDef(cd);
ucd = new UsesClassDef(cd);
usesIntfClassDict->insert(cd->name(),ucd);
m_
usesIntfClassDict->insert(cd->name(),ucd);
//printf("in class `%s' adding used intf class `%s'\n",
//printf("in class `%s' adding used intf class `%s'\n",
// name().data(),cd->name().data());
// name().data(),cd->name().data());
}
}
...
@@ -1778,7 +1807,7 @@ void ClassDef::addUsedInterfaceClasses(MemberDef *md,const char *typeStr)
...
@@ -1778,7 +1807,7 @@ void ClassDef::addUsedInterfaceClasses(MemberDef *md,const char *typeStr)
void ClassDef::determineIntfUsageRelation()
void ClassDef::determineIntfUsageRelation()
{
{
MemberNameInfo
ListIterator mnili(*
allMemberNameInfoList);
MemberNameInfo
SDict::Iterator mnili(*m_
allMemberNameInfoList);
MemberNameInfo *mni;
MemberNameInfo *mni;
for (;(mni=mnili.current());++mnili)
for (;(mni=mnili.current());++mnili)
{
{
...
@@ -1824,12 +1853,12 @@ void ClassDef::determineIntfUsageRelation()
...
@@ -1824,12 +1853,12 @@ void ClassDef::determineIntfUsageRelation()
PackageDef
*
ClassDef
::
packageDef
()
const
PackageDef
*
ClassDef
::
packageDef
()
const
{
{
return
fileDef
?
fileDef
->
packageDef
()
:
0
;
return
m_fileDef
?
m_
fileDef
->
packageDef
()
:
0
;
}
}
QCString
ClassDef
::
compoundTypeString
()
const
QCString
ClassDef
::
compoundTypeString
()
const
{
{
switch
(
compType
)
switch
(
m_
compType
)
{
{
case
Class
:
return
"class"
;
case
Class
:
return
"class"
;
case
Struct
:
return
"struct"
;
case
Struct
:
return
"struct"
;
...
@@ -1844,21 +1873,94 @@ QCString ClassDef::getOutputFileBase() const
...
@@ -1844,21 +1873,94 @@ QCString ClassDef::getOutputFileBase() const
{
{
if
(
isReference
())
if
(
isReference
())
{
{
return
fileName
;
return
m_
fileName
;
}
}
else
else
{
{
return
convertNameToFile
(
fileName
);
return
convertNameToFile
(
m_
fileName
);
}
}
}
}
QCString
ClassDef
::
getFileBase
()
const
QCString
ClassDef
::
getFileBase
()
const
{
{
return
fileName
;
return
m_
fileName
;
}
}
QCString
ClassDef
::
getSourceFileBase
()
const
QCString
ClassDef
::
getSourceFileBase
()
const
{
{
return
convertNameToFile
(
fileName
+
"-source"
);
return
convertNameToFile
(
m_fileName
+
"-source"
);
}
void
ClassDef
::
setGroupDefForAllMembers
(
GroupDef
*
gd
)
{
gd
->
addClass
(
this
);
//printf("ClassDef::setGroupDefForAllMembers(%s)\n",gd->name().data());
MemberNameInfoSDict
::
Iterator
mnili
(
*
m_allMemberNameInfoSDict
);
MemberNameInfo
*
mni
;
for
(;(
mni
=
mnili
.
current
());
++
mnili
)
{
MemberNameInfoIterator
mnii
(
*
mni
);
MemberInfo
*
mi
;
for
(
mnii
.
toFirst
();(
mi
=
mnii
.
current
());
++
mnii
)
{
MemberDef
*
md
=
mi
->
memberDef
;
md
->
setGroupDef
(
gd
);
gd
->
insertMember
(
md
,
TRUE
);
ClassDef
*
innerClass
=
md
->
getClassDefOfAnonymousType
();
if
(
innerClass
)
innerClass
->
setGroupDefForAllMembers
(
gd
);
}
}
}
void
ClassDef
::
addInnerCompound
(
Definition
*
d
)
{
m_innerClasses
->
inSort
(
d
->
localName
(),(
ClassDef
*
)
d
);
}
Definition
*
ClassDef
::
findInnerCompound
(
const
char
*
name
)
{
if
(
name
==
0
)
return
0
;
return
m_innerClasses
->
find
(
name
);
}
void
ClassDef
::
initTemplateMapping
()
{
m_templateMapping
->
clear
();
ArgumentList
*
al
=
templateArguments
();
if
(
al
)
{
ArgumentListIterator
ali
(
*
al
);
Argument
*
arg
;
for
(
ali
.
toFirst
();(
arg
=
ali
.
current
());
++
ali
)
{
setTemplateArgumentMapping
(
arg
->
name
,
arg
->
defval
);
}
}
}
void
ClassDef
::
setTemplateArgumentMapping
(
const
char
*
formal
,
const
char
*
actual
)
{
//printf("ClassDef::setTemplateArgumentMapping(%s,%s)\n",formal,actual);
if
(
m_templateMapping
&&
formal
)
{
if
(
m_templateMapping
->
find
(
formal
))
{
m_templateMapping
->
remove
(
formal
);
}
m_templateMapping
->
insert
(
formal
,
new
QCString
(
actual
));
}
}
QCString
ClassDef
::
getTemplateArgumentMapping
(
const
char
*
formal
)
const
{
if
(
m_templateMapping
&&
formal
)
{
QCString
*
s
=
m_templateMapping
->
find
(
formal
);
if
(
s
)
{
return
*
s
;
}
}
return
""
;
}
}
src/classdef.h
View file @
75fed736
...
@@ -29,21 +29,21 @@
...
@@ -29,21 +29,21 @@
class
MemberDict
;
class
MemberDict
;
class
ClassList
;
class
ClassList
;
class
ClassSDict
;
class
OutputList
;
class
OutputList
;
class
FileDef
;
class
FileDef
;
class
BaseClassList
;
class
BaseClassList
;
class
MemberInfoList
;
class
MemberInfoDict
;
class
NamespaceDef
;
class
NamespaceDef
;
class
MemberDef
;
class
MemberDef
;
class
ExampleList
;
class
ExampleSDict
;
class
MemberNameInfoList
;
class
MemberNameInfoSDict
;
class
MemberNameInfoDict
;
class
UsesClassDict
;
class
UsesClassDict
;
class
MemberGroupList
;
class
MemberGroupList
;
class
MemberGroupDict
;
class
MemberGroupDict
;
class
QTextStream
;
class
QTextStream
;
class
PackageDef
;
class
PackageDef
;
class
GroupDef
;
class
StringDict
;
struct
IncludeInfo
;
struct
IncludeInfo
;
/*! \brief This class contains all information about a compound.
/*! \brief This class contains all information about a compound.
...
@@ -76,7 +76,7 @@ class ClassDef : public Definition
...
@@ -76,7 +76,7 @@ class ClassDef : public Definition
QCString
displayName
()
const
;
QCString
displayName
()
const
;
/*! Returns the type of compound this is */
/*! Returns the type of compound this is */
CompoundType
compoundType
()
const
{
return
compType
;
}
CompoundType
compoundType
()
const
{
return
m_
compType
;
}
/*! Returns the type of compound as a string */
/*! Returns the type of compound as a string */
QCString
compoundTypeString
()
const
;
QCString
compoundTypeString
()
const
;
...
@@ -84,21 +84,16 @@ class ClassDef : public Definition
...
@@ -84,21 +84,16 @@ class ClassDef : public Definition
/*! Returns the list of base classes from which this class directly
/*! Returns the list of base classes from which this class directly
* inherits.
* inherits.
*/
*/
BaseClassList
*
baseClasses
()
{
return
inherits
;
}
BaseClassList
*
baseClasses
()
{
return
m_
inherits
;
}
/*! Returns the list of sub classes that directly inherit from this class
/*! Returns the list of sub classes that directly inherit from this class
*/
*/
BaseClassList
*
subClasses
()
{
return
inheritedBy
;
}
BaseClassList
*
subClasses
()
{
return
m_inheritedBy
;
}
/*! Returns a list of all members. This includes any inherited members.
* Members are sorted alphabetically.
*/
MemberNameInfoList
*
memberNameInfoList
()
{
return
allMemberNameInfoList
;
}
/*! Returns a dictionary of all members. This includes any inherited
/*! Returns a dictionary of all members. This includes any inherited
* members. Members are sorted alphabetically.
* members. Members are sorted alphabetically.
*/
*/
MemberNameInfo
Dict
*
memberNameInfoDict
()
{
return
allMemberNameInfo
Dict
;
}
MemberNameInfo
SDict
*
memberNameInfoSDict
()
{
return
m_allMemberNameInfoS
Dict
;
}
void
writeDocumentation
(
OutputList
&
ol
);
void
writeDocumentation
(
OutputList
&
ol
);
void
writeMemberList
(
OutputList
&
ol
);
void
writeMemberList
(
OutputList
&
ol
);
...
@@ -107,7 +102,7 @@ class ClassDef : public Definition
...
@@ -107,7 +102,7 @@ class ClassDef : public Definition
/*! Return the protection level (Public,Protected,Private) in which
/*! Return the protection level (Public,Protected,Private) in which
* this compound was found.
* this compound was found.
*/
*/
Protection
protection
()
const
{
return
prot
;
}
Protection
protection
()
const
{
return
m_
prot
;
}
/*! returns TRUE iff a link is possible to an item within this project.
/*! returns TRUE iff a link is possible to an item within this project.
*/
*/
...
@@ -127,7 +122,7 @@ class ClassDef : public Definition
...
@@ -127,7 +122,7 @@ class ClassDef : public Definition
/*! Returns the template arguments of this class
/*! Returns the template arguments of this class
* Will return 0 if not applicable.
* Will return 0 if not applicable.
*/
*/
ArgumentList
*
templateArguments
()
const
{
return
tempArgs
;
}
ArgumentList
*
templateArguments
()
const
{
return
m_
tempArgs
;
}
/*! Returns the template arguments that this nested class "inherits"
/*! Returns the template arguments that this nested class "inherits"
* from its outer class (doxygen assumes there is only one!).
* from its outer class (doxygen assumes there is only one!).
...
@@ -138,12 +133,12 @@ class ClassDef : public Definition
...
@@ -138,12 +133,12 @@ class ClassDef : public Definition
/*! Returns the namespace this compound is in, or 0 if it has a global
/*! Returns the namespace this compound is in, or 0 if it has a global
* scope.
* scope.
*/
*/
NamespaceDef
*
getNamespaceDef
()
{
return
nspace
;
}
NamespaceDef
*
getNamespaceDef
()
{
return
m_
nspace
;
}
/*! Returns the file in which this compound's definition can be found.
/*! Returns the file in which this compound's definition can be found.
* Should not return 0 (but it might be a good idea to check anyway).
* Should not return 0 (but it might be a good idea to check anyway).
*/
*/
FileDef
*
getFileDef
()
const
{
return
fileDef
;
}
FileDef
*
getFileDef
()
const
{
return
m_
fileDef
;
}
/*! Returns the Java package this class is in or 0 if not applicable.
/*! Returns the Java package this class is in or 0 if not applicable.
*/
*/
...
@@ -155,16 +150,24 @@ class ClassDef : public Definition
...
@@ -155,16 +150,24 @@ class ClassDef : public Definition
*/
*/
bool
isBaseClass
(
ClassDef
*
bcd
);
bool
isBaseClass
(
ClassDef
*
bcd
);
/*! Is this an artificial class that is the template argument of
* a class. If so the argument number is returned, otherwise -1
* is returned.
*/
int
isTemplateBaseClass
()
const
{
return
m_isTemplBaseClass
;
}
UsesClassDict
*
usedImplementationClasses
()
const
UsesClassDict
*
usedImplementationClasses
()
const
{
{
return
usesImplClassDict
;
return
m_
usesImplClassDict
;
}
}
UsesClassDict
*
usedInterfaceClasses
()
const
UsesClassDict
*
usedInterfaceClasses
()
const
{
{
return
usesIntfClassDict
;
return
m_
usesIntfClassDict
;
}
}
virtual
Definition
*
findInnerCompound
(
const
char
*
name
);
/* member lists by protection */
/* member lists by protection */
MemberList
pubMembers
;
MemberList
pubMembers
;
MemberList
proMembers
;
MemberList
proMembers
;
...
@@ -200,7 +203,7 @@ class ClassDef : public Definition
...
@@ -200,7 +203,7 @@ class ClassDef : public Definition
MemberList
variableMembers
;
MemberList
variableMembers
;
MemberList
propertyMembers
;
MemberList
propertyMembers
;
/*! \} */
/*! \}
Public API
*/
/*! \name Doxygen internal API
/*! \name Doxygen internal API
* \{
* \{
...
@@ -217,16 +220,24 @@ class ClassDef : public Definition
...
@@ -217,16 +220,24 @@ class ClassDef : public Definition
bool
addExample
(
const
char
*
anchor
,
const
char
*
name
,
const
char
*
file
);
bool
addExample
(
const
char
*
anchor
,
const
char
*
name
,
const
char
*
file
);
void
addMembersToMemberGroup
();
void
addMembersToMemberGroup
();
void
distributeMemberGroupDocumentation
();
void
distributeMemberGroupDocumentation
();
void
setNamespace
(
NamespaceDef
*
nd
)
{
nspace
=
nd
;
}
void
setNamespace
(
NamespaceDef
*
nd
)
{
m_
nspace
=
nd
;
}
void
setTemplateArguments
(
ArgumentList
*
al
);
void
setTemplateArguments
(
ArgumentList
*
al
);
void
mergeMembers
();
void
mergeMembers
();
void
setFileDef
(
FileDef
*
fd
)
{
fileDef
=
fd
;
}
void
setFileDef
(
FileDef
*
fd
)
{
m_
fileDef
=
fd
;
}
void
determineImplUsageRelation
();
void
determineImplUsageRelation
();
void
determineIntfUsageRelation
();
void
determineIntfUsageRelation
();
void
setSubGrouping
(
bool
enabled
)
{
subGrouping
=
enabled
;
}
void
setSubGrouping
(
bool
enabled
)
{
m_subGrouping
=
enabled
;
}
void
setProtection
(
Protection
p
)
{
prot
=
p
;
}
void
setProtection
(
Protection
p
)
{
m_prot
=
p
;
}
void
setGroupDefForAllMembers
(
GroupDef
*
g
);
void
addInnerCompound
(
Definition
*
d
);
void
setIsTemplateBaseClass
(
int
num
)
{
m_isTemplBaseClass
=
num
;
}
void
initTemplateMapping
();
void
setTemplateArgumentMapping
(
const
char
*
formal
,
const
char
*
actual
);
QCString
getTemplateArgumentMapping
(
const
char
*
formal
)
const
;
/*! Creates a new compound definition.
/*! Creates a new compound definition.
* \param outerScope class, file or namespace in which this class is
* defined.
* \param fileName full path and file name in which this compound was
* \param fileName full path and file name in which this compound was
* found.
* found.
* \param startLine line number where the definition of this compound
* \param startLine line number where the definition of this compound
...
@@ -252,37 +263,99 @@ class ClassDef : public Definition
...
@@ -252,37 +263,99 @@ class ClassDef : public Definition
bool
hasExamples
();
bool
hasExamples
();
bool
hasNonReferenceSuperClass
();
bool
hasNonReferenceSuperClass
();
/*! \} */
/*! \}
Interal API
*/
private
:
private
:
QCString
fileName
;
// HTML containing the class docs
/*! file name that forms the base for the output file containing the
IncludeInfo
*
incInfo
;
// header file to refer to
* class documentation. For compatibility with Qt (e.g. links via tag
QCString
incName
;
// alternative include file name
* files) this name cannot be derived from the class name directly.
QCString
memListFileName
;
*/
QCString
scopelessName
;
// name without any scopes
QCString
m_fileName
;
BaseClassList
*
inherits
;
BaseClassList
*
inheritedBy
;
/*! Include information about the header file should be included
NamespaceDef
*
nspace
;
// the namespace this class is in
* in the documentation. 0 by default, set by setIncludeFile().
*/
IncludeInfo
*
m_incInfo
;
/*! file name that forms the base for the "list of members" for this
* class.
*/
QCString
m_memListFileName
;
/*! Bare name of the class without any scoping prefixes
* (like for nested classes and classes inside namespaces)
*/
QCString
m_scopelessName
;
/*! List of base class (or super-classes) from which this class derives
* directly.
*/
BaseClassList
*
m_inherits
;
/*! List of sub-classes that directly derive from this class
*/
BaseClassList
*
m_inheritedBy
;
/*! Namespace this class is part of
* (this is the inner most namespace in case of nested namespaces)
*/
NamespaceDef
*
m_nspace
;
/*! File this class is defined in */
FileDef
*
m_fileDef
;
/*! List of all members (including inherited members) */
MemberNameInfoSDict
*
m_allMemberNameInfoSDict
;
/*! Template arguments of this class */
ArgumentList
*
m_tempArgs
;
/*! Files that were used for generating the class documentation. */
QStrList
m_files
;
/*! Examples that use this class */
ExampleSDict
*
m_exampleSDict
;
/*! Holds the kind of "class" this is. */
CompoundType
m_compType
;
/*! The protection level in which this class was found.
* Typically Public, but for nested classes this can also be Protected
* or Private.
*/
Protection
m_prot
;
/*! Does this class group its user-grouped members
* as a sub-section of the normal (public/protected/..)
* groups?
*/
bool
m_subGrouping
;
/*! The inner classes contained in this class. Will be 0 if there are
* no inner classes.
*/
ClassSDict
*
m_innerClasses
;
/* user defined member groups */
/* user defined member groups */
MemberGroupList
*
memberGroupList
;
MemberGroupList
*
m_memberGroupList
;
MemberGroupDict
*
memberGroupDict
;
MemberGroupDict
*
m_memberGroupDict
;
MemberNameInfoList
*
allMemberNameInfoList
;
MemberNameInfoDict
*
allMemberNameInfoDict
;
ArgumentList
*
tempArgs
;
QStrList
files
;
ExampleList
*
exampleList
;
ExampleDict
*
exampleDict
;
CompoundType
compType
;
Protection
prot
;
FileDef
*
fileDef
;
UsesClassDict
*
usesImplClassDict
;
UsesClassDict
*
usesIntfClassDict
;
bool
subGrouping
;
// does this class group its user-grouped members
/* classes for the collaboration diagram */
// as a sub-section of the normal (public/protected/..)
UsesClassDict
*
m_usesImplClassDict
;
// groups?
UsesClassDict
*
m_usesIntfClassDict
;
/*! Is this a class that exists because of template class that
* inherited one of it's template arguments. If so that this
* variable indicate the template argument number, otherwise
* this is -1
*/
int
m_isTemplBaseClass
;
/*! A mapping used by template classes, which maps formal
* template arguments to their actual instantiations.
* This is used while generating inheritance graphs.
*/
StringDict
*
m_templateMapping
;
};
};
/*! \brief Class that contains information about a usage relation.
/*! \brief Class that contains information about a usage relation.
...
...
src/classlist.cpp
View file @
75fed736
...
@@ -35,9 +35,15 @@ int ClassList::compareItems(GCI item1, GCI item2)
...
@@ -35,9 +35,15 @@ int ClassList::compareItems(GCI item1, GCI item2)
{
{
ClassDef
*
c1
=
(
ClassDef
*
)
item1
;
ClassDef
*
c1
=
(
ClassDef
*
)
item1
;
ClassDef
*
c2
=
(
ClassDef
*
)
item2
;
ClassDef
*
c2
=
(
ClassDef
*
)
item2
;
//int prefixLength = Config::instance()->get("").length();
return
stricmp
(
c1
->
name
().
data
()
+
getPrefixIndex
(
c1
->
name
()),
//int i1 = c1->name().left(prefixLength)==Config::instance()->get("") ? prefixLength : 0;
c2
->
name
().
data
()
+
getPrefixIndex
(
c2
->
name
())
//int i2 = c2->name().left(prefixLength)==Config::instance()->get("") ? prefixLength : 0;
);
}
int
ClassSDict
::
compareItems
(
GCI
item1
,
GCI
item2
)
{
ClassDef
*
c1
=
(
ClassDef
*
)
item1
;
ClassDef
*
c2
=
(
ClassDef
*
)
item2
;
return
stricmp
(
c1
->
name
().
data
()
+
getPrefixIndex
(
c1
->
name
()),
return
stricmp
(
c1
->
name
().
data
()
+
getPrefixIndex
(
c1
->
name
()),
c2
->
name
().
data
()
+
getPrefixIndex
(
c2
->
name
())
c2
->
name
().
data
()
+
getPrefixIndex
(
c2
->
name
())
);
);
...
@@ -48,13 +54,14 @@ ClassListIterator::ClassListIterator(const ClassList &cllist) :
...
@@ -48,13 +54,14 @@ ClassListIterator::ClassListIterator(const ClassList &cllist) :
{
{
}
}
void
Class
Lis
t
::
writeDeclaration
(
OutputList
&
ol
,
const
ClassDef
::
CompoundType
*
filter
,
const
char
*
header
)
void
Class
SDic
t
::
writeDeclaration
(
OutputList
&
ol
,
const
ClassDef
::
CompoundType
*
filter
,
const
char
*
header
)
{
{
if
(
count
()
>
0
)
if
(
count
()
>
0
)
{
{
ClassDef
*
cd
=
first
();
ClassSDict
::
Iterator
sdi
(
*
this
);
ClassDef
*
cd
=
0
;
bool
found
=
FALSE
;
bool
found
=
FALSE
;
while
(
cd
)
for
(
sdi
.
toFirst
();(
cd
=
sdi
.
current
());
++
sdi
)
{
{
if
(
cd
->
name
().
find
(
'@'
)
==-
1
&&
if
(
cd
->
name
().
find
(
'@'
)
==-
1
&&
(
filter
==
0
||
*
filter
==
cd
->
compoundType
())
(
filter
==
0
||
*
filter
==
cd
->
compoundType
())
...
@@ -124,7 +131,6 @@ void ClassList::writeDeclaration(OutputList &ol,const ClassDef::CompoundType *fi
...
@@ -124,7 +131,6 @@ void ClassList::writeDeclaration(OutputList &ol,const ClassDef::CompoundType *fi
}
}
}
}
}
}
cd
=
next
();
}
}
if
(
found
)
ol
.
endMemberList
();
if
(
found
)
ol
.
endMemberList
();
}
}
...
...
src/classlist.h
View file @
75fed736
...
@@ -22,6 +22,7 @@
...
@@ -22,6 +22,7 @@
#include <qdict.h>
#include <qdict.h>
#include "classdef.h"
#include "classdef.h"
#include "sortdict.h"
class
ClassList
:
public
QList
<
ClassDef
>
class
ClassList
:
public
QList
<
ClassDef
>
{
{
...
@@ -30,8 +31,6 @@ class ClassList : public QList<ClassDef>
...
@@ -30,8 +31,6 @@ class ClassList : public QList<ClassDef>
~
ClassList
();
~
ClassList
();
int
compareItems
(
GCI
item1
,
GCI
item2
);
int
compareItems
(
GCI
item1
,
GCI
item2
);
void
writeDeclaration
(
OutputList
&
ol
,
const
ClassDef
::
CompoundType
*
filter
=
0
,
const
char
*
header
=
0
);
};
};
class
ClassListIterator
:
public
QListIterator
<
ClassDef
>
class
ClassListIterator
:
public
QListIterator
<
ClassDef
>
...
@@ -47,4 +46,14 @@ class ClassDict : public QDict<ClassDef>
...
@@ -47,4 +46,14 @@ class ClassDict : public QDict<ClassDef>
~
ClassDict
()
{}
~
ClassDict
()
{}
};
};
class
ClassSDict
:
public
SDict
<
ClassDef
>
{
public
:
ClassSDict
(
int
size
)
:
SDict
<
ClassDef
>
(
size
)
{}
~
ClassSDict
()
{}
int
compareItems
(
GCI
item1
,
GCI
item2
);
void
writeDeclaration
(
OutputList
&
ol
,
const
ClassDef
::
CompoundType
*
filter
=
0
,
const
char
*
header
=
0
);
};
#endif
#endif
src/definition.cpp
View file @
75fed736
...
@@ -31,26 +31,33 @@
...
@@ -31,26 +31,33 @@
Definition
::
Definition
(
const
char
*
df
,
int
dl
,
Definition
::
Definition
(
const
char
*
df
,
int
dl
,
const
char
*
name
,
const
char
*
b
,
const
char
*
d
)
const
char
*
name
,
const
char
*
b
,
const
char
*
d
)
{
{
defFileName
=
df
;
m_defFileName
=
df
;
defLine
=
dl
;
m_defLine
=
dl
;
n
=
name
;
m_name
=
name
;
brief
=
b
;
m_localName
=
name
;
doc
=
d
;
int
i
=
m_localName
.
findRev
(
"::"
);
sectionDict
=
0
,
if
(
i
!=-
1
)
startBodyLine
=
endBodyLine
=-
1
,
{
bodyDef
=
0
;
m_localName
=
m_localName
.
right
(
m_localName
.
length
()
-
i
-
2
);
sourceRefList
=
0
;
}
sourceRefDict
=
0
;
m_brief
=
b
;
m_doc
=
d
;
m_sectionDict
=
0
,
m_startBodyLine
=
m_endBodyLine
=-
1
,
m_bodyDef
=
0
;
m_sourceRefList
=
0
;
m_sourceRefDict
=
0
;
m_todoId
=
0
;
m_todoId
=
0
;
m_testId
=
0
;
m_testId
=
0
;
m_bugId
=
0
;
m_bugId
=
0
;
m_outerScope
=
0
;
}
}
Definition
::~
Definition
()
Definition
::~
Definition
()
{
{
delete
sectionDict
;
delete
m_
sectionDict
;
delete
sourceRefList
;
delete
m_
sourceRefList
;
delete
sourceRefDict
;
delete
m_
sourceRefDict
;
}
}
...
@@ -65,13 +72,13 @@ void Definition::addSectionsToDefinition(QList<QCString> *anchorList)
...
@@ -65,13 +72,13 @@ void Definition::addSectionsToDefinition(QList<QCString> *anchorList)
{
{
//printf("Add section `%s' to definition `%s'\n",
//printf("Add section `%s' to definition `%s'\n",
// si->label.data(),n.data());
// si->label.data(),n.data());
if
(
sectionDict
==
0
)
if
(
m_
sectionDict
==
0
)
{
{
sectionDict
=
new
SectionDict
(
17
);
m_
sectionDict
=
new
SectionDict
(
17
);
}
}
if
(
sectionDict
->
find
(
*
s
)
==
0
)
if
(
m_
sectionDict
->
find
(
*
s
)
==
0
)
{
{
sectionDict
->
insert
(
*
s
,
si
);
m_
sectionDict
->
insert
(
*
s
,
si
);
}
}
si
->
definition
=
this
;
si
->
definition
=
this
;
}
}
...
@@ -81,9 +88,9 @@ void Definition::addSectionsToDefinition(QList<QCString> *anchorList)
...
@@ -81,9 +88,9 @@ void Definition::addSectionsToDefinition(QList<QCString> *anchorList)
void
Definition
::
writeDocAnchorsToTagFile
()
void
Definition
::
writeDocAnchorsToTagFile
()
{
{
if
(
!
Config_getString
(
"GENERATE_TAGFILE"
).
isEmpty
()
&&
sectionDict
)
if
(
!
Config_getString
(
"GENERATE_TAGFILE"
).
isEmpty
()
&&
m_
sectionDict
)
{
{
QDictIterator
<
SectionInfo
>
sdi
(
*
sectionDict
);
QDictIterator
<
SectionInfo
>
sdi
(
*
m_
sectionDict
);
SectionInfo
*
si
;
SectionInfo
*
si
;
for
(;(
si
=
sdi
.
current
());
++
sdi
)
for
(;(
si
=
sdi
.
current
());
++
sdi
)
{
{
...
@@ -99,14 +106,14 @@ void Definition::writeDocAnchorsToTagFile()
...
@@ -99,14 +106,14 @@ void Definition::writeDocAnchorsToTagFile()
void
Definition
::
setBriefDescription
(
const
char
*
b
)
void
Definition
::
setBriefDescription
(
const
char
*
b
)
{
{
brief
=
QCString
(
b
).
stripWhiteSpace
();
m_
brief
=
QCString
(
b
).
stripWhiteSpace
();
int
bl
=
brief
.
length
();
int
bl
=
m_
brief
.
length
();
if
(
bl
>
0
)
// add puntuation if needed
if
(
bl
>
0
)
// add puntuation if needed
{
{
switch
(
brief
.
at
(
bl
-
1
))
switch
(
m_
brief
.
at
(
bl
-
1
))
{
{
case
'.'
:
case
'!'
:
case
'?'
:
break
;
case
'.'
:
case
'!'
:
case
'?'
:
break
;
default
:
brief
+=
'.'
;
break
;
default
:
m_
brief
+=
'.'
;
break
;
}
}
}
}
}
}
...
@@ -219,7 +226,7 @@ void Definition::writeSourceDef(OutputList &ol,const char *)
...
@@ -219,7 +226,7 @@ void Definition::writeSourceDef(OutputList &ol,const char *)
{
{
ol
.
pushGeneratorState
();
ol
.
pushGeneratorState
();
//printf("Definition::writeSourceRef %d %p\n",bodyLine,bodyDef);
//printf("Definition::writeSourceRef %d %p\n",bodyLine,bodyDef);
if
(
Config_getBool
(
"SOURCE_BROWSER"
)
&&
startBodyLine
!=-
1
&&
bodyDef
)
if
(
Config_getBool
(
"SOURCE_BROWSER"
)
&&
m_startBodyLine
!=-
1
&&
m_
bodyDef
)
{
{
//ol.disable(OutputGenerator::RTF);
//ol.disable(OutputGenerator::RTF);
ol
.
newParagraph
();
ol
.
newParagraph
();
...
@@ -231,15 +238,15 @@ void Definition::writeSourceDef(OutputList &ol,const char *)
...
@@ -231,15 +238,15 @@ void Definition::writeSourceDef(OutputList &ol,const char *)
if
(
lineMarkerPos
!=-
1
&&
fileMarkerPos
!=-
1
)
// should always pass this.
if
(
lineMarkerPos
!=-
1
&&
fileMarkerPos
!=-
1
)
// should always pass this.
{
{
QCString
lineStr
,
anchorStr
;
QCString
lineStr
,
anchorStr
;
lineStr
.
sprintf
(
"%d"
,
startBodyLine
);
lineStr
.
sprintf
(
"%d"
,
m_
startBodyLine
);
anchorStr
.
sprintf
(
"l%05d"
,
startBodyLine
);
anchorStr
.
sprintf
(
"l%05d"
,
m_
startBodyLine
);
if
(
lineMarkerPos
<
fileMarkerPos
)
// line marker before file marker
if
(
lineMarkerPos
<
fileMarkerPos
)
// line marker before file marker
{
{
// write text left from linePos marker
// write text left from linePos marker
parseText
(
ol
,
refText
.
left
(
lineMarkerPos
));
parseText
(
ol
,
refText
.
left
(
lineMarkerPos
));
ol
.
disableAllBut
(
OutputGenerator
::
Html
);
ol
.
disableAllBut
(
OutputGenerator
::
Html
);
// write line link (HTML only)
// write line link (HTML only)
ol
.
writeObjectLink
(
0
,
bodyDef
->
getSourceFileBase
(),
ol
.
writeObjectLink
(
0
,
m_
bodyDef
->
getSourceFileBase
(),
anchorStr
,
lineStr
);
anchorStr
,
lineStr
);
ol
.
enableAll
();
ol
.
enableAll
();
ol
.
disable
(
OutputGenerator
::
Html
);
ol
.
disable
(
OutputGenerator
::
Html
);
...
@@ -253,12 +260,12 @@ void Definition::writeSourceDef(OutputList &ol,const char *)
...
@@ -253,12 +260,12 @@ void Definition::writeSourceDef(OutputList &ol,const char *)
ol
.
disableAllBut
(
OutputGenerator
::
Html
);
ol
.
disableAllBut
(
OutputGenerator
::
Html
);
// write file link (HTML only)
// write file link (HTML only)
ol
.
writeObjectLink
(
0
,
bodyDef
->
getSourceFileBase
(),
ol
.
writeObjectLink
(
0
,
m_
bodyDef
->
getSourceFileBase
(),
0
,
bodyDef
->
name
());
0
,
m_
bodyDef
->
name
());
ol
.
enableAll
();
ol
.
enableAll
();
ol
.
disable
(
OutputGenerator
::
Html
);
ol
.
disable
(
OutputGenerator
::
Html
);
// write normal text (Latex/Man only)
// write normal text (Latex/Man only)
ol
.
docify
(
bodyDef
->
name
());
ol
.
docify
(
m_
bodyDef
->
name
());
ol
.
enableAll
();
ol
.
enableAll
();
// write text right from file marker
// write text right from file marker
...
@@ -271,12 +278,12 @@ void Definition::writeSourceDef(OutputList &ol,const char *)
...
@@ -271,12 +278,12 @@ void Definition::writeSourceDef(OutputList &ol,const char *)
parseText
(
ol
,
refText
.
left
(
fileMarkerPos
));
parseText
(
ol
,
refText
.
left
(
fileMarkerPos
));
ol
.
disableAllBut
(
OutputGenerator
::
Html
);
ol
.
disableAllBut
(
OutputGenerator
::
Html
);
// write file link (HTML only)
// write file link (HTML only)
ol
.
writeObjectLink
(
0
,
bodyDef
->
getSourceFileBase
(),
ol
.
writeObjectLink
(
0
,
m_
bodyDef
->
getSourceFileBase
(),
0
,
bodyDef
->
name
());
0
,
m_
bodyDef
->
name
());
ol
.
enableAll
();
ol
.
enableAll
();
ol
.
disable
(
OutputGenerator
::
Html
);
ol
.
disable
(
OutputGenerator
::
Html
);
// write normal text (Latex/Man only)
// write normal text (Latex/Man only)
ol
.
docify
(
bodyDef
->
name
());
ol
.
docify
(
m_
bodyDef
->
name
());
ol
.
enableAll
();
ol
.
enableAll
();
// write text between markers
// write text between markers
...
@@ -285,7 +292,7 @@ void Definition::writeSourceDef(OutputList &ol,const char *)
...
@@ -285,7 +292,7 @@ void Definition::writeSourceDef(OutputList &ol,const char *)
ol
.
disableAllBut
(
OutputGenerator
::
Html
);
ol
.
disableAllBut
(
OutputGenerator
::
Html
);
// write line link (HTML only)
// write line link (HTML only)
ol
.
writeObjectLink
(
0
,
bodyDef
->
getSourceFileBase
(),
ol
.
writeObjectLink
(
0
,
m_
bodyDef
->
getSourceFileBase
(),
anchorStr
,
lineStr
);
anchorStr
,
lineStr
);
ol
.
enableAll
();
ol
.
enableAll
();
ol
.
disable
(
OutputGenerator
::
Html
);
ol
.
disable
(
OutputGenerator
::
Html
);
...
@@ -316,12 +323,12 @@ void Definition::writeInlineCode(OutputList &ol,const char *scopeName)
...
@@ -316,12 +323,12 @@ void Definition::writeInlineCode(OutputList &ol,const char *scopeName)
ol
.
pushGeneratorState
();
ol
.
pushGeneratorState
();
//printf("Source Fragment %s: %d-%d bodyDef=%p\n",name().data(),
//printf("Source Fragment %s: %d-%d bodyDef=%p\n",name().data(),
// startBodyLine,endBodyLine,bodyDef);
// startBodyLine,endBodyLine,bodyDef);
if
(
Config_getBool
(
"INLINE_SOURCES"
)
&&
startBodyLine
!=-
1
&&
if
(
Config_getBool
(
"INLINE_SOURCES"
)
&&
m_
startBodyLine
!=-
1
&&
endBodyLine
>=
startBodyLine
&&
bodyDef
)
m_endBodyLine
>=
m_startBodyLine
&&
m_
bodyDef
)
{
{
QCString
codeFragment
;
QCString
codeFragment
;
int
actualStart
=
startBodyLine
,
actualEnd
=
endBodyLine
;
int
actualStart
=
m_startBodyLine
,
actualEnd
=
m_
endBodyLine
;
if
(
readCodeFragment
(
bodyDef
->
absFilePath
(),
if
(
readCodeFragment
(
m_
bodyDef
->
absFilePath
(),
actualStart
,
actualEnd
,
codeFragment
)
actualStart
,
actualEnd
,
codeFragment
)
)
)
{
{
...
@@ -330,7 +337,7 @@ void Definition::writeInlineCode(OutputList &ol,const char *scopeName)
...
@@ -330,7 +337,7 @@ void Definition::writeInlineCode(OutputList &ol,const char *scopeName)
if
(
definitionType
()
==
TypeMember
)
setParameterList
((
MemberDef
*
)
this
);
if
(
definitionType
()
==
TypeMember
)
setParameterList
((
MemberDef
*
)
this
);
ol
.
startCodeFragment
();
ol
.
startCodeFragment
();
parseCode
(
ol
,
scopeName
,
codeFragment
,
FALSE
,
0
,
parseCode
(
ol
,
scopeName
,
codeFragment
,
FALSE
,
0
,
bodyDef
,
actualStart
,
actualEnd
,
TRUE
);
m_
bodyDef
,
actualStart
,
actualEnd
,
TRUE
);
ol
.
endCodeFragment
();
ol
.
endCodeFragment
();
}
}
}
}
...
@@ -343,13 +350,13 @@ void Definition::writeInlineCode(OutputList &ol,const char *scopeName)
...
@@ -343,13 +350,13 @@ void Definition::writeInlineCode(OutputList &ol,const char *scopeName)
void
Definition
::
writeSourceRefs
(
OutputList
&
ol
,
const
char
*
scopeName
)
void
Definition
::
writeSourceRefs
(
OutputList
&
ol
,
const
char
*
scopeName
)
{
{
ol
.
pushGeneratorState
();
ol
.
pushGeneratorState
();
if
(
Config_getBool
(
"SOURCE_BROWSER"
)
&&
sourceRefList
)
if
(
Config_getBool
(
"SOURCE_BROWSER"
)
&&
m_
sourceRefList
)
{
{
ol
.
newParagraph
();
ol
.
newParagraph
();
parseText
(
ol
,
theTranslator
->
trReferencedBy
());
parseText
(
ol
,
theTranslator
->
trReferencedBy
());
ol
.
docify
(
" "
);
ol
.
docify
(
" "
);
QCString
ldefLine
=
theTranslator
->
trWriteList
(
sourceRefList
->
count
());
QCString
ldefLine
=
theTranslator
->
trWriteList
(
m_
sourceRefList
->
count
());
QRegExp
marker
(
"@[0-9]+"
);
QRegExp
marker
(
"@[0-9]+"
);
int
index
=
0
,
newIndex
,
matchLen
;
int
index
=
0
,
newIndex
,
matchLen
;
...
@@ -359,7 +366,7 @@ void Definition::writeSourceRefs(OutputList &ol,const char *scopeName)
...
@@ -359,7 +366,7 @@ void Definition::writeSourceRefs(OutputList &ol,const char *scopeName)
bool
ok
;
bool
ok
;
parseText
(
ol
,
ldefLine
.
mid
(
index
,
newIndex
-
index
));
parseText
(
ol
,
ldefLine
.
mid
(
index
,
newIndex
-
index
));
uint
entryIndex
=
ldefLine
.
mid
(
newIndex
+
1
,
matchLen
-
1
).
toUInt
(
&
ok
);
uint
entryIndex
=
ldefLine
.
mid
(
newIndex
+
1
,
matchLen
-
1
).
toUInt
(
&
ok
);
MemberDef
*
md
=
sourceRefList
->
at
(
entryIndex
);
MemberDef
*
md
=
m_
sourceRefList
->
at
(
entryIndex
);
if
(
ok
&&
md
)
if
(
ok
&&
md
)
{
{
QCString
scope
=
md
->
getScopeString
();
QCString
scope
=
md
->
getScopeString
();
...
@@ -402,8 +409,8 @@ void Definition::writeSourceRefs(OutputList &ol,const char *scopeName)
...
@@ -402,8 +409,8 @@ void Definition::writeSourceRefs(OutputList &ol,const char *scopeName)
bool
Definition
::
hasDocumentation
()
const
bool
Definition
::
hasDocumentation
()
const
{
{
return
!
doc
.
isEmpty
()
||
// has detailed docs
return
!
m_
doc
.
isEmpty
()
||
// has detailed docs
!
brief
.
isEmpty
()
||
// has brief description
!
m_
brief
.
isEmpty
()
||
// has brief description
Config_getBool
(
"EXTRACT_ALL"
);
// extract everything
Config_getBool
(
"EXTRACT_ALL"
);
// extract everything
}
}
...
@@ -419,16 +426,49 @@ void Definition::addSourceReference(MemberDef *md)
...
@@ -419,16 +426,49 @@ void Definition::addSourceReference(MemberDef *md)
name
.
prepend
(
scope
+
"::"
);
name
.
prepend
(
scope
+
"::"
);
}
}
if
(
sourceRefList
==
0
)
if
(
m_
sourceRefList
==
0
)
{
{
sourceRefDict
=
new
MemberDict
(
53
);
m_
sourceRefDict
=
new
MemberDict
(
53
);
sourceRefList
=
new
MemberList
;
m_
sourceRefList
=
new
MemberList
;
}
}
if
(
sourceRefDict
->
find
(
name
)
==
0
)
if
(
m_
sourceRefDict
->
find
(
name
)
==
0
)
{
{
sourceRefDict
->
insert
(
name
,
md
);
m_
sourceRefDict
->
insert
(
name
,
md
);
sourceRefList
->
inSort
(
md
);
m_
sourceRefList
->
inSort
(
md
);
}
}
}
}
}
}
Definition
*
Definition
::
findInnerCompound
(
const
char
*
)
{
return
0
;
}
void
Definition
::
addInnerCompound
(
Definition
*
)
{
err
(
"Error: Definition::addInnerCompound() called
\n
"
);
}
QCString
Definition
::
qualifiedName
()
const
{
//printf("start Definition::qualifiedName()\n");
if
(
m_outerScope
==
0
)
return
m_localName
;
// TODO: remove this check
QCString
qualifiedName
;
if
(
m_outerScope
->
name
()
==
"<globalScope>"
)
{
qualifiedName
=
m_localName
.
copy
();
}
else
{
qualifiedName
=
m_outerScope
->
qualifiedName
()
+
"::"
+
m_localName
;
}
//printf("end Definition::qualifiedName()=%s\n",qualifiedName.data());
return
qualifiedName
;
};
QCString
Definition
::
localName
()
const
{
return
m_localName
;
}
src/definition.h
View file @
75fed736
...
@@ -47,26 +47,28 @@ class Definition
...
@@ -47,26 +47,28 @@ class Definition
/*! Destroys the definition */
/*! Destroys the definition */
virtual
~
Definition
();
virtual
~
Definition
();
/*! Returns the name of the definition */
/*! Returns the name of the definition */
const
QCString
&
name
()
const
{
return
n
;
}
const
QCString
&
name
()
const
{
return
m_name
;
}
/*! Returns the base name of the output file that contains this
/*! Returns the base name of the output file that contains this
* definition.
* definition.
*/
*/
QCString
qualifiedName
()
const
;
QCString
localName
()
const
;
virtual
QCString
getOutputFileBase
()
const
=
0
;
virtual
QCString
getOutputFileBase
()
const
=
0
;
/*! Returns the name of the source listing of this file. */
/*! Returns the name of the source listing of this file. */
const
QCString
getSourceFileBase
()
const
{
ASSERT
(
0
);
return
"NULL"
;
}
const
QCString
getSourceFileBase
()
const
{
ASSERT
(
0
);
return
"NULL"
;
}
/*! Returns the detailed description of this definition */
/*! Returns the detailed description of this definition */
const
QCString
&
documentation
()
const
{
return
doc
;
}
const
QCString
&
documentation
()
const
{
return
m_
doc
;
}
/*! Returns the brief description of this definition */
/*! Returns the brief description of this definition */
const
QCString
&
briefDescription
()
const
{
return
brief
;
}
const
QCString
&
briefDescription
()
const
{
return
m_
brief
;
}
/*! Sets a new \a name for the definition */
/*! Sets a new \a name for the definition */
void
setName
(
const
char
*
name
)
{
n
=
name
;
}
void
setName
(
const
char
*
name
)
{
m_name
=
name
;
}
/*! Sets the documentation of this definition to \a d. */
/*! Sets the documentation of this definition to \a d. */
void
setDocumentation
(
const
char
*
d
,
bool
stripWhiteSpace
=
TRUE
)
void
setDocumentation
(
const
char
*
d
,
bool
stripWhiteSpace
=
TRUE
)
{
{
if
(
stripWhiteSpace
)
if
(
stripWhiteSpace
)
doc
=
((
QCString
)
d
).
stripWhiteSpace
();
m_
doc
=
((
QCString
)
d
).
stripWhiteSpace
();
else
else
doc
=
d
;
m_
doc
=
d
;
}
}
/*! Sets the brief description of this definition to \a b.
/*! Sets the brief description of this definition to \a b.
* A dot is added to the sentence if not available.
* A dot is added to the sentence if not available.
...
@@ -77,9 +79,9 @@ class Definition
...
@@ -77,9 +79,9 @@ class Definition
virtual
bool
isLinkableInProject
()
=
0
;
virtual
bool
isLinkableInProject
()
=
0
;
virtual
bool
isLinkable
()
=
0
;
virtual
bool
isLinkable
()
=
0
;
bool
isReference
()
const
{
return
!
ref
.
isEmpty
();
}
bool
isReference
()
const
{
return
!
m_
ref
.
isEmpty
();
}
void
setReference
(
const
char
*
r
)
{
ref
=
r
;
}
void
setReference
(
const
char
*
r
)
{
m_
ref
=
r
;
}
QCString
getReference
()
const
{
return
ref
;
}
QCString
getReference
()
const
{
return
m_
ref
;
}
/*! Add the list of anchors that mark the sections that are found in the
/*! Add the list of anchors that mark the sections that are found in the
* documentation.
* documentation.
...
@@ -90,13 +92,13 @@ class Definition
...
@@ -90,13 +92,13 @@ class Definition
// source references
// source references
void
setBodySegment
(
int
bls
,
int
ble
)
void
setBodySegment
(
int
bls
,
int
ble
)
{
{
startBodyLine
=
bls
;
m_
startBodyLine
=
bls
;
endBodyLine
=
ble
;
m_
endBodyLine
=
ble
;
}
}
void
setBodyDef
(
FileDef
*
fd
)
{
bodyDef
=
fd
;
}
void
setBodyDef
(
FileDef
*
fd
)
{
m_
bodyDef
=
fd
;
}
int
getStartBodyLine
()
const
{
return
startBodyLine
;
}
int
getStartBodyLine
()
const
{
return
m_
startBodyLine
;
}
int
getEndBodyLine
()
const
{
return
endBodyLine
;
}
int
getEndBodyLine
()
const
{
return
m_
endBodyLine
;
}
FileDef
*
getBodyDef
()
{
return
bodyDef
;
}
FileDef
*
getBodyDef
()
{
return
m_
bodyDef
;
}
void
writeSourceDef
(
OutputList
&
ol
,
const
char
*
scopeName
);
void
writeSourceDef
(
OutputList
&
ol
,
const
char
*
scopeName
);
void
writeInlineCode
(
OutputList
&
ol
,
const
char
*
scopeName
);
void
writeInlineCode
(
OutputList
&
ol
,
const
char
*
scopeName
);
void
writeSourceRefs
(
OutputList
&
ol
,
const
char
*
scopeName
);
void
writeSourceRefs
(
OutputList
&
ol
,
const
char
*
scopeName
);
...
@@ -113,28 +115,40 @@ class Definition
...
@@ -113,28 +115,40 @@ class Definition
int
bugId
()
const
{
return
m_bugId
;
}
int
bugId
()
const
{
return
m_bugId
;
}
/*! returns the file in which this definition was found */
/*! returns the file in which this definition was found */
QCString
getDefFileName
()
const
{
return
defFileName
;
}
QCString
getDefFileName
()
const
{
return
m_
defFileName
;
}
/*! returns the line number at which the definition was found */
/*! returns the line number at which the definition was found */
int
getDefLine
()
const
{
return
defLine
;
}
int
getDefLine
()
const
{
return
m_defLine
;
}
virtual
Definition
*
findInnerCompound
(
const
char
*
name
);
virtual
Definition
*
getOuterScope
()
{
return
m_outerScope
;
}
virtual
void
addInnerCompound
(
Definition
*
d
);
virtual
void
setOuterScope
(
Definition
*
d
)
{
m_outerScope
=
d
;
}
protected
:
protected
:
int
startBodyLine
;
// line number of the start of the definition
int
m_
startBodyLine
;
// line number of the start of the definition
int
endBodyLine
;
// line number of the end of the definition
int
m_
endBodyLine
;
// line number of the end of the definition
FileDef
*
bodyDef
;
// file definition containing the function body
FileDef
*
m_
bodyDef
;
// file definition containing the function body
// where the item was found
// where the item was found
QCString
defFileName
;
QCString
m_defFileName
;
int
defLine
;
int
m_defLine
;
/*! The class, namespace in which this class is located
*/
Definition
*
m_outerScope
;
QCString
m_name
;
// name of the definition
QCString
m_localName
;
// local (unqualified) name of the definition
// in the future m_name should become m_localName
private
:
private
:
QCString
n
;
// name of the definition
//QCString m_qualifiedName;
// name of the definition
QCString
brief
;
// brief description
QCString
m_
brief
;
// brief description
QCString
doc
;
// detailed description
QCString
m_
doc
;
// detailed description
QCString
ref
;
// reference to external documentation
QCString
m_
ref
;
// reference to external documentation
SectionDict
*
sectionDict
;
// dictionary of all sections
SectionDict
*
m_
sectionDict
;
// dictionary of all sections
MemberList
*
sourceRefList
;
// list of entities that refer to this
MemberList
*
m_
sourceRefList
;
// list of entities that refer to this
// entity in their definition
// entity in their definition
MemberDict
*
sourceRefDict
;
MemberDict
*
m_
sourceRefDict
;
int
m_testId
;
// id for test list item
int
m_testId
;
// id for test list item
int
m_todoId
;
// id for todo list item
int
m_todoId
;
// id for todo list item
int
m_bugId
;
// id for bug list item
int
m_bugId
;
// id for bug list item
...
...
src/diagram.cpp
View file @
75fed736
...
@@ -916,7 +916,7 @@ void TreeDiagram::drawConnectors(QTextStream &t,Image *image,
...
@@ -916,7 +916,7 @@ void TreeDiagram::drawConnectors(QTextStream &t,Image *image,
void
clearVisitFlags
()
void
clearVisitFlags
()
{
{
Class
ListIterator
cli
(
Doxygen
::
classLis
t
);
Class
SDict
::
Iterator
cli
(
Doxygen
::
classSDic
t
);
ClassDef
*
cd
;
ClassDef
*
cd
;
for
(;(
cd
=
cli
.
current
());
++
cli
)
for
(;(
cd
=
cli
.
current
());
++
cli
)
{
{
...
...
src/doc.l
View file @
75fed736
...
@@ -831,6 +831,7 @@ HREF [hH][rR][eE][fF]
...
@@ -831,6 +831,7 @@ HREF [hH][rR][eE][fF]
I [iI]
I [iI]
IMG [iI][mM][gG]
IMG [iI][mM][gG]
INPUT [iI][nN][pP][uU][tT]
INPUT [iI][nN][pP][uU][tT]
KBD [kK][bB][dD]
LI [lL][iI]
LI [lL][iI]
META [mM][eE][tT][aA]
META [mM][eE][tT][aA]
MULTICOL [mM][uU][lL][tT][iI][cC][oO][lL]
MULTICOL [mM][uU][lL][tT][iI][cC][oO][lL]
...
@@ -2099,6 +2100,8 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG})
...
@@ -2099,6 +2100,8 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG})
<DocScan>"</"{LI}{ATTR}">"
<DocScan>"</"{LI}{ATTR}">"
<DocScan>"<"{TT}{ATTR}">" { outDoc->startTypewriter(); }
<DocScan>"<"{TT}{ATTR}">" { outDoc->startTypewriter(); }
<DocScan>"</"{TT}{ATTR}">" { outDoc->endTypewriter(); }
<DocScan>"</"{TT}{ATTR}">" { outDoc->endTypewriter(); }
<DocScan>"<"{KBD}{ATTR}">" { outDoc->startTypewriter(); }
<DocScan>"</"{KBD}{ATTR}">" { outDoc->endTypewriter(); }
<DocScan>"<"{EM}{ATTR}">" { outDoc->startEmphasis(); }
<DocScan>"<"{EM}{ATTR}">" { outDoc->startEmphasis(); }
<DocScan>"</"{EM}{ATTR}">" { outDoc->endEmphasis(); }
<DocScan>"</"{EM}{ATTR}">" { outDoc->endEmphasis(); }
<DocScan>"<"{HR}{ATTR}">" { outDoc->writeRuler(); }
<DocScan>"<"{HR}{ATTR}">" { outDoc->writeRuler(); }
...
...
src/dot.cpp
View file @
75fed736
...
@@ -25,6 +25,7 @@
...
@@ -25,6 +25,7 @@
#include "config.h"
#include "config.h"
#include "language.h"
#include "language.h"
#include "scanner.h"
#include "scanner.h"
#include "defargs.h"
#include <qdir.h>
#include <qdir.h>
#include <qfile.h>
#include <qfile.h>
...
@@ -175,6 +176,141 @@ static bool isLeaf(ClassDef *cd)
...
@@ -175,6 +176,141 @@ static bool isLeaf(ClassDef *cd)
return
TRUE
;
return
TRUE
;
}
}
/*! Builds a mapping from formal arguments of class \a tcd to the
* actual arguments stored in templSpec. To properly initialize
* the mapping with the default template values
* ClassDef::initTemplateMapping() is called once for each class graph
* (the ClassDef::visited flag is used for this).
*/
static
void
setTemplateInstance
(
QCString
templSpec
,
ClassDef
*
tcd
)
{
//printf("====== setTemplateInstance(templ=%s,class=%s)\n",templSpec.data(),tcd->name().data());
if
(
!
templSpec
.
isEmpty
())
{
//if (!tcd->visited)
//{
// tcd->visited=TRUE;
//}
ArgumentList
*
tempArgList
=
new
ArgumentList
;
stringToArgumentList
(
templSpec
,
tempArgList
);
ArgumentListIterator
ali
(
*
tempArgList
);
Argument
*
arg
;
uint
count
=
0
;
for
(
ali
.
toFirst
();(
arg
=
ali
.
current
());
++
ali
,
++
count
)
{
ArgumentList
*
formalArgList
=
tcd
->
templateArguments
();
Argument
*
formalArg
=
0
;
//printf("arg->type=%s count=%d formalArgList=%p\n",
// arg->type.data(),count,formalArgList);
if
(
formalArgList
&&
formalArgList
->
count
()
>
count
&&
(
formalArg
=
formalArgList
->
at
(
count
)))
{
if
(
formalArg
->
name
!=
arg
->
type
)
{
tcd
->
setTemplateArgumentMapping
(
formalArg
->
name
,
arg
->
type
);
//printf("%s->setTemplateInstantation(%s,%s)\n",tcd->name().data(),
// formalArg->name.data(),arg->type.data());
}
}
}
delete
tempArgList
;
}
}
/*! Substitutes the formal template argument list \a templSpec
* of class \a cd with the actual template arguments.
* The mapping from formal to actual template is assumed to be stored
* in \a cd using setTemplateInstance().
*/
static
QCString
substituteTemplateSpec
(
ClassDef
*
cd
,
const
QCString
&
templSpec
)
{
QCString
result
;
if
(
!
templSpec
.
isEmpty
())
{
ArgumentList
*
tempArgList
=
new
ArgumentList
;
stringToArgumentList
(
templSpec
,
tempArgList
);
ArgumentListIterator
ali
(
*
tempArgList
);
Argument
*
arg
;
bool
first
=
TRUE
;
for
(
ali
.
toFirst
();(
arg
=
ali
.
current
());)
{
if
(
first
)
result
=
"<"
,
first
=
FALSE
;
QCString
actual
=
cd
->
getTemplateArgumentMapping
(
arg
->
type
);
if
(
!
actual
.
isEmpty
())
{
result
+=
actual
;
}
else
{
result
+=
arg
->
type
;
}
++
ali
;
if
(
ali
.
current
())
result
+=
","
;
else
result
+=
">"
;
}
delete
tempArgList
;
}
//printf("substituteTemplateSpec(%s,%s)=`%s'\n",cd->name().data(),templSpec.data(),result.data());
return
removeRedundantWhiteSpace
(
result
);
}
/*! Determines the actual template instance of template class \a tcd that
* relates to class \a cd. The result is stored in \a tcd.
* \param cd A class
* \param tcd A template base class
* \param templSpec Actual template parameter list to be used for tcd
* \param result resulting instance class
* \param actualArg actual template instance name of the resulting class
*/
static
void
computeTemplateInstance
(
ClassDef
*
cd
,
ClassDef
*
tcd
,
const
QCString
templSpec
,
ClassDef
*&
result
,
QCString
&
actualArg
)
{
//printf("====== computeTemplateInstance(%s,base=%s,templ=%s)\n",
// cd->name().data(),tcd->name().data(),templSpec.data());
// store the specific instance inside the class
setTemplateInstance
(
templSpec
,
tcd
);
int
tArgNum
=
tcd
->
isTemplateBaseClass
();
if
(
tArgNum
!=-
1
)
{
//printf("tArgNum=%d\n",tArgNum);
ArgumentList
*
formalArgList
=
cd
->
templateArguments
();
if
(
formalArgList
)
{
//printf("formalArgList=%p\n",formalArgList);
Argument
*
formalArg
=
formalArgList
->
at
(
tArgNum
);
if
(
formalArg
)
{
//printf("formalArg=%s\n",formalArg->name.data());
actualArg
=
cd
->
getTemplateArgumentMapping
(
formalArg
->
name
);
//printf("ActualArg=%s\n",actualArg.data());
int
pos
=
0
;
QCString
name
;
QCString
templSpec
;
while
(
extractClassNameFromType
(
actualArg
,
pos
,
name
,
templSpec
))
{
//printf("name=%s templSpec=%s\n",name.data(),templSpec.data());
ClassDef
*
acd
=
getResolvedClass
(
name
);
if
(
acd
&&
!
templSpec
.
isEmpty
())
{
// store specific template instance in the class
setTemplateInstance
(
templSpec
,
acd
);
}
if
(
acd
)
{
result
=
acd
;
actualArg
=
acd
->
name
()
+
templSpec
;
return
;
}
}
}
}
}
actualArg
.
resize
(
0
);
result
=
0
;
}
//--------------------------------------------------------------------
//--------------------------------------------------------------------
class
DotNodeList
:
public
QList
<
DotNode
>
class
DotNodeList
:
public
QList
<
DotNode
>
...
@@ -693,8 +829,8 @@ DotGfxHierarchyTable::DotGfxHierarchyTable()
...
@@ -693,8 +829,8 @@ DotGfxHierarchyTable::DotGfxHierarchyTable()
// build a graph with each class as a node and the inheritance relations
// build a graph with each class as a node and the inheritance relations
// as edges
// as edges
initClassHierarchy
(
&
Doxygen
::
class
Lis
t
);
initClassHierarchy
(
&
Doxygen
::
class
SDic
t
);
Class
ListIterator
cli
(
Doxygen
::
classLis
t
);
Class
SDict
::
Iterator
cli
(
Doxygen
::
classSDic
t
);
ClassDef
*
cd
;
ClassDef
*
cd
;
for
(
cli
.
toLast
();(
cd
=
cli
.
current
());
--
cli
)
for
(
cli
.
toLast
();(
cd
=
cli
.
current
());
--
cli
)
{
{
...
@@ -784,8 +920,8 @@ int DotClassGraph::m_curNodeNumber;
...
@@ -784,8 +920,8 @@ int DotClassGraph::m_curNodeNumber;
void
DotClassGraph
::
addClass
(
ClassDef
*
cd
,
DotNode
*
n
,
int
prot
,
void
DotClassGraph
::
addClass
(
ClassDef
*
cd
,
DotNode
*
n
,
int
prot
,
const
char
*
label
,
int
distance
,
const
char
*
usedName
,
const
char
*
templSpec
,
bool
base
)
const
char
*
label
,
int
distance
,
const
char
*
usedName
,
const
char
*
templSpec
,
bool
base
)
{
{
//printf("
:: DoxGfxUsageGraph::addClass(class=%s,parent=%s,prot=%d,label=%s,dist
=%d)\n",
//printf("
DoxClassGraph::addClass(class=%s,parent=%s,prot=%d,label=%s,dist=%d,usedName=%s,templSpec=%s,base
=%d)\n",
// cd->name().data(),n->m_label.data(),prot,label,distance);
// cd->name().data(),n->m_label.data(),prot,label,distance
,usedName,templSpec,base
);
int
edgeStyle
=
label
?
EdgeInfo
::
Dashed
:
EdgeInfo
::
Solid
;
int
edgeStyle
=
label
?
EdgeInfo
::
Dashed
:
EdgeInfo
::
Solid
;
QCString
className
;
QCString
className
;
if
(
usedName
)
// name is a typedef
if
(
usedName
)
// name is a typedef
...
@@ -850,11 +986,25 @@ void DotClassGraph::buildGraph(ClassDef *cd,DotNode *n,int distance,bool base)
...
@@ -850,11 +986,25 @@ void DotClassGraph::buildGraph(ClassDef *cd,DotNode *n,int distance,bool base)
BaseClassDef
*
bcd
;
BaseClassDef
*
bcd
;
for
(
;
(
bcd
=
bcli
.
current
())
;
++
bcli
)
for
(
;
(
bcd
=
bcli
.
current
())
;
++
bcli
)
{
{
//printf("
addClass: base=%s this=%s templ=%s\n",bcd->classDef->name().data()
,
//printf("
-------- inheritance relation %s->%s templ=`%s'\n"
,
//
cd
->name().data(),bcd->templSpecifiers.data());
//
cd->name().data(),bcd->classDef
->name().data(),bcd->templSpecifiers.data());
QCString
templSpec
;
QCString
templSpec
;
if
(
base
)
templSpec
=
bcd
->
templSpecifiers
;
if
(
base
)
templSpec
=
substituteTemplateSpec
(
addClass
(
bcd
->
classDef
,
n
,
bcd
->
prot
,
0
,
distance
,
bcd
->
usedName
,
templSpec
,
base
);
cd
,
bcd
->
templSpecifiers
);
ClassDef
*
acd
=
0
;
QCString
actualArg
;
computeTemplateInstance
(
cd
,
bcd
->
classDef
,
templSpec
,
acd
,
actualArg
);
//printf("acd=%p actualArg=%s\n",acd,actualArg.data());
if
(
acd
)
{
addClass
(
acd
,
n
,
bcd
->
prot
,
0
,
distance
,
actualArg
,
templSpec
,
base
);
}
else
{
addClass
(
bcd
->
classDef
,
n
,
bcd
->
prot
,
0
,
distance
,
bcd
->
usedName
,
templSpec
,
base
);
}
}
}
if
(
m_graphType
!=
Inheritance
)
if
(
m_graphType
!=
Inheritance
)
{
{
...
@@ -883,8 +1033,25 @@ void DotClassGraph::buildGraph(ClassDef *cd,DotNode *n,int distance,bool base)
...
@@ -883,8 +1033,25 @@ void DotClassGraph::buildGraph(ClassDef *cd,DotNode *n,int distance,bool base)
label
+=
QCString
(
"
\\
n"
)
+
s
;
label
+=
QCString
(
"
\\
n"
)
+
s
;
}
}
}
}
QCString
actualArg
;
ClassDef
*
acd
=
0
;
//printf("-------- usage relation %s->%s templ=`%s'\n",
// cd->name().data(),ucd->classDef->name().data(),
// ucd->templSpecifiers.data());
QCString
templSpec
=
substituteTemplateSpec
(
cd
,
ucd
->
templSpecifiers
);
computeTemplateInstance
(
cd
,
ucd
->
classDef
,
templSpec
,
acd
,
actualArg
);
if
(
acd
)
{
addClass
(
acd
,
n
,
EdgeInfo
::
Black
,
label
,
distance
,
actualArg
,
templSpec
,
base
);
}
else
{
//printf("Found label=`%s'\n",label.data());
//printf("Found label=`%s'\n",label.data());
addClass
(
ucd
->
classDef
,
n
,
EdgeInfo
::
Black
,
label
,
distance
,
0
,
ucd
->
templSpecifiers
,
base
);
addClass
(
ucd
->
classDef
,
n
,
EdgeInfo
::
Black
,
label
,
distance
,
0
,
templSpec
,
base
);
}
}
}
}
}
}
}
...
@@ -906,6 +1073,11 @@ DotClassGraph::DotClassGraph(ClassDef *cd,GraphType t,int maxRecursionDepth)
...
@@ -906,6 +1073,11 @@ DotClassGraph::DotClassGraph(ClassDef *cd,GraphType t,int maxRecursionDepth)
);
);
m_usedNodes
=
new
QDict
<
DotNode
>
(
1009
);
m_usedNodes
=
new
QDict
<
DotNode
>
(
1009
);
m_usedNodes
->
insert
(
cd
->
name
(),
m_startNode
);
m_usedNodes
->
insert
(
cd
->
name
(),
m_startNode
);
ClassSDict
::
Iterator
cli
(
Doxygen
::
classSDict
);
ClassDef
*
icd
;
for
(
cli
.
toFirst
();(
icd
=
cli
.
current
());
++
cli
)
icd
->
initTemplateMapping
();
//printf("Root node %s\n",cd->name().data());
//printf("Root node %s\n",cd->name().data());
if
(
m_recDepth
>
0
)
if
(
m_recDepth
>
0
)
{
{
...
...
src/doxygen.cpp
View file @
75fed736
...
@@ -65,8 +65,8 @@
...
@@ -65,8 +65,8 @@
#define pclose _pclose
#define pclose _pclose
#endif
#endif
Class
List
Doxygen
::
classList
;
// all documented classes
Class
SDict
Doxygen
::
classSDict
(
1009
);
Class
Dict
Doxygen
::
classDict
(
1009
);
Class
List
Doxygen
::
hiddenClasses
;
NamespaceList
Doxygen
::
namespaceList
;
// all namespaces
NamespaceList
Doxygen
::
namespaceList
;
// all namespaces
NamespaceDict
Doxygen
::
namespaceDict
(
257
);
NamespaceDict
Doxygen
::
namespaceDict
(
257
);
...
@@ -107,6 +107,7 @@ QIntDict<QCString> Doxygen::memberDocDict(1009); // dictionary of the member
...
@@ -107,6 +107,7 @@ QIntDict<QCString> Doxygen::memberDocDict(1009); // dictionary of the member
PageInfo
*
Doxygen
::
mainPage
=
0
;
PageInfo
*
Doxygen
::
mainPage
=
0
;
QTextStream
Doxygen
::
tagFile
;
QTextStream
Doxygen
::
tagFile
;
NamespaceDef
*
Doxygen
::
globalScope
=
new
NamespaceDef
(
"<globalScope>"
,
1
,
"<globalScope>"
);
static
StringList
inputFiles
;
static
StringList
inputFiles
;
static
StringDict
excludeNameDict
(
1009
);
// sections
static
StringDict
excludeNameDict
(
1009
);
// sections
...
@@ -119,7 +120,7 @@ void clearAll()
...
@@ -119,7 +120,7 @@ void clearAll()
excludeNameDict
.
clear
();
excludeNameDict
.
clear
();
delete
outputList
;
outputList
=
0
;
delete
outputList
;
outputList
=
0
;
Doxygen
::
class
Lis
t
.
clear
();
Doxygen
::
class
SDic
t
.
clear
();
Doxygen
::
namespaceList
.
clear
();
Doxygen
::
namespaceList
.
clear
();
Doxygen
::
pageSDict
->
clear
();
Doxygen
::
pageSDict
->
clear
();
Doxygen
::
exampleSDict
->
clear
();
Doxygen
::
exampleSDict
->
clear
();
...
@@ -128,7 +129,7 @@ void clearAll()
...
@@ -128,7 +129,7 @@ void clearAll()
Doxygen
::
inputNameList
.
clear
();
Doxygen
::
inputNameList
.
clear
();
Doxygen
::
groupList
.
clear
();
Doxygen
::
groupList
.
clear
();
Doxygen
::
formulaList
.
clear
();
Doxygen
::
formulaList
.
clear
();
Doxygen
::
classDict
.
clear
();
Doxygen
::
class
S
Dict
.
clear
();
Doxygen
::
namespaceDict
.
clear
();
Doxygen
::
namespaceDict
.
clear
();
Doxygen
::
memberNameDict
.
clear
();
Doxygen
::
memberNameDict
.
clear
();
Doxygen
::
functionNameDict
.
clear
();
Doxygen
::
functionNameDict
.
clear
();
...
@@ -143,6 +144,7 @@ void clearAll()
...
@@ -143,6 +144,7 @@ void clearAll()
Doxygen
::
formulaNameDict
.
clear
();
Doxygen
::
formulaNameDict
.
clear
();
Doxygen
::
tagDestinationDict
.
clear
();
Doxygen
::
tagDestinationDict
.
clear
();
delete
Doxygen
::
mainPage
;
Doxygen
::
mainPage
=
0
;
delete
Doxygen
::
mainPage
;
Doxygen
::
mainPage
=
0
;
}
}
void
statistics
()
void
statistics
()
...
@@ -155,8 +157,8 @@ void statistics()
...
@@ -155,8 +157,8 @@ void statistics()
Doxygen
::
exampleNameDict
->
statistics
();
Doxygen
::
exampleNameDict
->
statistics
();
fprintf
(
stderr
,
"--- imageNameDict stats ----
\n
"
);
fprintf
(
stderr
,
"--- imageNameDict stats ----
\n
"
);
Doxygen
::
imageNameDict
->
statistics
();
Doxygen
::
imageNameDict
->
statistics
();
fprintf
(
stderr
,
"--- classDict stats ----
\n
"
);
//
fprintf(stderr,"--- classDict stats ----\n");
Doxygen
::
class
Dict
.
statistics
();
//Doxygen::classS
Dict.statistics();
fprintf
(
stderr
,
"--- namespaceDict stats ----
\n
"
);
fprintf
(
stderr
,
"--- namespaceDict stats ----
\n
"
);
Doxygen
::
namespaceDict
.
statistics
();
Doxygen
::
namespaceDict
.
statistics
();
fprintf
(
stderr
,
"--- memberNameDict stats ----
\n
"
);
fprintf
(
stderr
,
"--- memberNameDict stats ----
\n
"
);
...
@@ -639,6 +641,62 @@ static bool addNamespace(Entry *root,ClassDef *cd)
...
@@ -639,6 +641,62 @@ static bool addNamespace(Entry *root,ClassDef *cd)
return
FALSE
;
return
FALSE
;
}
}
static
Definition
*
findScope
(
Entry
*
root
,
int
level
=
0
)
{
if
(
root
==
0
)
return
0
;
//printf("start findScope name=%s\n",root->name.data());
Definition
*
result
=
0
;
if
(
root
->
section
&
Entry
::
SCOPE_MASK
)
{
result
=
findScope
(
root
->
parent
,
level
+
1
);
// traverse to the root of the tree
if
(
result
)
{
//printf("Found %s inside %s at level %d\n",root->name.data(),result->name().data(),level);
// TODO: look at template arguments
result
=
result
->
findInnerCompound
(
root
->
name
);
}
else
// reached the global scope
{
// TODO: look at template arguments
result
=
Doxygen
::
globalScope
->
findInnerCompound
(
root
->
name
);
//printf("Found in globalScope %s at level %d\n",result->name().data(),level);
}
}
//printf("end findScope(%s,%d)=%s\n",root->name.data(),
// level,result==0 ? "<none>" : result->name().data());
return
result
;
}
static
Definition
*
findScopeFromQualifiedName
(
Definition
*
startScope
,
const
QCString
&
n
)
{
//printf("findScopeFromName(%s,%s)\n",startScope ? startScope->name().data() : 0, n.data());
QCString
name
(
n
);
if
(
startScope
==
0
)
startScope
=
Doxygen
::
globalScope
;
int
i
=
name
.
find
(
"::"
);
if
(
i
==-
1
)
{
return
startScope
;
}
QCString
scope
;
while
((
i
=
name
.
find
(
"::"
))
!=-
1
)
{
int
ti
=
name
.
find
(
'<'
);
if
(
ti
!=-
1
&&
ti
<
i
)
i
=
ti
;
// strip template specifiers
QCString
nestedNameSpecifier
=
name
.
left
(
i
);
//Definition *oldScope = startScope;
startScope
=
startScope
->
findInnerCompound
(
nestedNameSpecifier
);
if
(
startScope
==
0
)
{
//printf("name %s not found in scope %s\n",nestedNameSpecifier.data(),oldScope->name().data());
return
0
;
}
name
=
name
.
right
(
name
.
length
()
-
i
-
2
);
}
//printf("findScopeFromName() result=%s\n",startScope ? startScope->name().data() : 0);
return
startScope
;
}
//----------------------------------------------------------------------
//----------------------------------------------------------------------
// build a list of all classes mentioned in the documentation
// build a list of all classes mentioned in the documentation
// and all classes that have a documentation block before their definition.
// and all classes that have a documentation block before their definition.
...
@@ -737,6 +795,7 @@ static void buildClassList(Entry *root)
...
@@ -737,6 +795,7 @@ static void buildClassList(Entry *root)
}
}
else
// new class
else
// new class
{
{
ClassDef
::
CompoundType
sec
=
ClassDef
::
Class
;
ClassDef
::
CompoundType
sec
=
ClassDef
::
Class
;
switch
(
root
->
section
)
switch
(
root
->
section
)
{
{
...
@@ -823,10 +882,27 @@ static void buildClassList(Entry *root)
...
@@ -823,10 +882,27 @@ static void buildClassList(Entry *root)
// add class to the list
// add class to the list
Doxygen
::
classList
.
inSort
(
cd
);
//printf("ClassDict.insert(%s)\n",resolveDefines(fullName).data());
//printf("ClassDict.insert(%s)\n",resolveDefines(fullName).data());
//classDict.insert(resolveDefines(fullName),cd);
Doxygen
::
classSDict
.
inSort
(
fullName
,
cd
);
Doxygen
::
classDict
.
insert
(
fullName
,
cd
);
// also add class to the correct structural context
Definition
*
d
=
findScopeFromQualifiedName
(
Doxygen
::
globalScope
,
fullName
);
if
(
d
==
0
)
{
// TODO: Due to the order in which the tag file is written
// a nested class can be found before its parent!
//
//warn(root->fileName,root->startLine,
// "Warning: Internal inconsistency: scope for class %s not "
// "found!\n",fullName.data()
// );
}
else
{
//printf("****** adding %s to scope %s\n",cd->name().data(),d->name().data());
d
->
addInnerCompound
(
cd
);
cd
->
setOuterScope
(
d
);
}
}
}
}
}
}
}
...
@@ -927,6 +1003,23 @@ static void buildNamespaceList(Entry *root)
...
@@ -927,6 +1003,23 @@ static void buildNamespaceList(Entry *root)
Doxygen
::
namespaceList
.
inSort
(
nd
);
Doxygen
::
namespaceList
.
inSort
(
nd
);
Doxygen
::
namespaceDict
.
insert
(
fullName
,
nd
);
Doxygen
::
namespaceDict
.
insert
(
fullName
,
nd
);
// also add namespace to the correct structural context
Definition
*
d
=
findScopeFromQualifiedName
(
Doxygen
::
globalScope
,
fullName
);
if
(
d
==
0
)
{
// TODO: Due to the order in which the tag file is written
// a nested class can be found before its parent!
//
//warn(root->fileName,root->startLine,
// "Warning: Internal inconsistency: scope for namespace %s not "
// "found!\n",fullName.data()
// );
}
else
{
d
->
addInnerCompound
(
nd
);
nd
->
setOuterScope
(
d
);
}
}
}
}
}
}
}
...
@@ -2247,8 +2340,11 @@ static void replaceNamespaceAliases(QCString &scope,int i)
...
@@ -2247,8 +2340,11 @@ static void replaceNamespaceAliases(QCString &scope,int i)
}
}
static
bool
findBaseClassRelation
(
Entry
*
root
,
ClassDef
*
cd
,
static
bool
findBaseClassRelation
(
Entry
*
root
,
ClassDef
*
cd
,
BaseInfo
*
bi
,
BaseInfo
*
bi
,
int
isTemplBaseClass
,
bool
insertUndocumented
bool
insertUndocumented
)
)
{
{
...
@@ -2416,7 +2512,7 @@ static bool findBaseClassRelation(Entry *root,ClassDef *cd,
...
@@ -2416,7 +2512,7 @@ static bool findBaseClassRelation(Entry *root,ClassDef *cd,
}
}
}
}
}
}
if
(
found
)
if
(
isTemplBaseClass
==-
1
&&
found
)
{
{
Debug
::
print
(
Debug
::
Classes
,
0
,
" Documented base class `%s'
\n
"
,
bi
->
name
.
data
());
Debug
::
print
(
Debug
::
Classes
,
0
,
" Documented base class `%s'
\n
"
,
bi
->
name
.
data
());
// add base class to this class
// add base class to this class
...
@@ -2427,7 +2523,7 @@ static bool findBaseClassRelation(Entry *root,ClassDef *cd,
...
@@ -2427,7 +2523,7 @@ static bool findBaseClassRelation(Entry *root,ClassDef *cd,
baseClass
->
insertSubClass
(
cd
,
bi
->
prot
,
bi
->
virt
,
templSpec
);
baseClass
->
insertSubClass
(
cd
,
bi
->
prot
,
bi
->
virt
,
templSpec
);
return
TRUE
;
return
TRUE
;
}
}
else
if
(
scopeOffset
==
0
&&
insertUndocumented
)
else
if
(
(
scopeOffset
==
0
&&
insertUndocumented
)
||
isTemplBaseClass
!=-
1
)
{
{
Debug
::
print
(
Debug
::
Classes
,
0
,
Debug
::
print
(
Debug
::
Classes
,
0
,
" Undocumented base class `%s' baseClassName=%s
\n
"
,
" Undocumented base class `%s' baseClassName=%s
\n
"
,
...
@@ -2441,12 +2537,18 @@ static bool findBaseClassRelation(Entry *root,ClassDef *cd,
...
@@ -2441,12 +2537,18 @@ static bool findBaseClassRelation(Entry *root,ClassDef *cd,
baseClass
->
insertSubClass
(
cd
,
bi
->
prot
,
bi
->
virt
,
templSpec
);
baseClass
->
insertSubClass
(
cd
,
bi
->
prot
,
bi
->
virt
,
templSpec
);
// the undocumented base was found in this file
// the undocumented base was found in this file
baseClass
->
insertUsedFile
(
root
->
fileName
);
baseClass
->
insertUsedFile
(
root
->
fileName
);
// is this an inherited template argument?
//printf("%s->setIsTemplateBaseClass(%d)\n",baseClass->name().data(),isTemplBaseClass);
baseClass
->
setIsTemplateBaseClass
(
isTemplBaseClass
);
// add class to the list
// add class to the list
//classList.inSort(baseClass);
if
(
isTemplBaseClass
==-
1
)
Doxygen
::
classList
.
inSort
(
baseClass
);
{
//printf("ClassDict.insert(%s)\n",resolveDefines(fullName).data());
Doxygen
::
classSDict
.
inSort
(
baseClassName
,
baseClass
);
//classDict.insert(resolveDefines(bi->name),baseClass);
}
Doxygen
::
classDict
.
insert
(
baseClassName
,
baseClass
);
else
{
Doxygen
::
hiddenClasses
.
append
(
baseClass
);
}
return
TRUE
;
return
TRUE
;
}
}
else
else
...
@@ -2511,16 +2613,34 @@ static void computeClassRelations(Entry *root)
...
@@ -2511,16 +2613,34 @@ static void computeClassRelations(Entry *root)
cd
->
visited
=
TRUE
;
// mark class as used
cd
->
visited
=
TRUE
;
// mark class as used
if
(
root
->
extends
->
count
()
>
0
)
// there are base classes
if
(
root
->
extends
->
count
()
>
0
)
// there are base classes
{
{
// The base class could ofcouse also be a non-nested class
// The base class could ofcouse also be a non-nested class
QList
<
BaseInfo
>
*
baseList
=
root
->
extends
;
QList
<
BaseInfo
>
*
baseList
=
root
->
extends
;
BaseInfo
*
bi
=
baseList
->
first
();
BaseInfo
*
bi
=
baseList
->
first
();
while
(
bi
)
// for each base class
while
(
bi
)
// for each base class
{
{
// check if the base class is a template argument
int
isTemplBaseClass
=
-
1
;
ArgumentList
*
tl
=
cd
->
templateArguments
();
if
(
tl
)
{
ArgumentListIterator
ali
(
*
tl
);
Argument
*
arg
;
int
count
=
0
;
for
(
ali
.
toFirst
();(
arg
=
ali
.
current
());
++
ali
,
++
count
)
{
if
(
arg
->
name
==
bi
->
name
)
// base class is a template argument
{
isTemplBaseClass
=
count
;
break
;
}
}
}
// find a documented base class in the correct scope
// find a documented base class in the correct scope
if
(
!
findBaseClassRelation
(
root
,
cd
,
bi
,
FALSE
))
if
(
!
findBaseClassRelation
(
root
,
cd
,
bi
,
isTemplBaseClass
,
FALSE
))
{
{
// no documented base class -> try to find an undocumented one
// no documented base class -> try to find an undocumented one
findBaseClassRelation
(
root
,
cd
,
bi
,
TRUE
);
findBaseClassRelation
(
root
,
cd
,
bi
,
isTemplBaseClass
,
TRUE
);
}
}
bi
=
baseList
->
next
();
bi
=
baseList
->
next
();
}
}
...
@@ -2550,11 +2670,11 @@ static void computeClassRelations(Entry *root)
...
@@ -2550,11 +2670,11 @@ static void computeClassRelations(Entry *root)
static
void
computeMemberReferences
()
static
void
computeMemberReferences
()
{
{
ClassDef
*
cd
=
Doxygen
::
classList
.
first
();
ClassSDict
::
Iterator
cli
(
Doxygen
::
classSDict
);
while
(
cd
)
ClassDef
*
cd
=
0
;
for
(
cli
.
toFirst
();(
cd
=
cli
.
current
());
++
cli
)
{
{
cd
->
computeAnchors
();
cd
->
computeAnchors
();
cd
=
Doxygen
::
classList
.
next
();
}
}
FileName
*
fn
=
Doxygen
::
inputNameList
.
first
();
FileName
*
fn
=
Doxygen
::
inputNameList
.
first
();
while
(
fn
)
while
(
fn
)
...
@@ -2585,14 +2705,14 @@ static void computeMemberReferences()
...
@@ -2585,14 +2705,14 @@ static void computeMemberReferences()
static
void
addTodoTestBugReferences
()
static
void
addTodoTestBugReferences
()
{
{
ClassDef
*
cd
=
Doxygen
::
classList
.
first
();
ClassSDict
::
Iterator
cli
(
Doxygen
::
classSDict
);
while
(
cd
)
ClassDef
*
cd
=
0
;
for
(
cli
.
toFirst
();(
cd
=
cli
.
current
());
++
cli
)
{
{
addRefItem
(
cd
->
todoId
(),
cd
->
testId
(),
cd
->
bugId
(),
addRefItem
(
cd
->
todoId
(),
cd
->
testId
(),
cd
->
bugId
(),
theTranslator
->
trClass
(
TRUE
,
TRUE
),
theTranslator
->
trClass
(
TRUE
,
TRUE
),
cd
->
getOutputFileBase
(),
cd
->
name
()
cd
->
getOutputFileBase
(),
cd
->
name
()
);
);
cd
=
Doxygen
::
classList
.
next
();
}
}
FileName
*
fn
=
Doxygen
::
inputNameList
.
first
();
FileName
*
fn
=
Doxygen
::
inputNameList
.
first
();
while
(
fn
)
while
(
fn
)
...
@@ -4115,10 +4235,9 @@ static void findEnums(Entry *root)
...
@@ -4115,10 +4235,9 @@ static void findEnums(Entry *root)
{
{
MemberNameIterator
fmni
(
*
fmn
);
MemberNameIterator
fmni
(
*
fmn
);
MemberDef
*
fmd
;
MemberDef
*
fmd
;
for
(
fmni
.
toFirst
();
for
(
fmni
.
toFirst
();
(
fmd
=
fmni
.
current
())
;
++
fmni
)
(
fmd
=
fmni
.
current
())
&&
fmd
->
isEnumValue
();
{
++
fmni
if
(
fmd
->
isEnumValue
())
)
// search for the scope with the right name
{
{
if
(
nd
&&
!
nd
->
name
().
isEmpty
()
&&
nd
->
name
().
at
(
0
)
!=
'@'
)
if
(
nd
&&
!
nd
->
name
().
isEmpty
()
&&
nd
->
name
().
at
(
0
)
!=
'@'
)
{
{
...
@@ -4143,6 +4262,8 @@ static void findEnums(Entry *root)
...
@@ -4143,6 +4262,8 @@ static void findEnums(Entry *root)
ClassDef
*
fcd
=
fmd
->
getClassDef
();
ClassDef
*
fcd
=
fmd
->
getClassDef
();
if
(
fcd
==
cd
)
// enum value is inside a class
if
(
fcd
==
cd
)
// enum value is inside a class
{
{
//printf("Inserting enum field %s in enum scope %s\n",
// fmd->name().data(),md->name().data());
md
->
insertEnumField
(
fmd
);
// add field def to list
md
->
insertEnumField
(
fmd
);
// add field def to list
fmd
->
setEnumScope
(
md
);
// cross ref with enum name
fmd
->
setEnumScope
(
md
);
// cross ref with enum name
}
}
...
@@ -4152,6 +4273,7 @@ static void findEnums(Entry *root)
...
@@ -4152,6 +4273,7 @@ static void findEnums(Entry *root)
}
}
}
}
}
}
}
else
else
{
{
EntryListIterator
eli
(
*
root
->
sublist
);
EntryListIterator
eli
(
*
root
->
sublist
);
...
@@ -4373,7 +4495,7 @@ static void computeMemberRelations()
...
@@ -4373,7 +4495,7 @@ static void computeMemberRelations()
static
void
computeClassImplUsageRelations
()
static
void
computeClassImplUsageRelations
()
{
{
ClassDef
*
cd
;
ClassDef
*
cd
;
Class
ListIterator
cli
(
Doxygen
::
classLis
t
);
Class
SDict
::
Iterator
cli
(
Doxygen
::
classSDic
t
);
for
(;(
cd
=
cli
.
current
());
++
cli
)
for
(;(
cd
=
cli
.
current
());
++
cli
)
{
{
cd
->
determineImplUsageRelation
();
cd
->
determineImplUsageRelation
();
...
@@ -4388,7 +4510,7 @@ static void buildCompleteMemberLists()
...
@@ -4388,7 +4510,7 @@ static void buildCompleteMemberLists()
{
{
ClassDef
*
cd
;
ClassDef
*
cd
;
// merge the member list of base classes into the inherited classes.
// merge the member list of base classes into the inherited classes.
Class
ListIterator
cli
(
Doxygen
::
classLis
t
);
Class
SDict
::
Iterator
cli
(
Doxygen
::
classSDic
t
);
for
(
cli
.
toFirst
();(
cd
=
cli
.
current
());
++
cli
)
for
(
cli
.
toFirst
();(
cd
=
cli
.
current
());
++
cli
)
{
{
if
(
!
cd
->
isReference
()
&&
// not an external class
if
(
!
cd
->
isReference
()
&&
// not an external class
...
@@ -4401,7 +4523,7 @@ static void buildCompleteMemberLists()
...
@@ -4401,7 +4523,7 @@ static void buildCompleteMemberLists()
// now sort the member list of all classes.
// now sort the member list of all classes.
for
(
cli
.
toFirst
();(
cd
=
cli
.
current
());
++
cli
)
for
(
cli
.
toFirst
();(
cd
=
cli
.
current
());
++
cli
)
{
{
cd
->
memberNameInfo
Lis
t
()
->
sort
();
cd
->
memberNameInfo
SDic
t
()
->
sort
();
}
}
}
}
...
@@ -4463,7 +4585,7 @@ static void generateFileDocs()
...
@@ -4463,7 +4585,7 @@ static void generateFileDocs()
static
void
addSourceReferences
()
static
void
addSourceReferences
()
{
{
// add source references for class definitions
// add source references for class definitions
Class
ListIterator
cli
(
Doxygen
::
classLis
t
);
Class
SDict
::
Iterator
cli
(
Doxygen
::
classSDic
t
);
ClassDef
*
cd
=
0
;
ClassDef
*
cd
=
0
;
for
(
cli
.
toFirst
();(
cd
=
cli
.
current
());
++
cli
)
for
(
cli
.
toFirst
();(
cd
=
cli
.
current
());
++
cli
)
{
{
...
@@ -4568,7 +4690,7 @@ static void generateClassDocs()
...
@@ -4568,7 +4690,7 @@ static void generateClassDocs()
msg
(
"Generating example index...
\n
"
);
msg
(
"Generating example index...
\n
"
);
}
}
Class
ListIterator
cli
(
Doxygen
::
classLis
t
);
Class
SDict
::
Iterator
cli
(
Doxygen
::
classSDic
t
);
for
(
;
cli
.
current
()
;
++
cli
)
for
(
;
cli
.
current
()
;
++
cli
)
{
{
ClassDef
*
cd
=
cli
.
current
();
ClassDef
*
cd
=
cli
.
current
();
...
@@ -4621,7 +4743,7 @@ static void inheritDocumentation()
...
@@ -4621,7 +4743,7 @@ static void inheritDocumentation()
static
void
addMembersToMemberGroup
()
static
void
addMembersToMemberGroup
()
{
{
// for each class
// for each class
Class
ListIterator
cli
(
Doxygen
::
classLis
t
);
Class
SDict
::
Iterator
cli
(
Doxygen
::
classSDic
t
);
ClassDef
*
cd
;
ClassDef
*
cd
;
for
(
;
(
cd
=
cli
.
current
())
;
++
cli
)
for
(
;
(
cd
=
cli
.
current
())
;
++
cli
)
{
{
...
@@ -4660,7 +4782,7 @@ static void addMembersToMemberGroup()
...
@@ -4660,7 +4782,7 @@ static void addMembersToMemberGroup()
static
void
distributeMemberGroupDocumentation
()
static
void
distributeMemberGroupDocumentation
()
{
{
// for each class
// for each class
Class
ListIterator
cli
(
Doxygen
::
classLis
t
);
Class
SDict
::
Iterator
cli
(
Doxygen
::
classSDic
t
);
ClassDef
*
cd
;
ClassDef
*
cd
;
for
(
;
(
cd
=
cli
.
current
())
;
++
cli
)
for
(
;
(
cd
=
cli
.
current
())
;
++
cli
)
{
{
...
@@ -4923,7 +5045,7 @@ static void buildPackageList(Entry *root)
...
@@ -4923,7 +5045,7 @@ static void buildPackageList(Entry *root)
static
void
addClassesToPackages
()
static
void
addClassesToPackages
()
{
{
ClassDef
*
cd
;
ClassDef
*
cd
;
Class
ListIterator
cli
(
Doxygen
::
classLis
t
);
Class
SDict
::
Iterator
cli
(
Doxygen
::
classSDic
t
);
for
(;(
cd
=
cli
.
current
());
++
cli
)
for
(;(
cd
=
cli
.
current
());
++
cli
)
{
{
PackageDef
*
pd
=
cd
->
packageDef
();
PackageDef
*
pd
=
cd
->
packageDef
();
...
@@ -4974,7 +5096,7 @@ static void generatePageDocs()
...
@@ -4974,7 +5096,7 @@ static void generatePageDocs()
if
(
!
pi
->
inGroup
&&
!
pi
->
isReference
())
if
(
!
pi
->
inGroup
&&
!
pi
->
isReference
())
{
{
msg
(
"Generating docs for page %s...
\n
"
,
pi
->
name
.
data
());
msg
(
"Generating docs for page %s...
\n
"
,
pi
->
name
.
data
());
outputList
->
disable
(
OutputGenerator
::
Man
);
//
outputList->disable(OutputGenerator::Man);
QCString
pageName
;
QCString
pageName
;
if
(
Config_getBool
(
"CASE_SENSE_NAMES"
))
if
(
Config_getBool
(
"CASE_SENSE_NAMES"
))
pageName
=
pi
->
name
.
copy
();
pageName
=
pi
->
name
.
copy
();
...
@@ -4982,19 +5104,29 @@ static void generatePageDocs()
...
@@ -4982,19 +5104,29 @@ static void generatePageDocs()
pageName
=
pi
->
name
.
lower
();
pageName
=
pi
->
name
.
lower
();
startFile
(
*
outputList
,
pageName
,
pi
->
title
);
startFile
(
*
outputList
,
pageName
,
pi
->
title
);
startFile
(
*
outputList
,
pageName
,
pi
->
title
);
// save old generator state and write title only to Man generator
outputList
->
pushGeneratorState
();
outputList
->
disableAllBut
(
OutputGenerator
::
Man
);
outputList
->
startTitleHead
(
pageName
);
outputList
->
endTitleHead
(
pageName
,
pageName
);
outputList
->
popGeneratorState
();
SectionInfo
*
si
=
0
;
SectionInfo
*
si
=
0
;
if
(
!
pi
->
title
.
isEmpty
()
&&
!
pi
->
name
.
isEmpty
()
&&
if
(
!
pi
->
title
.
isEmpty
()
&&
!
pi
->
name
.
isEmpty
()
&&
(
si
=
Doxygen
::
sectionDict
.
find
(
pi
->
name
))
!=
0
)
(
si
=
Doxygen
::
sectionDict
.
find
(
pi
->
name
))
!=
0
)
{
{
outputList
->
startSection
(
si
->
label
,
si
->
title
,
FALSE
);
outputList
->
startSection
(
si
->
label
,
si
->
title
,
si
->
type
==
SectionInfo
::
Subsection
);
outputList
->
docify
(
si
->
title
);
outputList
->
docify
(
si
->
title
);
outputList
->
endSection
(
si
->
label
,
FALSE
);
outputList
->
endSection
(
si
->
label
,
si
->
type
==
SectionInfo
::
Subsection
);
}
}
outputList
->
startTextBlock
();
outputList
->
startTextBlock
();
parseDoc
(
*
outputList
,
pi
->
defFileName
,
pi
->
defLine
,
0
,
0
,
pi
->
doc
);
parseDoc
(
*
outputList
,
pi
->
defFileName
,
pi
->
defLine
,
0
,
0
,
pi
->
doc
);
outputList
->
endTextBlock
();
outputList
->
endTextBlock
();
endFile
(
*
outputList
);
endFile
(
*
outputList
);
outputList
->
enable
(
OutputGenerator
::
Man
);
//
outputList->enable(OutputGenerator::Man);
if
(
!
Config_getString
(
"GENERATE_TAGFILE"
).
isEmpty
()
&&
pi
->
name
!=
"todo"
&&
pi
->
name
!=
"test"
)
if
(
!
Config_getString
(
"GENERATE_TAGFILE"
).
isEmpty
()
&&
pi
->
name
!=
"todo"
&&
pi
->
name
!=
"test"
)
{
{
...
@@ -5287,7 +5419,8 @@ static bool openOutputFile(const char *outFile,QFile &f)
...
@@ -5287,7 +5419,8 @@ static bool openOutputFile(const char *outFile,QFile &f)
* If the \a shortList parameter is TRUE a configuration file without
* If the \a shortList parameter is TRUE a configuration file without
* comments will be generated.
* comments will be generated.
*/
*/
static
void
generateConfigFile
(
const
char
*
configFile
,
bool
shortList
)
static
void
generateConfigFile
(
const
char
*
configFile
,
bool
shortList
,
bool
updateOnly
=
FALSE
)
{
{
QFile
f
;
QFile
f
;
bool
fileOpened
=
openOutputFile
(
configFile
,
f
);
bool
fileOpened
=
openOutputFile
(
configFile
,
f
);
...
@@ -5296,6 +5429,8 @@ static void generateConfigFile(const char *configFile,bool shortList)
...
@@ -5296,6 +5429,8 @@ static void generateConfigFile(const char *configFile,bool shortList)
{
{
Config
::
instance
()
->
writeTemplate
(
&
f
,
shortList
);
Config
::
instance
()
->
writeTemplate
(
&
f
,
shortList
);
if
(
!
writeToStdout
)
if
(
!
writeToStdout
)
{
if
(
!
updateOnly
)
{
{
msg
(
"
\n\n
Configuration file `%s' created.
\n\n
"
,
configFile
);
msg
(
"
\n\n
Configuration file `%s' created.
\n\n
"
,
configFile
);
msg
(
"Now edit the configuration file and enter
\n\n
"
);
msg
(
"Now edit the configuration file and enter
\n\n
"
);
...
@@ -5305,6 +5440,11 @@ static void generateConfigFile(const char *configFile,bool shortList)
...
@@ -5305,6 +5440,11 @@ static void generateConfigFile(const char *configFile,bool shortList)
msg
(
" doxygen
\n\n
"
);
msg
(
" doxygen
\n\n
"
);
msg
(
"to generate the documentation for your project
\n\n
"
);
msg
(
"to generate the documentation for your project
\n\n
"
);
}
}
else
{
msg
(
"
\n\n
Configuration file `%s' updated.
\n\n
"
,
configFile
);
}
}
}
}
else
else
{
{
...
@@ -6014,7 +6154,7 @@ void readConfiguration(int argc, char **argv)
...
@@ -6014,7 +6154,7 @@ void readConfiguration(int argc, char **argv)
if
(
updateConfig
)
if
(
updateConfig
)
{
{
generateConfigFile
(
configName
,
shortList
);
generateConfigFile
(
configName
,
shortList
,
TRUE
);
exit
(
1
);
exit
(
1
);
}
}
...
...
src/doxygen.h
View file @
75fed736
...
@@ -40,9 +40,15 @@ class PageInfo;
...
@@ -40,9 +40,15 @@ class PageInfo;
typedef
QList
<
QCString
>
StringList
;
typedef
QList
<
QCString
>
StringList
;
typedef
QDict
<
FileDef
>
FileDict
;
typedef
QDict
<
FileDef
>
FileDict
;
typedef
QDict
<
QCString
>
StringDict
;
typedef
QDict
<
GroupDef
>
GroupDict
;
typedef
QDict
<
GroupDef
>
GroupDict
;
class
StringDict
:
public
QDict
<
QCString
>
{
public
:
StringDict
(
uint
size
=
17
)
:
QDict
<
QCString
>
(
size
)
{}
virtual
~
StringDict
()
{}
};
extern
QCString
spaces
;
extern
QCString
spaces
;
/*! \brief This class serves as a namespace for global variables used by doxygen.
/*! \brief This class serves as a namespace for global variables used by doxygen.
...
@@ -52,8 +58,8 @@ extern QCString spaces;
...
@@ -52,8 +58,8 @@ extern QCString spaces;
class
Doxygen
class
Doxygen
{
{
public
:
public
:
static
Class
List
classLis
t
;
static
Class
SDict
classSDic
t
;
static
Class
Dict
classDict
;
static
Class
List
hiddenClasses
;
static
PageSDict
*
exampleSDict
;
static
PageSDict
*
exampleSDict
;
static
PageSDict
*
pageSDict
;
static
PageSDict
*
pageSDict
;
static
PageInfo
*
mainPage
;
static
PageInfo
*
mainPage
;
...
@@ -87,6 +93,7 @@ class Doxygen
...
@@ -87,6 +93,7 @@ class Doxygen
static
QIntDict
<
QCString
>
memberDocDict
;
// dictionary of the member groups heading
static
QIntDict
<
QCString
>
memberDocDict
;
// dictionary of the member groups heading
static
QDict
<
void
>
expandAsDefinedDict
;
static
QDict
<
void
>
expandAsDefinedDict
;
static
PackageSDict
packageDict
;
static
PackageSDict
packageDict
;
static
NamespaceDef
*
globalScope
;
};
};
void
initDoxygen
();
void
initDoxygen
();
...
...
src/example.h
View file @
75fed736
...
@@ -31,22 +31,33 @@ struct Example
...
@@ -31,22 +31,33 @@ struct Example
QCString
file
;
QCString
file
;
};
};
class
ExampleList
:
public
QList
<
Example
>
//class ExampleList : public QList<Example>
//{
// public:
// ExampleList() : QList<Example>() {}
// ~ExampleList() {}
// int compareItems(GCI item1,GCI item2)
// {
// return stricmp(((Example *)item1)->name,((Example *)item2)->name);
// }
//};
//class ExampleDict : public QDict<Example>
//{
// public:
// ExampleDict(int size=17) : QDict<Example>(size) {}
// ~ExampleDict() {}
//};
class
ExampleSDict
:
public
SDict
<
Example
>
{
{
public
:
public
:
Example
List
()
:
QList
<
Example
>
(
)
{}
Example
SDict
(
int
size
=
17
)
:
SDict
<
Example
>
(
size
)
{}
~
Example
Lis
t
()
{}
~
Example
SDic
t
()
{}
int
compareItems
(
GCI
item1
,
GCI
item2
)
int
compareItems
(
GCI
item1
,
GCI
item2
)
{
{
return
stricmp
(((
Example
*
)
item1
)
->
name
,((
Example
*
)
item2
)
->
name
);
return
stricmp
(((
Example
*
)
item1
)
->
name
,((
Example
*
)
item2
)
->
name
);
}
}
};
};
class
ExampleDict
:
public
QDict
<
Example
>
{
public
:
ExampleDict
(
int
size
=
17
)
:
QDict
<
Example
>
(
size
)
{}
~
ExampleDict
()
{}
};
#endif
#endif
src/filedef.cpp
View file @
75fed736
...
@@ -44,7 +44,7 @@ FileDef::FileDef(const char *p,const char *nm,const char *lref)
...
@@ -44,7 +44,7 @@ FileDef::FileDef(const char *p,const char *nm,const char *lref)
filename
=
nm
;
filename
=
nm
;
diskname
=
nm
;
diskname
=
nm
;
setReference
(
lref
);
setReference
(
lref
);
class
List
=
new
ClassList
;
class
SDict
=
new
ClassSDict
(
17
)
;
includeList
=
new
QList
<
IncludeInfo
>
;
includeList
=
new
QList
<
IncludeInfo
>
;
includeList
->
setAutoDelete
(
TRUE
);
includeList
->
setAutoDelete
(
TRUE
);
includeDict
=
new
QDict
<
IncludeInfo
>
(
61
);
includeDict
=
new
QDict
<
IncludeInfo
>
(
61
);
...
@@ -72,7 +72,7 @@ FileDef::FileDef(const char *p,const char *nm,const char *lref)
...
@@ -72,7 +72,7 @@ FileDef::FileDef(const char *p,const char *nm,const char *lref)
/*! destroy the file definition */
/*! destroy the file definition */
FileDef
::~
FileDef
()
FileDef
::~
FileDef
()
{
{
delete
class
Lis
t
;
delete
class
SDic
t
;
delete
includeDict
;
delete
includeDict
;
delete
includeList
;
delete
includeList
;
delete
namespaceList
;
delete
namespaceList
;
...
@@ -298,7 +298,7 @@ void FileDef::writeDocumentation(OutputList &ol)
...
@@ -298,7 +298,7 @@ void FileDef::writeDocumentation(OutputList &ol)
if
(
found
)
ol
.
endMemberList
();
if
(
found
)
ol
.
endMemberList
();
}
}
class
Lis
t
->
writeDeclaration
(
ol
);
class
SDic
t
->
writeDeclaration
(
ol
);
/* write user defined member groups */
/* write user defined member groups */
MemberGroupListIterator
mgli
(
*
memberGroupList
);
MemberGroupListIterator
mgli
(
*
memberGroupList
);
...
@@ -545,9 +545,9 @@ void FileDef::insertMember(MemberDef *md)
...
@@ -545,9 +545,9 @@ void FileDef::insertMember(MemberDef *md)
void
FileDef
::
insertClass
(
ClassDef
*
cd
)
void
FileDef
::
insertClass
(
ClassDef
*
cd
)
{
{
if
(
Config_getBool
(
"SORT_MEMBER_DOCS"
))
if
(
Config_getBool
(
"SORT_MEMBER_DOCS"
))
class
List
->
inSort
(
cd
);
class
SDict
->
inSort
(
cd
->
name
(),
cd
);
else
else
class
List
->
append
(
cd
);
class
SDict
->
append
(
cd
->
name
(),
cd
);
}
}
/*! Adds namespace definition \a nd to the list of all compounds of this file */
/*! Adds namespace definition \a nd to the list of all compounds of this file */
...
...
src/filedef.h
View file @
75fed736
...
@@ -29,8 +29,9 @@
...
@@ -29,8 +29,9 @@
class
FileDef
;
class
FileDef
;
class
FileList
;
class
FileList
;
class
Class
Lis
t
;
class
Class
SDic
t
;
class
ClassDef
;
class
ClassDef
;
class
ClassList
;
class
MemberDef
;
class
MemberDef
;
class
OutputList
;
class
OutputList
;
class
NamespaceDef
;
class
NamespaceDef
;
...
@@ -168,7 +169,7 @@ class FileDef : public Definition
...
@@ -168,7 +169,7 @@ class FileDef : public Definition
private
:
private
:
Class
List
*
classLis
t
;
Class
SDict
*
classSDic
t
;
QDict
<
IncludeInfo
>
*
includeDict
;
QDict
<
IncludeInfo
>
*
includeDict
;
QList
<
IncludeInfo
>
*
includeList
;
QList
<
IncludeInfo
>
*
includeList
;
QDict
<
IncludeInfo
>
*
includedByDict
;
QDict
<
IncludeInfo
>
*
includedByDict
;
...
...
src/groupdef.cpp
View file @
75fed736
...
@@ -36,7 +36,7 @@ GroupDef::GroupDef(const char *df,int dl,const char *na,const char *t) :
...
@@ -36,7 +36,7 @@ GroupDef::GroupDef(const char *df,int dl,const char *na,const char *t) :
Definition
(
df
,
dl
,
na
)
Definition
(
df
,
dl
,
na
)
{
{
fileList
=
new
FileList
;
fileList
=
new
FileList
;
class
List
=
new
ClassList
;
class
SDict
=
new
ClassSDict
(
257
)
;
groupList
=
new
GroupList
;
groupList
=
new
GroupList
;
parentGroupList
=
new
GroupList
;
parentGroupList
=
new
GroupList
;
namespaceList
=
new
NamespaceList
;
namespaceList
=
new
NamespaceList
;
...
@@ -78,7 +78,7 @@ GroupDef::GroupDef(const char *df,int dl,const char *na,const char *t) :
...
@@ -78,7 +78,7 @@ GroupDef::GroupDef(const char *df,int dl,const char *na,const char *t) :
GroupDef
::~
GroupDef
()
GroupDef
::~
GroupDef
()
{
{
delete
fileList
;
delete
fileList
;
delete
class
Lis
t
;
delete
class
SDic
t
;
delete
groupList
;
delete
groupList
;
delete
parentGroupList
;
delete
parentGroupList
;
delete
namespaceList
;
delete
namespaceList
;
...
@@ -108,12 +108,12 @@ void GroupDef::addFile(const FileDef *def)
...
@@ -108,12 +108,12 @@ void GroupDef::addFile(const FileDef *def)
fileList
->
append
(
def
);
fileList
->
append
(
def
);
}
}
void
GroupDef
::
addClass
(
const
ClassDef
*
def
)
void
GroupDef
::
addClass
(
const
ClassDef
*
cd
)
{
{
if
(
Config_getBool
(
"SORT_MEMBER_DOCS"
))
if
(
Config_getBool
(
"SORT_MEMBER_DOCS"
))
class
List
->
inSort
(
def
);
class
SDict
->
inSort
(
cd
->
name
(),
cd
);
else
else
class
List
->
append
(
def
);
class
SDict
->
append
(
cd
->
name
(),
cd
);
}
}
void
GroupDef
::
addNamespace
(
const
NamespaceDef
*
def
)
void
GroupDef
::
addNamespace
(
const
NamespaceDef
*
def
)
...
@@ -135,51 +135,9 @@ void GroupDef::addExample(const PageInfo *def)
...
@@ -135,51 +135,9 @@ void GroupDef::addExample(const PageInfo *def)
exampleDict
->
append
(
def
->
name
,
def
);
exampleDict
->
append
(
def
->
name
,
def
);
}
}
#if 0
void GroupDef::addMemberListToGroup(MemberList *ml,
bool (MemberDef::*func)() const)
{
if (ml==0) return;
MemberListIterator mli(*ml);
MemberDef *md;
for (;(md=mli.current());++mli)
{
int groupId=md->getMemberGroupId();
if ((md->*func)() && groupId!=-1)
{
QCString *pGrpHeader = Doxygen::memberHeaderDict[groupId];
QCString *pDocs = Doxygen::memberDocDict[groupId];
if (pGrpHeader)
{
MemberGroup *mg = memberGroupDict->find(groupId);
if (mg==0)
{
mg = new MemberGroup(groupId,*pGrpHeader,pDocs ? pDocs->data() : 0);
memberGroupDict->insert(groupId,mg);
memberGroupList->append(mg);
}
mg->insertMember(md);
md->setMemberGroup(mg);
}
}
}
}
#endif
void
GroupDef
::
addMembersToMemberGroup
()
void
GroupDef
::
addMembersToMemberGroup
()
{
{
#if 0
addMemberListToGroup(allMemberList,&MemberDef::isDefine);
addMemberListToGroup(allMemberList,&MemberDef::isTypedef);
addMemberListToGroup(allMemberList,&MemberDef::isEnumerate);
addMemberListToGroup(allMemberList,&MemberDef::isEnumValue);
addMemberListToGroup(allMemberList,&MemberDef::isFunction);
addMemberListToGroup(allMemberList,&MemberDef::isSlot);
addMemberListToGroup(allMemberList,&MemberDef::isSignal);
addMemberListToGroup(allMemberList,&MemberDef::isVariable);
#endif
::
addMembersToMemberGroup
(
&
decDefineMembers
,
memberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
decDefineMembers
,
memberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
decProtoMembers
,
memberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
decProtoMembers
,
memberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
decTypedefMembers
,
memberGroupDict
,
memberGroupList
);
::
addMembersToMemberGroup
(
&
decTypedefMembers
,
memberGroupDict
,
memberGroupList
);
...
@@ -198,7 +156,7 @@ void GroupDef::addMembersToMemberGroup()
...
@@ -198,7 +156,7 @@ void GroupDef::addMembersToMemberGroup()
}
}
void
GroupDef
::
insertMember
(
MemberDef
*
md
)
void
GroupDef
::
insertMember
(
MemberDef
*
md
,
bool
docOnly
)
{
{
//printf("GroupDef::insertMember(%s)\n",md->name().data());
//printf("GroupDef::insertMember(%s)\n",md->name().data());
MemberNameInfo
*
mni
=
0
;
MemberNameInfo
*
mni
=
0
;
...
@@ -226,28 +184,28 @@ void GroupDef::insertMember(MemberDef *md)
...
@@ -226,28 +184,28 @@ void GroupDef::insertMember(MemberDef *md)
switch
(
md
->
memberType
())
switch
(
md
->
memberType
())
{
{
case
MemberDef
:
:
Variable
:
case
MemberDef
:
:
Variable
:
decVarMembers
.
append
(
md
);
if
(
!
docOnly
)
decVarMembers
.
append
(
md
);
if
(
Config_getBool
(
"SORT_MEMBER_DOCS"
))
if
(
Config_getBool
(
"SORT_MEMBER_DOCS"
))
docVarMembers
.
inSort
(
md
);
docVarMembers
.
inSort
(
md
);
else
else
docVarMembers
.
append
(
md
);
docVarMembers
.
append
(
md
);
break
;
break
;
case
MemberDef
:
:
Function
:
case
MemberDef
:
:
Function
:
decFuncMembers
.
append
(
md
);
if
(
!
docOnly
)
decFuncMembers
.
append
(
md
);
if
(
Config_getBool
(
"SORT_MEMBER_DOCS"
))
if
(
Config_getBool
(
"SORT_MEMBER_DOCS"
))
docFuncMembers
.
inSort
(
md
);
docFuncMembers
.
inSort
(
md
);
else
else
docFuncMembers
.
append
(
md
);
docFuncMembers
.
append
(
md
);
break
;
break
;
case
MemberDef
:
:
Typedef
:
case
MemberDef
:
:
Typedef
:
decTypedefMembers
.
append
(
md
);
if
(
!
docOnly
)
decTypedefMembers
.
append
(
md
);
if
(
Config_getBool
(
"SORT_MEMBER_DOCS"
))
if
(
Config_getBool
(
"SORT_MEMBER_DOCS"
))
docTypedefMembers
.
inSort
(
md
);
docTypedefMembers
.
inSort
(
md
);
else
else
docTypedefMembers
.
append
(
md
);
docTypedefMembers
.
append
(
md
);
break
;
break
;
case
MemberDef
:
:
Enumeration
:
case
MemberDef
:
:
Enumeration
:
decEnumMembers
.
append
(
md
);
if
(
!
docOnly
)
decEnumMembers
.
append
(
md
);
if
(
Config_getBool
(
"SORT_MEMBER_DOCS"
))
if
(
Config_getBool
(
"SORT_MEMBER_DOCS"
))
docEnumMembers
.
inSort
(
md
);
docEnumMembers
.
inSort
(
md
);
else
else
...
@@ -256,14 +214,14 @@ void GroupDef::insertMember(MemberDef *md)
...
@@ -256,14 +214,14 @@ void GroupDef::insertMember(MemberDef *md)
case
MemberDef
:
:
EnumValue
:
case
MemberDef
:
:
EnumValue
:
break
;
break
;
case
MemberDef
:
:
Prototype
:
case
MemberDef
:
:
Prototype
:
decProtoMembers
.
append
(
md
);
if
(
!
docOnly
)
decProtoMembers
.
append
(
md
);
if
(
Config_getBool
(
"SORT_MEMBER_DOCS"
))
if
(
Config_getBool
(
"SORT_MEMBER_DOCS"
))
docProtoMembers
.
inSort
(
md
);
docProtoMembers
.
inSort
(
md
);
else
else
docProtoMembers
.
append
(
md
);
docProtoMembers
.
append
(
md
);
break
;
break
;
case
MemberDef
:
:
Define
:
case
MemberDef
:
:
Define
:
decDefineMembers
.
append
(
md
);
if
(
!
docOnly
)
decDefineMembers
.
append
(
md
);
if
(
Config_getBool
(
"SORT_MEMBER_DOCS"
))
if
(
Config_getBool
(
"SORT_MEMBER_DOCS"
))
docDefineMembers
.
inSort
(
md
);
docDefineMembers
.
inSort
(
md
);
else
else
...
@@ -304,7 +262,7 @@ bool GroupDef::isASubGroup() const
...
@@ -304,7 +262,7 @@ bool GroupDef::isASubGroup() const
int
GroupDef
::
countMembers
()
const
int
GroupDef
::
countMembers
()
const
{
{
return
fileList
->
count
()
+
return
fileList
->
count
()
+
class
Lis
t
->
count
()
+
class
SDic
t
->
count
()
+
namespaceList
->
count
()
+
namespaceList
->
count
()
+
groupList
->
count
()
+
groupList
->
count
()
+
allMemberList
->
count
()
+
allMemberList
->
count
()
+
...
@@ -332,7 +290,7 @@ void GroupDef::writeDocumentation(OutputList &ol)
...
@@ -332,7 +290,7 @@ void GroupDef::writeDocumentation(OutputList &ol)
OutputList
briefOutput
(
&
ol
);
OutputList
briefOutput
(
&
ol
);
if
(
!
briefDescription
().
isEmpty
())
if
(
!
briefDescription
().
isEmpty
())
{
{
parseDoc
(
briefOutput
,
defFileName
,
defLine
,
name
(),
0
,
briefDescription
());
parseDoc
(
briefOutput
,
m_defFileName
,
m_
defLine
,
name
(),
0
,
briefDescription
());
ol
+=
briefOutput
;
ol
+=
briefOutput
;
ol
.
writeString
(
"
\n
"
);
ol
.
writeString
(
"
\n
"
);
ol
.
pushGeneratorState
();
ol
.
pushGeneratorState
();
...
@@ -375,7 +333,7 @@ void GroupDef::writeDocumentation(OutputList &ol)
...
@@ -375,7 +333,7 @@ void GroupDef::writeDocumentation(OutputList &ol)
if
(
!
fd
->
briefDescription
().
isEmpty
()
&&
Config_getBool
(
"BRIEF_MEMBER_DESC"
))
if
(
!
fd
->
briefDescription
().
isEmpty
()
&&
Config_getBool
(
"BRIEF_MEMBER_DESC"
))
{
{
ol
.
startMemberDescription
();
ol
.
startMemberDescription
();
parseDoc
(
ol
,
defFileName
,
defLine
,
0
,
0
,
fd
->
briefDescription
());
parseDoc
(
ol
,
m_defFileName
,
m_
defLine
,
0
,
0
,
fd
->
briefDescription
());
ol
.
endMemberDescription
();
ol
.
endMemberDescription
();
ol
.
newParagraph
();
ol
.
newParagraph
();
}
}
...
@@ -404,7 +362,7 @@ void GroupDef::writeDocumentation(OutputList &ol)
...
@@ -404,7 +362,7 @@ void GroupDef::writeDocumentation(OutputList &ol)
if
(
!
nd
->
briefDescription
().
isEmpty
()
&&
Config_getBool
(
"BRIEF_MEMBER_DESC"
))
if
(
!
nd
->
briefDescription
().
isEmpty
()
&&
Config_getBool
(
"BRIEF_MEMBER_DESC"
))
{
{
ol
.
startMemberDescription
();
ol
.
startMemberDescription
();
parseDoc
(
ol
,
defFileName
,
defLine
,
0
,
0
,
nd
->
briefDescription
());
parseDoc
(
ol
,
m_defFileName
,
m_
defLine
,
0
,
0
,
nd
->
briefDescription
());
ol
.
endMemberDescription
();
ol
.
endMemberDescription
();
ol
.
newParagraph
();
ol
.
newParagraph
();
}
}
...
@@ -432,7 +390,7 @@ void GroupDef::writeDocumentation(OutputList &ol)
...
@@ -432,7 +390,7 @@ void GroupDef::writeDocumentation(OutputList &ol)
if
(
!
gd
->
briefDescription
().
isEmpty
()
&&
Config_getBool
(
"BRIEF_MEMBER_DESC"
))
if
(
!
gd
->
briefDescription
().
isEmpty
()
&&
Config_getBool
(
"BRIEF_MEMBER_DESC"
))
{
{
ol
.
startMemberDescription
();
ol
.
startMemberDescription
();
parseDoc
(
ol
,
defFileName
,
defLine
,
0
,
0
,
gd
->
briefDescription
());
parseDoc
(
ol
,
m_defFileName
,
m_
defLine
,
0
,
0
,
gd
->
briefDescription
());
ol
.
endMemberDescription
();
ol
.
endMemberDescription
();
ol
.
newParagraph
();
ol
.
newParagraph
();
}
}
...
@@ -441,7 +399,7 @@ void GroupDef::writeDocumentation(OutputList &ol)
...
@@ -441,7 +399,7 @@ void GroupDef::writeDocumentation(OutputList &ol)
ol
.
endMemberList
();
ol
.
endMemberList
();
}
}
class
Lis
t
->
writeDeclaration
(
ol
);
class
SDic
t
->
writeDeclaration
(
ol
);
if
(
allMemberList
->
count
()
>
0
)
if
(
allMemberList
->
count
()
>
0
)
{
{
...
@@ -490,7 +448,7 @@ void GroupDef::writeDocumentation(OutputList &ol)
...
@@ -490,7 +448,7 @@ void GroupDef::writeDocumentation(OutputList &ol)
// write documentation
// write documentation
if
(
!
documentation
().
isEmpty
())
if
(
!
documentation
().
isEmpty
())
{
{
parseDoc
(
ol
,
defFileName
,
defLine
,
name
(),
0
,
documentation
()
+
"
\n
"
);
parseDoc
(
ol
,
m_defFileName
,
m_
defLine
,
name
(),
0
,
documentation
()
+
"
\n
"
);
}
}
}
}
PageInfo
*
pi
=
0
;
PageInfo
*
pi
=
0
;
...
@@ -604,6 +562,7 @@ void addMemberToGroups(Entry *root,MemberDef *md)
...
@@ -604,6 +562,7 @@ void addMemberToGroups(Entry *root,MemberDef *md)
QCString
*
s
;
QCString
*
s
;
for
(;(
s
=
sli
.
current
());
++
sli
)
for
(;(
s
=
sli
.
current
());
++
sli
)
{
{
//printf("addMemberToGroups(group=%s,member=%s)\n",s->data(),md->name().data());
GroupDef
*
gd
=
0
;
GroupDef
*
gd
=
0
;
if
(
!
s
->
isEmpty
()
&&
(
gd
=
Doxygen
::
groupDict
[
*
s
]))
if
(
!
s
->
isEmpty
()
&&
(
gd
=
Doxygen
::
groupDict
[
*
s
]))
{
{
...
@@ -612,6 +571,8 @@ void addMemberToGroups(Entry *root,MemberDef *md)
...
@@ -612,6 +571,8 @@ void addMemberToGroups(Entry *root,MemberDef *md)
{
{
gd
->
insertMember
(
md
);
gd
->
insertMember
(
md
);
md
->
setGroupDef
(
gd
);
md
->
setGroupDef
(
gd
);
ClassDef
*
cd
=
md
->
getClassDefOfAnonymousType
();
if
(
cd
)
cd
->
setGroupDefForAllMembers
(
gd
);
}
}
else
if
(
mgd
!=
gd
)
else
if
(
mgd
!=
gd
)
{
{
...
...
src/groupdef.h
View file @
75fed736
...
@@ -27,7 +27,7 @@
...
@@ -27,7 +27,7 @@
#include "htmlhelp.h"
#include "htmlhelp.h"
class
FileList
;
class
FileList
;
class
Class
Lis
t
;
class
Class
SDic
t
;
class
FileDef
;
class
FileDef
;
class
ClassDef
;
class
ClassDef
;
class
NamespaceDef
;
class
NamespaceDef
;
...
@@ -55,7 +55,7 @@ class GroupDef : public Definition
...
@@ -55,7 +55,7 @@ class GroupDef : public Definition
void
addParentGroup
(
const
GroupDef
*
def
);
void
addParentGroup
(
const
GroupDef
*
def
);
void
addPage
(
PageInfo
*
def
);
// pages in this group
void
addPage
(
PageInfo
*
def
);
// pages in this group
void
addExample
(
const
PageInfo
*
def
);
// examples in this group
void
addExample
(
const
PageInfo
*
def
);
// examples in this group
void
insertMember
(
MemberDef
*
def
);
void
insertMember
(
MemberDef
*
def
,
bool
docOnly
=
FALSE
);
void
writeDocumentation
(
OutputList
&
ol
);
void
writeDocumentation
(
OutputList
&
ol
);
int
countMembers
()
const
;
int
countMembers
()
const
;
bool
isLinkableInProject
()
bool
isLinkableInProject
()
...
@@ -84,7 +84,7 @@ class GroupDef : public Definition
...
@@ -84,7 +84,7 @@ class GroupDef : public Definition
QCString
title
;
// title of the group
QCString
title
;
// title of the group
QCString
fileName
;
// base name of the generated file
QCString
fileName
;
// base name of the generated file
FileList
*
fileList
;
// list of files in the group
FileList
*
fileList
;
// list of files in the group
Class
List
*
classList
;
// list of classes in the group
Class
SDict
*
classSDict
;
// list of classes in the group
NamespaceList
*
namespaceList
;
// list of namespaces in the group
NamespaceList
*
namespaceList
;
// list of namespaces in the group
GroupList
*
groupList
;
// list of sub groups.
GroupList
*
groupList
;
// list of sub groups.
GroupList
*
parentGroupList
;
// list of parent groups.
GroupList
*
parentGroupList
;
// list of parent groups.
...
...
src/index.cpp
View file @
75fed736
...
@@ -469,26 +469,8 @@ void writeClassTree(BaseClassList *cl)
...
@@ -469,26 +469,8 @@ void writeClassTree(BaseClassList *cl)
//----------------------------------------------------------------------------
//----------------------------------------------------------------------------
/*! Generates HTML Help tree of classes */
/*! Generates HTML Help tree of classes */
void
writeClassTree
(
ClassList
*
cl
)
void
writeClassTree
Node
(
ClassDef
*
cd
,
bool
hasHtmlHelp
,
bool
hasFtvHelp
,
bool
&
started
)
{
{
HtmlHelp
*
htmlHelp
=
0
;
FTVHelp
*
ftvHelp
=
0
;
bool
&
generateHtml
=
Config_getBool
(
"GENERATE_HTML"
)
;
bool
hasHtmlHelp
=
generateHtml
&&
Config_getBool
(
"GENERATE_HTMLHELP"
);
bool
hasFtvHelp
=
generateHtml
&&
Config_getBool
(
"GENERATE_TREEVIEW"
);
if
(
hasHtmlHelp
)
{
htmlHelp
=
HtmlHelp
::
getInstance
();
}
if
(
hasFtvHelp
)
{
ftvHelp
=
FTVHelp
::
getInstance
();
}
ClassListIterator
cli
(
*
cl
);
bool
started
=
FALSE
;
for
(
;
cli
.
current
()
;
++
cli
)
{
ClassDef
*
cd
=
cli
.
current
();
if
(
cd
->
isVisibleInHierarchy
()
&&
!
cd
->
visited
)
if
(
cd
->
isVisibleInHierarchy
()
&&
!
cd
->
visited
)
{
{
if
(
!
started
)
if
(
!
started
)
...
@@ -500,11 +482,11 @@ void writeClassTree(ClassList *cl)
...
@@ -500,11 +482,11 @@ void writeClassTree(ClassList *cl)
{
{
if
(
hasHtmlHelp
)
if
(
hasHtmlHelp
)
{
{
htmlHelp
->
addContentsItem
(
hasChildren
,
cd
->
name
(),
cd
->
getOutputFileBase
());
HtmlHelp
::
getInstance
()
->
addContentsItem
(
hasChildren
,
cd
->
name
(),
cd
->
getOutputFileBase
());
}
}
if
(
hasFtvHelp
)
if
(
hasFtvHelp
)
{
{
ftvHelp
->
addContentsItem
(
hasChildren
,
cd
->
getReference
(),
cd
->
getOutputFileBase
(),
0
,
cd
->
name
());
FTVHelp
::
getInstance
()
->
addContentsItem
(
hasChildren
,
cd
->
getReference
(),
cd
->
getOutputFileBase
(),
0
,
cd
->
name
());
}
}
}
}
if
(
hasChildren
)
if
(
hasChildren
)
...
@@ -513,6 +495,31 @@ void writeClassTree(ClassList *cl)
...
@@ -513,6 +495,31 @@ void writeClassTree(ClassList *cl)
}
}
cd
->
visited
=
TRUE
;
cd
->
visited
=
TRUE
;
}
}
}
void
writeClassTree
(
ClassList
*
cl
)
{
bool
&
generateHtml
=
Config_getBool
(
"GENERATE_HTML"
)
;
bool
hasHtmlHelp
=
generateHtml
&&
Config_getBool
(
"GENERATE_HTMLHELP"
);
bool
hasFtvHelp
=
generateHtml
&&
Config_getBool
(
"GENERATE_TREEVIEW"
);
ClassListIterator
cli
(
*
cl
);
bool
started
=
FALSE
;
for
(
;
cli
.
current
()
;
++
cli
)
{
writeClassTreeNode
(
cli
.
current
(),
hasHtmlHelp
,
hasFtvHelp
,
started
);
}
}
void
writeClassTree
(
ClassSDict
*
d
)
{
bool
&
generateHtml
=
Config_getBool
(
"GENERATE_HTML"
)
;
bool
hasHtmlHelp
=
generateHtml
&&
Config_getBool
(
"GENERATE_HTMLHELP"
);
bool
hasFtvHelp
=
generateHtml
&&
Config_getBool
(
"GENERATE_TREEVIEW"
);
ClassSDict
::
Iterator
cli
(
*
d
);
bool
started
=
FALSE
;
for
(
;
cli
.
current
()
;
++
cli
)
{
writeClassTreeNode
(
cli
.
current
(),
hasHtmlHelp
,
hasFtvHelp
,
started
);
}
}
}
}
...
@@ -520,7 +527,7 @@ void writeClassTree(ClassList *cl)
...
@@ -520,7 +527,7 @@ void writeClassTree(ClassList *cl)
void
writeClassHierarchy
(
OutputList
&
ol
)
void
writeClassHierarchy
(
OutputList
&
ol
)
{
{
initClassHierarchy
(
&
Doxygen
::
class
Lis
t
);
initClassHierarchy
(
&
Doxygen
::
class
SDic
t
);
HtmlHelp
*
htmlHelp
=
0
;
HtmlHelp
*
htmlHelp
=
0
;
FTVHelp
*
ftvHelp
=
0
;
FTVHelp
*
ftvHelp
=
0
;
...
@@ -537,7 +544,7 @@ void writeClassHierarchy(OutputList &ol)
...
@@ -537,7 +544,7 @@ void writeClassHierarchy(OutputList &ol)
}
}
bool
started
=
FALSE
;
bool
started
=
FALSE
;
Class
ListIterator
cli
(
Doxygen
::
classLis
t
);
Class
SDict
::
Iterator
cli
(
Doxygen
::
classSDic
t
);
for
(;
cli
.
current
();
++
cli
)
for
(;
cli
.
current
();
++
cli
)
{
{
ClassDef
*
cd
=
cli
.
current
();
ClassDef
*
cd
=
cli
.
current
();
...
@@ -546,9 +553,9 @@ void writeClassHierarchy(OutputList &ol)
...
@@ -546,9 +553,9 @@ void writeClassHierarchy(OutputList &ol)
// hasVisibleRoot(cd->baseClasses()),
// hasVisibleRoot(cd->baseClasses()),
// cd->isVisibleInHierarchy()
// cd->isVisibleInHierarchy()
// );
// );
if
(
!
hasVisibleRoot
(
cd
->
baseClasses
()))
if
(
!
hasVisibleRoot
(
cd
->
baseClasses
()))
// filter on root classes
{
{
if
(
cd
->
isVisibleInHierarchy
())
if
(
cd
->
isVisibleInHierarchy
())
// should it be visible
{
{
if
(
!
started
)
if
(
!
started
)
{
{
...
@@ -560,6 +567,7 @@ void writeClassHierarchy(OutputList &ol)
...
@@ -560,6 +567,7 @@ void writeClassHierarchy(OutputList &ol)
bool
hasChildren
=
!
cd
->
visited
&&
cd
->
subClasses
()
->
count
()
>
0
;
bool
hasChildren
=
!
cd
->
visited
&&
cd
->
subClasses
()
->
count
()
>
0
;
if
(
cd
->
isLinkable
())
if
(
cd
->
isLinkable
())
{
{
//printf("Writing class %s\n",cd->name().data());
ol
.
writeIndexItem
(
cd
->
getReference
(),
cd
->
getOutputFileBase
(),
cd
->
displayName
());
ol
.
writeIndexItem
(
cd
->
getReference
(),
cd
->
getOutputFileBase
(),
cd
->
displayName
());
if
(
cd
->
isReference
())
if
(
cd
->
isReference
())
{
{
...
@@ -609,9 +617,9 @@ void writeClassHierarchy(OutputList &ol)
...
@@ -609,9 +617,9 @@ void writeClassHierarchy(OutputList &ol)
// TODO: let this function return the real number of items in the hierarchy.
// TODO: let this function return the real number of items in the hierarchy.
int
countClassHierarchy
()
int
countClassHierarchy
()
{
{
initClassHierarchy
(
&
Doxygen
::
class
Lis
t
);
initClassHierarchy
(
&
Doxygen
::
class
SDic
t
);
int
count
=
0
;
int
count
=
0
;
Class
ListIterator
cli
(
Doxygen
::
classLis
t
);
Class
SDict
::
Iterator
cli
(
Doxygen
::
classSDic
t
);
for
(
;
cli
.
current
();
++
cli
)
for
(
;
cli
.
current
();
++
cli
)
{
{
if
(
cli
.
current
()
->
subClasses
()
->
count
()
>
0
)
count
++
;
if
(
cli
.
current
()
->
subClasses
()
->
count
()
>
0
)
count
++
;
...
@@ -1060,7 +1068,7 @@ int countAnnotatedClasses()
...
@@ -1060,7 +1068,7 @@ int countAnnotatedClasses()
{
{
int
count
=
0
;
int
count
=
0
;
//ClassDef *cd=Doxygen::classList.first();
//ClassDef *cd=Doxygen::classList.first();
Class
ListIterator
cli
(
Doxygen
::
classLis
t
);
Class
SDict
::
Iterator
cli
(
Doxygen
::
classSDic
t
);
ClassDef
*
cd
;
ClassDef
*
cd
;
for
(;(
cd
=
cli
.
current
());
++
cli
)
for
(;(
cd
=
cli
.
current
());
++
cli
)
{
{
...
@@ -1083,7 +1091,7 @@ void writeAnnotatedClassList(OutputList &ol)
...
@@ -1083,7 +1091,7 @@ void writeAnnotatedClassList(OutputList &ol)
ol
.
startIndexList
();
ol
.
startIndexList
();
//ClassDef *cd=Doxygen::classList.first();
//ClassDef *cd=Doxygen::classList.first();
//while (cd)
//while (cd)
Class
ListIterator
cli
(
Doxygen
::
classLis
t
);
Class
SDict
::
Iterator
cli
(
Doxygen
::
classSDic
t
);
ClassDef
*
cd
;
ClassDef
*
cd
;
for
(;(
cd
=
cli
.
current
());
++
cli
)
for
(;(
cd
=
cli
.
current
());
++
cli
)
{
{
...
@@ -1164,7 +1172,7 @@ void writeAlphabeticalClassList(OutputList &ol)
...
@@ -1164,7 +1172,7 @@ void writeAlphabeticalClassList(OutputList &ol)
ol
.
startAlphabeticalIndexList
();
ol
.
startAlphabeticalIndexList
();
// first count the number of headers
// first count the number of headers
Class
ListIterator
cli
(
Doxygen
::
classLis
t
);
Class
SDict
::
Iterator
cli
(
Doxygen
::
classSDic
t
);
ClassDef
*
cd
;
ClassDef
*
cd
;
char
startLetter
=
0
;
char
startLetter
=
0
;
int
headerItems
=
0
;
int
headerItems
=
0
;
...
@@ -2167,15 +2175,33 @@ void writeGroupTreeNode(OutputList &ol, GroupDef *gd,bool subLevel)
...
@@ -2167,15 +2175,33 @@ void writeGroupTreeNode(OutputList &ol, GroupDef *gd,bool subLevel)
// write group info
// write group info
bool
hasSubGroups
=
gd
->
groupList
->
count
()
>
0
;
bool
hasSubGroups
=
gd
->
groupList
->
count
()
>
0
;
bool
hasSubPages
=
gd
->
pageDict
->
count
()
>
0
;
bool
hasSubPages
=
gd
->
pageDict
->
count
()
>
0
;
int
numSubItems
=
0
;
if
(
Config_getBool
(
"TOC_EXPAND"
))
{
numSubItems
+=
gd
->
docDefineMembers
.
count
();
numSubItems
+=
gd
->
docTypedefMembers
.
count
();
numSubItems
+=
gd
->
docEnumMembers
.
count
();
numSubItems
+=
gd
->
docEnumValMembers
.
count
();
numSubItems
+=
gd
->
docFuncMembers
.
count
();
numSubItems
+=
gd
->
docVarMembers
.
count
();
numSubItems
+=
gd
->
docProtoMembers
.
count
();
numSubItems
+=
gd
->
namespaceList
->
count
();
numSubItems
+=
gd
->
classSDict
->
count
();
numSubItems
+=
gd
->
fileList
->
count
();
numSubItems
+=
gd
->
exampleDict
->
count
();
}
bool
isDir
=
hasSubGroups
||
hasSubPages
||
numSubItems
>
0
;
//printf("gd=`%s': pageDict=%d\n",gd->name().data(),gd->pageDict->count());
//printf("gd=`%s': pageDict=%d\n",gd->name().data(),gd->pageDict->count());
if
(
htmlHelp
)
if
(
htmlHelp
)
{
{
htmlHelp
->
addContentsItem
(
hasSubGroups
||
hasSubPages
,
gd
->
groupTitle
(),
gd
->
getOutputFileBase
());
htmlHelp
->
addContentsItem
(
isDir
,
gd
->
groupTitle
(),
gd
->
getOutputFileBase
());
htmlHelp
->
incContentsDepth
();
htmlHelp
->
incContentsDepth
();
}
}
if
(
ftvHelp
)
if
(
ftvHelp
)
{
{
ftvHelp
->
addContentsItem
(
hasSubGroups
||
hasSubPages
,
gd
->
getReference
(),
gd
->
getOutputFileBase
(),
0
,
gd
->
groupTitle
());
ftvHelp
->
addContentsItem
(
isDir
,
gd
->
getReference
(),
gd
->
getOutputFileBase
(),
0
,
gd
->
groupTitle
());
ftvHelp
->
incContentsDepth
();
ftvHelp
->
incContentsDepth
();
}
}
...
@@ -2324,7 +2350,7 @@ void writeGroupTreeNode(OutputList &ol, GroupDef *gd,bool subLevel)
...
@@ -2324,7 +2350,7 @@ void writeGroupTreeNode(OutputList &ol, GroupDef *gd,bool subLevel)
}
}
// write classes
// write classes
if
(
gd
->
class
Lis
t
->
count
()
>
0
)
if
(
gd
->
class
SDic
t
->
count
()
>
0
)
{
{
if
(
htmlHelp
)
if
(
htmlHelp
)
{
{
...
@@ -2339,7 +2365,7 @@ void writeGroupTreeNode(OutputList &ol, GroupDef *gd,bool subLevel)
...
@@ -2339,7 +2365,7 @@ void writeGroupTreeNode(OutputList &ol, GroupDef *gd,bool subLevel)
ftvHelp
->
incContentsDepth
();
ftvHelp
->
incContentsDepth
();
}
}
writeClassTree
(
gd
->
class
Lis
t
);
writeClassTree
(
gd
->
class
SDic
t
);
if
(
htmlHelp
)
htmlHelp
->
decContentsDepth
();
if
(
htmlHelp
)
htmlHelp
->
decContentsDepth
();
if
(
ftvHelp
)
ftvHelp
->
decContentsDepth
();
if
(
ftvHelp
)
ftvHelp
->
decContentsDepth
();
}
}
...
...
src/language.cpp
View file @
75fed736
...
@@ -39,6 +39,7 @@
...
@@ -39,6 +39,7 @@
#include "translator_cn.h"
#include "translator_cn.h"
#include "translator_no.h"
#include "translator_no.h"
#include "translator_br.h"
#include "translator_br.h"
#include "translator_dk.h"
#endif
#endif
#define L_EQUAL(a) !stricmp(langName,a)
#define L_EQUAL(a) !stricmp(langName,a)
...
@@ -132,6 +133,10 @@ bool setTranslator(const char *langName)
...
@@ -132,6 +133,10 @@ bool setTranslator(const char *langName)
{
{
theTranslator
=
new
TranslatorBrazilian
;
theTranslator
=
new
TranslatorBrazilian
;
}
}
else
if
(
L_EQUAL
(
"danish"
))
{
theTranslator
=
new
TranslatorDanish
;
}
#endif
#endif
else
// use the default language (i.e. english)
else
// use the default language (i.e. english)
{
{
...
...
src/latexgen.cpp
View file @
75fed736
...
@@ -536,9 +536,10 @@ void LatexGenerator::startIndexSection(IndexSections is)
...
@@ -536,9 +536,10 @@ void LatexGenerator::startIndexSection(IndexSections is)
break
;
break
;
case
isClassDocumentation
:
case
isClassDocumentation
:
{
{
ClassDef
*
cd
=
Doxygen
::
classList
.
first
();
ClassSDict
::
Iterator
cli
(
Doxygen
::
classSDict
);
ClassDef
*
cd
=
0
;
bool
found
=
FALSE
;
bool
found
=
FALSE
;
while
(
cd
&&
!
found
)
for
(
cli
.
toFirst
();(
cd
=
cli
.
current
())
&&
!
found
;
++
cli
)
{
{
if
(
cd
->
isLinkableInProject
())
if
(
cd
->
isLinkableInProject
())
{
{
...
@@ -546,7 +547,6 @@ void LatexGenerator::startIndexSection(IndexSections is)
...
@@ -546,7 +547,6 @@ void LatexGenerator::startIndexSection(IndexSections is)
t
<<
"{"
;
//Compound Documentation}\n";
t
<<
"{"
;
//Compound Documentation}\n";
found
=
TRUE
;
found
=
TRUE
;
}
}
cd
=
Doxygen
::
classList
.
next
();
}
}
}
}
break
;
break
;
...
@@ -703,25 +703,24 @@ void LatexGenerator::endIndexSection(IndexSections is)
...
@@ -703,25 +703,24 @@ void LatexGenerator::endIndexSection(IndexSections is)
break
;
break
;
case
isClassDocumentation
:
case
isClassDocumentation
:
{
{
ClassDef
*
cd
=
Doxygen
::
classList
.
first
();
ClassSDict
::
Iterator
cli
(
Doxygen
::
classSDict
);
ClassDef
*
cd
=
0
;
bool
found
=
FALSE
;
bool
found
=
FALSE
;
while
(
cd
&&
!
found
)
for
(
cli
.
toFirst
();(
cd
=
cli
.
current
())
&&
!
found
;
++
cli
)
{
{
if
(
cd
->
isLinkableInProject
())
if
(
cd
->
isLinkableInProject
())
{
{
t
<<
"}
\n\\
input{"
<<
cd
->
getOutputFileBase
()
<<
"}
\n
"
;
t
<<
"}
\n\\
input{"
<<
cd
->
getOutputFileBase
()
<<
"}
\n
"
;
found
=
TRUE
;
found
=
TRUE
;
}
}
cd
=
Doxygen
::
classList
.
next
();
}
}
while
(
cd
)
for
(;(
cd
=
cli
.
current
());
++
cli
)
{
{
if
(
cd
->
isLinkableInProject
())
if
(
cd
->
isLinkableInProject
())
{
{
if
(
compactLatex
)
t
<<
"
\\
input"
;
else
t
<<
"
\\
include"
;
if
(
compactLatex
)
t
<<
"
\\
input"
;
else
t
<<
"
\\
include"
;
t
<<
"{"
<<
cd
->
getOutputFileBase
()
<<
"}
\n
"
;
t
<<
"{"
<<
cd
->
getOutputFileBase
()
<<
"}
\n
"
;
}
}
cd
=
Doxygen
::
classList
.
next
();
}
}
}
}
break
;
break
;
...
...
src/libdoxygen.pro.in
View file @
75fed736
...
@@ -20,7 +20,6 @@ HEADERS = bufstr.h \
...
@@ -20,7 +20,6 @@ HEADERS = bufstr.h \
classdef.h \
classdef.h \
classlist.h \
classlist.h \
code.h \
code.h \
config.h \
constexp.h \
constexp.h \
cppvalue.h \
cppvalue.h \
debug.h \
debug.h \
...
@@ -98,7 +97,6 @@ SOURCES = ce_lex.cpp \
...
@@ -98,7 +97,6 @@ SOURCES = ce_lex.cpp \
classdef.cpp \
classdef.cpp \
classlist.cpp \
classlist.cpp \
code.cpp \
code.cpp \
config.cpp \
cppvalue.cpp \
cppvalue.cpp \
debug.cpp \
debug.cpp \
declinfo.cpp \
declinfo.cpp \
...
@@ -124,7 +122,6 @@ SOURCES = ce_lex.cpp \
...
@@ -124,7 +122,6 @@ SOURCES = ce_lex.cpp \
language.cpp \
language.cpp \
latexgen.cpp \
latexgen.cpp \
logos.cpp \
logos.cpp \
main.cpp \
mangen.cpp \
mangen.cpp \
memberdef.cpp \
memberdef.cpp \
membergroup.cpp \
membergroup.cpp \
...
...
src/mangen.cpp
View file @
75fed736
...
@@ -28,14 +28,31 @@
...
@@ -28,14 +28,31 @@
#include "util.h"
#include "util.h"
#include "doxygen.h"
#include "doxygen.h"
static
QCString
getExtension
()
{
QCString
ext
=
Config_getString
(
"MAN_EXTENSION"
);
if
(
ext
.
length
()
>=
2
&&
ext
.
data
()[
0
]
==
'.'
&&
isdigit
(
ext
.
data
()[
1
]
)
)
{
ext
=
ext
.
mid
(
1
,
1
);
}
else
{
ext
=
"3"
;
}
return
ext
;
}
ManGenerator
::
ManGenerator
()
:
OutputGenerator
()
ManGenerator
::
ManGenerator
()
:
OutputGenerator
()
{
{
dir
=
Config_getString
(
"MAN_OUTPUT"
)
+
"/man
3"
;
dir
=
Config_getString
(
"MAN_OUTPUT"
)
+
"/man
"
+
getExtension
()
;
firstCol
=
TRUE
;
firstCol
=
TRUE
;
paragraph
=
FALSE
;
paragraph
=
FALSE
;
col
=
0
;
col
=
0
;
upperCase
=
FALSE
;
upperCase
=
FALSE
;
insideTabbing
=
FALSE
;
insideTabbing
=
FALSE
;
inHeader
=
FALSE
;
}
}
ManGenerator
::~
ManGenerator
()
ManGenerator
::~
ManGenerator
()
...
@@ -54,21 +71,25 @@ void ManGenerator::append(const OutputGenerator *g)
...
@@ -54,21 +71,25 @@ void ManGenerator::append(const OutputGenerator *g)
else
else
firstCol
=
((
ManGenerator
*
)
g
)
->
firstCol
;
firstCol
=
((
ManGenerator
*
)
g
)
->
firstCol
;
col
+=
((
ManGenerator
*
)
g
)
->
col
;
col
+=
((
ManGenerator
*
)
g
)
->
col
;
inHeader
=
((
ManGenerator
*
)
g
)
->
inHeader
;
paragraph
=
FALSE
;
paragraph
=
FALSE
;
}
}
void
ManGenerator
::
init
()
void
ManGenerator
::
init
()
{
{
QDir
d
(
Config_getString
(
"MAN_OUTPUT"
));
QCString
ext
=
getExtension
();
if
(
!
d
.
exists
()
&&
!
d
.
mkdir
(
Config_getString
(
"MAN_OUTPUT"
)))
QCString
&
manOutput
=
Config_getString
(
"MAN_OUTPUT"
);
QDir
d
(
manOutput
);
if
(
!
d
.
exists
()
&&
!
d
.
mkdir
(
manOutput
))
{
{
err
(
"Could not create output directory %s
\n
"
,
Config_getString
(
"MAN_OUTPUT"
)
.
data
());
err
(
"Could not create output directory %s
\n
"
,
manOutput
.
data
());
exit
(
1
);
exit
(
1
);
}
}
d
.
setPath
(
Config_getString
(
"MAN_OUTPUT"
)
+
"/man3"
);
d
.
setPath
(
manOutput
+
"/man"
+
ext
);
if
(
!
d
.
exists
()
&&
!
d
.
mkdir
(
Config_getString
(
"MAN_OUTPUT"
)
+
"/man3"
))
if
(
!
d
.
exists
()
&&
!
d
.
mkdir
(
manOutput
+
"/man"
+
ext
))
{
{
err
(
"Could not create output directory %s/man
3
\n
"
,
Config_getString
(
"MAN_OUTPUT"
)
.
data
());
err
(
"Could not create output directory %s/man
%s
\n
"
,
manOutput
.
data
(),
ext
.
data
());
exit
(
1
);
exit
(
1
);
}
}
}
}
...
@@ -123,7 +144,8 @@ void ManGenerator::endFile()
...
@@ -123,7 +144,8 @@ void ManGenerator::endFile()
void
ManGenerator
::
endTitleHead
(
const
char
*
,
const
char
*
name
)
void
ManGenerator
::
endTitleHead
(
const
char
*
,
const
char
*
name
)
{
{
t
<<
".TH
\"
"
<<
name
<<
"
\"
3
\"
"
<<
dateToString
(
FALSE
)
<<
"
\"
\"
"
;
t
<<
".TH
\"
"
<<
name
<<
"
\"
"
<<
getExtension
()
<<
"
\"
"
<<
dateToString
(
FALSE
)
<<
"
\"
\"
"
;
if
(
Config_getString
(
"PROJECT_NAME"
).
isEmpty
())
if
(
Config_getString
(
"PROJECT_NAME"
).
isEmpty
())
t
<<
"Doxygen"
;
t
<<
"Doxygen"
;
else
else
...
@@ -134,6 +156,7 @@ void ManGenerator::endTitleHead(const char *,const char *name)
...
@@ -134,6 +156,7 @@ void ManGenerator::endTitleHead(const char *,const char *name)
t
<<
".SH NAME"
<<
endl
;
t
<<
".SH NAME"
<<
endl
;
t
<<
name
<<
"
\\
- "
;
t
<<
name
<<
"
\\
- "
;
firstCol
=
FALSE
;
firstCol
=
FALSE
;
inHeader
=
TRUE
;
}
}
void
ManGenerator
::
newParagraph
()
void
ManGenerator
::
newParagraph
()
...
@@ -470,3 +493,42 @@ void ManGenerator::endMemberGroup(bool)
...
@@ -470,3 +493,42 @@ void ManGenerator::endMemberGroup(bool)
t
<<
"
\n
.in -1c"
;
t
<<
"
\n
.in -1c"
;
firstCol
=
FALSE
;
firstCol
=
FALSE
;
}
}
void
ManGenerator
::
startSection
(
const
char
*
,
const
char
*
,
bool
sub
)
{
if
(
!
inHeader
)
{
if
(
sub
)
{
startMemberHeader
();
}
else
{
startGroupHeader
();
}
}
}
void
ManGenerator
::
endSection
(
const
char
*
,
bool
sub
)
{
if
(
!
inHeader
)
{
if
(
sub
)
{
endMemberHeader
();
}
else
{
endGroupHeader
();
}
}
else
{
t
<<
"
\n
"
;
firstCol
=
TRUE
;
paragraph
=
FALSE
;
inHeader
=
FALSE
;
}
}
src/mangen.h
View file @
75fed736
...
@@ -175,8 +175,8 @@ class ManGenerator : public OutputGenerator
...
@@ -175,8 +175,8 @@ class ManGenerator : public OutputGenerator
void
endParamList
()
{
endDescList
();
}
void
endParamList
()
{
endDescList
();
}
void
endDescTitle
();
void
endDescTitle
();
void
writeDescItem
();
void
writeDescItem
();
void
startSection
(
const
char
*
,
const
char
*
,
bool
)
{}
void
startSection
(
const
char
*
,
const
char
*
,
bool
)
;
void
endSection
(
const
char
*
,
bool
)
{}
void
endSection
(
const
char
*
,
bool
)
;
void
writeSectionRef
(
const
char
*
,
const
char
*
,
const
char
*
,
const
char
*
)
{}
void
writeSectionRef
(
const
char
*
,
const
char
*
,
const
char
*
,
const
char
*
)
{}
void
writeSectionRefItem
(
const
char
*
,
const
char
*
,
const
char
*
)
{}
void
writeSectionRefItem
(
const
char
*
,
const
char
*
,
const
char
*
)
{}
//void writeSectionRefAnchor(const char *,const char *,const char *) {}
//void writeSectionRefAnchor(const char *,const char *,const char *) {}
...
@@ -231,6 +231,7 @@ class ManGenerator : public OutputGenerator
...
@@ -231,6 +231,7 @@ class ManGenerator : public OutputGenerator
int
col
;
int
col
;
bool
upperCase
;
bool
upperCase
;
bool
insideTabbing
;
bool
insideTabbing
;
bool
inHeader
;
ManGenerator
(
const
ManGenerator
&
g
);
ManGenerator
(
const
ManGenerator
&
g
);
ManGenerator
&
operator
=
(
const
ManGenerator
&
g
);
ManGenerator
&
operator
=
(
const
ManGenerator
&
g
);
...
...
src/memberdef.cpp
View file @
75fed736
...
@@ -241,8 +241,7 @@ MemberDef::MemberDef(const char *df,int dl,
...
@@ -241,8 +241,7 @@ MemberDef::MemberDef(const char *df,int dl,
memDec
=
0
;
memDec
=
0
;
group
=
0
;
group
=
0
;
grpId
=-
1
;
grpId
=-
1
;
exampleList
=
0
;
exampleSDict
=
0
;
exampleDict
=
0
;
enumFields
=
0
;
enumFields
=
0
;
enumScope
=
0
;
enumScope
=
0
;
enumDeclList
=
0
;
enumDeclList
=
0
;
...
@@ -271,6 +270,7 @@ MemberDef::MemberDef(const char *df,int dl,
...
@@ -271,6 +270,7 @@ MemberDef::MemberDef(const char *df,int dl,
indDepth
=
0
;
indDepth
=
0
;
section
=
0
;
section
=
0
;
explExt
=
FALSE
;
explExt
=
FALSE
;
cachedAnonymousType
=
0
;
maxInitLines
=
Config_getInt
(
"MAX_INITIALIZER_LINES"
);
maxInitLines
=
Config_getInt
(
"MAX_INITIALIZER_LINES"
);
userInitLines
=-
1
;
userInitLines
=-
1
;
docEnumValues
=
FALSE
;
docEnumValues
=
FALSE
;
...
@@ -315,8 +315,7 @@ MemberDef::MemberDef(const char *df,int dl,
...
@@ -315,8 +315,7 @@ MemberDef::MemberDef(const char *df,int dl,
MemberDef
::~
MemberDef
()
MemberDef
::~
MemberDef
()
{
{
delete
redefinedBy
;
delete
redefinedBy
;
delete
exampleList
;
delete
exampleSDict
;
delete
exampleDict
;
delete
enumFields
;
delete
enumFields
;
delete
argList
;
delete
argList
;
delete
tArgList
;
delete
tArgList
;
...
@@ -338,17 +337,15 @@ bool MemberDef::addExample(const char *anchor,const char *nameStr,
...
@@ -338,17 +337,15 @@ bool MemberDef::addExample(const char *anchor,const char *nameStr,
const
char
*
file
)
const
char
*
file
)
{
{
//printf("%s::addExample(%s,%s,%s)\n",name.data(),anchor,nameStr,file);
//printf("%s::addExample(%s,%s,%s)\n",name.data(),anchor,nameStr,file);
if
(
exampleDict
==
0
)
exampleDict
=
new
ExampleDict
;
if
(
exampleSDict
==
0
)
exampleSDict
=
new
ExampleSDict
;
if
(
exampleList
==
0
)
exampleList
=
new
ExampleList
;
if
(
exampleSDict
->
find
(
nameStr
)
==
0
)
if
(
exampleDict
->
find
(
nameStr
)
==
0
)
{
{
//printf("Add reference to example %s to member %s\n",nameStr,name.data());
//printf("Add reference to example %s to member %s\n",nameStr,name.data());
Example
*
e
=
new
Example
;
Example
*
e
=
new
Example
;
e
->
anchor
=
anchor
;
e
->
anchor
=
anchor
;
e
->
name
=
nameStr
;
e
->
name
=
nameStr
;
e
->
file
=
file
;
e
->
file
=
file
;
exampleDict
->
insert
(
nameStr
,
e
);
exampleSDict
->
inSort
(
nameStr
,
e
);
exampleList
->
inSort
(
e
);
return
TRUE
;
return
TRUE
;
}
}
return
FALSE
;
return
FALSE
;
...
@@ -356,32 +353,12 @@ bool MemberDef::addExample(const char *anchor,const char *nameStr,
...
@@ -356,32 +353,12 @@ bool MemberDef::addExample(const char *anchor,const char *nameStr,
bool
MemberDef
::
hasExamples
()
bool
MemberDef
::
hasExamples
()
{
{
if
(
example
Lis
t
==
0
)
if
(
example
SDic
t
==
0
)
return
FALSE
;
return
FALSE
;
else
else
return
example
Lis
t
->
count
()
>
0
;
return
example
SDic
t
->
count
()
>
0
;
}
}
#if 0
void MemberDef::writeExample(OutputList &ol)
{
Example *e=exampleList->first();
while (e)
{
ol.writeObjectLink(0,e->file,e->anchor,e->name);
e=exampleList->next();
if (e)
{
if (exampleList->at()==(int)exampleList->count()-1)
ol.writeString(" and ");
else
ol.writeString(", ");
}
}
ol.writeString(".");
}
#endif
QCString
MemberDef
::
getOutputFileBase
()
const
QCString
MemberDef
::
getOutputFileBase
()
const
{
{
if
(
classDef
)
if
(
classDef
)
...
@@ -396,7 +373,7 @@ QCString MemberDef::getOutputFileBase() const
...
@@ -396,7 +373,7 @@ QCString MemberDef::getOutputFileBase() const
{
{
return
nspace
->
getOutputFileBase
();
return
nspace
->
getOutputFileBase
();
}
}
warn
(
defFileName
,
defLine
,
warn
(
m_defFileName
,
m_
defLine
,
"Warning: Internal inconsistency: member %s does not belong to any"
"Warning: Internal inconsistency: member %s does not belong to any"
" container!"
,
name
().
data
()
" container!"
,
name
().
data
()
);
);
...
@@ -457,9 +434,19 @@ void MemberDef::writeLink(OutputList &ol,ClassDef *cd,NamespaceDef *nd,
...
@@ -457,9 +434,19 @@ void MemberDef::writeLink(OutputList &ol,ClassDef *cd,NamespaceDef *nd,
/*! If this member has an anonymous class/struct/union as its type, then
/*! If this member has an anonymous class/struct/union as its type, then
* this method will return the ClassDef that describes this return type.
* this method will return the ClassDef that describes this return type.
*/
*/
ClassDef
*
MemberDef
::
getClassDefOfAnonymousType
(
const
char
*
scopeName
)
const
ClassDef
*
MemberDef
::
getClassDefOfAnonymousType
(
)
{
{
QCString
cname
=
scopeName
;
if
(
cachedAnonymousType
)
return
cachedAnonymousType
;
QCString
cname
;
if
(
getClassDef
()
!=
0
)
{
cname
=
getClassDef
()
->
name
().
copy
();
}
else
if
(
getNamespaceDef
()
!=
0
)
{
cname
=
getNamespaceDef
()
->
name
().
copy
();
}
QCString
ltype
(
type
);
QCString
ltype
(
type
);
// strip `static' keyword from ltype
// strip `static' keyword from ltype
if
(
ltype
.
left
(
7
)
==
"static "
)
ltype
=
ltype
.
right
(
ltype
.
length
()
-
7
);
if
(
ltype
.
left
(
7
)
==
"static "
)
ltype
=
ltype
.
right
(
ltype
.
length
()
-
7
);
...
@@ -495,6 +482,7 @@ ClassDef *MemberDef::getClassDefOfAnonymousType(const char *scopeName) const
...
@@ -495,6 +482,7 @@ ClassDef *MemberDef::getClassDefOfAnonymousType(const char *scopeName) const
annoClassDef
=
getClass
(
ts
);
annoClassDef
=
getClass
(
ts
);
}
}
}
}
cachedAnonymousType
=
annoClassDef
;
return
annoClassDef
;
return
annoClassDef
;
}
}
...
@@ -539,7 +527,7 @@ void MemberDef::writeDeclaration(OutputList &ol,
...
@@ -539,7 +527,7 @@ void MemberDef::writeDeclaration(OutputList &ol,
bool
inGroup
bool
inGroup
)
)
{
{
//printf("%s MemberDef::writeDeclaration()
\n",name().data()
);
//printf("%s MemberDef::writeDeclaration()
inGroup=%d\n",name().data(),inGroup
);
// hide members whose brief section should not be visible
// hide members whose brief section should not be visible
if
(
!
isBriefSectionVisible
())
return
;
if
(
!
isBriefSectionVisible
())
return
;
...
@@ -598,7 +586,7 @@ void MemberDef::writeDeclaration(OutputList &ol,
...
@@ -598,7 +586,7 @@ void MemberDef::writeDeclaration(OutputList &ol,
if
(
hasHtmlHelp
)
htmlHelp
=
HtmlHelp
::
getInstance
();
if
(
hasHtmlHelp
)
htmlHelp
=
HtmlHelp
::
getInstance
();
// search for the last anonymous scope in the member type
// search for the last anonymous scope in the member type
ClassDef
*
annoClassDef
=
getClassDefOfAnonymousType
(
(
cd
||
nd
)
?
cname
.
data
()
:
0
);
ClassDef
*
annoClassDef
=
getClassDefOfAnonymousType
();
// start a new member declaration
// start a new member declaration
ol
.
startMemberItem
((
annoClassDef
||
annMemb
||
annEnumType
)
?
1
:
0
);
ol
.
startMemberItem
((
annoClassDef
||
annMemb
||
annEnumType
)
?
1
:
0
);
...
@@ -659,7 +647,6 @@ void MemberDef::writeDeclaration(OutputList &ol,
...
@@ -659,7 +647,6 @@ void MemberDef::writeDeclaration(OutputList &ol,
if
(
annoClassDef
)
// type is an anonymous compound
if
(
annoClassDef
)
// type is an anonymous compound
{
{
int
ir
=
i
+
l
;
int
ir
=
i
+
l
;
//printf("class found!\n");
annoClassDef
->
writeDeclaration
(
ol
,
annMemb
,
inGroup
);
annoClassDef
->
writeDeclaration
(
ol
,
annMemb
,
inGroup
);
ol
.
startMemberItem
(
2
);
ol
.
startMemberItem
(
2
);
int
j
;
int
j
;
...
@@ -674,10 +661,6 @@ void MemberDef::writeDeclaration(OutputList &ol,
...
@@ -674,10 +661,6 @@ void MemberDef::writeDeclaration(OutputList &ol,
{
{
ol
.
docify
(
";"
);
ol
.
docify
(
";"
);
}
}
//else
//{
// ol.docify(varName);
//}
}
}
else
else
{
{
...
@@ -724,7 +707,8 @@ void MemberDef::writeDeclaration(OutputList &ol,
...
@@ -724,7 +707,8 @@ void MemberDef::writeDeclaration(OutputList &ol,
// write name
// write name
if
(
!
name
().
isEmpty
()
&&
name
().
at
(
0
)
!=
'@'
)
if
(
!
name
().
isEmpty
()
&&
name
().
at
(
0
)
!=
'@'
)
{
{
if
(
isLinkable
())
//printf("Member name=`%s gd=%p md->groupDef=%p inGroup=%d isLinkable()=%d\n",name().data(),gd,getGroupDef(),inGroup,isLinkable());
if
(
/*d->isLinkable() &&*/
isLinkable
())
{
{
if
(
annMemb
)
if
(
annMemb
)
{
{
...
@@ -738,9 +722,11 @@ void MemberDef::writeDeclaration(OutputList &ol,
...
@@ -738,9 +722,11 @@ void MemberDef::writeDeclaration(OutputList &ol,
annMemb
->
annUsed
=
annUsed
=
TRUE
;
annMemb
->
annUsed
=
annUsed
=
TRUE
;
}
}
else
else
{
//printf("writeLink %s->%d\n",name.data(),hasDocumentation());
//printf("writeLink %s->%d\n",name.data(),hasDocumentation());
writeLink
(
ol
,
cd
,
nd
,
fd
,
gd
);
writeLink
(
ol
,
cd
,
nd
,
fd
,
gd
);
}
}
}
else
// there is a brief member description and brief member
else
// there is a brief member description and brief member
// descriptions are enabled or there is no detailed description.
// descriptions are enabled or there is no detailed description.
{
{
...
@@ -796,7 +782,7 @@ void MemberDef::writeDeclaration(OutputList &ol,
...
@@ -796,7 +782,7 @@ void MemberDef::writeDeclaration(OutputList &ol,
if
(
!
briefDescription
().
isEmpty
()
&&
Config_getBool
(
"BRIEF_MEMBER_DESC"
)
&&
!
annMemb
)
if
(
!
briefDescription
().
isEmpty
()
&&
Config_getBool
(
"BRIEF_MEMBER_DESC"
)
&&
!
annMemb
)
{
{
ol
.
startMemberDescription
();
ol
.
startMemberDescription
();
parseDoc
(
ol
,
defFileName
,
defLine
,
cname
,
name
(),
briefDescription
());
parseDoc
(
ol
,
m_defFileName
,
m_
defLine
,
cname
,
name
(),
briefDescription
());
if
(
detailsVisible
)
if
(
detailsVisible
)
{
{
ol
.
pushGeneratorState
();
ol
.
pushGeneratorState
();
...
@@ -850,6 +836,7 @@ bool MemberDef::isDetailedSectionVisible(bool inGroup) const
...
@@ -850,6 +836,7 @@ bool MemberDef::isDetailedSectionVisible(bool inGroup) const
bool
staticFilter
=
getClassDef
()
!=
0
||
!
isStatic
()
||
Config_getBool
(
"EXTRACT_STATIC"
);
bool
staticFilter
=
getClassDef
()
!=
0
||
!
isStatic
()
||
Config_getBool
(
"EXTRACT_STATIC"
);
// details are not part of a group or this is for a group documentation page
// details are not part of a group or this is for a group documentation page
// TODO: FIX THIS!!! This should made such that it is always TRUE.
bool
groupFilter
=
getGroupDef
()
==
0
||
inGroup
;
bool
groupFilter
=
getGroupDef
()
==
0
||
inGroup
;
// member is part of an anonymous scope that is the type of
// member is part of an anonymous scope that is the type of
...
@@ -887,7 +874,6 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
...
@@ -887,7 +874,6 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
QCString
cname
=
container
->
name
();
QCString
cname
=
container
->
name
();
QCString
cfname
=
container
->
getOutputFileBase
();
QCString
cfname
=
container
->
getOutputFileBase
();
// get member name
// get member name
QCString
doxyName
=
name
().
copy
();
QCString
doxyName
=
name
().
copy
();
// prepend scope if there is any. TODO: make this optional for C only docs
// prepend scope if there is any. TODO: make this optional for C only docs
...
@@ -1122,14 +1108,14 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
...
@@ -1122,14 +1108,14 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
)
/* || !annMemb */
)
/* || !annMemb */
)
)
{
{
parseDoc
(
ol
,
defFileName
,
defLine
,
scopeName
,
name
(),
briefDescription
());
parseDoc
(
ol
,
m_defFileName
,
m_
defLine
,
scopeName
,
name
(),
briefDescription
());
ol
.
newParagraph
();
ol
.
newParagraph
();
}
}
/* write detailed description */
/* write detailed description */
if
(
!
documentation
().
isEmpty
())
if
(
!
documentation
().
isEmpty
())
{
{
parseDoc
(
ol
,
defFileName
,
defLine
,
scopeName
,
name
(),
documentation
()
+
"
\n
"
);
parseDoc
(
ol
,
m_defFileName
,
m_
defLine
,
scopeName
,
name
(),
documentation
()
+
"
\n
"
);
ol
.
pushGeneratorState
();
ol
.
pushGeneratorState
();
ol
.
disableAllBut
(
OutputGenerator
::
RTF
);
ol
.
disableAllBut
(
OutputGenerator
::
RTF
);
ol
.
newParagraph
();
ol
.
newParagraph
();
...
@@ -1161,7 +1147,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
...
@@ -1161,7 +1147,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
ol
.
endEmphasis
();
ol
.
endEmphasis
();
ol
.
endDescTableTitle
();
ol
.
endDescTableTitle
();
ol
.
startDescTableData
();
ol
.
startDescTableData
();
parseDoc
(
ol
,
defFileName
,
defLine
,
scopeName
,
name
(),
a
->
docs
);
parseDoc
(
ol
,
m_defFileName
,
m_
defLine
,
scopeName
,
name
(),
a
->
docs
);
ol
.
endDescTableData
();
ol
.
endDescTableData
();
}
}
}
}
...
@@ -1218,7 +1204,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
...
@@ -1218,7 +1204,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
if
(
!
fmd
->
briefDescription
().
isEmpty
())
if
(
!
fmd
->
briefDescription
().
isEmpty
())
{
{
parseDoc
(
ol
,
defFileName
,
defLine
,
scopeName
,
fmd
->
name
(),
fmd
->
briefDescription
());
parseDoc
(
ol
,
m_defFileName
,
m_
defLine
,
scopeName
,
fmd
->
name
(),
fmd
->
briefDescription
());
//ol.newParagraph();
//ol.newParagraph();
}
}
if
(
!
fmd
->
briefDescription
().
isEmpty
()
&&
if
(
!
fmd
->
briefDescription
().
isEmpty
()
&&
...
@@ -1228,7 +1214,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
...
@@ -1228,7 +1214,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
}
}
if
(
!
fmd
->
documentation
().
isEmpty
())
if
(
!
fmd
->
documentation
().
isEmpty
())
{
{
parseDoc
(
ol
,
defFileName
,
defLine
,
scopeName
,
fmd
->
name
(),
fmd
->
documentation
()
+
"
\n
"
);
parseDoc
(
ol
,
m_defFileName
,
m_
defLine
,
scopeName
,
fmd
->
name
(),
fmd
->
documentation
()
+
"
\n
"
);
}
}
ol
.
endDescTableData
();
ol
.
endDescTableData
();
}
}
...
@@ -1376,7 +1362,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
...
@@ -1376,7 +1362,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
ol
.
endBold
();
ol
.
endBold
();
ol
.
endDescTitle
();
ol
.
endDescTitle
();
ol
.
writeDescItem
();
ol
.
writeDescItem
();
writeExample
(
ol
,
getExample
List
());
writeExample
(
ol
,
getExample
s
());
//ol.endDescItem();
//ol.endDescItem();
ol
.
endDescList
();
ol
.
endDescList
();
}
}
...
@@ -1412,7 +1398,7 @@ void MemberDef::warnIfUndocumented()
...
@@ -1412,7 +1398,7 @@ void MemberDef::warnIfUndocumented()
t
=
"file"
,
d
=
fd
;
t
=
"file"
,
d
=
fd
;
if
(
d
&&
d
->
isLinkable
()
&&
!
isLinkable
()
&&
name
().
find
(
'@'
)
==-
1
)
if
(
d
&&
d
->
isLinkable
()
&&
!
isLinkable
()
&&
name
().
find
(
'@'
)
==-
1
)
warn_undoc
(
defFileName
,
defLine
,
"Warning: Member %s of %s %s is not documented."
,
warn_undoc
(
m_defFileName
,
m_
defLine
,
"Warning: Member %s of %s %s is not documented."
,
name
().
data
(),
t
,
d
->
name
().
data
());
name
().
data
(),
t
,
d
->
name
().
data
());
}
}
...
@@ -1481,3 +1467,9 @@ QCString MemberDef::anchor() const
...
@@ -1481,3 +1467,9 @@ QCString MemberDef::anchor() const
if
(
enumScope
)
return
enumScope
->
anchor
()
+
anc
;
if
(
enumScope
)
return
enumScope
->
anchor
()
+
anc
;
return
anc
;
return
anc
;
}
}
void
MemberDef
::
setGroupDef
(
GroupDef
*
gd
)
{
printf
(
"%s MemberDef::setGroupDef(%s)
\n
"
,
name
().
data
(),
gd
->
name
().
data
());
group
=
gd
;
}
src/memberdef.h
View file @
75fed736
...
@@ -31,8 +31,7 @@ class GroupDef;
...
@@ -31,8 +31,7 @@ class GroupDef;
class
FileDef
;
class
FileDef
;
class
MemberList
;
class
MemberList
;
class
MemberGroup
;
class
MemberGroup
;
class
ExampleList
;
class
ExampleSDict
;
class
ExampleDict
;
class
OutputList
;
class
OutputList
;
class
GroupDef
;
class
GroupDef
;
class
QTextStream
;
class
QTextStream
;
...
@@ -138,7 +137,7 @@ class MemberDef : public Definition
...
@@ -138,7 +137,7 @@ class MemberDef : public Definition
void
setMaxInitLines
(
int
lines
)
{
userInitLines
=
lines
;
}
void
setMaxInitLines
(
int
lines
)
{
userInitLines
=
lines
;
}
void
setMemberClass
(
ClassDef
*
cd
)
{
classDef
=
cd
;
}
void
setMemberClass
(
ClassDef
*
cd
)
{
classDef
=
cd
;
}
void
setSectionList
(
MemberList
*
sl
)
{
section
=
sl
;
}
void
setSectionList
(
MemberList
*
sl
)
{
section
=
sl
;
}
void
setGroupDef
(
GroupDef
*
gd
)
{
group
=
gd
;
}
void
setGroupDef
(
GroupDef
*
gd
)
;
void
setExplicitExternal
(
bool
b
)
{
explExt
=
b
;
}
void
setExplicitExternal
(
bool
b
)
{
explExt
=
b
;
}
void
makeRelated
()
{
related
=
TRUE
;
}
void
makeRelated
()
{
related
=
TRUE
;
}
...
@@ -177,8 +176,7 @@ class MemberDef : public Definition
...
@@ -177,8 +176,7 @@ class MemberDef : public Definition
// example related members
// example related members
bool
addExample
(
const
char
*
anchor
,
const
char
*
name
,
const
char
*
file
);
bool
addExample
(
const
char
*
anchor
,
const
char
*
name
,
const
char
*
file
);
bool
hasExamples
();
bool
hasExamples
();
ExampleList
*
getExampleList
()
const
{
return
exampleList
;
}
ExampleSDict
*
getExamples
()
const
{
return
exampleSDict
;
}
// prototype related members
// prototype related members
void
setPrototype
(
bool
p
)
{
proto
=
p
;
}
void
setPrototype
(
bool
p
)
{
proto
=
p
;
}
...
@@ -217,7 +215,7 @@ class MemberDef : public Definition
...
@@ -217,7 +215,7 @@ class MemberDef : public Definition
QCString
getScopeString
()
const
;
QCString
getScopeString
()
const
;
ClassDef
*
getClassDefOfAnonymousType
(
const
char
*
scopeName
)
const
;
ClassDef
*
getClassDefOfAnonymousType
(
)
;
private
:
private
:
ClassDef
*
classDef
;
// member of or related to
ClassDef
*
classDef
;
// member of or related to
...
@@ -228,8 +226,9 @@ class MemberDef : public Definition
...
@@ -228,8 +226,9 @@ class MemberDef : public Definition
MemberList
*
redefinedBy
;
// the list of members that redefine this one
MemberList
*
redefinedBy
;
// the list of members that redefine this one
MemberDef
*
memDef
;
// member definition for this declaration
MemberDef
*
memDef
;
// member definition for this declaration
MemberDef
*
memDec
;
// member declaration for this definition
MemberDef
*
memDec
;
// member declaration for this definition
ExampleList
*
exampleList
;
// a list of all examples using this member
ExampleDict
*
exampleDict
;
// a dictionary of all examples for quick access
ExampleSDict
*
exampleSDict
;
// a dictionary of all examples for quick access
MemberList
*
enumFields
;
// enumeration fields
MemberList
*
enumFields
;
// enumeration fields
OutputList
*
enumDeclList
;
// stored piece of documentation for enumeration.
OutputList
*
enumDeclList
;
// stored piece of documentation for enumeration.
NamespaceDef
*
nspace
;
// the namespace this member is in.
NamespaceDef
*
nspace
;
// the namespace this member is in.
...
@@ -271,6 +270,11 @@ class MemberDef : public Definition
...
@@ -271,6 +270,11 @@ class MemberDef : public Definition
GroupDef
*
group
;
// group in which this member is in
GroupDef
*
group
;
// group in which this member is in
bool
explExt
;
// member was explicitly declared external
bool
explExt
;
// member was explicitly declared external
ClassDef
*
cachedAnonymousType
;
// if the member has an anonymous compound
// as its type then this is computed by
// getClassDefOfAnonymousType() and
// cached here.
// disable copying of member defs
// disable copying of member defs
MemberDef
(
const
MemberDef
&
);
MemberDef
(
const
MemberDef
&
);
...
...
src/memberlist.cpp
View file @
75fed736
/******************************************************************************
/******************************************************************************
*
*
*
$Id$
*
*
*
* Copyright (C) 1997-2001 by Dimitri van Heesch.
* Copyright (C) 1997-2001 by Dimitri van Heesch.
*
*
...
...
src/membername.h
View file @
75fed736
...
@@ -20,6 +20,7 @@
...
@@ -20,6 +20,7 @@
#include <qlist.h>
#include <qlist.h>
#include "memberdef.h"
#include "memberdef.h"
#include "sortdict.h"
class
MemberName
:
public
QList
<
MemberDef
>
class
MemberName
:
public
QList
<
MemberDef
>
{
{
...
@@ -107,6 +108,19 @@ class MemberNameInfoDict : public QDict<MemberNameInfo>
...
@@ -107,6 +108,19 @@ class MemberNameInfoDict : public QDict<MemberNameInfo>
~
MemberNameInfoDict
()
{}
~
MemberNameInfoDict
()
{}
};
};
class
MemberNameInfoSDict
:
public
SDict
<
MemberNameInfo
>
{
public
:
MemberNameInfoSDict
(
int
size
)
:
SDict
<
MemberNameInfo
>
(
size
)
{}
~
MemberNameInfoSDict
()
{}
int
compareItems
(
GCI
item1
,
GCI
item2
)
{
return
stricmp
(
((
MemberNameInfo
*
)
item1
)
->
memberName
(),
((
MemberNameInfo
*
)
item2
)
->
memberName
()
);
}
};
class
MemberNameInfoListIterator
:
public
QListIterator
<
MemberNameInfo
>
class
MemberNameInfoListIterator
:
public
QListIterator
<
MemberNameInfo
>
{
{
public
:
public
:
...
...
src/namespacedef.cpp
View file @
75fed736
...
@@ -32,23 +32,22 @@ NamespaceDef::NamespaceDef(const char *df,int dl,
...
@@ -32,23 +32,22 @@ NamespaceDef::NamespaceDef(const char *df,int dl,
Definition
(
df
,
dl
,
name
)
Definition
(
df
,
dl
,
name
)
{
{
fileName
=
(
QCString
)
"namespace_"
+
name
;
fileName
=
(
QCString
)
"namespace_"
+
name
;
class
List
=
new
ClassList
;
class
SDict
=
new
ClassSDict
(
257
)
;
classDict
=
new
ClassDict
(
1009
);
namespaceSDict
=
new
NamespaceSDict
(
257
);
//memList = new MemberList
;
m_innerCompounds
=
new
SDict
<
Definition
>
(
257
)
;
usingDirList
=
0
;
usingDirList
=
0
;
usingDeclList
=
0
;
usingDeclList
=
0
;
setReference
(
lref
);
setReference
(
lref
);
memberGroupList
=
new
MemberGroupList
;
memberGroupList
=
new
MemberGroupList
;
memberGroupList
->
setAutoDelete
(
TRUE
);
memberGroupList
->
setAutoDelete
(
TRUE
);
memberGroupDict
=
new
MemberGroupDict
(
1009
);
memberGroupDict
=
new
MemberGroupDict
(
1009
);
defFileName
=
df
;
defLine
=
dl
;
}
}
NamespaceDef
::~
NamespaceDef
()
NamespaceDef
::~
NamespaceDef
()
{
{
delete
classList
;
delete
classSDict
;
delete
classDict
;
delete
namespaceSDict
;
delete
m_innerCompounds
;
delete
usingDirList
;
delete
usingDirList
;
delete
usingDeclList
;
delete
usingDeclList
;
delete
memberGroupList
;
delete
memberGroupList
;
...
@@ -77,13 +76,23 @@ void NamespaceDef::insertUsedFile(const char *f)
...
@@ -77,13 +76,23 @@ void NamespaceDef::insertUsedFile(const char *f)
void
NamespaceDef
::
insertClass
(
ClassDef
*
cd
)
void
NamespaceDef
::
insertClass
(
ClassDef
*
cd
)
{
{
if
(
classDict
->
find
(
cd
->
name
())
==
0
)
if
(
class
S
Dict
->
find
(
cd
->
name
())
==
0
)
{
{
if
(
Config_getBool
(
"SORT_MEMBER_DOCS"
))
if
(
Config_getBool
(
"SORT_MEMBER_DOCS"
))
class
List
->
inSort
(
cd
);
class
SDict
->
inSort
(
cd
->
name
(),
cd
);
else
else
classList
->
append
(
cd
);
classSDict
->
append
(
cd
->
name
(),
cd
);
classDict
->
insert
(
cd
->
name
(),
cd
);
}
}
void
NamespaceDef
::
insertNamespace
(
NamespaceDef
*
nd
)
{
if
(
namespaceSDict
->
find
(
nd
->
name
())
==
0
)
{
if
(
Config_getBool
(
"SORT_MEMBER_DOCS"
))
namespaceSDict
->
inSort
(
nd
->
name
(),
nd
);
else
namespaceSDict
->
append
(
nd
->
name
(),
nd
);
}
}
}
}
...
@@ -219,7 +228,7 @@ void NamespaceDef::writeDocumentation(OutputList &ol)
...
@@ -219,7 +228,7 @@ void NamespaceDef::writeDocumentation(OutputList &ol)
OutputList
briefOutput
(
&
ol
);
OutputList
briefOutput
(
&
ol
);
if
(
!
briefDescription
().
isEmpty
())
if
(
!
briefDescription
().
isEmpty
())
{
{
parseDoc
(
briefOutput
,
defFileName
,
defLine
,
name
(),
0
,
briefDescription
());
parseDoc
(
briefOutput
,
m_defFileName
,
m_
defLine
,
name
(),
0
,
briefDescription
());
ol
+=
briefOutput
;
ol
+=
briefOutput
;
ol
.
writeString
(
"
\n
"
);
ol
.
writeString
(
"
\n
"
);
ol
.
pushGeneratorState
();
ol
.
pushGeneratorState
();
...
@@ -237,7 +246,7 @@ void NamespaceDef::writeDocumentation(OutputList &ol)
...
@@ -237,7 +246,7 @@ void NamespaceDef::writeDocumentation(OutputList &ol)
ol
.
endTextBlock
();
ol
.
endTextBlock
();
ol
.
startMemberSections
();
ol
.
startMemberSections
();
class
Lis
t
->
writeDeclaration
(
ol
);
class
SDic
t
->
writeDeclaration
(
ol
);
/* write user defined member groups */
/* write user defined member groups */
MemberGroupListIterator
mgli
(
*
memberGroupList
);
MemberGroupListIterator
mgli
(
*
memberGroupList
);
...
@@ -283,7 +292,7 @@ void NamespaceDef::writeDocumentation(OutputList &ol)
...
@@ -283,7 +292,7 @@ void NamespaceDef::writeDocumentation(OutputList &ol)
}
}
if
(
!
documentation
().
isEmpty
())
if
(
!
documentation
().
isEmpty
())
{
{
parseDoc
(
ol
,
defFileName
,
defLine
,
name
(),
0
,
documentation
()
+
"
\n
"
);
parseDoc
(
ol
,
m_defFileName
,
m_
defLine
,
name
(),
0
,
documentation
()
+
"
\n
"
);
ol
.
newParagraph
();
ol
.
newParagraph
();
}
}
ol
.
endTextBlock
();
ol
.
endTextBlock
();
...
@@ -328,7 +337,7 @@ void NamespaceDef::writeDocumentation(OutputList &ol)
...
@@ -328,7 +337,7 @@ void NamespaceDef::writeDocumentation(OutputList &ol)
int
NamespaceDef
::
countMembers
()
int
NamespaceDef
::
countMembers
()
{
{
allMemberList
.
countDocMembers
();
allMemberList
.
countDocMembers
();
return
allMemberList
.
numDocMembers
()
+
class
Lis
t
->
count
();
return
allMemberList
.
numDocMembers
()
+
class
SDic
t
->
count
();
}
}
void
NamespaceDef
::
addUsingDirective
(
NamespaceDef
*
nd
)
void
NamespaceDef
::
addUsingDirective
(
NamespaceDef
*
nd
)
...
@@ -354,3 +363,15 @@ QCString NamespaceDef::getOutputFileBase() const
...
@@ -354,3 +363,15 @@ QCString NamespaceDef::getOutputFileBase() const
return
convertNameToFile
(
fileName
);
return
convertNameToFile
(
fileName
);
}
}
Definition
*
NamespaceDef
::
findInnerCompound
(
const
char
*
name
)
{
if
(
name
==
0
)
return
0
;
return
m_innerCompounds
->
find
(
name
);
}
void
NamespaceDef
::
addInnerCompound
(
Definition
*
d
)
{
m_innerCompounds
->
append
(
d
->
localName
(),
d
);
}
src/namespacedef.h
View file @
75fed736
...
@@ -21,17 +21,19 @@
...
@@ -21,17 +21,19 @@
#include "qtbc.h"
#include "qtbc.h"
#include <qstrlist.h>
#include <qstrlist.h>
#include <qdict.h>
#include <qdict.h>
#include "sortdict.h"
#include "definition.h"
#include "definition.h"
#include "memberlist.h"
#include "memberlist.h"
class
ClassDef
;
class
ClassDef
;
class
OutputList
;
class
ClassList
;
class
ClassList
;
class
ClassDict
;
class
OutputList
;
class
ClassSDict
;
class
MemberDef
;
class
MemberDef
;
class
NamespaceList
;
class
NamespaceList
;
class
MemberGroupDict
;
class
MemberGroupDict
;
class
MemberGroupList
;
class
MemberGroupList
;
class
NamespaceSDict
;
class
NamespaceDef
:
public
Definition
class
NamespaceDef
:
public
Definition
{
{
...
@@ -43,8 +45,11 @@ class NamespaceDef : public Definition
...
@@ -43,8 +45,11 @@ class NamespaceDef : public Definition
QCString
getOutputFileBase
()
const
;
QCString
getOutputFileBase
()
const
;
void
insertUsedFile
(
const
char
*
fname
);
void
insertUsedFile
(
const
char
*
fname
);
void
writeDocumentation
(
OutputList
&
ol
);
void
writeDocumentation
(
OutputList
&
ol
);
void
insertClass
(
ClassDef
*
cd
);
void
insertClass
(
ClassDef
*
cd
);
void
insertNamespace
(
NamespaceDef
*
nd
);
void
insertMember
(
MemberDef
*
md
);
void
insertMember
(
MemberDef
*
md
);
void
computeAnchors
();
void
computeAnchors
();
int
countMembers
();
int
countMembers
();
void
addUsingDirective
(
NamespaceDef
*
nd
);
void
addUsingDirective
(
NamespaceDef
*
nd
);
...
@@ -66,6 +71,9 @@ class NamespaceDef : public Definition
...
@@ -66,6 +71,9 @@ class NamespaceDef : public Definition
void
addMembersToMemberGroup
();
void
addMembersToMemberGroup
();
void
distributeMemberGroupDocumentation
();
void
distributeMemberGroupDocumentation
();
virtual
Definition
*
findInnerCompound
(
const
char
*
name
);
void
addInnerCompound
(
Definition
*
d
);
//protected:
//protected:
// void addMemberListToGroup(MemberList *,bool (MemberDef::*)() const);
// void addMemberListToGroup(MemberList *,bool (MemberDef::*)() const);
...
@@ -73,10 +81,15 @@ class NamespaceDef : public Definition
...
@@ -73,10 +81,15 @@ class NamespaceDef : public Definition
//QCString reference;
//QCString reference;
QCString
fileName
;
QCString
fileName
;
QStrList
files
;
QStrList
files
;
ClassList
*
classList
;
ClassDict
*
classDict
;
/*! Classes inside this namespace */
ClassSDict
*
classSDict
;
/*! Namespaces inside this namespace */
NamespaceSDict
*
namespaceSDict
;
NamespaceList
*
usingDirList
;
NamespaceList
*
usingDirList
;
ClassList
*
usingDeclList
;
ClassList
*
usingDeclList
;
SDict
<
Definition
>
*
m_innerCompounds
;
MemberList
allMemberList
;
MemberList
allMemberList
;
...
@@ -128,4 +141,19 @@ class NamespaceDict : public QDict<NamespaceDef>
...
@@ -128,4 +141,19 @@ class NamespaceDict : public QDict<NamespaceDef>
~
NamespaceDict
()
{}
~
NamespaceDict
()
{}
};
};
class
NamespaceSDict
:
public
SDict
<
NamespaceDef
>
{
public
:
NamespaceSDict
(
int
size
)
:
SDict
<
NamespaceDef
>
(
size
)
{}
~
NamespaceSDict
()
{}
int
compareItems
(
GCI
item1
,
GCI
item2
)
{
return
stricmp
(((
NamespaceDef
*
)
item1
)
->
name
(),
((
NamespaceDef
*
)
item2
)
->
name
()
);
}
};
#endif
#endif
src/packagedef.cpp
View file @
75fed736
...
@@ -30,22 +30,22 @@
...
@@ -30,22 +30,22 @@
PackageDef
::
PackageDef
(
const
char
*
df
,
int
dl
,
const
char
*
na
,
const
char
*
ref
)
:
PackageDef
::
PackageDef
(
const
char
*
df
,
int
dl
,
const
char
*
na
,
const
char
*
ref
)
:
Definition
(
df
,
dl
,
na
)
Definition
(
df
,
dl
,
na
)
{
{
class
List
=
new
ClassList
;
class
SDict
=
new
ClassSDict
(
17
)
;
packageFileName
=
(
QCString
)
"package_"
+
na
;
packageFileName
=
(
QCString
)
"package_"
+
na
;
setReference
(
ref
);
setReference
(
ref
);
}
}
PackageDef
::~
PackageDef
()
PackageDef
::~
PackageDef
()
{
{
delete
class
Lis
t
;
delete
class
SDic
t
;
}
}
void
PackageDef
::
addClass
(
const
ClassDef
*
def
)
void
PackageDef
::
addClass
(
const
ClassDef
*
cd
)
{
{
if
(
Config_getBool
(
"SORT_MEMBER_DOCS"
))
if
(
Config_getBool
(
"SORT_MEMBER_DOCS"
))
class
List
->
inSort
(
def
);
class
SDict
->
inSort
(
cd
->
name
(),
cd
);
else
else
class
List
->
append
(
def
);
class
SDict
->
append
(
cd
->
name
(),
cd
);
}
}
void
PackageDef
::
writeDocumentation
(
OutputList
&
ol
)
void
PackageDef
::
writeDocumentation
(
OutputList
&
ol
)
...
@@ -61,7 +61,7 @@ void PackageDef::writeDocumentation(OutputList &ol)
...
@@ -61,7 +61,7 @@ void PackageDef::writeDocumentation(OutputList &ol)
OutputList
briefOutput
(
&
ol
);
OutputList
briefOutput
(
&
ol
);
if
(
!
briefDescription
().
isEmpty
())
if
(
!
briefDescription
().
isEmpty
())
{
{
parseDoc
(
briefOutput
,
defFileName
,
defLine
,
name
(),
0
,
briefDescription
());
parseDoc
(
briefOutput
,
m_defFileName
,
m_
defLine
,
name
(),
0
,
briefDescription
());
ol
+=
briefOutput
;
ol
+=
briefOutput
;
ol
.
writeString
(
"
\n
"
);
ol
.
writeString
(
"
\n
"
);
ol
.
pushGeneratorState
();
ol
.
pushGeneratorState
();
...
@@ -81,9 +81,9 @@ void PackageDef::writeDocumentation(OutputList &ol)
...
@@ -81,9 +81,9 @@ void PackageDef::writeDocumentation(OutputList &ol)
ol
.
startMemberSections
();
ol
.
startMemberSections
();
ClassDef
::
CompoundType
ct
;
ClassDef
::
CompoundType
ct
;
ct
=
ClassDef
::
Interface
;
ct
=
ClassDef
::
Interface
;
class
Lis
t
->
writeDeclaration
(
ol
,
&
ct
,
theTranslator
->
trInterfaces
());
class
SDic
t
->
writeDeclaration
(
ol
,
&
ct
,
theTranslator
->
trInterfaces
());
ct
=
ClassDef
::
Class
;
ct
=
ClassDef
::
Class
;
class
Lis
t
->
writeDeclaration
(
ol
,
&
ct
,
theTranslator
->
trClasses
());
class
SDic
t
->
writeDeclaration
(
ol
,
&
ct
,
theTranslator
->
trClasses
());
ol
.
endMemberSections
();
ol
.
endMemberSections
();
if
(
!
Config_getString
(
"GENERATE_TAGFILE"
).
isEmpty
())
if
(
!
Config_getString
(
"GENERATE_TAGFILE"
).
isEmpty
())
...
@@ -114,7 +114,7 @@ void PackageDef::writeDocumentation(OutputList &ol)
...
@@ -114,7 +114,7 @@ void PackageDef::writeDocumentation(OutputList &ol)
// write documentation
// write documentation
if
(
!
documentation
().
isEmpty
())
if
(
!
documentation
().
isEmpty
())
{
{
parseDoc
(
ol
,
defFileName
,
defLine
,
name
(),
0
,
documentation
()
+
"
\n
"
);
parseDoc
(
ol
,
m_defFileName
,
m_
defLine
,
name
(),
0
,
documentation
()
+
"
\n
"
);
}
}
}
}
...
...
src/packagedef.h
View file @
75fed736
...
@@ -24,7 +24,7 @@
...
@@ -24,7 +24,7 @@
#include "definition.h"
#include "definition.h"
#include "sortdict.h"
#include "sortdict.h"
class
Class
Lis
t
;
class
Class
SDic
t
;
class
ClassDef
;
class
ClassDef
;
class
PackageList
;
class
PackageList
;
class
OutputList
;
class
OutputList
;
...
@@ -49,7 +49,7 @@ class PackageDef : public Definition
...
@@ -49,7 +49,7 @@ class PackageDef : public Definition
private
:
private
:
QCString
packageFileName
;
// base name of the generated file
QCString
packageFileName
;
// base name of the generated file
Class
List
*
classList
;
// list of classes in the package
Class
SDict
*
classSDict
;
// list of classes in the package
};
};
class
PackageSDict
:
public
SDict
<
PackageDef
>
class
PackageSDict
:
public
SDict
<
PackageDef
>
...
...
src/rtfgen.cpp
View file @
75fed736
...
@@ -991,16 +991,16 @@ void RTFGenerator::startIndexSection(IndexSections is)
...
@@ -991,16 +991,16 @@ void RTFGenerator::startIndexSection(IndexSections is)
case
isClassDocumentation
:
case
isClassDocumentation
:
{
{
//Compound Documentation
//Compound Documentation
ClassDef
*
cd
=
Doxygen
::
classList
.
first
();
ClassSDict
::
Iterator
cli
(
Doxygen
::
classSDict
);
ClassDef
*
cd
=
0
;
bool
found
=
FALSE
;
bool
found
=
FALSE
;
while
(
cd
&&
!
found
)
for
(
cli
.
toFirst
();(
cd
=
cli
.
current
())
&&
!
found
;
++
cli
)
{
{
if
(
cd
->
isLinkableInProject
())
if
(
cd
->
isLinkableInProject
())
{
{
beginRTFChapter
();
beginRTFChapter
();
found
=
TRUE
;
found
=
TRUE
;
}
}
cd
=
Doxygen
::
classList
.
next
();
}
}
}
}
break
;
break
;
...
@@ -1220,11 +1220,12 @@ void RTFGenerator::endIndexSection(IndexSections is)
...
@@ -1220,11 +1220,12 @@ void RTFGenerator::endIndexSection(IndexSections is)
break
;
break
;
case
isClassDocumentation
:
case
isClassDocumentation
:
{
{
ClassDef
*
cd
=
Doxygen
::
classList
.
first
();
ClassSDict
::
Iterator
cli
(
Doxygen
::
classSDict
);
ClassDef
*
cd
=
0
;
bool
found
=
FALSE
;
bool
found
=
FALSE
;
t
<<
"{
\\
tc
\\
v "
<<
theTranslator
->
trClassDocumentation
()
<<
"}"
<<
endl
;
t
<<
"{
\\
tc
\\
v "
<<
theTranslator
->
trClassDocumentation
()
<<
"}"
<<
endl
;
while
(
cd
&&
!
found
)
for
(
cli
.
toFirst
();(
cd
=
cli
.
current
())
&&
!
found
;
++
cli
)
{
{
if
(
cd
->
isLinkableInProject
())
if
(
cd
->
isLinkableInProject
())
{
{
...
@@ -1234,9 +1235,8 @@ void RTFGenerator::endIndexSection(IndexSections is)
...
@@ -1234,9 +1235,8 @@ void RTFGenerator::endIndexSection(IndexSections is)
t
<<
".rtf
\"
\\\\
*MERGEFORMAT}{
\\
fldrslt includedstuff}}
\n
"
;
t
<<
".rtf
\"
\\\\
*MERGEFORMAT}{
\\
fldrslt includedstuff}}
\n
"
;
found
=
TRUE
;
found
=
TRUE
;
}
}
cd
=
Doxygen
::
classList
.
next
();
}
}
while
(
cd
)
for
(;(
cd
=
cli
.
current
());
++
cli
)
{
{
if
(
cd
->
isLinkableInProject
())
if
(
cd
->
isLinkableInProject
())
{
{
...
@@ -1246,7 +1246,6 @@ void RTFGenerator::endIndexSection(IndexSections is)
...
@@ -1246,7 +1246,6 @@ void RTFGenerator::endIndexSection(IndexSections is)
t
<<
cd
->
getOutputFileBase
();
t
<<
cd
->
getOutputFileBase
();
t
<<
".rtf
\"
\\\\
*MERGEFORMAT}{
\\
fldrslt includedstuff}}
\n
"
;
t
<<
".rtf
\"
\\\\
*MERGEFORMAT}{
\\
fldrslt includedstuff}}
\n
"
;
}
}
cd
=
Doxygen
::
classList
.
next
();
}
}
}
}
break
;
break
;
...
...
src/scanner.l
View file @
75fed736
...
@@ -1557,7 +1557,6 @@ TITLE [tT][iI][tT][lL][eE]
...
@@ -1557,7 +1557,6 @@ TITLE [tT][iI][tT][lL][eE]
{
{
current->endBodyLine = yyLineNr;
current->endBodyLine = yyLineNr;
QCString &cn = current->name;
QCString &cn = current->name;
//QCString rn = stripAnnonymousScope(current_root->name);
QCString rn = current_root->name.copy();
QCString rn = current_root->name.copy();
//printf("cn=`%s' rn=`%s'\n",cn.data(),rn.data());
//printf("cn=`%s' rn=`%s'\n",cn.data(),rn.data());
if (!cn.isEmpty() && !rn.isEmpty() &&
if (!cn.isEmpty() && !rn.isEmpty() &&
...
@@ -3855,14 +3854,14 @@ static void parseCompounds(Entry *rt)
...
@@ -3855,14 +3854,14 @@ static void parseCompounds(Entry *rt)
memberGroupId = NOGROUP;
memberGroupId = NOGROUP;
// rebuild compound's group context
// rebuild compound's group context
QCString *s = ce->groups->first();
//
QCString *s = ce->groups->first();
if (s)
//
if (s)
{
//
{
lastDefGroup=*s;
//
lastDefGroup=*s;
startGroup();
//
startGroup();
}
//
}
current->mGrpId = memberGroupId = ce->mGrpId;
//
current->mGrpId = memberGroupId = ce->mGrpId;
scanYYlex() ;
scanYYlex() ;
delete current; current=0;
delete current; current=0;
...
...
src/sortdict.h
View file @
75fed736
...
@@ -79,6 +79,14 @@ class SDict
...
@@ -79,6 +79,14 @@ class SDict
m_list
->
append
(
d
);
m_list
->
append
(
d
);
m_dict
->
insert
(
key
,
d
);
m_dict
->
insert
(
key
,
d
);
}
}
/*! Sorts the members of the dictionary. First appending a number
* of members and then sorting them is faster (O(NlogN) than using
* inSort() for each member (O(N^2)).
*/
void
sort
()
{
m_list
->
sort
();
}
/*! Inserts a compound into the dictionary in a sorted way.
/*! Inserts a compound into the dictionary in a sorted way.
* \param key The unique key to use to quicky find the item later on.
* \param key The unique key to use to quicky find the item later on.
* \param d The compound to add.
* \param d The compound to add.
...
@@ -103,6 +111,12 @@ class SDict
...
@@ -103,6 +111,12 @@ class SDict
{
{
return
m_dict
->
find
(
key
);
return
m_dict
->
find
(
key
);
}
}
/*! Returns the item at position \a i in the sorted dictionary */
T
*
at
(
uint
i
)
{
return
m_list
->
at
(
i
);
}
/*! Function that is used to compare two items when sorting.
/*! Function that is used to compare two items when sorting.
* Overload this to properly sort items.
* Overload this to properly sort items.
* \sa inSort()
* \sa inSort()
...
@@ -152,6 +166,13 @@ class SDict
...
@@ -152,6 +166,13 @@ class SDict
{
{
return
m_li
->
toFirst
();
return
m_li
->
toFirst
();
}
}
/*! Set the iterator to the last element in the list.
* \return The first compound, or zero if the list was empty.
*/
T
*
toLast
()
const
{
return
m_li
->
toLast
();
}
/*! Returns the current compound */
/*! Returns the current compound */
T
*
current
()
const
T
*
current
()
const
{
{
...
@@ -165,6 +186,14 @@ class SDict
...
@@ -165,6 +186,14 @@ class SDict
{
{
return
m_li
->
operator
++
();
return
m_li
->
operator
++
();
}
}
/*! Moves the iterator to the previous element.
* \return the new "current" element, or zero if the iterator was
* already pointing at the first element.
*/
T
*
operator
--
()
{
return
m_li
->
operator
--
();
}
private
:
private
:
QListIterator
<
T
>
*
m_li
;
QListIterator
<
T
>
*
m_li
;
...
...
src/translator_cz.h
View file @
75fed736
...
@@ -120,9 +120,9 @@
...
@@ -120,9 +120,9 @@
// Windows version. The version which does not call the function is
// Windows version. The version which does not call the function is
// probably slightly faster.
// probably slightly faster.
#include "translator
_adapter
.h"
#include "translator.h"
class
TranslatorCzech
:
public
Translator
AdapterBase
class
TranslatorCzech
:
public
Translator
{
{
private
:
private
:
/*! The Decode() inline assumes the source written in the
/*! The Decode() inline assumes the source written in the
...
...
src/translator_dk.h
0 → 100644
View file @
75fed736
/******************************************************************************
*
*
*
* Copyright (C) 1997-2001 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.
*
*/
/* OBS!
Til danskere og andet godtfolk:
Jeg har været i tvivl om (i hvert fald) følgende ord:
- Member
- Compound
- Namespace
- Interface
Jeg har besluttet (indtil videre) at lade følgende ord stå som de er,
da jeg selv overvejende bruger det engelske udtryk:
- Interface
- Typedef
- Union
(union ved jeg ikke engang, hvad jeg skal kalde på dansk...
udover måske 'union')
(Konstruktivt) input modtages med glæde!
*/
#ifndef TRANSLATOR_DK_H
#define TRANSLATOR_DK_H
#include "translator.h"
class
TranslatorDanish
:
public
Translator
{
public
:
// --- Language control methods -------------------
/*! Used for identification of the language. The identification
* should not be translated. It should be replaced by the name
* of the language in English using lower-case characters only
* (e.g. "czech", "japanese", "russian", etc.). It should be equal to
* the identification used in language.cpp.
*/
virtual
QCString
idLanguage
()
{
return
"danish"
;
}
/*! Used to get the LaTeX command(s) for the language support. This method
* was designed for languages which do wish to use a babel package.
*/
virtual
QCString
latexLanguageSupportCommand
()
{
return
"danish"
;
}
/*! return the language charset. This will be used for the HTML output */
virtual
QCString
idLanguageCharset
()
{
return
"iso-8859-1"
;
}
// --- Language translation methods -------------------
/*! used in the compound documentation before a list of related functions. */
virtual
QCString
trRelatedFunctions
()
{
return
"Relaterede funktioner"
;
}
/*! subscript for the related functions. */
virtual
QCString
trRelatedSubscript
()
{
return
"(Bemærk at disse ikke er medlems-funktioner.)"
;
}
/*! header that is put before the detailed description of files, classes and namespaces. */
virtual
QCString
trDetailedDescription
()
{
return
"Detaljeret beskrivelse"
;
}
/*! header that is put before the list of typedefs. */
virtual
QCString
trMemberTypedefDocumentation
()
{
return
"Dokumentation af medlems-typedefs"
;
}
/*! header that is put before the list of enumerations. */
virtual
QCString
trMemberEnumerationDocumentation
()
{
return
"Dokumentation af medlems-enumerationer"
;
}
/*! header that is put before the list of member functions. */
virtual
QCString
trMemberFunctionDocumentation
()
{
return
"Dokumentation af medlemsfunktioner"
;
}
/*! header that is put before the list of member attributes. */
virtual
QCString
trMemberDataDocumentation
()
{
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
return
"Felt-dokumentation"
;
}
else
{
return
"Dokumentation af medlems-data"
;
}
}
/*! this is the text of a link put after brief descriptions. */
virtual
QCString
trMore
()
{
return
"Mere..."
;
}
/*! put in the class documentation */
virtual
QCString
trListOfAllMembers
()
{
return
"Liste over alle medlemmer."
;
}
/*! used as the title of the "list of all members" page of a class */
virtual
QCString
trMemberList
()
{
return
"Liste over medlemmer"
;
}
/*! this is the first part of a sentence that is followed by a class name */
virtual
QCString
trThisIsTheListOfAllMembers
()
{
return
"Dette er den komplette liste over medlemmer for "
;
}
/*! this is the remainder of the sentence after the class name */
virtual
QCString
trIncludingInheritedMembers
()
{
return
", inklusive alle nedarvede medlemmer."
;
}
/*! this is put at the author sections at the bottom of man pages.
* parameter s is name of the project name.
*/
virtual
QCString
trGeneratedAutomatically
(
const
char
*
s
)
{
QCString
result
=
"Automatisk genereret af Doxygen"
;
if
(
s
)
result
+=
(
QCString
)
" for "
+
s
;
result
+=
" ud fra kildekoden."
;
return
result
;
}
/*! put after an enum name in the list of all members */
virtual
QCString
trEnumName
()
{
return
"enum-navn"
;
}
/*! put after an enum value in the list of all members */
virtual
QCString
trEnumValue
()
{
return
"enum-værdi"
;
}
/*! put after an undocumented member in the list of all members */
virtual
QCString
trDefinedIn
()
{
return
"defineret i"
;
}
// quick reference sections
/*! This is put above each page as a link to the list of all groups of
* compounds or files (see the \\group command).
*/
virtual
QCString
trModules
()
{
return
"Moduler"
;
}
/*! This is put above each page as a link to the class hierarchy */
virtual
QCString
trClassHierarchy
()
{
return
"Klassehierarki"
;
}
/*! This is put above each page as a link to the list of annotated classes */
virtual
QCString
trCompoundList
()
{
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
return
"Datastrukturer"
;
}
else
{
return
"Compound List"
;
}
}
/*! This is put above each page as a link to the list of documented files */
virtual
QCString
trFileList
()
{
return
"Filliste"
;
}
/*! This is put above each page as a link to the list of all verbatim headers */
virtual
QCString
trHeaderFiles
()
{
return
"Header-filer"
;
}
/*! This is put above each page as a link to all members of compounds. */
virtual
QCString
trCompoundMembers
()
{
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
return
"Data-felter"
;
}
else
{
return
"Compound Members"
;
}
}
/*! This is put above each page as a link to all members of files. */
virtual
QCString
trFileMembers
()
{
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
return
"Globale"
;
}
else
{
return
"Fil-medlemmer"
;
}
}
/*! This is put above each page as a link to all related pages. */
virtual
QCString
trRelatedPages
()
{
return
"Relaterede sider"
;
}
/*! This is put above each page as a link to all examples. */
virtual
QCString
trExamples
()
{
return
"Eksempler"
;
}
/*! This is put above each page as a link to the search engine. */
virtual
QCString
trSearch
()
{
return
"Søg"
;
}
/*! This is an introduction to the class hierarchy. */
virtual
QCString
trClassHierarchyDescription
()
{
return
"Denne nedarvningsliste er sorteret næsten - "
"men ikke helt - alfabetisk:"
;
}
/*! This is an introduction to the list with all files. */
virtual
QCString
trFileListDescription
(
bool
extractAll
)
{
QCString
result
=
"Her er en liste over alle "
;
if
(
!
extractAll
)
result
+=
"dokumenterede "
;
result
+=
"filer med korte beskrivelser:"
;
return
result
;
}
/*! This is an introduction to the annotated compound list. */
virtual
QCString
trCompoundListDescription
()
{
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
return
"Her er datastrukturerne med korte beskrivelser:"
;
}
else
{
return
"Her er klasserne, strukturerne, "
"unionerne og grænsefladerne med korte beskrivelser:"
;
}
}
/*! This is an introduction to the page with all class members. */
virtual
QCString
trCompoundMembersDescription
(
bool
extractAll
)
{
QCString
result
=
"Her er en liste over alle "
;
if
(
!
extractAll
)
{
result
+=
"dokumenterede "
;
}
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
result
+=
"felter i strukturer og unioner"
;
}
else
{
result
+=
"klassemedlemmer"
;
}
result
+=
" med links til "
;
if
(
extractAll
)
{
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
result
+=
"struktur/unions-dokumentationen for hvert felt:"
;
}
else
{
result
+=
"klassedokumentationen for hvert medlem:"
;
}
}
else
{
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
result
+=
"de strukturer/unioner de hører til:"
;
}
else
{
result
+=
"de klasser de hører til:"
;
}
}
return
result
;
}
/*! This is an introduction to the page with all file members. */
virtual
QCString
trFileMembersDescription
(
bool
extractAll
)
{
QCString
result
=
"Her er en liste over alle "
;
if
(
!
extractAll
)
result
+=
"dokumenterede "
;
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
result
+=
"funktioner, variable, #defines, enumerationer "
"og typedefinitioner"
;
}
else
{
result
+=
"fil-medlemmer"
;
}
result
+=
" med links til "
;
if
(
extractAll
)
result
+=
"de filer de hører til:"
;
else
result
+=
"dokumentationen:"
;
return
result
;
}
/*! This is an introduction to the page with the list of all header files. */
virtual
QCString
trHeaderFilesDescription
()
{
return
"Her er de headerfiler der udgør API'en:"
;
}
/*! This is an introduction to the page with the list of all examples */
virtual
QCString
trExamplesDescription
()
{
return
"Her er en liste over alle eksempler:"
;
}
/*! This is an introduction to the page with the list of related pages */
virtual
QCString
trRelatedPagesDescription
()
{
return
"Her er en liste over alle relaterede dokumentationssider:"
;
}
/*! This is an introduction to the page with the list of class/file groups */
virtual
QCString
trModulesDescription
()
{
return
"Her er en liste over alle moduler:"
;
}
/*! This sentences is used in the annotated class/file lists if no brief
* description is given.
*/
virtual
QCString
trNoDescriptionAvailable
()
{
return
"Ikke beskrevet"
;
}
// index titles (the project name is prepended for these)
/*! This is used in HTML as the title of index.html. */
virtual
QCString
trDocumentation
()
{
return
"Dokumentation"
;
}
/*! This is used in LaTeX as the title of the chapter with the
* index of all groups.
*/
virtual
QCString
trModuleIndex
()
{
return
"Modul-index"
;
}
/*! This is used in LaTeX as the title of the chapter with the
* class hierarchy.
*/
virtual
QCString
trHierarchicalIndex
()
{
return
"Hierarkisk index"
;
}
/*! This is used in LaTeX as the title of the chapter with the
* annotated compound index.
*/
virtual
QCString
trCompoundIndex
()
{
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
return
"Indeks over datastrukturer"
;
}
else
{
return
"Compound Index"
;
}
}
/*! This is used in LaTeX as the title of the chapter with the
* list of all files.
*/
virtual
QCString
trFileIndex
()
{
return
"Fil-index"
;
}
/*! This is used in LaTeX as the title of the chapter containing
* the documentation of all groups.
*/
virtual
QCString
trModuleDocumentation
()
{
return
"Modul-dokumentation"
;
}
/*! This is used in LaTeX as the title of the chapter containing
* the documentation of all classes, structs and unions.
*/
virtual
QCString
trClassDocumentation
()
{
return
"Klasse-dokumentation"
;
}
/*! This is used in LaTeX as the title of the chapter containing
* the documentation of all files.
*/
virtual
QCString
trFileDocumentation
()
{
return
"Fil-dokumentation"
;
}
/*! This is used in LaTeX as the title of the chapter containing
* the documentation of all examples.
*/
virtual
QCString
trExampleDocumentation
()
{
return
"Eksempel-dokumentation"
;
}
/*! This is used in LaTeX as the title of the chapter containing
* the documentation of all related pages.
*/
virtual
QCString
trPageDocumentation
()
{
return
"Side-dokumentation"
;
}
/*! This is used in LaTeX as the title of the document */
virtual
QCString
trReferenceManual
()
{
return
"Reference-manual"
;
}
/*! This is used in the documentation of a file as a header before the
* list of defines
*/
virtual
QCString
trDefines
()
{
return
"#Defines"
;
}
/*! This is used in the documentation of a file as a header before the
* list of function prototypes
*/
virtual
QCString
trFuncProtos
()
{
return
"Funktionsprototyper"
;
}
/*! This is used in the documentation of a file as a header before the
* list of typedefs
*/
virtual
QCString
trTypedefs
()
{
return
"Typedefs"
;
}
/*! This is used in the documentation of a file as a header before the
* list of enumerations
*/
virtual
QCString
trEnumerations
()
{
return
"Enumerationer"
;
}
/*! This is used in the documentation of a file as a header before the
* list of (global) functions
*/
virtual
QCString
trFunctions
()
{
return
"Funktioner"
;
}
/*! This is used in the documentation of a file as a header before the
* list of (global) variables
*/
virtual
QCString
trVariables
()
{
return
"Variabler"
;
}
/*! This is used in the documentation of a file as a header before the
* list of (global) variables
*/
virtual
QCString
trEnumerationValues
()
{
return
"Enumerationsværdier"
;
}
/*! This is used in man pages as the author section. */
virtual
QCString
trAuthor
()
{
return
"Forfatter"
;
}
/*! This is used in the documentation of a file before the list of
* documentation blocks for defines
*/
virtual
QCString
trDefineDocumentation
()
{
return
"#Define-dokumentation"
;
}
/*! This is used in the documentation of a file/namespace before the list
* of documentation blocks for function prototypes
*/
virtual
QCString
trFunctionPrototypeDocumentation
()
{
return
"Funktionsprototype-dokumentation"
;
}
/*! This is used in the documentation of a file/namespace before the list
* of documentation blocks for typedefs
*/
virtual
QCString
trTypedefDocumentation
()
{
return
"Typedef-dokumentation"
;
}
/*! This is used in the documentation of a file/namespace before the list
* of documentation blocks for enumeration types
*/
virtual
QCString
trEnumerationTypeDocumentation
()
{
return
"Dokumentation af enumerations-typer"
;
}
/*! This is used in the documentation of a file/namespace before the list
* of documentation blocks for enumeration values
*/
virtual
QCString
trEnumerationValueDocumentation
()
{
return
"Dokumentation af enumerations-værdier"
;
}
/*! This is used in the documentation of a file/namespace before the list
* of documentation blocks for functions
*/
virtual
QCString
trFunctionDocumentation
()
{
return
"Funktions-dokumentation"
;
}
/*! This is used in the documentation of a file/namespace before the list
* of documentation blocks for variables
*/
virtual
QCString
trVariableDocumentation
()
{
return
"Variabel-dokumentation"
;
}
/*! This is used in the documentation of a file/namespace/group before
* the list of links to documented compounds
*/
virtual
QCString
trCompounds
()
{
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
return
"Datastrukturer"
;
}
else
{
return
"Compounds"
;
}
}
/*! This is used in the standard footer of each page and indicates when
* the page was generated
*/
virtual
QCString
trGeneratedAt
(
const
char
*
date
,
const
char
*
projName
)
{
QCString
result
=
(
QCString
)
"Genereret "
+
date
;
if
(
projName
)
result
+=
(
QCString
)
" for "
+
projName
;
result
+=
(
QCString
)
" af"
;
return
result
;
}
/*! This is part of the sentence used in the standard footer of each page.
*/
virtual
QCString
trWrittenBy
()
{
return
"skrevet af"
;
}
/*! this text is put before a class diagram */
virtual
QCString
trClassDiagram
(
const
char
*
clName
)
{
return
(
QCString
)
"Nedarvningsdiagram for "
+
clName
+
":"
;
}
/*! this text is generated when the \\internal command is used. */
virtual
QCString
trForInternalUseOnly
()
{
return
"Kun til intern brug."
;
}
/*! this text is generated when the \\reimp command is used. */
virtual
QCString
trReimplementedForInternalReasons
()
{
return
"Metode overskrevet af interne grunde; "
"API'en er ikke påvirket."
;
}
/*! this text is generated when the \\warning command is used. */
virtual
QCString
trWarning
()
{
return
"Advarsel"
;
}
/*! this text is generated when the \\bug command is used. */
virtual
QCString
trBugsAndLimitations
()
{
return
"Fejl og begrænsninger"
;
}
/*! this text is generated when the \\version command is used. */
virtual
QCString
trVersion
()
{
return
"Version"
;
}
/*! this text is generated when the \\date command is used. */
virtual
QCString
trDate
()
{
return
"Dato"
;
}
/*! this text is generated when the \\author command is used. */
virtual
QCString
trAuthors
()
{
return
"Forfatter(e)"
;
}
/*! this text is generated when the \\return command is used. */
virtual
QCString
trReturns
()
{
return
"Returnerer"
;
}
/*! this text is generated when the \\sa command is used. */
virtual
QCString
trSeeAlso
()
{
return
"Se også"
;
}
/*! this text is generated when the \\param command is used. */
virtual
QCString
trParameters
()
{
return
"Parametre"
;
}
/*! this text is generated when the \\exception command is used. */
virtual
QCString
trExceptions
()
{
return
"Exceptions"
;
}
/*! this text is used in the title page of a LaTeX document. */
virtual
QCString
trGeneratedBy
()
{
return
"Genereret af"
;
}
//////////////////////////////////////////////////////////////////////////
// new since 0.49-990307
//////////////////////////////////////////////////////////////////////////
/*! used as the title of page containing all the index of all namespaces. */
virtual
QCString
trNamespaceList
()
{
return
"Namespace-liste"
;
}
/*! used as an introduction to the namespace list */
virtual
QCString
trNamespaceListDescription
(
bool
extractAll
)
{
QCString
result
=
"Her er en liste over alle "
;
if
(
!
extractAll
)
result
+=
"dokumenterede "
;
result
+=
"namespaces med korte beskrivelser:"
;
return
result
;
}
/*! used in the class documentation as a header before the list of all
* friends of a class
*/
virtual
QCString
trFriends
()
{
return
"Friends"
;
}
//////////////////////////////////////////////////////////////////////////
// new since 0.49-990405
//////////////////////////////////////////////////////////////////////////
/*! used in the class documentation as a header before the list of all
* related classes
*/
virtual
QCString
trRelatedFunctionDocumentation
()
{
return
"Friends og relateret funktions-dokumentation"
;
}
//??
//////////////////////////////////////////////////////////////////////////
// new since 0.49-990425
//////////////////////////////////////////////////////////////////////////
/*! used as the title of the HTML page of a class/struct/union */
virtual
QCString
trCompoundReference
(
const
char
*
clName
,
ClassDef
::
CompoundType
compType
,
bool
isTemplate
)
{
QCString
result
=
(
QCString
)
clName
+
" "
;
switch
(
compType
)
{
case
ClassDef
:
:
Class
:
result
+=
" Klasse-"
;
break
;
case
ClassDef
:
:
Struct
:
result
+=
" Struktur-"
;
break
;
case
ClassDef
:
:
Union
:
result
+=
" Union-"
;
break
;
case
ClassDef
:
:
Interface
:
result
+=
" Interface-"
;
break
;
case
ClassDef
:
:
Exception
:
result
+=
" Exception-"
;
break
;
}
if
(
isTemplate
)
result
+=
"template-"
;
result
+=
"reference"
;
return
result
;
}
/*! used as the title of the HTML page of a file */
virtual
QCString
trFileReference
(
const
char
*
fileName
)
{
QCString
result
=
fileName
;
result
+=
" Fil-reference"
;
return
result
;
}
/*! used as the title of the HTML page of a namespace */
virtual
QCString
trNamespaceReference
(
const
char
*
namespaceName
)
{
QCString
result
=
namespaceName
;
result
+=
" Namespace-reference"
;
return
result
;
}
virtual
QCString
trPublicMembers
()
{
return
"Public Methods"
;
}
virtual
QCString
trPublicSlots
()
{
return
"Public Slots"
;
}
virtual
QCString
trSignals
()
{
return
"Signals"
;
}
virtual
QCString
trStaticPublicMembers
()
{
return
"Static Public Methods"
;
}
virtual
QCString
trProtectedMembers
()
{
return
"Protected Methods"
;
}
virtual
QCString
trProtectedSlots
()
{
return
"Protected Slots"
;
}
virtual
QCString
trStaticProtectedMembers
()
{
return
"Static Protected Methods"
;
}
virtual
QCString
trPrivateMembers
()
{
return
"Private Methods"
;
}
virtual
QCString
trPrivateSlots
()
{
return
"Private Slots"
;
}
virtual
QCString
trStaticPrivateMembers
()
{
return
"Static Private Methods"
;
}
/*! this function is used to produce a comma-separated list of items.
* use generateMarker(i) to indicate where item i should be put.
*/
virtual
QCString
trWriteList
(
int
numEntries
)
{
QCString
result
;
int
i
;
// the inherits list contain `numEntries' classes
for
(
i
=
0
;
i
<
numEntries
;
i
++
)
{
// use generateMarker to generate placeholders for the class links!
result
+=
generateMarker
(
i
);
// generate marker for entry i in the list
// (order is left to right)
if
(
i
!=
numEntries
-
1
)
// not the last entry, so we need a separator
{
if
(
i
<
numEntries
-
2
)
// not the fore last entry
result
+=
", "
;
else
// the fore last entry
result
+=
", and "
;
}
}
return
result
;
}
/*! used in class documentation to produce a list of base classes,
* if class diagrams are disabled.
*/
virtual
QCString
trInheritsList
(
int
numEntries
)
{
return
"Inherits "
+
trWriteList
(
numEntries
)
+
"."
;
}
/*! used in class documentation to produce a list of super classes,
* if class diagrams are disabled.
*/
virtual
QCString
trInheritedByList
(
int
numEntries
)
{
return
"Inherited by "
+
trWriteList
(
numEntries
)
+
"."
;
}
/*! used in member documentation blocks to produce a list of
* members that are hidden by this one.
*/
virtual
QCString
trReimplementedFromList
(
int
numEntries
)
{
return
"Overskriver metode fra "
+
trWriteList
(
numEntries
)
+
"."
;
}
/*! used in member documentation blocks to produce a list of
* all member that overwrite the implementation of this member.
*/
virtual
QCString
trReimplementedInList
(
int
numEntries
)
{
return
"Reimplemented in "
+
trWriteList
(
numEntries
)
+
"."
;
}
/*! This is put above each page as a link to all members of namespaces. */
virtual
QCString
trNamespaceMembers
()
{
return
"Namespace-medlemmer"
;
}
/*! This is an introduction to the page with all namespace members */
virtual
QCString
trNamespaceMemberDescription
(
bool
extractAll
)
{
QCString
result
=
"Her er en liste over alle "
;
if
(
!
extractAll
)
result
+=
"dokumenterede "
;
result
+=
"namespace-medlemmer med links til "
;
if
(
extractAll
)
result
+=
"namespace-dokumentationen for hvert medlem:"
;
else
result
+=
"de namespaces, de hører til:"
;
return
result
;
}
/*! This is used in LaTeX as the title of the chapter with the
* index of all namespaces.
*/
virtual
QCString
trNamespaceIndex
()
{
return
"Namespace Index"
;
}
/*! This is used in LaTeX as the title of the chapter containing
* the documentation of all namespaces.
*/
virtual
QCString
trNamespaceDocumentation
()
{
return
"Namespace Dokumentation"
;
}
//////////////////////////////////////////////////////////////////////////
// new since 0.49-990522
//////////////////////////////////////////////////////////////////////////
/*! This is used in the documentation before the list of all
* namespaces in a file.
*/
virtual
QCString
trNamespaces
()
{
return
"Namespaces"
;
}
//////////////////////////////////////////////////////////////////////////
// new since 0.49-990728
//////////////////////////////////////////////////////////////////////////
/*! This is put at the bottom of a class documentation page and is
* followed by a list of files that were used to generate the page.
*/
virtual
QCString
trGeneratedFromFiles
(
ClassDef
::
CompoundType
compType
,
bool
single
)
{
// here s is one of " Class", " Struct" or " Union"
// single is true implies a single file
QCString
result
=
(
QCString
)
"The documentation for this "
;
switch
(
compType
)
{
case
ClassDef
:
:
Class
:
result
+=
"class"
;
break
;
case
ClassDef
:
:
Struct
:
result
+=
"struct"
;
break
;
case
ClassDef
:
:
Union
:
result
+=
"union"
;
break
;
case
ClassDef
:
:
Interface
:
result
+=
"interface"
;
break
;
case
ClassDef
:
:
Exception
:
result
+=
"exception"
;
break
;
}
result
+=
" was generated from the following file"
;
if
(
single
)
result
+=
":"
;
else
result
+=
"s:"
;
return
result
;
}
/*! This is in the (quick) index as a link to the alphabetical compound
* list.
*/
virtual
QCString
trAlphabeticalList
()
{
return
"Alfabetisk oversigt"
;
}
//////////////////////////////////////////////////////////////////////////
// new since 0.49-990901
//////////////////////////////////////////////////////////////////////////
/*! This is used as the heading text for the retval command. */
virtual
QCString
trReturnValues
()
{
return
"Returværdier"
;
}
/*! This is in the (quick) index as a link to the main page (index.html)
*/
virtual
QCString
trMainPage
()
{
return
"Hovedside"
;
}
/*! This is used in references to page that are put in the LaTeX
* documentation. It should be an abbreviation of the word page.
*/
virtual
QCString
trPageAbbreviation
()
{
return
"s."
;
}
//////////////////////////////////////////////////////////////////////////
// new since 0.49-991003
//////////////////////////////////////////////////////////////////////////
virtual
QCString
trSources
()
{
return
"Sources"
;
}
virtual
QCString
trDefinedAtLineInSourceFile
()
{
return
"Defineret på linje @0 i filen @1."
;
}
virtual
QCString
trDefinedInSourceFile
()
{
return
"Defineret i filen @0."
;
}
//////////////////////////////////////////////////////////////////////////
// new since 0.49-991205
//////////////////////////////////////////////////////////////////////////
virtual
QCString
trDeprecated
()
{
return
"Deprecated"
;
}
//////////////////////////////////////////////////////////////////////////
// new since 1.0.0
//////////////////////////////////////////////////////////////////////////
/*! this text is put before a collaboration diagram */
virtual
QCString
trCollaborationDiagram
(
const
char
*
clName
)
{
return
(
QCString
)
"Samarbejdsdiagram for "
+
clName
+
":"
;
}
/*! this text is put before an include dependency graph */
virtual
QCString
trInclDepGraph
(
const
char
*
fName
)
{
return
(
QCString
)
"Include-afhængighedsgraf for "
+
fName
+
":"
;
}
/*! header that is put before the list of constructor/destructors. */
virtual
QCString
trConstructorDocumentation
()
{
return
"Constructor & Destructor dokumentation"
;
}
/*! Used in the file documentation to point to the corresponding sources. */
virtual
QCString
trGotoSourceCode
()
{
return
"Hop til denne fils kildekode."
;
}
/*! Used in the file sources to point to the corresponding documentation. */
virtual
QCString
trGotoDocumentation
()
{
return
"Hop til denne fils dokumentation."
;
}
/*! Text for the \pre command */
virtual
QCString
trPrecondition
()
{
return
"Precondition"
;
}
/*! Text for the \post command */
virtual
QCString
trPostcondition
()
{
return
"Postcondition"
;
}
/*! Text for the \invariant command */
virtual
QCString
trInvariant
()
{
return
"Invariant"
;
}
/*! Text shown before a multi-line variable/enum initialization */
virtual
QCString
trInitialValue
()
{
return
"Startværdi:"
;
}
/*! Text used the source code in the file index */
virtual
QCString
trCode
()
{
return
"code"
;
}
virtual
QCString
trGraphicalHierarchy
()
{
return
"Grafiske klassehierarki"
;
}
virtual
QCString
trGotoGraphicalHierarchy
()
{
return
"Hop til det grafiske klassehierarki"
;
}
virtual
QCString
trGotoTextualHierarchy
()
{
return
"Hop til det tekstuelle klassehierarki"
;
}
virtual
QCString
trPageIndex
()
{
return
"Page Index"
;
}
//////////////////////////////////////////////////////////////////////////
// new since 1.1.0
//////////////////////////////////////////////////////////////////////////
virtual
QCString
trNote
()
{
return
"Note"
;
}
virtual
QCString
trPublicTypes
()
{
return
"Public Typer"
;
}
virtual
QCString
trPublicAttribs
()
{
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
return
"Datafelter"
;
}
else
{
return
"Public Attributes"
;
}
}
virtual
QCString
trStaticPublicAttribs
()
{
return
"Static Public Attributes"
;
}
virtual
QCString
trProtectedTypes
()
{
return
"Protected Typer"
;
}
virtual
QCString
trProtectedAttribs
()
{
return
"Protected Attributes"
;
}
virtual
QCString
trStaticProtectedAttribs
()
{
return
"Static Protected Attributes"
;
}
virtual
QCString
trPrivateTypes
()
{
return
"Private Types"
;
}
virtual
QCString
trPrivateAttribs
()
{
return
"Private Attributes"
;
}
virtual
QCString
trStaticPrivateAttribs
()
{
return
"Static Private Attributes"
;
}
//////////////////////////////////////////////////////////////////////////
// new since 1.1.3
//////////////////////////////////////////////////////////////////////////
/*! Used as a marker that is put before a \\todo item */
virtual
QCString
trTodo
()
{
return
"Todo"
;
}
/*! Used as the header of the todo list */
virtual
QCString
trTodoList
()
{
return
"Todo List"
;
}
//////////////////////////////////////////////////////////////////////////
// new since 1.1.4
//////////////////////////////////////////////////////////////////////////
virtual
QCString
trReferencedBy
()
{
return
"Refereret til af"
;
}
virtual
QCString
trRemarks
()
{
return
"Bemærkninger"
;
}
virtual
QCString
trAttention
()
{
return
"Attention"
;
}
virtual
QCString
trInclByDepGraph
()
{
return
"Denne graf viser, hvilke filer der direkte eller "
"indirekte inkluderer denne fil:"
;
}
virtual
QCString
trSince
()
{
return
"Siden"
;
}
//////////////////////////////////////////////////////////////////////////
// new since 1.1.5
//////////////////////////////////////////////////////////////////////////
/*! title of the graph legend page */
virtual
QCString
trLegendTitle
()
{
return
"Graf-forklaring"
;
}
/*! page explaining how the dot graph's should be interpreted */
virtual
QCString
trLegendDocs
()
{
return
"Denne side forklarer, hvordan man skal fortolke de grafer, "
"der genereres af doxygen.<p>
\n
"
"Consider the following example:
\n
"
"
\\
code
\n
"
"/*! Invisible class because of truncation */
\n
"
"class Invisible { };
\n\n
"
"/*! Truncated class, inheritance relation is hidden */
\n
"
"class Truncated : public Invisible { };
\n\n
"
"/* Class not documented with doxygen comments */
\n
"
"class Undocumented { };
\n\n
"
"/*! Class that is inherited using public inheritance */
\n
"
"class PublicBase : public Truncated { };
\n\n
"
"/*! Class that is inherited using protected inheritance */
\n
"
"class ProtectedBase { };
\n\n
"
"/*! Class that is inherited using private inheritance */
\n
"
"class PrivateBase { };
\n\n
"
"/*! Class that is used by the Inherited class */
\n
"
"class Used { };
\n\n
"
"/*! Super class that inherits a number of other classes */
\n
"
"class Inherited : public PublicBase,
\n
"
" protected ProtectedBase,
\n
"
" private PrivateBase,
\n
"
" public Undocumented
\n
"
"{
\n
"
" private:
\n
"
" Used *m_usedClass;
\n
"
"};
\n
"
"
\\
endcode
\n
"
"If the
\\
c MAX_DOT_GRAPH_HEIGHT tag in the configuration file "
"is set to 200 this will result in the following graph:"
"<p><center><img src=
\"
graph_legend.gif
\"
></center>
\n
"
"<p>
\n
"
"The boxes in the above graph have the following meaning:
\n
"
"<ul>
\n
"
"<li>A filled black box represents the struct or class for which the "
"graph is generated.
\n
"
"<li>A box with a black border denotes a documented struct or class.
\n
"
"<li>A box with a grey border denotes an undocumented struct or class.
\n
"
"<li>A box with a red border denotes a documented struct or class for
\n
"
"which not all inheritance/containment relations are shown. A graph is "
"truncated if it does not fit within the specified boundaries."
"</ul>
\n
"
"The arrows have the following meaning:
\n
"
"<ul>
\n
"
"<li>A dark blue arrow is used to visualize a public inheritance "
"relation between two classes.
\n
"
"<li>A dark green arrow is used for protected inheritance.
\n
"
"<li>A dark red arrow is used for private inheritance.
\n
"
"<li>A purple dashed arrow is used if a class is contained or used "
"by another class. The arrow is labeled with the variable(s) "
"through which the pointed class or struct is accessible.
\n
"
"</ul>
\n
"
;
}
/*! text for the link to the legend page */
virtual
QCString
trLegend
()
{
return
"forklaring til graf"
;
}
//////////////////////////////////////////////////////////////////////////
// new since 1.2.0
//////////////////////////////////////////////////////////////////////////
/*! Used as a marker that is put before a test item */
virtual
QCString
trTest
()
{
return
"Test"
;
}
/*! Used as the header of the test list */
virtual
QCString
trTestList
()
{
return
"Testliste"
;
}
//////////////////////////////////////////////////////////////////////////
// new since 1.2.1
//////////////////////////////////////////////////////////////////////////
/*! Used as a section header for KDE-2 IDL methods */
virtual
QCString
trDCOPMethods
()
{
return
"DCOP-metoder"
;
}
//////////////////////////////////////////////////////////////////////////
// new since 1.2.2
//////////////////////////////////////////////////////////////////////////
/*! Used as a section header for IDL properties */
virtual
QCString
trProperties
()
{
return
"Properties"
;
}
/*! Used as a section header for IDL property documentation */
virtual
QCString
trPropertyDocumentation
()
{
return
"Property-dokumentation"
;
}
//////////////////////////////////////////////////////////////////////////
// new since 1.2.4
//////////////////////////////////////////////////////////////////////////
/*! Used for Java interfaces in the summary section of Java packages */
virtual
QCString
trInterfaces
()
{
return
"Interfaces"
;
}
/*! Used for Java classes in the summary section of Java packages */
virtual
QCString
trClasses
()
{
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
return
"Datastrukturer"
;
}
else
{
return
"Klasser"
;
}
}
/*! Used as the title of a Java package */
virtual
QCString
trPackage
(
const
char
*
name
)
{
return
(
QCString
)
"Pakke "
+
name
;
}
/*! Title of the package index page */
virtual
QCString
trPackageList
()
{
return
"Pakkeliste"
;
}
/*! The description of the package index page */
virtual
QCString
trPackageListDescription
()
{
return
"Here are the packages with brief descriptions (if available):"
;
}
/*! The link name in the Quick links header for each page */
virtual
QCString
trPackages
()
{
return
"Packages"
;
}
/*! Used as a chapter title for Latex & RTF output */
virtual
QCString
trPackageDocumentation
()
{
return
"Package Dokumentation"
;
}
/*! Text shown before a multi-line define */
virtual
QCString
trDefineValue
()
{
return
"Værdi:"
;
}
//////////////////////////////////////////////////////////////////////////
// new since 1.2.5
//////////////////////////////////////////////////////////////////////////
/*! Used as a marker that is put before a \\bug item */
virtual
QCString
trBug
()
{
return
"Fejl"
;
}
/*! Used as the header of the bug list */
virtual
QCString
trBugList
()
{
return
"Liste over kendte fejl"
;
}
//////////////////////////////////////////////////////////////////////////
// new since 1.2.6
//////////////////////////////////////////////////////////////////////////
/*! Used as ansicpg for RTF file */
virtual
QCString
trRTFansicp
()
{
return
"1252"
;
}
/*! Used as ansicpg for RTF fcharset */
virtual
QCString
trRTFCharSet
()
{
return
"0"
;
}
/*! Used as header RTF general index */
virtual
QCString
trRTFGeneralIndex
()
{
return
"Indeks"
;
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trClass
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
"Klasse"
:
"klasse"
));
if
(
first_capital
)
toupper
(
result
.
at
(
0
));
if
(
!
singular
)
result
+=
"r"
;
return
result
;
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trFile
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
"Fil"
:
"fil"
));
if
(
!
singular
)
result
+=
"er"
;
return
result
;
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trNamespace
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
"Namespace"
:
"namespace"
));
if
(
!
singular
)
result
+=
"s"
;
return
result
;
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trGroup
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
"Gruppe"
:
"gruppe"
));
if
(
!
singular
)
result
+=
"r"
;
return
result
;
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trPage
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
"Side"
:
"side"
));
if
(
!
singular
)
result
+=
"r"
;
return
result
;
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trMember
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
"Medlem"
:
"medlem"
));
if
(
!
singular
)
result
+=
"mer"
;
return
result
;
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trField
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
"Felt"
:
"felt"
));
if
(
!
singular
)
result
+=
"er"
;
return
result
;
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trGlobal
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
"Global"
:
"global"
));
if
(
!
singular
)
result
+=
"e"
;
return
result
;
}
};
#endif
src/translator_en.h
View file @
75fed736
...
@@ -1176,13 +1176,37 @@ class TranslatorEnglish : public Translator
...
@@ -1176,13 +1176,37 @@ class TranslatorEnglish : public Translator
// new since 1.2.6
// new since 1.2.6
//////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////
/*! Used as ansicpg for RTF file */
/*! Used as ansicpg for RTF file
*
* The following table shows the correlation of Charset name, Charset Value and
* Codepage number:
* Charset Name Charset Value(hex) Codepage number
* ------------------------------------------------------
* DEFAULT_CHARSET 1 (x01)
* SYMBOL_CHARSET 2 (x02)
* OEM_CHARSET 255 (xFF)
* ANSI_CHARSET 0 (x00) 1252
* RUSSIAN_CHARSET 204 (xCC) 1251
* EE_CHARSET 238 (xEE) 1250
* GREEK_CHARSET 161 (xA1) 1253
* TURKISH_CHARSET 162 (xA2) 1254
* BALTIC_CHARSET 186 (xBA) 1257
* HEBREW_CHARSET 177 (xB1) 1255
* ARABIC _CHARSET 178 (xB2) 1256
* SHIFTJIS_CHARSET 128 (x80) 932
* HANGEUL_CHARSET 129 (x81) 949
* GB2313_CHARSET 134 (x86) 936
* CHINESEBIG5_CHARSET 136 (x88) 950
*
*/
virtual
QCString
trRTFansicp
()
virtual
QCString
trRTFansicp
()
{
{
return
"1252"
;
return
"1252"
;
}
}
/*! Used as ansicpg for RTF fcharset */
/*! Used as ansicpg for RTF fcharset
* \see trRTFansicp() for a table of possible values.
*/
virtual
QCString
trRTFCharSet
()
virtual
QCString
trRTFCharSet
()
{
{
return
"0"
;
return
"0"
;
...
...
src/translator_it.h
View file @
75fed736
/******************************************************************************
/******************************************************************************
*
*
*
*
* Copyright (C) 1997-2001 by Dimitri van Heesch.
* Copyright (C) 1997-2001 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.
*
*/
/******************************************************************************
*
* Revision history
*
* Initial Italian Translation by Ahmed Aldo Faisal
* Initial Italian Translation by Ahmed Aldo Faisal
* Revised and completed by Alessandro Falappa (June 1999)
* Revised and completed by Alessandro Falappa (
since
June 1999)
* Updates:
* Updates:
* 2001/05: adopted new translation mechanism (trough adapters),
* translated new items used since version 1.2.5 and 1.2.6,
* revised those function returning strings in OPTIMIZE_OTPUT_FOR_C case,
* corrections regarding the plurals of some english terms mantained in the translation,
* changed some terms to better suit the sense
* 2001/02: translated new items used since version 1.2.4
* 2001/02: translated new items used since version 1.2.4
* 2000/11: modified slightly the translation in trLegendDocs() function,
* 2000/11: modified slightly the translation in trLegendDocs() function,
* translated new items used since version 1.2.1 and 1.2.2
* translated new items used since version 1.2.1 and 1.2.2
...
@@ -15,32 +37,59 @@
...
@@ -15,32 +37,59 @@
* commented translator.h for the english language
* commented translator.h for the english language
* 1999/09: corrected some small typos in the "new since 0.49-990425" section
* 1999/09: corrected some small typos in the "new since 0.49-990425" section
* added the "new since 0.49-990728" section
* added the "new since 0.49-990728" section
*/
/******************************************************************************
*
*
* Permission to use, copy, modify, and distribute this software and its
* Note sui criteri adottati per la traduzione
* 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
* Nella traduzione non si sono tradotti alcuni termini inglesi ormai entrati
* input used in their production; they are not affected by this license.
* a far parte del "gergo" informatico (per es. file o namespace)
*
* Il plurale dei termini inglesi non tradotti è stato reso con il singolare
* della parola inglese secondo una convenzione spesso ritrovata nella documentazione
* tecnica (ad es "lista dei file" e non "lista dei files")
*
*
* Se avete suggerimenti sulla traduzione di alcuni termini o volete segnalare
* eventuali sviste potete scrivermi all'indirizzo: a.falappa@flashnet.it
*/
*/
#ifndef TRANSLATOR_IT_H
#ifndef TRANSLATOR_IT_H
#define TRANSLATOR_IT_H
#define TRANSLATOR_IT_H
#include "translator
_adapter
.h"
#include "translator.h"
class
TranslatorItalian
:
public
Translator
Adapter_1_2_5
class
TranslatorItalian
:
public
Translator
{
{
public
:
public
:
QCString
idLanguage
()
{
return
"italian"
;
}
// --- Language control methods -------------------
/*! returns the name of the package that is included by LaTeX */
QCString
latexBabelPackage
()
/*! Used for identification of the language. The identification
* should not be translated. It should be replaced by the name
* of the language in English using lower-case characters only
* (e.g. "czech", "japanese", "russian", etc.). It should be equal to
* the identification used in language.cpp.
*/
virtual
QCString
idLanguage
()
{
return
"italian"
;
}
{
return
"italian"
;
}
/*! Used to get the LaTeX command(s) for the language support. This method
* was designed for languages which do wish to use a babel package.
*/
virtual
QCString
latexLanguageSupportCommand
()
{
return
"
\\
usepackage[italian]{babel}
\n
"
;
}
/*! return the language charset. This will be used for the HTML output */
virtual
QCString
idLanguageCharset
()
{
return
"iso-8859-1"
;
}
// --- Language translation methods -------------------
/*! used in the compound documentation before a list of related functions. */
/*! used in the compound documentation before a list of related functions. */
QCString
trRelatedFunctions
()
QCString
trRelatedFunctions
()
{
return
"Funzioni collegate"
;
}
{
return
"Funzioni collegate"
;
}
...
@@ -67,7 +116,16 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -67,7 +116,16 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
/*! header that is put before the list of member attributes. */
/*! header that is put before the list of member attributes. */
QCString
trMemberDataDocumentation
()
QCString
trMemberDataDocumentation
()
{
return
"Documentazione dei dati membri"
;
}
{
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
return
"Documentazione dei campi"
;
}
else
{
return
"Documentazione dei dati membri"
;
}
}
/*! this is the text of a link put after brief descriptions. */
/*! this is the text of a link put after brief descriptions. */
QCString
trMore
()
QCString
trMore
()
...
@@ -132,11 +190,20 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -132,11 +190,20 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
/*! This is put above each page as a link to the list of annotated classes */
/*! This is put above each page as a link to the list of annotated classes */
QCString
trCompoundList
()
QCString
trCompoundList
()
{
return
"Lista dei composti"
;
}
{
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
return
"Strutture dati"
;
}
else
{
return
"Lista dei composti"
;
}
}
/*! This is put above each page as a link to the list of documented files */
/*! This is put above each page as a link to the list of documented files */
QCString
trFileList
()
QCString
trFileList
()
{
return
"Lista dei file
s
"
;
}
{
return
"Lista dei file"
;
}
/*! This is put above each page as a link to the list of all verbatim headers */
/*! This is put above each page as a link to the list of all verbatim headers */
QCString
trHeaderFiles
()
QCString
trHeaderFiles
()
...
@@ -144,11 +211,29 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -144,11 +211,29 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
/*! This is put above each page as a link to all members of compounds. */
/*! This is put above each page as a link to all members of compounds. */
QCString
trCompoundMembers
()
QCString
trCompoundMembers
()
{
return
"Membri dei composti"
;
}
{
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
return
"Campi dei dati"
;
}
else
{
return
"Membri dei composti"
;
}
}
/*! This is put above each page as a link to all members of files. */
/*! This is put above each page as a link to all members of files. */
QCString
trFileMembers
()
QCString
trFileMembers
()
{
return
"Membri dei files"
;
}
{
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
return
"Elementi globali"
;
}
else
{
return
"Membri dei file"
;
}
}
/*! This is put above each page as a link to all related pages. */
/*! This is put above each page as a link to all related pages. */
QCString
trRelatedPages
()
QCString
trRelatedPages
()
...
@@ -173,26 +258,51 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -173,26 +258,51 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
QCString
trFileListDescription
(
bool
extractAll
)
QCString
trFileListDescription
(
bool
extractAll
)
{
{
QCString
result
=
"Questa è una lista "
;
QCString
result
=
"Questa è una lista "
;
if
(
!
extractAll
)
result
+=
"dei file
s
documentati "
;
if
(
!
extractAll
)
result
+=
"dei file documentati "
;
else
result
+=
"di tutti i file
s
"
;
else
result
+=
"di tutti i file "
;
result
+=
"con una loro breve descrizione:"
;
result
+=
"con una loro breve descrizione:"
;
return
result
;
return
result
;
}
}
/*! This is an introduction to the annotated compound list. */
/*! This is an introduction to the annotated compound list. */
QCString
trCompoundListDescription
()
QCString
trCompoundListDescription
()
{
return
"Queste sono le classi, structs, unions e interfacce con una loro breve descrizione:"
;
{
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
return
"Queste sono le strutture dati con una loro breve descrizione:"
;
}
else
{
return
"Queste sono le classi, structs, unions e interfacce con una loro breve descrizione:"
;
}
}
}
/*! This is an introduction to the page with all class members. */
/*! This is an introduction to the page with all class members. */
QCString
trCompoundMembersDescription
(
bool
extractAll
)
QCString
trCompoundMembersDescription
(
bool
extractAll
)
{
{
QCString
result
=
"Questa è una lista "
;
QCString
result
=
"Questa è una lista "
;
if
(
!
extractAll
)
result
+=
"dei membri documentati, "
;
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
if
(
!
extractAll
)
result
+=
"delle struct e delle union documentate "
;
else
result
+=
"di tutte le struct e le union "
;
}
else
{
if
(
!
extractAll
)
result
+=
"dei membri documentati "
;
else
result
+=
"di tutti i membri "
;
else
result
+=
"di tutti i membri "
;
result
+=
"con collegamenti "
;
}
if
(
extractAll
)
result
+=
"alla documentazione della classe di ciascun membro:"
;
result
+=
"con collegamenti alla documentazione "
;
else
result
+=
"alla documentazione delle classi a cui appartengono:"
;
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
if
(
extractAll
)
result
+=
"della struct/union per ciascun campo:"
;
else
result
+=
"delle struct/union a cui appartengono:"
;
}
else
{
if
(
extractAll
)
result
+=
"della classe di ciascun membro:"
;
else
result
+=
"delle classi a cui appartengono:"
;
}
return
result
;
return
result
;
}
}
...
@@ -200,17 +310,25 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -200,17 +310,25 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
QCString
trFileMembersDescription
(
bool
extractAll
)
QCString
trFileMembersDescription
(
bool
extractAll
)
{
{
QCString
result
=
"Questa è una lista "
;
QCString
result
=
"Questa è una lista "
;
if
(
!
extractAll
)
result
+=
"dei membri dei files documentati, "
;
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
else
result
+=
"di tutti i membri dei files "
;
{
result
+=
"con collegamenti "
;
if
(
!
extractAll
)
result
+=
"delle funczioni, variabili, define, tipi enumerati, e typedefs documentati "
;
if
(
extractAll
)
result
+=
"alla documentazione del file di ciascun membro:"
;
else
result
+=
"di tutte le funczioni, variabili, define, tipi enumerati, e typedefs "
;
else
result
+=
"alla documentazione dei files a cui appartengono:"
;
}
else
{
if
(
!
extractAll
)
result
+=
"dei membri dei file documentati "
;
else
result
+=
"di tutti i membri dei file "
;
}
result
+=
"con collegamenti alla documentazione"
;
if
(
extractAll
)
result
+=
" del file a cui appartengono:"
;
else
result
+=
":"
;
return
result
;
return
result
;
}
}
/*! This is an introduction to the page with the list of all header files. */
/*! This is an introduction to the page with the list of all header files. */
QCString
trHeaderFilesDescription
()
QCString
trHeaderFilesDescription
()
{
return
"Questi sono gli header file
s
che compongono l'API:"
;
}
{
return
"Questi sono gli header file che compongono l'API:"
;
}
/*! This is an introduction to the page with the list of all examples */
/*! This is an introduction to the page with the list of all examples */
QCString
trExamplesDescription
()
QCString
trExamplesDescription
()
...
@@ -253,13 +371,22 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -253,13 +371,22 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
* annotated compound index.
* annotated compound index.
*/
*/
QCString
trCompoundIndex
()
QCString
trCompoundIndex
()
{
return
"Indice dei composti"
;
}
{
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
return
"Indice delle strutture dati"
;
}
else
{
return
"Indice dei composti"
;
}
}
/*! This is used in LaTeX as the title of the chapter with the
/*! This is used in LaTeX as the title of the chapter with the
* list of all files.
* list of all files.
*/
*/
QCString
trFileIndex
()
QCString
trFileIndex
()
{
return
"Indice dei file
s
"
;
}
{
return
"Indice dei file"
;
}
/*! This is used in LaTeX as the title of the chapter containing
/*! This is used in LaTeX as the title of the chapter containing
* the documentation of all groups.
* the documentation of all groups.
...
@@ -277,7 +404,7 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -277,7 +404,7 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
* the documentation of all files.
* the documentation of all files.
*/
*/
QCString
trFileDocumentation
()
QCString
trFileDocumentation
()
{
return
"Documentazione dei file
s
"
;
}
{
return
"Documentazione dei file"
;
}
/*! This is used in LaTeX as the title of the chapter containing
/*! This is used in LaTeX as the title of the chapter containing
* the documentation of all examples.
* the documentation of all examples.
...
@@ -387,13 +514,22 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -387,13 +514,22 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
* the list of links to documented compounds
* the list of links to documented compounds
*/
*/
QCString
trCompounds
()
QCString
trCompounds
()
{
return
"Composti"
;
}
{
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
return
"Strutture dati"
;
}
else
{
return
"Composti"
;
}
}
/*! This is used in the documentation of a group before the list of
/*! This is used in the documentation of a group before the list of
* links to documented files
* links to documented files
*/
*/
QCString
trFiles
()
QCString
trFiles
()
{
return
"File
s
"
;
}
{
return
"File"
;
}
/*! This is used in the standard footer of each page and indicates when
/*! This is used in the standard footer of each page and indicates when
* the page was generated
* the page was generated
...
@@ -432,7 +568,7 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -432,7 +568,7 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
/*! this text is generated when the \\bug command is used. */
/*! this text is generated when the \\bug command is used. */
QCString
trBugsAndLimitations
()
QCString
trBugsAndLimitations
()
{
return
"Bug
s
e limitazioni"
;
}
{
return
"Bug e limitazioni"
;
}
/*! this text is generated when the \\version command is used. */
/*! this text is generated when the \\version command is used. */
QCString
trVersion
()
QCString
trVersion
()
...
@@ -472,14 +608,14 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -472,14 +608,14 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
/*! used as the title of page containing all the index of all namespaces. */
/*! used as the title of page containing all the index of all namespaces. */
QCString
trNamespaceList
()
QCString
trNamespaceList
()
{
return
"Lista dei namespace
s
"
;
}
{
return
"Lista dei namespace"
;
}
/*! used as an introduction to the namespace list */
/*! used as an introduction to the namespace list */
QCString
trNamespaceListDescription
(
bool
extractAll
)
QCString
trNamespaceListDescription
(
bool
extractAll
)
{
{
QCString
result
=
"Questa è la lista "
;
QCString
result
=
"Questa è la lista "
;
if
(
!
extractAll
)
result
+=
"dei namespace
s
documentati, "
;
if
(
!
extractAll
)
result
+=
"dei namespace documentati, "
;
else
result
+=
"di tutti i namespace
s
"
;
else
result
+=
"di tutti i namespace "
;
result
+=
"con una loro breve descrizione:"
;
result
+=
"con una loro breve descrizione:"
;
return
result
;
return
result
;
}
}
...
@@ -488,7 +624,7 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -488,7 +624,7 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
* friends of a class
* friends of a class
*/
*/
QCString
trFriends
()
QCString
trFriends
()
{
return
"Friend
s
"
;
}
{
return
"Friend"
;
}
//////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////
// new since 0.49-990405
// new since 0.49-990405
...
@@ -498,7 +634,7 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -498,7 +634,7 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
* related classes
* related classes
*/
*/
QCString
trRelatedFunctionDocumentation
()
QCString
trRelatedFunctionDocumentation
()
{
return
"Documentazione dei friend
s
e delle funzioni collegate"
;
}
{
return
"Documentazione dei friend e delle funzioni collegate"
;
}
//////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////
// new since 0.49-990425
// new since 0.49-990425
...
@@ -507,9 +643,10 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -507,9 +643,10 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
/*! used as the title of the HTML page of a class/struct/union */
/*! used as the title of the HTML page of a class/struct/union */
QCString
trCompoundReference
(
const
char
*
clName
,
QCString
trCompoundReference
(
const
char
*
clName
,
ClassDef
::
CompoundType
compType
,
ClassDef
::
CompoundType
compType
,
bool
/* isTemplate */
)
bool
isTemplate
)
{
{
QCString
result
=
"Riferimenti per "
;
QCString
result
=
"Riferimenti per "
;
if
(
isTemplate
)
result
=
"Template per "
;
switch
(
compType
)
switch
(
compType
)
{
{
case
ClassDef
:
:
Class
:
result
+=
"la classe "
;
break
;
case
ClassDef
:
:
Class
:
result
+=
"la classe "
;
break
;
...
@@ -545,21 +682,21 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -545,21 +682,21 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
QCString
trPublicMembers
()
QCString
trPublicMembers
()
{
return
"Membri pubblici"
;
}
{
return
"Membri pubblici"
;
}
QCString
trPublicSlots
()
QCString
trPublicSlots
()
{
return
"Slot
s
pubblici"
;
}
{
return
"Slot pubblici"
;
}
QCString
trSignals
()
QCString
trSignals
()
{
return
"Signal
s
"
;
}
{
return
"Signal"
;
}
QCString
trStaticPublicMembers
()
QCString
trStaticPublicMembers
()
{
return
"Membri pubblici statici"
;
}
{
return
"Membri pubblici statici"
;
}
QCString
trProtectedMembers
()
QCString
trProtectedMembers
()
{
return
"Membri protetti"
;
}
{
return
"Membri protetti"
;
}
QCString
trProtectedSlots
()
QCString
trProtectedSlots
()
{
return
"Slot
s
protetti"
;
}
{
return
"Slot protetti"
;
}
QCString
trStaticProtectedMembers
()
QCString
trStaticProtectedMembers
()
{
return
"Membri protetti statici"
;
}
{
return
"Membri protetti statici"
;
}
QCString
trPrivateMembers
()
QCString
trPrivateMembers
()
{
return
"Membri privati"
;
}
{
return
"Membri privati"
;
}
QCString
trPrivateSlots
()
QCString
trPrivateSlots
()
{
return
"Slot
s
privati"
;
}
{
return
"Slot privati"
;
}
QCString
trStaticPrivateMembers
()
QCString
trStaticPrivateMembers
()
{
return
"Membri privati statici"
;
}
{
return
"Membri privati statici"
;
}
/*! \endmgroup */
/*! \endmgroup */
...
@@ -623,32 +760,32 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -623,32 +760,32 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
/*! This is put above each page as a link to all members of namespaces. */
/*! This is put above each page as a link to all members of namespaces. */
QCString
trNamespaceMembers
()
QCString
trNamespaceMembers
()
{
return
"Membri dei namespace
s
"
;
}
{
return
"Membri dei namespace"
;
}
/*! This is an introduction to the page with all namespace members */
/*! This is an introduction to the page with all namespace members */
QCString
trNamespaceMemberDescription
(
bool
extractAll
)
QCString
trNamespaceMemberDescription
(
bool
extractAll
)
{
{
QCString
result
=
"Questa è la lista "
;
QCString
result
=
"Questa è la lista "
;
if
(
!
extractAll
)
result
+=
"dei membri dei namespace
s
documentati, "
;
if
(
!
extractAll
)
result
+=
"dei membri dei namespace documentati, "
;
else
result
+=
"di tutti i membri dei namespace
s
"
;
else
result
+=
"di tutti i membri dei namespace "
;
result
+=
"con collegamenti "
;
result
+=
"con collegamenti "
;
if
(
extractAll
)
if
(
extractAll
)
result
+=
"alla documentazione del namespace per ciascun membro:"
;
result
+=
"alla documentazione del namespace per ciascun membro:"
;
else
else
result
+=
"ai namespace
s
a cui appartengono:"
;
result
+=
"ai namespace a cui appartengono:"
;
return
result
;
return
result
;
}
}
/*! This is used in LaTeX as the title of the chapter with the
/*! This is used in LaTeX as the title of the chapter with the
* index of all namespaces.
* index of all namespaces.
*/
*/
QCString
trNamespaceIndex
()
QCString
trNamespaceIndex
()
{
return
"Indice dei namespace
s
"
;
}
{
return
"Indice dei namespace"
;
}
/*! This is used in LaTeX as the title of the chapter containing
/*! This is used in LaTeX as the title of the chapter containing
* the documentation of all namespaces.
* the documentation of all namespaces.
*/
*/
QCString
trNamespaceDocumentation
()
QCString
trNamespaceDocumentation
()
{
return
"Documentazione dei namespace
s
"
;
}
{
return
"Documentazione dei namespace"
;
}
//////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////
// new since 0.49-990522
// new since 0.49-990522
...
@@ -658,7 +795,7 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -658,7 +795,7 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
* namespaces in a file.
* namespaces in a file.
*/
*/
QCString
trNamespaces
()
QCString
trNamespaces
()
{
return
"Namespace
s
"
;
}
{
return
"Namespace"
;
}
//////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////
// new since 0.49-990728
// new since 0.49-990728
...
@@ -682,7 +819,7 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -682,7 +819,7 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
}
}
result
+=
" è stata generata a partire "
;
result
+=
" è stata generata a partire "
;
if
(
single
)
result
+=
"dal seguente file:"
;
if
(
single
)
result
+=
"dal seguente file:"
;
else
result
+=
"dai seguenti file
s
:"
;
else
result
+=
"dai seguenti file:"
;
return
result
;
return
result
;
}
}
...
@@ -744,7 +881,7 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -744,7 +881,7 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
/*! this text is put before a collaboration diagram */
/*! this text is put before a collaboration diagram */
QCString
trCollaborationDiagram
(
const
char
*
clName
)
QCString
trCollaborationDiagram
(
const
char
*
clName
)
{
{
return
(
QCString
)
"Diagramma di
interrel
azione per "
+
clName
+
":"
;
return
(
QCString
)
"Diagramma di
collabor
azione per "
+
clName
+
":"
;
}
}
/*! this text is put before an include dependency graph */
/*! this text is put before an include dependency graph */
QCString
trInclDepGraph
(
const
char
*
fName
)
QCString
trInclDepGraph
(
const
char
*
fName
)
...
@@ -821,9 +958,17 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -821,9 +958,17 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
return
"Tipi pubblici"
;
return
"Tipi pubblici"
;
}
}
QCString
trPublicAttribs
()
QCString
trPublicAttribs
()
{
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
return
"Campi"
;
}
else
{
{
return
"Attributi pubblici"
;
return
"Attributi pubblici"
;
}
}
}
QCString
trStaticPublicAttribs
()
QCString
trStaticPublicAttribs
()
{
{
return
"Attributi pubblici statici"
;
return
"Attributi pubblici statici"
;
...
@@ -860,7 +1005,7 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -860,7 +1005,7 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
/*! Used as a marker that is put before a todo item */
/*! Used as a marker that is put before a todo item */
virtual
QCString
trTodo
()
virtual
QCString
trTodo
()
{
{
return
"Da
F
are"
;
return
"Da
f
are"
;
}
}
/*! Used as the header of the todo list */
/*! Used as the header of the todo list */
virtual
QCString
trTodoList
()
virtual
QCString
trTodoList
()
...
@@ -886,7 +1031,7 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -886,7 +1031,7 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
}
}
virtual
QCString
trInclByDepGraph
()
virtual
QCString
trInclByDepGraph
()
{
{
return
"Queato grafo mostra quali file
s
includono direttamente o indirettamente questo file:"
;
return
"Queato grafo mostra quali file includono direttamente o indirettamente questo file:"
;
}
}
virtual
QCString
trSince
()
virtual
QCString
trSince
()
{
{
...
@@ -996,7 +1141,7 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -996,7 +1141,7 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
/*! Used as a section header for IDL property documentation */
/*! Used as a section header for IDL property documentation */
virtual
QCString
trPropertyDocumentation
()
virtual
QCString
trPropertyDocumentation
()
{
{
return
"Documentazione delle
P
roprietà"
;
return
"Documentazione delle
p
roprietà"
;
}
}
//////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////
...
@@ -1010,9 +1155,16 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -1010,9 +1155,16 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
}
}
/*! Used for Java classes in the summary section of Java packages */
/*! Used for Java classes in the summary section of Java packages */
virtual
QCString
trClasses
()
virtual
QCString
trClasses
()
{
if
(
Config_getBool
(
"OPTIMIZE_OUTPUT_FOR_C"
))
{
return
"Strutture dati"
;
}
else
{
{
return
"Classi"
;
return
"Classi"
;
}
}
}
/*! Used as the title of a Java package */
/*! Used as the title of a Java package */
virtual
QCString
trPackage
(
const
char
*
name
)
virtual
QCString
trPackage
(
const
char
*
name
)
{
{
...
@@ -1043,6 +1195,129 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
...
@@ -1043,6 +1195,129 @@ class TranslatorItalian : public TranslatorAdapter_1_2_5
{
{
return
"Valore:"
;
return
"Valore:"
;
}
}
//////////////////////////////////////////////////////////////////////////
// new since 1.2.5
//////////////////////////////////////////////////////////////////////////
/*! Used as a marker that is put before a \\bug item */
virtual
QCString
trBug
()
{
return
"Bug"
;
}
/*! Used as the header of the bug list */
virtual
QCString
trBugList
()
{
return
"Lista dei bug"
;
}
//////////////////////////////////////////////////////////////////////////
// new since 1.2.6
//////////////////////////////////////////////////////////////////////////
/*! Used as ansicpg for RTF file */
virtual
QCString
trRTFansicp
()
{
return
"1252"
;
}
/*! Used as ansicpg for RTF fcharset */
virtual
QCString
trRTFCharSet
()
{
return
"0"
;
}
/*! Used as header RTF general index */
virtual
QCString
trRTFGeneralIndex
()
{
return
"Indice"
;
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trClass
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
"Class"
:
"class"
));
result
+=
(
singular
?
"e"
:
"i"
);
return
result
;
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trFile
(
bool
first_capital
,
bool
)
{
QCString
result
((
first_capital
?
"File"
:
"file"
));
return
result
;
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trNamespace
(
bool
first_capital
,
bool
)
{
QCString
result
((
first_capital
?
"Namespace"
:
"namespace"
));
return
result
;
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trGroup
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
"Grupp"
:
"grupp"
));
result
+=
(
singular
?
"o"
:
"i"
);
return
result
;
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trPage
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
"Pagin"
:
"pagin"
));
result
+=
(
singular
?
"a"
:
"e"
);
return
result
;
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trMember
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
"Membr"
:
"membr"
));
result
+=
(
singular
?
"o"
:
"i"
);
return
result
;
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trField
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
"Camp"
:
"camp"
));
result
+=
(
singular
?
"o"
:
"i"
);
return
result
;
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trGlobal
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
"Global"
:
"global"
));
result
+=
(
singular
?
"e"
:
"i"
);
return
result
;
}
};
};
#endif
#endif
src/translator_ru.h
View file @
75fed736
...
@@ -48,9 +48,9 @@
...
@@ -48,9 +48,9 @@
#ifndef TRANSLATOR_RU_H
#ifndef TRANSLATOR_RU_H
#define TRANSLATOR_RU_H
#define TRANSLATOR_RU_H
#include "translator
_adapter
.h"
#include "translator.h"
class
TranslatorRussian
:
public
Translator
Adapter_1_2_5
class
TranslatorRussian
:
public
Translator
{
{
private
:
private
:
/*! The Decode() inline assumes the source written in the
/*! The Decode() inline assumes the source written in the
...
@@ -1216,6 +1216,21 @@ class TranslatorRussian : public TranslatorAdapter_1_2_5
...
@@ -1216,6 +1216,21 @@ class TranslatorRussian : public TranslatorAdapter_1_2_5
return
decode
(
":"
);
return
decode
(
":"
);
}
}
//////////////////////////////////////////////////////////////////////////
// new since 1.2.5
//////////////////////////////////////////////////////////////////////////
/*! Used as a marker that is put before a \\bug item */
virtual
QCString
trBug
()
{
return
decode
(
""
);
}
/*! Used as the header of the bug list */
virtual
QCString
trBugList
()
{
return
decode
(
""
);
}
//////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////
// new since 1.2.6
// new since 1.2.6
//////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////
...
@@ -1234,6 +1249,95 @@ class TranslatorRussian : public TranslatorAdapter_1_2_5
...
@@ -1234,6 +1249,95 @@ class TranslatorRussian : public TranslatorAdapter_1_2_5
{
{
return
decode
(
" "
);
return
decode
(
" "
);
}
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trClass
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
""
:
""
));
if
(
!
singular
)
result
+=
""
;
return
decode
(
result
);
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trFile
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
""
:
""
));
if
(
!
singular
)
result
+=
""
;
return
decode
(
result
);
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trNamespace
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
""
:
""
));
result
+=
(
singular
?
" "
:
" "
);
return
decode
(
result
);
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trGroup
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
""
:
""
));
result
+=
(
singular
?
""
:
""
);
return
decode
(
result
);
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trPage
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
""
:
""
));
result
+=
(
singular
?
""
:
""
);
return
decode
(
result
);
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trMember
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
""
:
""
));
if
(
!
singular
)
result
+=
""
;
return
decode
(
result
);
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trField
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
""
:
""
));
result
+=
(
singular
?
""
:
""
);
return
decode
(
result
);
}
/*! This is used for translation of the word that will possibly
* be followed by a single name or by a list of names
* of the category.
*/
virtual
QCString
trGlobal
(
bool
first_capital
,
bool
singular
)
{
QCString
result
((
first_capital
?
""
:
""
));
result
+=
(
singular
?
""
:
""
);
return
decode
(
result
);
}
};
};
#endif
#endif
src/util.cpp
View file @
75fed736
...
@@ -338,7 +338,7 @@ int guessSection(const char *name)
...
@@ -338,7 +338,7 @@ int guessSection(const char *name)
ClassDef
*
getClass
(
const
char
*
name
)
ClassDef
*
getClass
(
const
char
*
name
)
{
{
if
(
name
==
0
||
name
[
0
]
==
'\0'
)
return
0
;
if
(
name
==
0
||
name
[
0
]
==
'\0'
)
return
0
;
return
Doxygen
::
class
Dict
[
name
]
;
return
Doxygen
::
class
SDict
.
find
(
name
)
;
}
}
NamespaceDef
*
getResolvedNamespace
(
const
char
*
name
)
NamespaceDef
*
getResolvedNamespace
(
const
char
*
name
)
...
@@ -376,30 +376,30 @@ ClassDef *getResolvedClass(const char *name,bool *pIsTypeDef,QCString *pTemplSpe
...
@@ -376,30 +376,30 @@ ClassDef *getResolvedClass(const char *name,bool *pIsTypeDef,QCString *pTemplSpe
//printf("getResolvedClass `%s'->`%s'\n",name,subst->data());
//printf("getResolvedClass `%s'->`%s'\n",name,subst->data());
if
(
*
subst
==
name
)
// avoid resolving typedef struct foo foo;
if
(
*
subst
==
name
)
// avoid resolving typedef struct foo foo;
{
{
return
Doxygen
::
class
Dict
[
name
]
;
return
Doxygen
::
class
SDict
.
find
(
name
)
;
}
}
int
count
=
0
;
// recursion detection guard
int
count
=
0
;
// recursion detection guard
QCString
*
newSubst
;
QCString
*
newSubst
;
while
((
newSubst
=
Doxygen
::
typedefDict
[
*
subst
])
&&
count
<
10
)
while
((
newSubst
=
Doxygen
::
typedefDict
[
*
subst
])
&&
count
<
10
)
{
{
if
(
*
subst
==*
newSubst
)
return
Doxygen
::
class
Dict
[
subst
->
data
()]
;
// for breaking typedef struct A A;
if
(
*
subst
==*
newSubst
)
return
Doxygen
::
class
SDict
.
find
(
subst
->
data
())
;
// for breaking typedef struct A A;
subst
=
newSubst
;
subst
=
newSubst
;
count
++
;
count
++
;
}
}
if
(
count
==
10
)
if
(
count
==
10
)
{
{
warn_cont
(
"Warning: possible recursive typedef dependency detected for %s!
\n
"
,
name
);
warn_cont
(
"Warning: possible recursive typedef dependency detected for %s!
\n
"
,
name
);
return
Doxygen
::
class
Dict
[
name
]
;
return
Doxygen
::
class
SDict
.
find
(
name
)
;
}
}
else
else
{
{
//printf("getClass: subst %s->%s\n",name,subst->data());
//printf("getClass: subst %s->%s\n",name,subst->data());
int
i
;
int
i
;
ClassDef
*
cd
=
Doxygen
::
class
Dict
[
subst
->
data
()]
;
ClassDef
*
cd
=
Doxygen
::
class
SDict
.
find
(
subst
->
data
())
;
if
(
cd
==
0
&&
(
i
=
subst
->
find
(
'<'
))
>
0
)
// try unspecialized version as well
if
(
cd
==
0
&&
(
i
=
subst
->
find
(
'<'
))
>
0
)
// try unspecialized version as well
{
{
if
(
pTemplSpec
)
*
pTemplSpec
=
subst
->
right
(
subst
->
length
()
-
i
);
if
(
pTemplSpec
)
*
pTemplSpec
=
subst
->
right
(
subst
->
length
()
-
i
);
return
Doxygen
::
class
Dict
[
subst
->
left
(
i
)]
;
return
Doxygen
::
class
SDict
.
find
(
subst
->
left
(
i
))
;
}
}
else
else
{
{
...
@@ -410,7 +410,7 @@ ClassDef *getResolvedClass(const char *name,bool *pIsTypeDef,QCString *pTemplSpe
...
@@ -410,7 +410,7 @@ ClassDef *getResolvedClass(const char *name,bool *pIsTypeDef,QCString *pTemplSpe
else
else
{
{
if
(
pIsTypeDef
)
*
pIsTypeDef
=
FALSE
;
if
(
pIsTypeDef
)
*
pIsTypeDef
=
FALSE
;
return
Doxygen
::
class
Dict
[
name
]
;
return
Doxygen
::
class
SDict
.
find
(
name
)
;
}
}
}
}
...
@@ -635,9 +635,9 @@ void linkifyText(const TextGeneratorIntf &out,const char *scName,const char *nam
...
@@ -635,9 +635,9 @@ void linkifyText(const TextGeneratorIntf &out,const char *scName,const char *nam
}
}
void
writeExample
(
OutputList
&
ol
,
Example
List
*
el
)
void
writeExample
(
OutputList
&
ol
,
Example
SDict
*
ed
)
{
{
QCString
exampleLine
=
theTranslator
->
trWriteList
(
e
l
->
count
());
QCString
exampleLine
=
theTranslator
->
trWriteList
(
e
d
->
count
());
//bool latexEnabled = ol.isEnabled(OutputGenerator::Latex);
//bool latexEnabled = ol.isEnabled(OutputGenerator::Latex);
//bool manEnabled = ol.isEnabled(OutputGenerator::Man);
//bool manEnabled = ol.isEnabled(OutputGenerator::Man);
...
@@ -650,7 +650,7 @@ void writeExample(OutputList &ol,ExampleList *el)
...
@@ -650,7 +650,7 @@ void writeExample(OutputList &ol,ExampleList *el)
bool
ok
;
bool
ok
;
parseText
(
ol
,
exampleLine
.
mid
(
index
,
newIndex
-
index
));
parseText
(
ol
,
exampleLine
.
mid
(
index
,
newIndex
-
index
));
uint
entryIndex
=
exampleLine
.
mid
(
newIndex
+
1
,
matchLen
-
1
).
toUInt
(
&
ok
);
uint
entryIndex
=
exampleLine
.
mid
(
newIndex
+
1
,
matchLen
-
1
).
toUInt
(
&
ok
);
Example
*
e
=
e
l
->
at
(
entryIndex
);
Example
*
e
=
e
d
->
at
(
entryIndex
);
if
(
ok
&&
e
)
if
(
ok
&&
e
)
{
{
ol
.
pushGeneratorState
();
ol
.
pushGeneratorState
();
...
@@ -1091,6 +1091,23 @@ static bool matchArgument(const Argument *srcA,const Argument *dstA,
...
@@ -1091,6 +1091,23 @@ static bool matchArgument(const Argument *srcA,const Argument *dstA,
QCString
dstAType
=
trimTemplateSpecifiers
(
className
,
dstA
->
type
);
QCString
dstAType
=
trimTemplateSpecifiers
(
className
,
dstA
->
type
);
if
(
srcAType
.
left
(
6
)
==
"class "
)
srcAType
=
srcAType
.
right
(
srcAType
.
length
()
-
6
);
if
(
srcAType
.
left
(
6
)
==
"class "
)
srcAType
=
srcAType
.
right
(
srcAType
.
length
()
-
6
);
if
(
dstAType
.
left
(
6
)
==
"class "
)
dstAType
=
dstAType
.
right
(
dstAType
.
length
()
-
6
);
if
(
dstAType
.
left
(
6
)
==
"class "
)
dstAType
=
dstAType
.
right
(
dstAType
.
length
()
-
6
);
// allow distingishing "const A" from "const B" even though
// from a syntactic point of view they would be two names of the same
// type "const". This is not fool prove ofcourse, but should at least
// catch the most common cases.
if
(
srcAType
==
"const"
&&
!
srcA
->
name
.
isEmpty
())
{
srcAType
+=
" "
;
srcAType
+=
srcA
->
name
;
}
if
(
dstAType
==
"const"
&&
!
dstA
->
name
.
isEmpty
())
{
dstAType
+=
" "
;
dstAType
+=
dstA
->
name
;
}
//printf("scope=`%s': `%s' <=> `%s'\n",className.data(),srcAType.data(),dstAType.data());
stripIrrelevantConstVolatile
(
srcAType
);
stripIrrelevantConstVolatile
(
srcAType
);
stripIrrelevantConstVolatile
(
dstAType
);
stripIrrelevantConstVolatile
(
dstAType
);
...
@@ -1101,7 +1118,6 @@ static bool matchArgument(const Argument *srcA,const Argument *dstA,
...
@@ -1101,7 +1118,6 @@ static bool matchArgument(const Argument *srcA,const Argument *dstA,
}
}
if
(
srcAType
!=
dstAType
)
// check if the argument only differs on name
if
(
srcAType
!=
dstAType
)
// check if the argument only differs on name
{
{
//printf("scope=`%s': `%s' <=> `%s'\n",className.data(),srcAType.data(),dstAType.data());
// remove a namespace scope that is only in one type
// remove a namespace scope that is only in one type
// (assuming a using statement was used)
// (assuming a using statement was used)
...
@@ -2461,7 +2477,8 @@ int getPrefixIndex(const QCString &name)
...
@@ -2461,7 +2477,8 @@ int getPrefixIndex(const QCString &name)
int
ni
=
name
.
findRev
(
"::"
);
int
ni
=
name
.
findRev
(
"::"
);
if
(
ni
==-
1
)
ni
=
0
;
else
ni
+=
2
;
if
(
ni
==-
1
)
ni
=
0
;
else
ni
+=
2
;
//printf("getPrefixIndex(%s) ni=%d\n",name.data(),ni);
//printf("getPrefixIndex(%s) ni=%d\n",name.data(),ni);
char
*
s
=
Config_getList
(
"IGNORE_PREFIX"
).
first
();
QStrList
&
sl
=
Config_getList
(
"IGNORE_PREFIX"
);
char
*
s
=
sl
.
first
();
while
(
s
)
while
(
s
)
{
{
const
char
*
ps
=
s
;
const
char
*
ps
=
s
;
...
@@ -2472,7 +2489,7 @@ int getPrefixIndex(const QCString &name)
...
@@ -2472,7 +2489,7 @@ int getPrefixIndex(const QCString &name)
{
{
return
ni
+
i
;
return
ni
+
i
;
}
}
s
=
Config_getList
(
"IGNORE_PREFIX"
)
.
next
();
s
=
sl
.
next
();
}
}
return
ni
;
return
ni
;
}
}
...
@@ -2495,9 +2512,9 @@ static void initBaseClassHierarchy(BaseClassList *bcl)
...
@@ -2495,9 +2512,9 @@ static void initBaseClassHierarchy(BaseClassList *bcl)
//----------------------------------------------------------------------------
//----------------------------------------------------------------------------
void
initClassHierarchy
(
Class
Lis
t
*
cl
)
void
initClassHierarchy
(
Class
SDic
t
*
cl
)
{
{
Class
List
Iterator
cli
(
*
cl
);
Class
SDict
::
Iterator
cli
(
*
cl
);
ClassDef
*
cd
;
ClassDef
*
cd
;
for
(
;
(
cd
=
cli
.
current
());
++
cli
)
for
(
;
(
cd
=
cli
.
current
());
++
cli
)
{
{
...
@@ -2743,3 +2760,50 @@ void addMembersToMemberGroup(MemberList *ml,MemberGroupDict *memberGroupDict,
...
@@ -2743,3 +2760,50 @@ void addMembersToMemberGroup(MemberList *ml,MemberGroupDict *memberGroupDict,
}
}
}
}
}
}
/*! Extracts a (sub-)string from \a type starting at \a pos that
* could form a class. When TRUE is returned the result is the
* class \a name and a template argument list \a templSpec.
*/
bool
extractClassNameFromType
(
const
QCString
&
type
,
int
&
pos
,
QCString
&
name
,
QCString
&
templSpec
)
{
static
const
QRegExp
re
(
"[a-z_A-Z][a-z_A-Z0-9:]*"
);
name
.
resize
(
0
);
templSpec
.
resize
(
0
);
int
i
,
l
;
int
typeLen
=
type
.
length
();
if
(
typeLen
>
0
)
{
if
((
i
=
re
.
match
(
type
,
pos
,
&
l
))
!=-
1
)
// for each class name in the type
{
int
ts
=
i
+
l
;
int
te
=
ts
;
while
(
type
.
at
(
ts
)
==
' '
&&
ts
<
typeLen
)
ts
++
;
// skip any whitespace
if
(
type
.
at
(
ts
)
==
'<'
)
// assume template instance
{
// locate end of template
te
=
ts
+
1
;
int
brCount
=
1
;
while
(
te
<
typeLen
&&
brCount
!=
0
)
{
if
(
type
.
at
(
te
)
==
'<'
)
{
if
(
te
<
typeLen
-
1
&&
type
.
at
(
te
+
1
)
==
'<'
)
te
++
;
else
brCount
++
;
}
if
(
type
.
at
(
te
)
==
'>'
)
{
if
(
te
<
typeLen
-
1
&&
type
.
at
(
te
+
1
)
==
'>'
)
te
++
;
else
brCount
--
;
}
te
++
;
}
}
if
(
te
>
ts
)
templSpec
=
type
.
mid
(
ts
,
te
-
ts
);
name
=
type
.
mid
(
i
,
l
);
pos
=
i
+
l
;
return
TRUE
;
}
}
return
FALSE
;
}
src/util.h
View file @
75fed736
...
@@ -33,8 +33,8 @@ class ArgumentList;
...
@@ -33,8 +33,8 @@ class ArgumentList;
class
OutputList
;
class
OutputList
;
class
OutputDocInterface
;
class
OutputDocInterface
;
class
MemberDef
;
class
MemberDef
;
class
Example
Lis
t
;
class
Example
SDic
t
;
class
Class
Lis
t
;
class
Class
SDic
t
;
class
BaseClassList
;
class
BaseClassList
;
class
GroupDef
;
class
GroupDef
;
class
NamespaceList
;
class
NamespaceList
;
...
@@ -122,7 +122,7 @@ extern QCString removeRedundantWhiteSpace(const QCString &s);
...
@@ -122,7 +122,7 @@ extern QCString removeRedundantWhiteSpace(const QCString &s);
QCString
argListToString
(
ArgumentList
*
al
);
QCString
argListToString
(
ArgumentList
*
al
);
QCString
tempArgListToString
(
ArgumentList
*
al
);
QCString
tempArgListToString
(
ArgumentList
*
al
);
QCString
generateMarker
(
int
id
);
QCString
generateMarker
(
int
id
);
void
writeExample
(
OutputList
&
ol
,
Example
Lis
t
*
el
);
void
writeExample
(
OutputList
&
ol
,
Example
SDic
t
*
el
);
//void setFileNameForSections(QList<QCString> *anchorList,const char *fileName,
//void setFileNameForSections(QList<QCString> *anchorList,const char *fileName,
// PageInfo *pi=0);
// PageInfo *pi=0);
QCString
stripAnonymousNamespaceScope
(
const
QCString
&
s
);
QCString
stripAnonymousNamespaceScope
(
const
QCString
&
s
);
...
@@ -133,7 +133,7 @@ QCString substituteKeywords(const QCString &s,const char *title);
...
@@ -133,7 +133,7 @@ QCString substituteKeywords(const QCString &s,const char *title);
int
getPrefixIndex
(
const
QCString
&
name
);
int
getPrefixIndex
(
const
QCString
&
name
);
QCString
removeAnonymousScopes
(
const
QCString
&
s
);
QCString
removeAnonymousScopes
(
const
QCString
&
s
);
QCString
replaceAnonymousScopes
(
const
QCString
&
s
);
QCString
replaceAnonymousScopes
(
const
QCString
&
s
);
void
initClassHierarchy
(
Class
Lis
t
*
cl
);
void
initClassHierarchy
(
Class
SDic
t
*
cl
);
bool
hasVisibleRoot
(
BaseClassList
*
bcl
);
bool
hasVisibleRoot
(
BaseClassList
*
bcl
);
int
minClassDistance
(
ClassDef
*
cd
,
ClassDef
*
bcd
,
int
level
=
0
);
int
minClassDistance
(
ClassDef
*
cd
,
ClassDef
*
bcd
,
int
level
=
0
);
QCString
convertNameToFile
(
const
char
*
name
,
bool
allowDots
=
FALSE
);
QCString
convertNameToFile
(
const
char
*
name
,
bool
allowDots
=
FALSE
);
...
@@ -147,6 +147,8 @@ QCString convertToXML(const char *s);
...
@@ -147,6 +147,8 @@ QCString convertToXML(const char *s);
const
char
*
getOverloadDocs
();
const
char
*
getOverloadDocs
();
void
addMembersToMemberGroup
(
MemberList
*
ml
,
MemberGroupDict
*
memberGroupDict
,
void
addMembersToMemberGroup
(
MemberList
*
ml
,
MemberGroupDict
*
memberGroupDict
,
MemberGroupList
*
memberGroupList
);
MemberGroupList
*
memberGroupList
);
bool
extractClassNameFromType
(
const
QCString
&
type
,
int
&
pos
,
QCString
&
name
,
QCString
&
templSpec
);
#endif
#endif
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