Commit 1042ef3a authored by Dimitri van Heesch's avatar Dimitri van Heesch

Release-1.6.1-20091004

parent ab254316
DOXYGEN Version 1.6.1 DOXYGEN Version 1.6.1-20091004
Please read the installation section of the manual Please read the installation section of the manual
(http://www.doxygen.org/install.html) for instructions. (http://www.doxygen.org/install.html) for instructions.
-------- --------
Dimitri van Heesch (25 August 2009) Dimitri van Heesch (04 October 2009)
DOXYGEN Version 1.6.1 DOXYGEN Version 1.6.1_20091004
Please read INSTALL for compilation instructions. Please read INSTALL for compilation instructions.
...@@ -17,4 +17,4 @@ to subscribe to the lists or to visit the archives. ...@@ -17,4 +17,4 @@ to subscribe to the lists or to visit the archives.
Enjoy, Enjoy,
Dimitri van Heesch (dimitri@stack.nl) (25 August 2009) Dimitri van Heesch (dimitri@stack.nl) (04 October 2009)
...@@ -185,7 +185,7 @@ void MainWindow::about() ...@@ -185,7 +185,7 @@ void MainWindow::about()
t << QString::fromAscii("<qt><center>A tool to configure and run doxygen version ")+ t << QString::fromAscii("<qt><center>A tool to configure and run doxygen version ")+
QString::fromAscii(versionString)+ QString::fromAscii(versionString)+
QString::fromAscii(" on your source files.</center><p><br>" QString::fromAscii(" on your source files.</center><p><br>"
"<center>Written by<br> Dimitri van Heesch<br>&copy; 2000-2008</center><p>" "<center>Written by<br> Dimitri van Heesch<br>&copy; 2000-2009</center><p>"
"</qt>"); "</qt>");
QMessageBox::about(this,tr("Doxygen GUI"),msg); QMessageBox::about(this,tr("Doxygen GUI"),msg);
} }
...@@ -230,7 +230,14 @@ void MainWindow::saveConfig(const QString &fileName) ...@@ -230,7 +230,14 @@ void MainWindow::saveConfig(const QString &fileName)
{ {
if (fileName.isEmpty()) return; if (fileName.isEmpty()) return;
QFile f(fileName); QFile f(fileName);
if (!f.open(QIODevice::WriteOnly)) return; if (!f.open(QIODevice::WriteOnly))
{
QMessageBox::warning(this,
tr("Error saving"),
tr("Error: cannot open the file ")+fileName+tr(" for writing!\n")+
tr("Reason given: ")+f.error());
return;
}
QTextStream t(&f); QTextStream t(&f);
m_expert->writeConfig(t,false); m_expert->writeConfig(t,false);
updateConfigFileName(fileName); updateConfigFileName(fileName);
......
...@@ -20,7 +20,7 @@ doxygen_version_minor=6 ...@@ -20,7 +20,7 @@ doxygen_version_minor=6
doxygen_version_revision=1 doxygen_version_revision=1
#NOTE: Setting version_mmn to "NO" will omit mmn info from the package. #NOTE: Setting version_mmn to "NO" will omit mmn info from the package.
doxygen_version_mmn=NO doxygen_version_mmn=20091004
bin_dirs=`echo $PATH | sed -e "s/:/ /g"` bin_dirs=`echo $PATH | sed -e "s/:/ /g"`
......
...@@ -61,8 +61,8 @@ followed by the descriptions of the tags grouped by category. ...@@ -61,8 +61,8 @@ followed by the descriptions of the tags grouped by category.
\refitem cfg_alphabetical_index ALPHABETICAL_INDEX \refitem cfg_alphabetical_index ALPHABETICAL_INDEX
\refitem cfg_always_detailed_sec ALWAYS_DETAILED_SEC \refitem cfg_always_detailed_sec ALWAYS_DETAILED_SEC
\refitem cfg_binary_toc BINARY_TOC \refitem cfg_binary_toc BINARY_TOC
\refitem cfg_builtin_stl_support BUILTIN_STL_SUPPORT
\refitem cfg_brief_member_desc BRIEF_MEMBER_DESC \refitem cfg_brief_member_desc BRIEF_MEMBER_DESC
\refitem cfg_builtin_stl_support BUILTIN_STL_SUPPORT
\refitem cfg_call_graph CALL_GRAPH \refitem cfg_call_graph CALL_GRAPH
\refitem cfg_caller_graph CALLER_GRAPH \refitem cfg_caller_graph CALLER_GRAPH
\refitem cfg_case_sense_names CASE_SENSE_NAMES \refitem cfg_case_sense_names CASE_SENSE_NAMES
...@@ -80,6 +80,7 @@ followed by the descriptions of the tags grouped by category. ...@@ -80,6 +80,7 @@ followed by the descriptions of the tags grouped by category.
\refitem cfg_distribute_group_doc DISTRIBUTE_GROUP_DOC \refitem cfg_distribute_group_doc DISTRIBUTE_GROUP_DOC
\refitem cfg_docset_bundle_id DOCSET_BUNDLE_ID \refitem cfg_docset_bundle_id DOCSET_BUNDLE_ID
\refitem cfg_docset_feedname DOCSET_FEEDNAME \refitem cfg_docset_feedname DOCSET_FEEDNAME
\refitem cfg_dot_cleanup DOT_CLEANUP
\refitem cfg_dot_fontname DOT_FONTNAME \refitem cfg_dot_fontname DOT_FONTNAME
\refitem cfg_dot_fontpath DOT_FONTPATH \refitem cfg_dot_fontpath DOT_FONTPATH
\refitem cfg_dot_fontsize DOT_FONTSIZE \refitem cfg_dot_fontsize DOT_FONTSIZE
...@@ -91,8 +92,8 @@ followed by the descriptions of the tags grouped by category. ...@@ -91,8 +92,8 @@ followed by the descriptions of the tags grouped by category.
\refitem cfg_dotfile_dirs DOTFILE_DIRS \refitem cfg_dotfile_dirs DOTFILE_DIRS
\refitem cfg_doxyfile_encoding DOXYFILE_ENCODING \refitem cfg_doxyfile_encoding DOXYFILE_ENCODING
\refitem cfg_enable_preprocessing ENABLE_PREPROCESSING \refitem cfg_enable_preprocessing ENABLE_PREPROCESSING
\refitem cfg_enum_values_per_line ENUM_VALUES_PER_LINE
\refitem cfg_enabled_sections ENABLED_SECTIONS \refitem cfg_enabled_sections ENABLED_SECTIONS
\refitem cfg_enum_values_per_line ENUM_VALUES_PER_LINE
\refitem cfg_example_path EXAMPLE_PATH \refitem cfg_example_path EXAMPLE_PATH
\refitem cfg_example_patterns EXAMPLE_PATTERNS \refitem cfg_example_patterns EXAMPLE_PATTERNS
\refitem cfg_example_recursive EXAMPLE_RECURSIVE \refitem cfg_example_recursive EXAMPLE_RECURSIVE
...@@ -146,6 +147,7 @@ followed by the descriptions of the tags grouped by category. ...@@ -146,6 +147,7 @@ followed by the descriptions of the tags grouped by category.
\refitem cfg_hide_undoc_relations HIDE_UNDOC_RELATIONS \refitem cfg_hide_undoc_relations HIDE_UNDOC_RELATIONS
\refitem cfg_html_align_members HTML_ALIGN_MEMBERS \refitem cfg_html_align_members HTML_ALIGN_MEMBERS
\refitem cfg_html_dynamic_sections HTML_DYNAMIC_SECTIONS \refitem cfg_html_dynamic_sections HTML_DYNAMIC_SECTIONS
\refitem cfg_html_file_extension HTML_FILE_EXTENSION
\refitem cfg_html_footer HTML_FOOTER \refitem cfg_html_footer HTML_FOOTER
\refitem cfg_html_header HTML_HEADER \refitem cfg_html_header HTML_HEADER
\refitem cfg_html_output HTML_OUTPUT \refitem cfg_html_output HTML_OUTPUT
...@@ -155,6 +157,7 @@ followed by the descriptions of the tags grouped by category. ...@@ -155,6 +157,7 @@ followed by the descriptions of the tags grouped by category.
\refitem cfg_image_path IMAGE_PATH \refitem cfg_image_path IMAGE_PATH
\refitem cfg_include_graph INCLUDE_GRAPH \refitem cfg_include_graph INCLUDE_GRAPH
\refitem cfg_include_path INCLUDE_PATH \refitem cfg_include_path INCLUDE_PATH
\refitem cfg_included_by_graph INCLUDED_BY_GRAPH
\refitem cfg_inherit_docs INHERIT_DOCS \refitem cfg_inherit_docs INHERIT_DOCS
\refitem cfg_inline_info INLINE_INFO \refitem cfg_inline_info INLINE_INFO
\refitem cfg_inline_inherited_memb INLINE_INHERITED_MEMB \refitem cfg_inline_inherited_memb INLINE_INHERITED_MEMB
...@@ -189,23 +192,23 @@ followed by the descriptions of the tags grouped by category. ...@@ -189,23 +192,23 @@ followed by the descriptions of the tags grouped by category.
\refitem cfg_pdf_hyperlinks PDF_HYPERLINKS \refitem cfg_pdf_hyperlinks PDF_HYPERLINKS
\refitem cfg_perl_path PERL_PATH \refitem cfg_perl_path PERL_PATH
\refitem cfg_perlmod_latex PERLMOD_LATEX \refitem cfg_perlmod_latex PERLMOD_LATEX
\refitem cfg_perlmod_pretty PERLMOD_PRETTY
\refitem cfg_perlmod_makevar_prefix PERLMOD_MAKEVAR_PREFIX \refitem cfg_perlmod_makevar_prefix PERLMOD_MAKEVAR_PREFIX
\refitem cfg_perlmod_pretty PERLMOD_PRETTY
\refitem cfg_predefined PREDEFINED \refitem cfg_predefined PREDEFINED
\refitem cfg_project_name PROJECT_NAME \refitem cfg_project_name PROJECT_NAME
\refitem cfg_project_number PROJECT_NUMBER \refitem cfg_project_number PROJECT_NUMBER
\refitem cfg_qhp_namespace QHP_NAMESPACE \refitem cfg_qhg_location QHG_LOCATION
\refitem cfg_qhp_virtual_folder QHP_VIRTUAL_FOLDER
\refitem cfg_qhp_cust_filter_name QHP_CUST_FILTER_NAME
\refitem cfg_qhp_cust_filter_attrs QHP_CUST_FILTER_ATTRS \refitem cfg_qhp_cust_filter_attrs QHP_CUST_FILTER_ATTRS
\refitem cfg_qhp_cust_filter_name QHP_CUST_FILTER_NAME
\refitem cfg_qhp_namespace QHP_NAMESPACE
\refitem cfg_qhp_sect_filter_attrs QHP_SECT_FILTER_ATTRS \refitem cfg_qhp_sect_filter_attrs QHP_SECT_FILTER_ATTRS
\refitem cfg_qhg_location QHG_LOCATION \refitem cfg_qhp_virtual_folder QHP_VIRTUAL_FOLDER
\refitem cfg_qt_autobrief QT_AUTOBRIEF \refitem cfg_qt_autobrief QT_AUTOBRIEF
\refitem cfg_quiet QUIET \refitem cfg_quiet QUIET
\refitem cfg_recursive RECURSIVE \refitem cfg_recursive RECURSIVE
\refitem cfg_referenced_by_relation REFERENCED_BY_RELATION \refitem cfg_referenced_by_relation REFERENCED_BY_RELATION
\refitem cfg_references_relation REFERENCES_RELATION
\refitem cfg_references_link_source REFERENCES_LINK_SOURCE \refitem cfg_references_link_source REFERENCES_LINK_SOURCE
\refitem cfg_references_relation REFERENCES_RELATION
\refitem cfg_repeat_brief REPEAT_BRIEF \refitem cfg_repeat_brief REPEAT_BRIEF
\refitem cfg_rtf_extensions_file RTF_EXTENSIONS_FILE \refitem cfg_rtf_extensions_file RTF_EXTENSIONS_FILE
\refitem cfg_rtf_hyperlinks RTF_HYPERLINKS \refitem cfg_rtf_hyperlinks RTF_HYPERLINKS
...@@ -219,13 +222,14 @@ followed by the descriptions of the tags grouped by category. ...@@ -219,13 +222,14 @@ followed by the descriptions of the tags grouped by category.
\refitem cfg_show_files SHOW_FILES \refitem cfg_show_files SHOW_FILES
\refitem cfg_show_include_files SHOW_INCLUDE_FILES \refitem cfg_show_include_files SHOW_INCLUDE_FILES
\refitem cfg_show_namespaces SHOW_NAMESPACES \refitem cfg_show_namespaces SHOW_NAMESPACES
\refitem cfg_show_used_files SHOW_USED_FILES
\refitem cfg_sip_support SIP_SUPPORT \refitem cfg_sip_support SIP_SUPPORT
\refitem cfg_skip_function_macros SKIP_FUNCTION_MACROS \refitem cfg_skip_function_macros SKIP_FUNCTION_MACROS
\refitem cfg_sort_brief_docs SORT_BRIEF_DOCS \refitem cfg_sort_brief_docs SORT_BRIEF_DOCS
\refitem cfg_sort_by_scope_name SORT_BY_SCOPE_NAME \refitem cfg_sort_by_scope_name SORT_BY_SCOPE_NAME
\refitem cfg_sort_members_constructors_first SORT_MEMBERS_CTORS_1ST
\refitem cfg_sort_group_names SORT_GROUP_NAMES \refitem cfg_sort_group_names SORT_GROUP_NAMES
\refitem cfg_sort_member_docs SORT_MEMBER_DOCS \refitem cfg_sort_member_docs SORT_MEMBER_DOCS
\refitem cfg_sort_members_constructors_first SORT_MEMBERS_CTORS_1ST
\refitem cfg_source_browser SOURCE_BROWSER \refitem cfg_source_browser SOURCE_BROWSER
\refitem cfg_strip_code_comments STRIP_CODE_COMMENTS \refitem cfg_strip_code_comments STRIP_CODE_COMMENTS
\refitem cfg_strip_from_inc_path STRIP_FROM_INC_PATH \refitem cfg_strip_from_inc_path STRIP_FROM_INC_PATH
...@@ -240,8 +244,8 @@ followed by the descriptions of the tags grouped by category. ...@@ -240,8 +244,8 @@ followed by the descriptions of the tags grouped by category.
\refitem cfg_typedef_hides_struct TYPEDEF_HIDES_STRUCT \refitem cfg_typedef_hides_struct TYPEDEF_HIDES_STRUCT
\refitem cfg_uml_look UML_LOOK \refitem cfg_uml_look UML_LOOK
\refitem cfg_use_htags USE_HTAGS \refitem cfg_use_htags USE_HTAGS
\refitem cfg_use_inline_trees USE_INLINE_TREES
\refitem cfg_use_pdflatex USE_PDFLATEX \refitem cfg_use_pdflatex USE_PDFLATEX
\refitem cfg_use_windows_encoding USE_WINDOWS_ENCODING
\refitem cfg_verbatim_headers VERBATIM_HEADERS \refitem cfg_verbatim_headers VERBATIM_HEADERS
\refitem cfg_warn_format WARN_FORMAT \refitem cfg_warn_format WARN_FORMAT
\refitem cfg_warn_if_doc_error WARN_IF_DOC_ERROR \refitem cfg_warn_if_doc_error WARN_IF_DOC_ERROR
...@@ -312,17 +316,6 @@ followed by the descriptions of the tags grouped by category. ...@@ -312,17 +316,6 @@ followed by the descriptions of the tags grouped by category.
Lithuanian, Norwegian, Persian, Polish, Portuguese, Romanian, Russian, Serbian, Lithuanian, Norwegian, Persian, Polish, Portuguese, Romanian, Russian, Serbian,
Slovak, Slovene, Spanish, Swedish, and Ukrainian. Slovak, Slovene, Spanish, Swedish, and Ukrainian.
\anchor cfg_use_windows_encoding
<dt>\c USE_WINDOWS_ENCODING <dd>
\addindex USE_WINDOWS_ENCODING
This tag can be used to specify the encoding used in the generated output.
The encoding is not always determined by the language that is chosen,
but also whether or not the output is meant for Windows or non-Windows users.
In case there is a difference, setting the \c USE_WINDOWS_ENCODING tag to \c YES
forces the Windows encoding, (this is the default for the Windows binary),
whereas setting the tag to \c NO uses a Unix-style encoding (the default for
all platforms other than Windows).
\anchor cfg_brief_member_desc \anchor cfg_brief_member_desc
<dt>\c BRIEF_MEMBER_DESC <dd> <dt>\c BRIEF_MEMBER_DESC <dd>
\addindex BRIEF_MEMBER_DESC \addindex BRIEF_MEMBER_DESC
...@@ -1565,6 +1558,9 @@ and Class Hierarchy pages using a tree view instead of an ordered list. ...@@ -1565,6 +1558,9 @@ and Class Hierarchy pages using a tree view instead of an ordered list.
\addindex LATEX_CMD_NAME \addindex LATEX_CMD_NAME
The \c LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be invoked. The \c LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be invoked.
If left blank `latex' will be used as the default command name. If left blank `latex' will be used as the default command name.
Note that when enabling USE_PDFLATEX this option is only used for
generating bitmaps for formulas in the HTML output, but not in the
Makefile that is written to the output directory.
\anchor cfg_makeindex_cmd_name \anchor cfg_makeindex_cmd_name
<dt>\c MAKEINDEX_CMD_NAME <dd> <dt>\c MAKEINDEX_CMD_NAME <dd>
......
...@@ -23,7 +23,7 @@ text fragments, generated by doxygen, can be produced in languages other ...@@ -23,7 +23,7 @@ text fragments, generated by doxygen, can be produced in languages other
than English (the default). The output language is chosen through the than English (the default). The output language is chosen through the
configuration file (with default name and known as Doxyfile). configuration file (with default name and known as Doxyfile).
Currently (version 1.6.0), 38 languages Currently (version 1.6.1), 38 languages
are supported (sorted alphabetically): are supported (sorted alphabetically):
Afrikaans, Arabic, Brazilian Portuguese, Catalan, Chinese, Chinese Afrikaans, Arabic, Brazilian Portuguese, Catalan, Chinese, Chinese
Traditional, Croatian, Czech, Danish, Dutch, English, Esperanto, Traditional, Croatian, Czech, Danish, Dutch, English, Esperanto,
...@@ -56,7 +56,7 @@ when the translator was updated. ...@@ -56,7 +56,7 @@ when the translator was updated.
<td>Afrikaans</td> <td>Afrikaans</td>
<td>Johan Prinsloo</td> <td>Johan Prinsloo</td>
<td>johan at zippysnoek dot com</td> <td>johan at zippysnoek dot com</td>
<td>1.4.6</td> <td>1.6.0</td>
</tr> </tr>
<tr bgcolor="#ffffff"> <tr bgcolor="#ffffff">
<td>Arabic</td> <td>Arabic</td>
...@@ -218,7 +218,7 @@ when the translator was updated. ...@@ -218,7 +218,7 @@ when the translator was updated.
<td>Polish</td> <td>Polish</td>
<td>Piotr Kaminski<br/>Grzegorz Kowal<br/>Krzysztof Kral</td> <td>Piotr Kaminski<br/>Grzegorz Kowal<br/>Krzysztof Kral</td>
<td>Piotr.Kaminski at ctm dot gdynia dot pl<br/>g_kowal at poczta dot onet dot pl<br/>krzysztof.kral at gmail dot com</td> <td>Piotr.Kaminski at ctm dot gdynia dot pl<br/>g_kowal at poczta dot onet dot pl<br/>krzysztof.kral at gmail dot com</td>
<td>1.6.0</td> <td>up-to-date</td>
</tr> </tr>
<tr bgcolor="#ffffff"> <tr bgcolor="#ffffff">
<td>Portuguese</td> <td>Portuguese</td>
...@@ -307,7 +307,7 @@ when the translator was updated. ...@@ -307,7 +307,7 @@ when the translator was updated.
\hline \hline
\hline \hline
Afrikaans & Johan Prinsloo & {\tt\tiny johan@zippysnoek.com} & 1.4.6 \\ Afrikaans & Johan Prinsloo & {\tt\tiny johan@zippysnoek.com} & 1.6.0 \\
\hline \hline
Arabic & Moaz Reyad & {\tt\tiny moazreyad@yahoo.com} & 1.4.6 \\ Arabic & Moaz Reyad & {\tt\tiny moazreyad@yahoo.com} & 1.4.6 \\
\hline \hline
...@@ -373,7 +373,7 @@ when the translator was updated. ...@@ -373,7 +373,7 @@ when the translator was updated.
\hline \hline
Persian & Ali Nadalizadeh & {\tt\tiny nadalizadeh@gmail.com} & 1.6.0 \\ Persian & Ali Nadalizadeh & {\tt\tiny nadalizadeh@gmail.com} & 1.6.0 \\
\hline \hline
Polish & Piotr Kaminski & {\tt\tiny Piotr.Kaminski@ctm.gdynia.pl} & 1.6.0 \\ Polish & Piotr Kaminski & {\tt\tiny Piotr.Kaminski@ctm.gdynia.pl} & up-to-date \\
~ & Grzegorz Kowal & {\tt\tiny g\_kowal@poczta.onet.pl} & ~ \\ ~ & Grzegorz Kowal & {\tt\tiny g\_kowal@poczta.onet.pl} & ~ \\
~ & Krzysztof Kral & {\tt\tiny krzysztof.kral@gmail.com} & ~ \\ ~ & Krzysztof Kral & {\tt\tiny krzysztof.kral@gmail.com} & ~ \\
\hline \hline
......
...@@ -48,8 +48,10 @@ ...@@ -48,8 +48,10 @@
2005/02/28 - Slight modification to generate "mailto.txt" auxiliary file. 2005/02/28 - Slight modification to generate "mailto.txt" auxiliary file.
2005/08/15 - Doxygen's root directory determined primarily from DOXYGEN 2005/08/15 - Doxygen's root directory determined primarily from DOXYGEN
environment variable. When not found, then relatively to the script. environment variable. When not found, then relatively to the script.
2007/03/20 - The "translate me!" searched in comments and reported if found. 2007/03/20 - The "translate me!" searched in comments and reported if found.
2009/05/09 - Changed HTML output to make it confirm to XHTML DTD 2008/06/09 - Warning when the MAX_DOT_GRAPH_HEIGHT is still part of trLegendDocs().
2009/05/09 - Changed HTML output to fit it with XHTML DTD
2009/09/02 - Added percentage info to the report (implemented / to be implemented).
""" """
from __future__ import generators from __future__ import generators
...@@ -166,6 +168,7 @@ class Transl: ...@@ -166,6 +168,7 @@ class Transl:
self.prototypeDic = {} # uniPrototype -> prototype self.prototypeDic = {} # uniPrototype -> prototype
self.translateMeText = 'translate me!' self.translateMeText = 'translate me!'
self.translateMeFlag = False # comments with "translate me!" found self.translateMeFlag = False # comments with "translate me!" found
self.txtMAX_DOT_GRAPH_HEIGHT_flag = False # found in string in trLegendDocs()
self.obsoleteMethods = None # list of prototypes to be removed self.obsoleteMethods = None # list of prototypes to be removed
self.missingMethods = None # list of prototypes to be implemented self.missingMethods = None # list of prototypes to be implemented
self.implementedMethods = None # list of implemented required methods self.implementedMethods = None # list of implemented required methods
...@@ -769,6 +772,8 @@ class Transl: ...@@ -769,6 +772,8 @@ class Transl:
# identifiers. # identifiers.
prototype = '' # readable prototype (with everything) prototype = '' # readable prototype (with everything)
uniPrototype = '' # unified prototype (without arg. identifiers) uniPrototype = '' # unified prototype (without arg. identifiers)
warning = '' # warning message -- if something special detected
methodId = None # processed method id
# Collect the method prototypes. Stop on the closing # Collect the method prototypes. Stop on the closing
# curly brace followed by the semicolon (end of class). # curly brace followed by the semicolon (end of class).
...@@ -823,6 +828,7 @@ class Transl: ...@@ -823,6 +828,7 @@ class Transl:
if tokenId == 'id': if tokenId == 'id':
prototype += ' ' + tokenStr prototype += ' ' + tokenStr
uniPrototype += ' ' + tokenStr uniPrototype += ' ' + tokenStr
methodId = tokenStr # for reporting
status = 5 status = 5
else: else:
self.__unexpectedToken(status, tokenId, tokenLineNo) self.__unexpectedToken(status, tokenId, tokenLineNo)
...@@ -884,9 +890,17 @@ class Transl: ...@@ -884,9 +890,17 @@ class Transl:
# Insert new dictionary item. # Insert new dictionary item.
assert(not self.prototypeDic.has_key(uniPrototype)) assert(not self.prototypeDic.has_key(uniPrototype))
self.prototypeDic[uniPrototype] = prototype self.prototypeDic[uniPrototype] = prototype
status = 2 # body consumed status = 2 # body consumed
methodId = None # outside of any method
elif tokenId == 'lcurly': elif tokenId == 'lcurly':
curlyCnt += 1 curlyCnt += 1
# Warn in special case.
elif methodId == 'trLegendDocs' and tokenId == 'string' \
and tokenStr.find('MAX_DOT_GRAPH_HEIGHT') >= 0:
self.txtMAX_DOT_GRAPH_HEIGHT_flag = True
elif status == 11: # probably the end of class elif status == 11: # probably the end of class
if tokenId == 'semic': if tokenId == 'semic':
status = 777 status = 777
...@@ -1114,10 +1128,17 @@ class Transl: ...@@ -1114,10 +1128,17 @@ class Transl:
self.adaptMinClass = adaptMinClass self.adaptMinClass = adaptMinClass
self.readableStatus = adaptMinVersion # simplified self.readableStatus = adaptMinVersion # simplified
# If everything seems OK, but the explicit mark self.translateMeText # If everything seems OK, some explicit warning flags still could
# in comments was found, something must be translated. # be set.
if not self.note and self.status == '' and self.translateMeFlag: if not self.note and self.status == '' and \
self.note = 'The "%s" found in a comment.' % self.translateMeText (self.translateMeFlag or self.txtMAX_DOT_GRAPH_HEIGHT_flag):
self.note = ''
if self.translateMeFlag:
self.note += 'The "%s" found in a comment.' % self.translateMeText
if self.note != '':
self.note += '\n\t\t'
if self.txtMAX_DOT_GRAPH_HEIGHT_flag:
self.note += 'The MAX_DOT_GRAPH_HEIGHT found in trLegendDocs()'
# If everything seems OK, but there are obsolete methods, set # If everything seems OK, but there are obsolete methods, set
# the note to clean-up source. This note will be used only when # the note to clean-up source. This note will be used only when
...@@ -1138,18 +1159,21 @@ class Transl: ...@@ -1138,18 +1159,21 @@ class Transl:
# Report the number of not implemented methods. # Report the number of not implemented methods.
fout.write('\n\n\n') fout.write('\n\n\n')
fout.write(self.classId + ' (' + self.baseClassId + ')') fout.write(self.classId + ' (' + self.baseClassId + ')')
percentImplemented = 100 # init
allNum = len(self.manager.requiredMethodsDic)
if self.missingMethods: if self.missingMethods:
num = len(self.missingMethods) num = len(self.missingMethods)
percentImplemented = 100 * (allNum - num) / allNum
fout.write(' %d' % num) fout.write(' %d' % num)
fout.write(' method') fout.write(' method')
if num > 1: if num > 1:
fout.write('s') fout.write('s')
fout.write(' to implement') fout.write(' to implement (%d %%)' % (100 * num / allNum))
fout.write('\n' + '-' * len(self.classId)) fout.write('\n' + '-' * len(self.classId))
# Write the info about the implemented required methods. # Write the info about the implemented required methods.
fout.write('\n\n Implements %d' % len(self.implementedMethods)) fout.write('\n\n Implements %d' % len(self.implementedMethods))
fout.write(' of the required methods.') fout.write(' of the required methods (%d %%).' % percentImplemented)
# Report the missing method, but only when it is not English-based # Report the missing method, but only when it is not English-based
# translator. # translator.
...@@ -1541,6 +1565,7 @@ class TrManager: ...@@ -1541,6 +1565,7 @@ class TrManager:
adaptMinVersion = '9.9.99' adaptMinVersion = '9.9.99'
mailtoLst = [] mailtoLst = []
numRequired = len(self.requiredMethodsDic)
for x in self.adaptIdLst: for x in self.adaptIdLst:
obj = self.__translDic[x] obj = self.__translDic[x]
f.write(' %-30s' % obj.classId) f.write(' %-30s' % obj.classId)
...@@ -1548,7 +1573,9 @@ class TrManager: ...@@ -1548,7 +1573,9 @@ class TrManager:
numimpl = len(obj.missingMethods) numimpl = len(obj.missingMethods)
pluralS = '' pluralS = ''
if numimpl > 1: pluralS = 's' if numimpl > 1: pluralS = 's'
f.write('\t%2d method%s to implement' % (numimpl, pluralS)) percent = 100 * numimpl / numRequired
f.write('\t%2d method%s to implement (%d %%)' % (
numimpl, pluralS, percent))
if obj.note: if obj.note:
f.write('\n\tNote: ' + obj.note + '\n') f.write('\n\tNote: ' + obj.note + '\n')
f.write('\n') f.write('\n')
......
This diff is collapsed.
...@@ -69,6 +69,10 @@ class BufStr ...@@ -69,6 +69,10 @@ class BufStr
} }
m_buf = (char *)realloc(m_buf,m_size); m_buf = (char *)realloc(m_buf,m_size);
} }
int size() const
{
return m_size;
}
char *data() const char *data() const
{ {
return m_buf; return m_buf;
......
...@@ -3089,10 +3089,12 @@ void ClassDef::addListReferences() ...@@ -3089,10 +3089,12 @@ void ClassDef::addListReferences()
{ {
LockingPtr< QList<ListItemInfo> > xrefItems = xrefListItems(); LockingPtr< QList<ListItemInfo> > xrefItems = xrefListItems();
addRefItem(xrefItems.pointer(), addRefItem(xrefItems.pointer(),
qualifiedName(),
fortranOpt?theTranslator->trType(TRUE,TRUE): fortranOpt?theTranslator->trType(TRUE,TRUE):
theTranslator->trClass(TRUE,TRUE), theTranslator->trClass(TRUE,TRUE),
getOutputFileBase(), getOutputFileBase(),
displayName() displayName(),
0
); );
} }
if (m_impl->memberGroupSDict) if (m_impl->memberGroupSDict)
......
...@@ -1395,26 +1395,6 @@ void Config::check() ...@@ -1395,26 +1395,6 @@ void Config::check()
config_err("Warning: Specifying QCH_FILE requires QHG_LOCATION to be set.\n"); config_err("Warning: Specifying QCH_FILE requires QHG_LOCATION to be set.\n");
} }
if (Config_getBool("HAVE_DOT"))
{
QCString curFontPath = Config_getString("DOT_FONTPATH");
if (curFontPath.isEmpty())
{
portable_getenv("DOTFONTPATH");
QCString newFontPath = ".";
if (!curFontPath.isEmpty())
{
newFontPath+=portable_pathListSeparator();
newFontPath+=curFontPath;
}
portable_setenv("DOTFONTPATH",newFontPath);
}
else
{
portable_setenv("DOTFONTPATH",curFontPath);
}
}
if (Config_getBool("OPTIMIZE_OUTPUT_JAVA") && Config_getBool("INLINE_INFO")) if (Config_getBool("OPTIMIZE_OUTPUT_JAVA") && Config_getBool("INLINE_INFO"))
{ {
// don't show inline info for Java output, since Java has no inline // don't show inline info for Java output, since Java has no inline
......
...@@ -139,7 +139,7 @@ the path. The tag can be used to show relative paths in the file list. ...@@ -139,7 +139,7 @@ the path. The tag can be used to show relative paths in the file list.
If left blank the directory from which doxygen is run is used as the If left blank the directory from which doxygen is run is used as the
path to strip. path to strip.
' depends='FULL_PATH_NAMES'> ' depends='FULL_PATH_NAMES'>
<value name='/Users/dimitri/doxygen/mail/1.5.7/doxywizard/'/> <value name=''/>
</option> </option>
<option type='list' id='STRIP_FROM_INC_PATH' format='string' docs=' <option type='list' id='STRIP_FROM_INC_PATH' format='string' docs='
The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of
...@@ -536,7 +536,7 @@ documented source files. You may enter file names like &quot;myfile.cpp&quot; or ...@@ -536,7 +536,7 @@ documented source files. You may enter file names like &quot;myfile.cpp&quot; or
directories like &quot;/usr/src/myproject&quot;. Separate the files or directories directories like &quot;/usr/src/myproject&quot;. Separate the files or directories
with spaces. with spaces.
'> '>
<value name='/Users/dimitri/doxygen/mail/1.5.7/doxywizard'/> <value name=''/>
</option> </option>
<option type='string' id='INPUT_ENCODING' format='string' docs=' <option type='string' id='INPUT_ENCODING' format='string' docs='
This tag can be used to specify the character encoding of the source files This tag can be used to specify the character encoding of the source files
...@@ -933,6 +933,9 @@ put in front of it. If left blank `latex&apos; will be used as the default path. ...@@ -933,6 +933,9 @@ put in front of it. If left blank `latex&apos; will be used as the default path.
<option type='string' id='LATEX_CMD_NAME' format='file' docs=' <option type='string' id='LATEX_CMD_NAME' format='file' docs='
The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be
invoked. If left blank `latex&apos; will be used as the default command name. invoked. If left blank `latex&apos; will be used as the default command name.
Note that when enabling USE_PDFLATEX this option is only used for
generating bitmaps for formulas in the HTML output, but not in the
Makefile that is written to the output directory.
' defval='latex' depends='GENERATE_LATEX'/> ' defval='latex' depends='GENERATE_LATEX'/>
<option type='string' id='MAKEINDEX_CMD_NAME' format='file' docs=' <option type='string' id='MAKEINDEX_CMD_NAME' format='file' docs='
The MAKEINDEX_CMD_NAME tag can be used to specify the command name to The MAKEINDEX_CMD_NAME tag can be used to specify the command name to
......
...@@ -192,7 +192,7 @@ void addConfigOptions(Config *cfg) ...@@ -192,7 +192,7 @@ void addConfigOptions(Config *cfg)
"If left blank the directory from which doxygen is run is used as the\n" "If left blank the directory from which doxygen is run is used as the\n"
"path to strip." "path to strip."
); );
cl->addValue("/Users/dimitri/doxygen/mail/1.5.7/doxywizard/"); cl->addValue("");
cl->addDependency("FULL_PATH_NAMES"); cl->addDependency("FULL_PATH_NAMES");
//---- //----
cl = cfg->addList( cl = cfg->addList(
...@@ -767,7 +767,7 @@ void addConfigOptions(Config *cfg) ...@@ -767,7 +767,7 @@ void addConfigOptions(Config *cfg)
"directories like \"/usr/src/myproject\". Separate the files or directories\n" "directories like \"/usr/src/myproject\". Separate the files or directories\n"
"with spaces." "with spaces."
); );
cl->addValue("/Users/dimitri/doxygen/mail/1.5.7/doxywizard"); cl->addValue("");
cl->setWidgetType(ConfigList::FileAndDir); cl->setWidgetType(ConfigList::FileAndDir);
//---- //----
cs = cfg->addString( cs = cfg->addString(
...@@ -1372,7 +1372,10 @@ void addConfigOptions(Config *cfg) ...@@ -1372,7 +1372,10 @@ void addConfigOptions(Config *cfg)
cs = cfg->addString( cs = cfg->addString(
"LATEX_CMD_NAME", "LATEX_CMD_NAME",
"The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be\n" "The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be\n"
"invoked. If left blank `latex' will be used as the default command name." "invoked. If left blank `latex' will be used as the default command name.\n"
"Note that when enabling USE_PDFLATEX this option is only used for\n"
"generating bitmaps for formulas in the HTML output, but not in the\n"
"Makefile that is written to the output directory."
); );
cs->setDefaultValue("latex"); cs->setDefaultValue("latex");
cs->setWidgetType(ConfigString::File); cs->setWidgetType(ConfigString::File);
......
...@@ -198,9 +198,10 @@ static bool matchExcludedSymbols(const char *name) ...@@ -198,9 +198,10 @@ static bool matchExcludedSymbols(const char *name)
void Definition::addToMap(const char *name,Definition *d) void Definition::addToMap(const char *name,Definition *d)
{ {
static bool vhdlOpt = Config_getBool("OPTIMIZE_OUTPUT_VHDL");
QCString symbolName = name; QCString symbolName = name;
int index=computeQualifiedIndex(symbolName); int index=computeQualifiedIndex(symbolName);
if (index!=-1) symbolName=symbolName.mid(index+2); if (!vhdlOpt && index!=-1) symbolName=symbolName.mid(index+2);
if (!symbolName.isEmpty()) if (!symbolName.isEmpty())
{ {
//printf("******* adding symbol `%s' (%p)\n",symbolName.data(),d); //printf("******* adding symbol `%s' (%p)\n",symbolName.data(),d);
...@@ -1240,7 +1241,7 @@ void Definition::writePathFragment(OutputList &ol) const ...@@ -1240,7 +1241,7 @@ void Definition::writePathFragment(OutputList &ol) const
else else
{ {
ol.writeString("&nbsp;"); ol.writeString("&nbsp;");
ol.writeString("&raquo"); ol.writeString("&raquo;");
ol.writeString("&nbsp;"); ol.writeString("&nbsp;");
} }
} }
......
...@@ -720,9 +720,11 @@ void DirRelation::writeDocumentation(OutputList &ol) ...@@ -720,9 +720,11 @@ void DirRelation::writeDocumentation(OutputList &ol)
ol.writeString("<table class=\"dirtab\">"); ol.writeString("<table class=\"dirtab\">");
ol.writeString("<tr class=\"dirtab\">"); ol.writeString("<tr class=\"dirtab\">");
// TODO: translate me! "File in %s"
ol.writeString("<th class=\"dirtab\">File in "); ol.writeString("<th class=\"dirtab\">File in ");
m_src->writePathFragment(ol); m_src->writePathFragment(ol);
ol.writeString("</th>"); ol.writeString("</th>");
// TODO: translate me! "Includes file in %s"
ol.writeString("<th class=\"dirtab\">Includes file in "); ol.writeString("<th class=\"dirtab\">Includes file in ");
m_dst->dir()->writePathFragment(ol); m_dst->dir()->writePathFragment(ol);
ol.writeString("</th>"); ol.writeString("</th>");
...@@ -844,7 +846,7 @@ void computeDirDependencies() ...@@ -844,7 +846,7 @@ void computeDirDependencies()
#endif #endif
} }
#if 0
void writeDirDependencyGraph(const char *dirName) void writeDirDependencyGraph(const char *dirName)
{ {
QString path; QString path;
...@@ -889,6 +891,7 @@ void writeDirDependencyGraph(const char *dirName) ...@@ -889,6 +891,7 @@ void writeDirDependencyGraph(const char *dirName)
} }
htmlPage.close(); htmlPage.close();
} }
#endif
void generateDirDocs(OutputList &ol) void generateDirDocs(OutputList &ol)
{ {
......
This diff is collapsed.
...@@ -321,10 +321,14 @@ class DotRunner ...@@ -321,10 +321,14 @@ class DotRunner
*/ */
void addJob(const char *format,const char *output); void addJob(const char *format,const char *output);
void addPostProcessing(const char *cmd,const char *args);
/** Runs dot for all jobs added. */ /** Runs dot for all jobs added. */
bool run(); bool run();
private: private:
QList<QCString> m_jobs; QList<QCString> m_jobs;
QCString m_postArgs;
QCString m_postCmd;
QCString m_file; QCString m_file;
}; };
......
...@@ -78,6 +78,7 @@ ...@@ -78,6 +78,7 @@
#include "marshal.h" #include "marshal.h"
#include "portable.h" #include "portable.h"
#include "vhdlscanner.h" #include "vhdlscanner.h"
#include "vhdldocgen.h"
#include "layout.h" #include "layout.h"
...@@ -4078,12 +4079,12 @@ static bool findClassRelation( ...@@ -4078,12 +4079,12 @@ static bool findClassRelation(
QCString biName=bi->name; QCString biName=bi->name;
bool explicitGlobalScope=FALSE; bool explicitGlobalScope=FALSE;
//printf("findClassRelation: biName=`%s'\n",biName.data());
if (biName.left(2)=="::") // explicit global scope if (biName.left(2)=="::") // explicit global scope
{ {
biName=biName.right(biName.length()-2); biName=biName.right(biName.length()-2);
explicitGlobalScope=TRUE; explicitGlobalScope=TRUE;
} }
//printf("biName=`%s'\n",biName.data());
EntryNav *parentNode=rootNav->parent(); EntryNav *parentNode=rootNav->parent();
bool lastParent=FALSE; bool lastParent=FALSE;
...@@ -4108,7 +4109,7 @@ static bool findClassRelation( ...@@ -4108,7 +4109,7 @@ static bool findClassRelation(
// &stripped); // &stripped);
MemberDef *baseClassTypeDef=0; MemberDef *baseClassTypeDef=0;
QCString templSpec; QCString templSpec;
ClassDef *baseClass=getResolvedClass(explicitGlobalScope ? 0 : cd, ClassDef *baseClass=getResolvedClass(explicitGlobalScope ? Doxygen::globalScope : context,
cd->getFileDef(), cd->getFileDef(),
baseClassName, baseClassName,
&baseClassTypeDef, &baseClassTypeDef,
...@@ -4154,7 +4155,7 @@ static bool findClassRelation( ...@@ -4154,7 +4155,7 @@ static bool findClassRelation(
{ {
templSpec=removeRedundantWhiteSpace(baseClassName.mid(i,e-i)); templSpec=removeRedundantWhiteSpace(baseClassName.mid(i,e-i));
baseClassName=baseClassName.left(i)+baseClassName.right(baseClassName.length()-e); baseClassName=baseClassName.left(i)+baseClassName.right(baseClassName.length()-e);
baseClass=getResolvedClass(cd, baseClass=getResolvedClass(explicitGlobalScope ? Doxygen::globalScope : context,
cd->getFileDef(), cd->getFileDef(),
baseClassName, baseClassName,
&baseClassTypeDef, &baseClassTypeDef,
...@@ -4190,7 +4191,7 @@ static bool findClassRelation( ...@@ -4190,7 +4191,7 @@ static bool findClassRelation(
QCString tmpTemplSpec; QCString tmpTemplSpec;
// replace any namespace aliases // replace any namespace aliases
replaceNamespaceAliases(baseClassName,si); replaceNamespaceAliases(baseClassName,si);
baseClass=getResolvedClass(cd, baseClass=getResolvedClass(explicitGlobalScope ? Doxygen::globalScope : context,
cd->getFileDef(), cd->getFileDef(),
baseClassName, baseClassName,
&baseClassTypeDef, &baseClassTypeDef,
...@@ -4648,8 +4649,9 @@ static void addListReferences() ...@@ -4648,8 +4649,9 @@ static void addListReferences()
{ {
LockingPtr< QList<ListItemInfo> > xrefItems = pd->xrefListItems(); LockingPtr< QList<ListItemInfo> > xrefItems = pd->xrefListItems();
addRefItem(xrefItems.pointer(), addRefItem(xrefItems.pointer(),
name,
theTranslator->trPage(TRUE,TRUE), theTranslator->trPage(TRUE,TRUE),
name,pd->title()); name,pd->title(),0);
} }
} }
DirSDict::Iterator ddi(*Doxygen::directories); DirSDict::Iterator ddi(*Doxygen::directories);
...@@ -4663,8 +4665,9 @@ static void addListReferences() ...@@ -4663,8 +4665,9 @@ static void addListReferences()
//} //}
LockingPtr< QList<ListItemInfo> > xrefItems = dd->xrefListItems(); LockingPtr< QList<ListItemInfo> > xrefItems = dd->xrefListItems();
addRefItem(xrefItems.pointer(), addRefItem(xrefItems.pointer(),
name,
theTranslator->trDir(TRUE,TRUE), theTranslator->trDir(TRUE,TRUE),
name,dd->displayName()); name,dd->displayName(),0);
} }
} }
...@@ -7782,9 +7785,13 @@ static void buildPageList(EntryNav *rootNav) ...@@ -7782,9 +7785,13 @@ static void buildPageList(EntryNav *rootNav)
QCString title=root->args.stripWhiteSpace(); QCString title=root->args.stripWhiteSpace();
if (title.isEmpty()) title=theTranslator->trMainPage(); if (title.isEmpty()) title=theTranslator->trMainPage();
addRefItem(root->sli,"page", QCString name = Config_getBool("GENERATE_TREEVIEW")?"main":"index";
Config_getBool("GENERATE_TREEVIEW")?"main":"index", addRefItem(root->sli,
title name,
"page",
name,
title,
0
); );
rootNav->releaseEntry(); rootNav->releaseEntry();
...@@ -8422,113 +8429,6 @@ static bool patternMatch(QFileInfo *fi,QStrList *patList) ...@@ -8422,113 +8429,6 @@ static bool patternMatch(QFileInfo *fi,QStrList *patList)
return found; return found;
} }
static int transcodeCharacterBuffer(BufStr &srcBuf,int size,
const char *inputEncoding,const char *outputEncoding)
{
if (inputEncoding==0 || outputEncoding==0) return size;
if (qstricmp(inputEncoding,outputEncoding)==0) return size;
void *cd = portable_iconv_open(outputEncoding,inputEncoding);
if (cd==(void *)(-1))
{
err("Error: unsupported character conversion: '%s'->'%s': %s\n"
"Check the INPUT_ENCODING setting in the config file!\n",
inputEncoding,outputEncoding,strerror(errno));
exit(1);
}
int tmpBufSize=size*4+1;
BufStr tmpBuf(tmpBufSize);
size_t iLeft=size;
size_t oLeft=tmpBufSize;
const char *srcPtr = srcBuf.data();
char *dstPtr = tmpBuf.data();
uint newSize=0;
if (!portable_iconv(cd, &srcPtr, &iLeft, &dstPtr, &oLeft))
{
newSize = tmpBufSize-oLeft;
srcBuf.shrink(newSize);
strncpy(srcBuf.data(),tmpBuf.data(),newSize);
//printf("iconv: input size=%d output size=%d\n[%s]\n",size,newSize,srcBuf.data());
}
else
{
err("Error: failed to translate characters from %s to %s: check INPUT_ENCODING\n",
inputEncoding,outputEncoding);
exit(1);
}
portable_iconv_close(cd);
return newSize;
}
//----------------------------------------------------------------------------
// reads a file into an array and filters out any 0x00 and 0x06 bytes,
// because these are special for the parser.
void copyAndFilterFile(const char *fileName,BufStr &dest)
{
// try to open file
int size=0;
//uint oldPos = dest.curPos();
//printf(".......oldPos=%d\n",oldPos);
QFileInfo fi(fileName);
if (!fi.exists()) return;
QCString filterName = getFileFilter(fileName);
if (filterName.isEmpty())
{
QFile f(fileName);
if (!f.open(IO_ReadOnly))
{
err("Error: could not open file %s\n",fileName);
return;
}
size=fi.size();
// read the file
dest.skip(size);
if (f.readBlock(dest.data()/*+oldPos*/,size)!=size)
{
err("Error while reading file %s\n",fileName);
return;
}
}
else
{
QCString cmd=filterName+" \""+fileName+"\"";
Debug::print(Debug::ExtCmd,0,"Executing popen(`%s`)\n",cmd.data());
FILE *f=portable_popen(cmd,"r");
if (!f)
{
err("Error: could not execute filter %s\n",filterName.data());
return;
}
const int bufSize=1024;
char buf[bufSize];
int numRead;
while ((numRead=fread(buf,1,bufSize,f))>0)
{
//printf(">>>>>>>>Reading %d bytes\n",numRead);
dest.addArray(buf,numRead),size+=numRead;
}
portable_pclose(f);
}
// filter unwanted bytes from the resulting data
uchar conv[256];
int i;
for (i=0;i<256;i++) conv[i]=i;
conv[0x06]=0x20; // replace the offending characters with spaces
conv[0x00]=0x20;
// remove any special markers from the input
uchar *p=(uchar *)dest.data()/*+oldPos*/;
for (i=0;i<size;i++,p++) *p=conv[*p];
// and translate CR's
int newSize=filterCRLF(dest.data()/*+oldPos*/,size);
//printf("filter char at %p size=%d newSize=%d\n",dest.data()+oldPos,size,newSize);
if (newSize!=size) // we removed chars
{
dest.shrink(/*oldPos+*/newSize); // resize the array
//printf(".......resizing from %d to %d result=[%s]\n",oldPos+size,oldPos+newSize,dest.data());
}
}
//---------------------------------------------------------------------------- //----------------------------------------------------------------------------
static void copyStyleSheet() static void copyStyleSheet()
{ {
...@@ -8562,6 +8462,8 @@ static void copyStyleSheet() ...@@ -8562,6 +8462,8 @@ static void copyStyleSheet()
} }
} }
//! parse the list of input files
static void parseFiles(Entry *root,EntryNav *rootNav) static void parseFiles(Entry *root,EntryNav *rootNav)
{ {
void *cd = 0; void *cd = 0;
...@@ -8587,26 +8489,21 @@ static void parseFiles(Entry *root,EntryNav *rootNav) ...@@ -8587,26 +8489,21 @@ static void parseFiles(Entry *root,EntryNav *rootNav)
QFileInfo fi(fileName); QFileInfo fi(fileName);
BufStr preBuf(fi.size()+4096); BufStr preBuf(fi.size()+4096);
//BufStr *bufPtr = &preBuf;
if (Config_getBool("ENABLE_PREPROCESSING") && if (Config_getBool("ENABLE_PREPROCESSING") &&
parser->needsPreprocessing(extension)) parser->needsPreprocessing(extension))
{ {
BufStr inBuf(fi.size()+4096);
msg("Preprocessing %s...\n",s->data()); msg("Preprocessing %s...\n",s->data());
preprocessFile(fileName,preBuf); readInputFile(fileName,inBuf);
preprocessFile(fileName,inBuf,preBuf);
} }
else else // no preprocessing
{ {
msg("Reading %s...\n",s->data()); msg("Reading %s...\n",s->data());
copyAndFilterFile(fileName,preBuf); readInputFile(fileName,preBuf);
} }
preBuf.addChar('\n'); /* to prevent problems under Windows ? */
// do character transcoding if needed.
transcodeCharacterBuffer(preBuf,preBuf.curPos(),
Config_getString("INPUT_ENCODING"),"UTF-8");
BufStr convBuf(preBuf.curPos()+1024); BufStr convBuf(preBuf.curPos()+1024);
// convert multi-line C++ comments to C style comments // convert multi-line C++ comments to C style comments
...@@ -9911,6 +9808,29 @@ void parseInput() ...@@ -9911,6 +9808,29 @@ void parseInput()
if (generateMan) if (generateMan)
manOutput = createOutputDirectory(outputDirectory,"MAN_OUTPUT","/man"); manOutput = createOutputDirectory(outputDirectory,"MAN_OUTPUT","/man");
if (Config_getBool("HAVE_DOT"))
{
QCString curFontPath = Config_getString("DOT_FONTPATH");
if (curFontPath.isEmpty())
{
portable_getenv("DOTFONTPATH");
QCString newFontPath = ".";
if (!curFontPath.isEmpty())
{
newFontPath+=portable_pathListSeparator();
newFontPath+=curFontPath;
}
portable_setenv("DOTFONTPATH",newFontPath);
}
else
{
portable_setenv("DOTFONTPATH",curFontPath);
}
}
/************************************************************************** /**************************************************************************
* Handle layout file * * Handle layout file *
**************************************************************************/ **************************************************************************/
...@@ -10102,14 +10022,14 @@ void parseInput() ...@@ -10102,14 +10022,14 @@ void parseInput()
msg("Computing class relations...\n"); msg("Computing class relations...\n");
computeTemplateClassRelations(); computeTemplateClassRelations();
flushUnresolvedRelations(); flushUnresolvedRelations();
//if (Config_getBool("OPTIMIZE_OUTPUT_VHDL")) if (Config_getBool("OPTIMIZE_OUTPUT_VHDL"))
//{ {
// VhdlDocGen::computeVhdlComponentRelations(g_classEntries,g_storage); VhdlDocGen::computeVhdlComponentRelations();
//} }
//else else
//{ {
computeClassRelations(); computeClassRelations();
//} }
g_classEntries.clear(); g_classEntries.clear();
msg("Add enum values to enums...\n"); msg("Add enum values to enums...\n");
......
...@@ -1094,8 +1094,10 @@ void FileDef::addListReferences() ...@@ -1094,8 +1094,10 @@ void FileDef::addListReferences()
{ {
LockingPtr< QList<ListItemInfo> > xrefItems = xrefListItems(); LockingPtr< QList<ListItemInfo> > xrefItems = xrefListItems();
addRefItem(xrefItems.pointer(), addRefItem(xrefItems.pointer(),
getOutputFileBase(),
theTranslator->trFile(TRUE,TRUE), theTranslator->trFile(TRUE,TRUE),
getOutputFileBase(),name() getOutputFileBase(),name(),
0
); );
} }
if (memberGroupSDict) if (memberGroupSDict)
......
...@@ -84,7 +84,7 @@ void FormulaList::generateBitmaps(const char *path) ...@@ -84,7 +84,7 @@ void FormulaList::generateBitmaps(const char *path)
for (fli.toFirst();(formula=fli.current());++fli) for (fli.toFirst();(formula=fli.current());++fli)
{ {
QCString resultName; QCString resultName;
resultName.sprintf("form_%d.png",formula->getId()); resultName.sprintf("form_%d.gif",formula->getId());
// only formulas for which no image exists are generated // only formulas for which no image exists are generated
QFileInfo fi(resultName); QFileInfo fi(resultName);
if (!fi.exists()) if (!fi.exists())
...@@ -119,7 +119,7 @@ void FormulaList::generateBitmaps(const char *path) ...@@ -119,7 +119,7 @@ void FormulaList::generateBitmaps(const char *path)
for (;(pagePtr=pli.current());++pli,++pageIndex) for (;(pagePtr=pli.current());++pli,++pageIndex)
{ {
int pageNum=*pagePtr; int pageNum=*pagePtr;
msg("Generating image form_%d.png for formula\n",pageNum); msg("Generating image form_%d.gif for formula\n",pageNum);
char dviArgs[4096]; char dviArgs[4096];
QCString formBase; QCString formBase;
formBase.sprintf("_form%d",pageNum); formBase.sprintf("_form%d",pageNum);
...@@ -268,7 +268,7 @@ void FormulaList::generateBitmaps(const char *path) ...@@ -268,7 +268,7 @@ void FormulaList::generateBitmaps(const char *path)
} }
// save the result as a png // save the result as a png
QCString resultName; QCString resultName;
resultName.sprintf("form_%d.png",pageNum); resultName.sprintf("form_%d.gif",pageNum);
// the option parameter 1 is used here as a temporary hack // the option parameter 1 is used here as a temporary hack
// to select the right color palette! // to select the right color palette!
dstImage.save(resultName,1); dstImage.save(resultName,1);
......
...@@ -1230,8 +1230,10 @@ void GroupDef::addListReferences() ...@@ -1230,8 +1230,10 @@ void GroupDef::addListReferences()
{ {
LockingPtr< QList<ListItemInfo> > xrefItems = xrefListItems(); LockingPtr< QList<ListItemInfo> > xrefItems = xrefListItems();
addRefItem(xrefItems.pointer(), addRefItem(xrefItems.pointer(),
getOutputFileBase(),
theTranslator->trGroup(TRUE,TRUE), theTranslator->trGroup(TRUE,TRUE),
getOutputFileBase(),name() getOutputFileBase(),name(),
0
); );
} }
MemberGroupSDict::Iterator mgli(*memberGroupSDict); MemberGroupSDict::Iterator mgli(*memberGroupSDict);
......
...@@ -1758,7 +1758,7 @@ void HtmlGenerator::startMemberGroupDocs() ...@@ -1758,7 +1758,7 @@ void HtmlGenerator::startMemberGroupDocs()
void HtmlGenerator::endMemberGroupDocs() void HtmlGenerator::endMemberGroupDocs()
{ {
t << "<br/><br/></div></td></tr>" << endl; t << "</div></td></tr>" << endl;
} }
void HtmlGenerator::startMemberGroup() void HtmlGenerator::startMemberGroup()
......
...@@ -1580,38 +1580,18 @@ void LatexGenerator::docify(const char *str) ...@@ -1580,38 +1580,18 @@ void LatexGenerator::docify(const char *str)
void LatexGenerator::codify(const char *str) void LatexGenerator::codify(const char *str)
{ {
static bool isJapanese = theTranslator->idLanguage()=="japanese" ||
theTranslator->idLanguage()=="japanese-en";
if (str) if (str)
{ {
const char *p=str; const char *p=str;
char c; char c;
char cs[2]; char cs[5];
cs[1]='\0';
int spacesToNextTabStop; int spacesToNextTabStop;
static int tabSize = Config_getInt("TAB_SIZE"); static int tabSize = Config_getInt("TAB_SIZE");
while (*p) while (*p)
{ {
static bool MultiByte = FALSE; //static bool MultiByte = FALSE;
c=*p++; c=*p++;
if( isJapanese )
{
if ( MultiByte )
{
t << (char)c;
MultiByte = FALSE;
continue;
}
if ((uchar)c>=0x80) // char in range [0x80..0xff]
{
t << (char)c;
MultiByte = TRUE;
continue;
}
}
switch(c) switch(c)
{ {
case 0x0c: break; // remove ^L case 0x0c: break; // remove ^L
...@@ -1621,14 +1601,34 @@ void LatexGenerator::codify(const char *str) ...@@ -1621,14 +1601,34 @@ void LatexGenerator::codify(const char *str)
col+=spacesToNextTabStop; col+=spacesToNextTabStop;
break; break;
case '\n': t << '\n'; col=0; break; case '\n': t << '\n'; col=0; break;
default: if (m_prettyCode) default: cs[0]=c;
cs[1]=0;
int bytes=1;
if (c<0) // multibyte utf-8 character
{
bytes++; // 1xxx.xxxx: >=2 byte character
cs[1]=*p;
cs[2]=0;
if (((uchar)c&0xE0)==0xE0)
{
bytes++; // 111x.xxxx: >=3 byte character
cs[2]=*(p+1);
cs[3]=0;
}
if (((uchar)c&0xF0)==0xF0)
{
bytes++; // 1111.xxxx: 4 byte character
cs[2]=*(p+2);
cs[4]=0;
}
}
if (m_prettyCode)
{ {
cs[0]=c;
filterLatexString(t,cs,insideTabbing,TRUE); filterLatexString(t,cs,insideTabbing,TRUE);
} }
else else
{ {
t << c; t << cs;
} }
if (col>=80) if (col>=80)
{ {
...@@ -1637,8 +1637,9 @@ void LatexGenerator::codify(const char *str) ...@@ -1637,8 +1637,9 @@ void LatexGenerator::codify(const char *str)
} }
else else
{ {
col++; col++;
} }
p+=(bytes-1); // skip to next character
break; break;
} }
} }
......
...@@ -47,3 +47,6 @@ sub GenerateDep { ...@@ -47,3 +47,6 @@ sub GenerateDep {
#$ GenerateDep("config.cpp","config.l"); #$ GenerateDep("config.cpp","config.l");
$(LEX) -PconfigYY -t config.l >config.cpp $(LEX) -PconfigYY -t config.l >config.cpp
configoptions.cpp: config.xml
python configgen.py config.xml >configoptions.cpp
...@@ -1538,6 +1538,12 @@ void MemberDef::writeDeclaration(OutputList &ol, ...@@ -1538,6 +1538,12 @@ void MemberDef::writeDeclaration(OutputList &ol,
//ol.startEmphasis(); //ol.startEmphasis();
ol.popGeneratorState(); ol.popGeneratorState();
} }
// for RTF we need to add an extra empty paragraph
ol.pushGeneratorState();
ol.disableAllBut(OutputGenerator::RTF);
ol.startParagraph();
ol.endParagraph();
ol.popGeneratorState();
ol.endMemberDescription(); ol.endMemberDescription();
} }
warnIfUndocumented(); warnIfUndocumented();
...@@ -2714,14 +2720,16 @@ void MemberDef::addListReference(Definition *) ...@@ -2714,14 +2720,16 @@ void MemberDef::addListReference(Definition *)
QCString memName = name(); QCString memName = name();
Definition *pd=getOuterScope(); Definition *pd=getOuterScope();
QCString memArgs; QCString memArgs;
if (!isRelated() && if (!isRelated()
/* && commented out as a result of bug 597016
( (
(!hideScopeNames && // there is a scope (!hideScopeNames && // there is a scope
pd && pd!=Doxygen::globalScope) // and we can show it pd && pd!=Doxygen::globalScope) // and we can show it
|| ||
(pd=getClassDef()) // it's a class so we (pd=getClassDef()) // it's a class so we
// show the scope anyway // show the scope anyway
) )
*/
) )
{ {
if (isObjCMethod()) if (isObjCMethod())
...@@ -2730,19 +2738,21 @@ void MemberDef::addListReference(Definition *) ...@@ -2730,19 +2738,21 @@ void MemberDef::addListReference(Definition *)
} }
else if (optimizeOutputJava) else if (optimizeOutputJava)
{ {
memName.prepend(pd->name()+"."); if (!hideScopeNames) memName.prepend(pd->name()+".");
memArgs = argsString(); memArgs = argsString();
} }
else else
{ {
memName.prepend(pd->name()+"::"); if (!hideScopeNames) memName.prepend(pd->name()+"::");
memArgs = argsString(); memArgs = argsString();
} }
} }
LockingPtr< QList<ListItemInfo> > xrefItems = xrefListItems(); LockingPtr< QList<ListItemInfo> > xrefItems = xrefListItems();
if (xrefItems!=0) if (xrefItems!=0)
{ {
addRefItem(xrefItems.pointer(),memLabel, addRefItem(xrefItems.pointer(),
qualifiedName(),
memLabel,
getOutputFileBase()+"#"+anchor(),memName,memArgs); getOutputFileBase()+"#"+anchor(),memName,memArgs);
} }
} }
......
...@@ -273,8 +273,12 @@ void MemberGroup::addListReferences(Definition *def) ...@@ -273,8 +273,12 @@ void MemberGroup::addListReferences(Definition *def)
memberList->addListReferences(def); memberList->addListReferences(def);
if (m_xrefListItems && def) if (m_xrefListItems && def)
{ {
addRefItem(m_xrefListItems,theTranslator->trGroup(TRUE,TRUE), QCString name = def->getOutputFileBase()+"#"+anchor();
def->getOutputFileBase()+"#"+anchor(),grpHeader,0); addRefItem(m_xrefListItems,
name,
theTranslator->trGroup(TRUE,TRUE),
name,
grpHeader,0);
} }
} }
......
...@@ -655,8 +655,10 @@ void NamespaceDef::addListReferences() ...@@ -655,8 +655,10 @@ void NamespaceDef::addListReferences()
{ {
LockingPtr< QList<ListItemInfo> > xrefItems = xrefListItems(); LockingPtr< QList<ListItemInfo> > xrefItems = xrefListItems();
addRefItem(xrefItems.pointer(), addRefItem(xrefItems.pointer(),
qualifiedName(),
fortranOpt?theTranslator->trModule(TRUE,TRUE):theTranslator->trNamespace(TRUE,TRUE), fortranOpt?theTranslator->trModule(TRUE,TRUE):theTranslator->trNamespace(TRUE,TRUE),
getOutputFileBase(),displayName() getOutputFileBase(),displayName(),
0
); );
} }
MemberGroupSDict::Iterator mgli(*memberGroupSDict); MemberGroupSDict::Iterator mgli(*memberGroupSDict);
......
...@@ -70,10 +70,7 @@ void PageDef::writeDocumentation(OutputList &ol) ...@@ -70,10 +70,7 @@ void PageDef::writeDocumentation(OutputList &ol)
{ {
//outputList->disable(OutputGenerator::Man); //outputList->disable(OutputGenerator::Man);
QCString pageName; QCString pageName;
if (Config_getBool("CASE_SENSE_NAMES")) pageName=escapeCharsInString(name(),FALSE);
pageName=name();
else
pageName=name().lower();
startFile(ol,pageName,pageName,title(),HLI_Pages,TRUE); startFile(ol,pageName,pageName,title(),HLI_Pages,TRUE);
......
...@@ -20,7 +20,6 @@ ...@@ -20,7 +20,6 @@
#include "qtbc.h" #include "qtbc.h"
#include <stdio.h> #include <stdio.h>
//#include <qfile.h>
#include "define.h" #include "define.h"
class BufStr; class BufStr;
...@@ -29,7 +28,7 @@ DefineDict* getFileDefineDict(); ...@@ -29,7 +28,7 @@ DefineDict* getFileDefineDict();
void initPreprocessor(); void initPreprocessor();
void cleanUpPreprocessor(); void cleanUpPreprocessor();
void addSearchDir(const char *dir); void addSearchDir(const char *dir);
void preprocessFile(const char *fileName,BufStr &output); void preprocessFile(const char *fileName,BufStr &input,BufStr &output);
void preFreeScanner(); void preFreeScanner();
#endif #endif
...@@ -46,16 +46,21 @@ ...@@ -46,16 +46,21 @@
#include "debug.h" #include "debug.h"
#include "bufstr.h" #include "bufstr.h"
#include "portable.h" #include "portable.h"
#include "bufstr.h"
#define YY_NEVER_INTERACTIVE 1 #define YY_NEVER_INTERACTIVE 1
struct FileState struct FileState
{ {
FileState(int size) : fileBuf(size), oldFileBuf(0), oldFileBufPos(0) {}
int lineNr; int lineNr;
FILE *filePtr; //FILE *filePtr;
FILE *oldYYin; BufStr fileBuf;
bool isPlainFile; //FILE *oldYYin;
BufStr *oldFileBuf;
int oldFileBufPos;
//bool isPlainFile;
YY_BUFFER_STATE bufState; YY_BUFFER_STATE bufState;
QCString fileName; QCString fileName;
}; };
...@@ -83,6 +88,8 @@ static int g_level; ...@@ -83,6 +88,8 @@ static int g_level;
static int g_lastCContext; static int g_lastCContext;
static int g_lastCPPContext; static int g_lastCPPContext;
static QArray<int> g_levelGuard; static QArray<int> g_levelGuard;
static BufStr *g_inputBuf;
static int g_inputBufPos;
static BufStr *g_outputBuf; static BufStr *g_outputBuf;
static int g_roundCount; static int g_roundCount;
static bool g_quoteArg; static bool g_quoteArg;
...@@ -192,11 +199,11 @@ static FileState *checkAndOpenFile(const QCString &fileName,bool &alreadyInclude ...@@ -192,11 +199,11 @@ static FileState *checkAndOpenFile(const QCString &fileName,bool &alreadyInclude
// global guard // global guard
if (g_curlyCount==0) // not #include inside { ... } if (g_curlyCount==0) // not #include inside { ... }
{ {
if (g_allIncludes.find(absName)==0) if (g_allIncludes.find(absName)!=0)
{ {
alreadyIncluded = TRUE; alreadyIncluded = TRUE;
//printf(" already included 1\n"); //printf(" already included 1\n");
return 0; // already done return 0; // already done
} }
g_allIncludes.insert(absName,(void *)0x8); g_allIncludes.insert(absName,(void *)0x8);
} }
...@@ -215,16 +222,28 @@ static FileState *checkAndOpenFile(const QCString &fileName,bool &alreadyInclude ...@@ -215,16 +222,28 @@ static FileState *checkAndOpenFile(const QCString &fileName,bool &alreadyInclude
} }
g_includeStack.setAutoDelete(TRUE); g_includeStack.setAutoDelete(TRUE);
if (alreadyIncluded) if (alreadyIncluded)
{ {
//printf(" already included 2\n"); //printf(" already included 2\n");
return 0; return 0;
} }
//printf("#include %s\n",absName.data()); //printf("#include %s\n",absName.data());
fs = new FileState; fs = new FileState(fi.size()+4096);
alreadyIncluded = FALSE; alreadyIncluded = FALSE;
if (!readInputFile(absName,fs->fileBuf))
{ // error
//printf(" error reading\n");
delete fs;
fs=0;
}
else
{
fs->oldFileBuf = g_inputBuf;
fs->oldFileBufPos = g_inputBufPos;
}
#if 0
QCString filterName = getFileFilter(absName); QCString filterName = getFileFilter(absName);
if (!filterName.isEmpty()) if (!filterName.isEmpty())
{ {
...@@ -256,6 +275,8 @@ static FileState *checkAndOpenFile(const QCString &fileName,bool &alreadyInclude ...@@ -256,6 +275,8 @@ static FileState *checkAndOpenFile(const QCString &fileName,bool &alreadyInclude
{ {
fs->oldYYin = preYYin; fs->oldYYin = preYYin;
} }
#endif
} }
return fs; return fs;
} }
...@@ -1155,9 +1176,9 @@ static void readIncludeFile(const QCString &inc) ...@@ -1155,9 +1176,9 @@ static void readIncludeFile(const QCString &inc)
uint i=0; uint i=0;
// find the start of the include file name // find the start of the include file name
while (i<inc.length() && while (i<inc.length() &&
(inc.at(i)==' ' || inc.at(i)=='"' || inc.at(i)=='<') (inc.at(i)==' ' || inc.at(i)=='"' || inc.at(i)=='<')
) i++; ) i++;
uint s=i; uint s=i;
// was it a local include? // was it a local include?
...@@ -1190,13 +1211,13 @@ static void readIncludeFile(const QCString &inc) ...@@ -1190,13 +1211,13 @@ static void readIncludeFile(const QCString &inc)
} }
if (oldFileDef) if (oldFileDef)
{ {
// add include dependency to the file in which the #include was found // add include dependency to the file in which the #include was found
oldFileDef->addIncludeDependency(g_yyFileDef,incFileName,localInclude,g_isImported); oldFileDef->addIncludeDependency(g_yyFileDef,incFileName,localInclude,g_isImported);
// add included by dependency // add included by dependency
if (g_yyFileDef) if (g_yyFileDef)
{ {
//printf("Adding include dependency %s->%s\n",oldFileDef->name().data(),incFileName.data()); //printf("Adding include dependency %s->%s\n",oldFileDef->name().data(),incFileName.data());
g_yyFileDef->addIncludedByDependency(oldFileDef,oldFileDef->docName(),localInclude,g_isImported); g_yyFileDef->addIncludedByDependency(oldFileDef,oldFileDef->docName(),localInclude,g_isImported);
} }
} }
fs->bufState=YY_CURRENT_BUFFER; fs->bufState=YY_CURRENT_BUFFER;
...@@ -1213,8 +1234,11 @@ static void readIncludeFile(const QCString &inc) ...@@ -1213,8 +1234,11 @@ static void readIncludeFile(const QCString &inc)
outputArray(lineStr.data(),lineStr.length()); outputArray(lineStr.data(),lineStr.length());
//fprintf(stderr,"Switching to include file %s\n",incFileName.data()); //fprintf(stderr,"Switching to include file %s\n",incFileName.data());
preYYin=fs->filePtr; //preYYin=fs->filePtr;
yy_switch_to_buffer(yy_create_buffer(preYYin, YY_BUF_SIZE)); //yy_switch_to_buffer(yy_create_buffer(preYYin, YY_BUF_SIZE));
g_inputBuf=&fs->fileBuf;
g_inputBufPos=0;
yy_switch_to_buffer(yy_create_buffer(0, YY_BUF_SIZE));
} }
else else
{ {
...@@ -1309,6 +1333,7 @@ static char resolveTrigraph(char c) ...@@ -1309,6 +1333,7 @@ static char resolveTrigraph(char c)
static int yyread(char *buf,int max_size) static int yyread(char *buf,int max_size)
{ {
#if 0
int len = fread( buf, 1, max_size, preYYin ); int len = fread( buf, 1, max_size, preYYin );
if (len==0 && ferror( yyin )) if (len==0 && ferror( yyin ))
{ {
...@@ -1316,6 +1341,13 @@ static int yyread(char *buf,int max_size) ...@@ -1316,6 +1341,13 @@ static int yyread(char *buf,int max_size)
return len; return len;
} }
return filterCRLF(buf,len); return filterCRLF(buf,len);
#endif
int bytesInBuf = g_inputBuf->curPos()-g_inputBufPos;
int bytesToCopy = QMIN(max_size,bytesInBuf);
memcpy(buf,g_inputBuf->data()+g_inputBufPos,bytesToCopy);
g_inputBufPos+=bytesToCopy;
return bytesToCopy;
} }
/* ----------------------------------------------------------------- */ /* ----------------------------------------------------------------- */
...@@ -1590,7 +1622,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -1590,7 +1622,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
g_incName=c; g_incName=c;
BEGIN(Include); BEGIN(Include);
} }
<Command>"define"{B}+ { <Command>("cmake")?"define"{B}+ {
//printf("!!!DefName\n"); //printf("!!!DefName\n");
BEGIN(DefName); BEGIN(DefName);
} }
...@@ -2231,6 +2263,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -2231,6 +2263,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
{ {
FileState *fs=g_includeStack.pop(); FileState *fs=g_includeStack.pop();
//fileDefineCache->merge(g_yyFileName,fs->fileName); //fileDefineCache->merge(g_yyFileName,fs->fileName);
#if 0
if (fs->isPlainFile) if (fs->isPlainFile)
{ {
if (fs->filePtr && fclose(fs->filePtr)!=0) if (fs->filePtr && fclose(fs->filePtr)!=0)
...@@ -2247,11 +2280,14 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -2247,11 +2280,14 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
} }
fs->filePtr=0; fs->filePtr=0;
} }
#endif
YY_BUFFER_STATE oldBuf = YY_CURRENT_BUFFER; YY_BUFFER_STATE oldBuf = YY_CURRENT_BUFFER;
yy_switch_to_buffer( fs->bufState ); yy_switch_to_buffer( fs->bufState );
yy_delete_buffer( oldBuf ); yy_delete_buffer( oldBuf );
g_yyLineNr=fs->lineNr; g_yyLineNr=fs->lineNr;
preYYin = fs->oldYYin; //preYYin = fs->oldYYin;
g_inputBuf = fs->oldFileBuf;
g_inputBufPos = fs->oldFileBufPos;
setFileName(fs->fileName.copy()); setFileName(fs->fileName.copy());
//fprintf(stderr,"######## FileName %s\n",g_yyFileName.data()); //fprintf(stderr,"######## FileName %s\n",g_yyFileName.data());
...@@ -2264,6 +2300,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -2264,6 +2300,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
delete fs; fs=0; delete fs; fs=0;
} }
} }
<*>"/*"/"*/" |
<*>"/*"[*]? { <*>"/*"[*]? {
outputArray(yytext,yyleng); outputArray(yytext,yyleng);
g_lastCContext=YY_START; g_lastCContext=YY_START;
...@@ -2385,14 +2422,18 @@ void cleanUpPreprocessor() ...@@ -2385,14 +2422,18 @@ void cleanUpPreprocessor()
} }
void preprocessFile(const char *fileName,BufStr &output) void preprocessFile(const char *fileName,BufStr &input,BufStr &output)
{ {
uint orgOffset=output.curPos(); uint orgOffset=output.curPos();
//printf("##########################\n%s\n####################\n",
// input.data());
g_macroExpansion = Config_getBool("MACRO_EXPANSION"); g_macroExpansion = Config_getBool("MACRO_EXPANSION");
g_expandOnlyPredef = Config_getBool("EXPAND_ONLY_PREDEF"); g_expandOnlyPredef = Config_getBool("EXPAND_ONLY_PREDEF");
g_curlyCount=0; g_curlyCount=0;
g_nospaces=FALSE; g_nospaces=FALSE;
g_inputBuf=&input;
g_inputBufPos=0;
g_outputBuf=&output; g_outputBuf=&output;
g_includeStack.setAutoDelete(TRUE); g_includeStack.setAutoDelete(TRUE);
g_includeStack.clear(); g_includeStack.clear();
...@@ -2511,6 +2552,7 @@ void preprocessFile(const char *fileName,BufStr &output) ...@@ -2511,6 +2552,7 @@ void preprocessFile(const char *fileName,BufStr &output)
firstTime=FALSE; firstTime=FALSE;
} }
#if 0
QCString inputFilter = getFileFilter(fileName); QCString inputFilter = getFileFilter(fileName);
if (inputFilter.isEmpty()) if (inputFilter.isEmpty())
{ {
...@@ -2532,6 +2574,7 @@ void preprocessFile(const char *fileName,BufStr &output) ...@@ -2532,6 +2574,7 @@ void preprocessFile(const char *fileName,BufStr &output)
return; return;
} }
} }
#endif
g_yyLineNr = 1; g_yyLineNr = 1;
g_level = 0; g_level = 0;
g_ifcount = 0; g_ifcount = 0;
...@@ -2544,10 +2587,13 @@ void preprocessFile(const char *fileName,BufStr &output) ...@@ -2544,10 +2587,13 @@ void preprocessFile(const char *fileName,BufStr &output)
preYYlex(); preYYlex();
g_lexInit=TRUE; g_lexInit=TRUE;
#if 0
if (inputFilter.isEmpty()) if (inputFilter.isEmpty())
fclose(preYYin); fclose(preYYin);
else else
portable_pclose(preYYin); portable_pclose(preYYin);
#endif
if (Debug::isFlagSet(Debug::Preprocessor)) if (Debug::isFlagSet(Debug::Preprocessor))
{ {
......
...@@ -1124,7 +1124,7 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?) ...@@ -1124,7 +1124,7 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?)
<FindMembers>{BN}{1,80} { <FindMembers>{BN}{1,80} {
lineCount(); lineCount();
} }
<FindMembers>"@"{ID}{BN}*"(" { <FindMembers>"@"({ID}".")*{ID}{BN}*"(" {
if (insideJava) // Java annotation if (insideJava) // Java annotation
{ {
lineCount(); lineCount();
...@@ -2010,7 +2010,8 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?) ...@@ -2010,7 +2010,8 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?)
lastCPPContext = YY_START; lastCPPContext = YY_START;
BEGIN( SkipCPP ) ; BEGIN( SkipCPP ) ;
} }
<FindMembers,FindFields>{B}*"#"{B}*"define" { if (insidePHP) <FindMembers,FindFields>{B}*"#"{B}*("cmake")?"define" {
if (insidePHP)
REJECT; REJECT;
current->bodyLine = yyLineNr; current->bodyLine = yyLineNr;
BEGIN( Define ); BEGIN( Define );
...@@ -2674,6 +2675,10 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?) ...@@ -2674,6 +2675,10 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?)
current->type=current->type.simplifyWhiteSpace(); current->type=current->type.simplifyWhiteSpace();
current->args=removeRedundantWhiteSpace(current->args); current->args=removeRedundantWhiteSpace(current->args);
current->name=current->name.stripWhiteSpace(); current->name=current->name.stripWhiteSpace();
if (current->section==Entry::CLASS_SEC) // remove spec for "struct Bla bla;"
{
current->spec = 0;
}
current->section = Entry::VARIABLE_SEC ; current->section = Entry::VARIABLE_SEC ;
current->fileName = yyFileName; current->fileName = yyFileName;
current->startLine = yyLineNr; current->startLine = yyLineNr;
......
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
// Updates: // Updates:
// -------- // --------
// 2009/08/24 - // 2009/09/02 - Updates for "new since 1.6.0 (mainly for the new search engine)".
// 2008/06/09 - Corrections in trLegendDocs(). // 2008/06/09 - Corrections in trLegendDocs().
// 2007/11/13 - Update for "new since 1.5.4 (mainly for Fortran)". // 2007/11/13 - Update for "new since 1.5.4 (mainly for Fortran)".
// 2007/03/20 - removing decode(), conversion of literals to UTF-8. // 2007/03/20 - removing decode(), conversion of literals to UTF-8.
...@@ -1821,7 +1821,7 @@ class TranslatorCzech : public Translator ...@@ -1821,7 +1821,7 @@ class TranslatorCzech : public Translator
/*! directory relation for \a name */ /*! directory relation for \a name */
virtual QCString trDirRelation(const char *name) virtual QCString trDirRelation(const char *name)
{ {
return "Relace "+QCString(name); return "Relace " + QCString(name);
} }
/*! Loading message shown when loading search results */ /*! Loading message shown when loading search results */
...@@ -1847,7 +1847,6 @@ class TranslatorCzech : public Translator ...@@ -1847,7 +1847,6 @@ class TranslatorCzech : public Translator
{ {
return "Nic se nenašlo"; return "Nic se nenašlo";
} }
}; };
#endif // TRANSLATOR_CZ_H #endif // TRANSLATOR_CZ_H
...@@ -158,7 +158,7 @@ class TranslatorFrench : public TranslatorAdapter_1_5_4 ...@@ -158,7 +158,7 @@ class TranslatorFrench : public TranslatorAdapter_1_5_4
/*! header that is put before the list of typedefs. */ /*! header that is put before the list of typedefs. */
virtual QCString trMemberTypedefDocumentation() virtual QCString trMemberTypedefDocumentation()
{ {
return "Documentation des définitions de type membres"; } return "Documentation des définitions de type membre"; }
/*! header that is put before the list of enumerations. */ /*! header that is put before the list of enumerations. */
virtual QCString trMemberEnumerationDocumentation() virtual QCString trMemberEnumerationDocumentation()
...@@ -386,7 +386,7 @@ class TranslatorFrench : public TranslatorAdapter_1_5_4 ...@@ -386,7 +386,7 @@ class TranslatorFrench : public TranslatorAdapter_1_5_4
if (Config_getBool("OPTIMIZE_OUTPUT_FOR_C")) if (Config_getBool("OPTIMIZE_OUTPUT_FOR_C"))
{ {
result+="des fonctions, variables, macros, enumérations, et définitions de type "; result+="des fonctions, variables, macros, énumérations, et définitions de type ";
} }
else else
{ {
...@@ -573,7 +573,7 @@ class TranslatorFrench : public TranslatorAdapter_1_5_4 ...@@ -573,7 +573,7 @@ class TranslatorFrench : public TranslatorAdapter_1_5_4
*/ */
virtual QCString trTypedefDocumentation() virtual QCString trTypedefDocumentation()
{ {
return "Documentation des définition de type"; } return "Documentation des définitions de type"; }
/*! This is used in the documentation of a file/namespace before the list /*! This is used in the documentation of a file/namespace before the list
* of documentation blocks for enumeration types * of documentation blocks for enumeration types
...@@ -812,7 +812,7 @@ class TranslatorFrench : public TranslatorAdapter_1_5_4 ...@@ -812,7 +812,7 @@ class TranslatorFrench : public TranslatorAdapter_1_5_4
if (i<numEntries-2) // not the fore last entry if (i<numEntries-2) // not the fore last entry
result+=", "; result+=", ";
else // the fore last entry else // the fore last entry
result+=", et "; result+=" et ";
} }
} }
return result; return result;
...@@ -998,7 +998,7 @@ class TranslatorFrench : public TranslatorAdapter_1_5_4 ...@@ -998,7 +998,7 @@ class TranslatorFrench : public TranslatorAdapter_1_5_4
/*! header that is put before the list of constructor/destructors. */ /*! header that is put before the list of constructor/destructors. */
virtual QCString trConstructorDocumentation() virtual QCString trConstructorDocumentation()
{ {
return "Documentation des constructeurs et destructeur"; return "Documentation des constructeurs et destructeurs";
} }
/*! Used in the file documentation to point to the corresponding sources. */ /*! Used in the file documentation to point to the corresponding sources. */
virtual QCString trGotoSourceCode() virtual QCString trGotoSourceCode()
...@@ -1192,7 +1192,7 @@ class TranslatorFrench : public TranslatorAdapter_1_5_4 ...@@ -1192,7 +1192,7 @@ class TranslatorFrench : public TranslatorAdapter_1_5_4
"};\n" "};\n"
"\\endcode\n" "\\endcode\n"
"Si la valeur 240 est attribuée au tag \\c MAX_DOT_GRAPH_HEIGHT " "Si la valeur 240 est attribuée au tag \\c MAX_DOT_GRAPH_HEIGHT "
"du fichier de configuration, cela génèrera le graphe suivant :" "du fichier de configuration, cela générera le graphe suivant :"
"<p><center><img alt=\"\" src=\"graph_legend."+Config_getEnum("DOT_IMAGE_FORMAT")+"\"></center>\n" "<p><center><img alt=\"\" src=\"graph_legend."+Config_getEnum("DOT_IMAGE_FORMAT")+"\"></center>\n"
"<p>\n" "<p>\n"
"Les rectangles du graphe ci-dessus ont la signification suivante :\n" "Les rectangles du graphe ci-dessus ont la signification suivante :\n"
...@@ -1736,6 +1736,41 @@ class TranslatorFrench : public TranslatorAdapter_1_5_4 ...@@ -1736,6 +1736,41 @@ class TranslatorFrench : public TranslatorAdapter_1_5_4
*/ */
virtual QCString trEnumerationValueDocumentation() virtual QCString trEnumerationValueDocumentation()
{ return "Documentation des énumérations"; } { return "Documentation des énumérations"; }
//////////////////////////////////////////////////////////////////////////
// new since 1.6.0 (mainly for the new search engine)
//////////////////////////////////////////////////////////////////////////
/*! directory relation for \a name */
virtual QCString trDirRelation(const char *name)
{
return QCString(name)+" Relation";
}
/*! Loading message shown when loading search results */
virtual QCString trLoading()
{
return "Chargement...";
}
/*! Label used for search results in the global namespace */
virtual QCString trGlobalNamespace()
{
return "Espace de nommage global";
}
/*! Message shown while searching */
virtual QCString trSearching()
{
return "Recherche...";
}
/*! Text shown when no search results are found */
virtual QCString trNoMatches()
{
return "Aucune correspondance";
}
}; };
#endif #endif
......
This diff is collapsed.
...@@ -49,6 +49,7 @@ ...@@ -49,6 +49,7 @@
#include "textdocvisitor.h" #include "textdocvisitor.h"
#include "portable.h" #include "portable.h"
#include "parserintf.h" #include "parserintf.h"
#include "bufstr.h"
#define ENABLE_TRACINGSUPPORT 0 #define ENABLE_TRACINGSUPPORT 0
...@@ -5515,31 +5516,48 @@ QCString substituteTemplateArgumentsInString( ...@@ -5515,31 +5516,48 @@ QCString substituteTemplateArgumentsInString(
{ {
//printf("n=%s formArg->type='%s' formArg->name='%s' formArg->defval='%s'\n", //printf("n=%s formArg->type='%s' formArg->name='%s' formArg->defval='%s'\n",
// n.data(),formArg->type.data(),formArg->name.data(),formArg->defval.data()); // n.data(),formArg->type.data(),formArg->name.data(),formArg->defval.data());
//printf(">> formArg->name='%s' actArg->type='%s' actArg->name='%s'\n",
// formArg->name.data(),actArg->type.data(),actArg->name.data()
// );
if (formArg->name==n && actArg && !actArg->type.isEmpty()) // base class is a template argument if (formArg->name==n && actArg && !actArg->type.isEmpty()) // base class is a template argument
{ {
// replace formal argument with the actual argument of the instance // replace formal argument with the actual argument of the instance
if (actArg->name.isEmpty()) if (!leftScopeMatch(actArg->type,n))
// the scope guard is to prevent recursive lockup for
// template<class A> class C : public<A::T>,
// where A::T would become A::T::T here,
// since n==A and actArg->type==A::T
// see bug595833 for an example
{ {
result += actArg->type+" "; if (actArg->name.isEmpty())
} {
else // for case where the actual arg is something like "unsigned int" result += actArg->type+" ";
// the "int" part is in actArg->name. found=TRUE;
{ }
result += actArg->type+" "+actArg->name+" "; else
// for case where the actual arg is something like "unsigned int"
// the "int" part is in actArg->name.
{
result += actArg->type+" "+actArg->name+" ";
found=TRUE;
}
} }
found=TRUE;
} }
else if (formArg->name==n && actArg==0 && !formArg->defval.isEmpty() && else if (formArg->name==n &&
formArg->defval!=name /* to prevent recursion */ actArg==0 &&
!formArg->defval.isEmpty() &&
formArg->defval!=name /* to prevent recursion */
) )
{ {
result += substituteTemplateArgumentsInString(formArg->defval,formalArgs,actualArgs)+" "; result += substituteTemplateArgumentsInString(formArg->defval,formalArgs,actualArgs)+" ";
found=TRUE; found=TRUE;
} }
} }
else if (formArg->name==n && actArg==0 && !formArg->defval.isEmpty() && else if (formArg->name==n &&
formArg->defval!=name /* to prevent recursion */ actArg==0 &&
) !formArg->defval.isEmpty() &&
formArg->defval!=name /* to prevent recursion */
)
{ {
result += substituteTemplateArgumentsInString(formArg->defval,formalArgs,actualArgs)+" "; result += substituteTemplateArgumentsInString(formArg->defval,formalArgs,actualArgs)+" ";
found=TRUE; found=TRUE;
...@@ -5777,12 +5795,7 @@ PageDef *addRelatedPage(const char *name,const QCString &ptitle, ...@@ -5777,12 +5795,7 @@ PageDef *addRelatedPage(const char *name,const QCString &ptitle,
pd->setReference(tagInfo->tagName); pd->setReference(tagInfo->tagName);
} }
QCString pageName; pd->setFileName(convertNameToFile(pd->name(),FALSE));
if (Config_getBool("CASE_SENSE_NAMES"))
pageName=pd->name();
else
pageName=pd->name().lower();
pd->setFileName(pageName);
//printf("Appending page `%s'\n",baseName.data()); //printf("Appending page `%s'\n",baseName.data());
Doxygen::pageSDict->append(baseName,pd); Doxygen::pageSDict->append(baseName,pd);
...@@ -5799,13 +5812,9 @@ PageDef *addRelatedPage(const char *name,const QCString &ptitle, ...@@ -5799,13 +5812,9 @@ PageDef *addRelatedPage(const char *name,const QCString &ptitle,
{ {
file=gd->getOutputFileBase(); file=gd->getOutputFileBase();
} }
else if (pd->getGroupDef()) else
{ {
file=pd->getGroupDef()->getOutputFileBase().copy(); file=pd->getOutputFileBase();
}
else
{
file=pageName;
} }
SectionInfo *si=new SectionInfo( SectionInfo *si=new SectionInfo(
file,pd->name(),pd->title(),SectionInfo::Page,pd->getReference()); file,pd->name(),pd->title(),SectionInfo::Page,pd->getReference());
...@@ -5814,7 +5823,7 @@ PageDef *addRelatedPage(const char *name,const QCString &ptitle, ...@@ -5814,7 +5823,7 @@ PageDef *addRelatedPage(const char *name,const QCString &ptitle,
// si->fileName.data()); // si->fileName.data());
//printf(" SectionInfo: sec=%p sec->fileName=%s\n",si,si->fileName.data()); //printf(" SectionInfo: sec=%p sec->fileName=%s\n",si,si->fileName.data());
//printf("Adding section key=%s si->fileName=%s\n",pageName.data(),si->fileName.data()); //printf("Adding section key=%s si->fileName=%s\n",pageName.data(),si->fileName.data());
Doxygen::sectionDict.insert(pageName,si); Doxygen::sectionDict.insert(pd->name(),si);
} }
} }
return pd; return pd;
...@@ -5823,6 +5832,7 @@ PageDef *addRelatedPage(const char *name,const QCString &ptitle, ...@@ -5823,6 +5832,7 @@ PageDef *addRelatedPage(const char *name,const QCString &ptitle,
//---------------------------------------------------------------------------- //----------------------------------------------------------------------------
void addRefItem(const QList<ListItemInfo> *sli, void addRefItem(const QList<ListItemInfo> *sli,
const char *key,
const char *prefix, const char *name,const char *title,const char *args) const char *prefix, const char *name,const char *title,const char *args)
{ {
//printf("addRefItem(sli=%p,prefix=%s,name=%s,title=%s,args=%s)\n",sli,prefix,name,title,args); //printf("addRefItem(sli=%p,prefix=%s,name=%s,title=%s,args=%s)\n",sli,prefix,name,title,args);
...@@ -5834,7 +5844,6 @@ void addRefItem(const QList<ListItemInfo> *sli, ...@@ -5834,7 +5844,6 @@ void addRefItem(const QList<ListItemInfo> *sli,
{ {
RefList *refList = Doxygen::xrefLists->find(lii->type); RefList *refList = Doxygen::xrefLists->find(lii->type);
if (refList if (refList
#if 0
&& &&
( (
// either not a built-in list or the list is enabled // either not a built-in list or the list is enabled
...@@ -5843,7 +5852,6 @@ void addRefItem(const QList<ListItemInfo> *sli, ...@@ -5843,7 +5852,6 @@ void addRefItem(const QList<ListItemInfo> *sli,
(lii->type!="bug" || Config_getBool("GENERATE_BUGLIST")) && (lii->type!="bug" || Config_getBool("GENERATE_BUGLIST")) &&
(lii->type!="deprecated" || Config_getBool("GENERATE_DEPRECATEDLIST")) (lii->type!="deprecated" || Config_getBool("GENERATE_DEPRECATEDLIST"))
) )
#endif
) )
{ {
RefItem *item = refList->getRefItem(lii->itemId); RefItem *item = refList->getRefItem(lii->itemId);
...@@ -5854,7 +5862,7 @@ void addRefItem(const QList<ListItemInfo> *sli, ...@@ -5854,7 +5862,7 @@ void addRefItem(const QList<ListItemInfo> *sli,
item->title = title; item->title = title;
item->args = args; item->args = args;
refList->insertIntoList(title,item); refList->insertIntoList(key,item);
#if 0 #if 0
...@@ -6843,3 +6851,121 @@ void stackTrace() ...@@ -6843,3 +6851,121 @@ void stackTrace()
#endif #endif
} }
static int transcodeCharacterBuffer(BufStr &srcBuf,int size,
const char *inputEncoding,const char *outputEncoding)
{
if (inputEncoding==0 || outputEncoding==0) return size;
if (qstricmp(inputEncoding,outputEncoding)==0) return size;
void *cd = portable_iconv_open(outputEncoding,inputEncoding);
if (cd==(void *)(-1))
{
err("Error: unsupported character conversion: '%s'->'%s': %s\n"
"Check the INPUT_ENCODING setting in the config file!\n",
inputEncoding,outputEncoding,strerror(errno));
exit(1);
}
int tmpBufSize=size*4+1;
BufStr tmpBuf(tmpBufSize);
size_t iLeft=size;
size_t oLeft=tmpBufSize;
const char *srcPtr = srcBuf.data();
char *dstPtr = tmpBuf.data();
uint newSize=0;
if (!portable_iconv(cd, &srcPtr, &iLeft, &dstPtr, &oLeft))
{
newSize = tmpBufSize-oLeft;
srcBuf.shrink(newSize);
strncpy(srcBuf.data(),tmpBuf.data(),newSize);
//printf("iconv: input size=%d output size=%d\n[%s]\n",size,newSize,srcBuf.data());
}
else
{
err("Error: failed to translate characters from %s to %s: check INPUT_ENCODING\n",
inputEncoding,outputEncoding);
exit(1);
}
portable_iconv_close(cd);
return newSize;
}
//! read a file name \a fileName and optionally filter and transcode it
bool readInputFile(const char *fileName,BufStr &inBuf)
{
// try to open file
int size=0;
//uint oldPos = dest.curPos();
//printf(".......oldPos=%d\n",oldPos);
QFileInfo fi(fileName);
if (!fi.exists()) return FALSE;
QCString filterName = getFileFilter(fileName);
if (filterName.isEmpty())
{
QFile f(fileName);
if (!f.open(IO_ReadOnly))
{
err("Error: could not open file %s\n",fileName);
return FALSE;
}
size=fi.size();
// read the file
inBuf.skip(size);
if (f.readBlock(inBuf.data()/*+oldPos*/,size)!=size)
{
err("Error while reading file %s\n",fileName);
return FALSE;
}
}
else
{
QCString cmd=filterName+" \""+fileName+"\"";
Debug::print(Debug::ExtCmd,0,"Executing popen(`%s`)\n",cmd.data());
FILE *f=portable_popen(cmd,"r");
if (!f)
{
err("Error: could not execute filter %s\n",filterName.data());
return FALSE;
}
const int bufSize=1024;
char buf[bufSize];
int numRead;
while ((numRead=fread(buf,1,bufSize,f))>0)
{
//printf(">>>>>>>>Reading %d bytes\n",numRead);
inBuf.addArray(buf,numRead),size+=numRead;
}
portable_pclose(f);
}
if (inBuf.size()>=2 &&
((inBuf.at(0)==-1 && inBuf.at(1)==-2) || // Litte endian BOM
(inBuf.at(0)==-2 && inBuf.at(1)==-1) // big endian BOM
)
) // UCS-2 encoded file
{
transcodeCharacterBuffer(inBuf,inBuf.curPos(),
"UCS-2","UTF-8");
}
else // transcode according to the INPUT_ENCODING setting
{
// do character transcoding if needed.
transcodeCharacterBuffer(inBuf,inBuf.curPos(),
Config_getString("INPUT_ENCODING"),"UTF-8");
}
inBuf.addChar('\n'); /* to prevent problems under Windows ? */
// and translate CR's
size=inBuf.curPos();
int newSize=filterCRLF(inBuf.data(),size);
//printf("filter char at %p size=%d newSize=%d\n",dest.data()+oldPos,size,newSize);
if (newSize!=size) // we removed chars
{
inBuf.shrink(newSize); // resize the array
//printf(".......resizing from %d to %d result=[%s]\n",oldPos+size,oldPos+newSize,dest.data());
}
inBuf.at(inBuf.curPos())='\0';
return TRUE;
}
...@@ -53,6 +53,7 @@ class PageDef; ...@@ -53,6 +53,7 @@ class PageDef;
struct SectionInfo; struct SectionInfo;
class QDir; class QDir;
class Definition; class Definition;
class BufStr;
//-------------------------------------------------------------------- //--------------------------------------------------------------------
...@@ -279,7 +280,8 @@ int getScopeFragment(const QCString &s,int p,int *l); ...@@ -279,7 +280,8 @@ int getScopeFragment(const QCString &s,int p,int *l);
int filterCRLF(char *buf,int len); int filterCRLF(char *buf,int len);
void addRefItem(const QList<ListItemInfo> *sli,const char *prefix, void addRefItem(const QList<ListItemInfo> *sli,const char *prefix,
const char *name,const char *title,const char *args=0); const char *key,
const char *name,const char *title,const char *args);
PageDef *addRelatedPage(const char *name,const QCString &ptitle, PageDef *addRelatedPage(const char *name,const QCString &ptitle,
const QCString &doc,QList<SectionInfo> *anchors, const QCString &doc,QList<SectionInfo> *anchors,
...@@ -363,5 +365,8 @@ QCString convertCharEntitiesToUTF8(const QCString &s); ...@@ -363,5 +365,8 @@ QCString convertCharEntitiesToUTF8(const QCString &s);
bool usingTreeIndex(); bool usingTreeIndex();
void stackTrace(); void stackTrace();
bool readInputFile(const char *fileName,BufStr &inBuf);
#endif #endif
...@@ -204,52 +204,32 @@ ClassDef *VhdlDocGen::getClass(const char *name) ...@@ -204,52 +204,32 @@ ClassDef *VhdlDocGen::getClass(const char *name)
} }
/*! /*!
* adds components to their entities * adds architectures to their entity
*/ */
void VhdlDocGen::computeVhdlComponentRelations(const QDict<EntryNav>& classEntries,FileStorage* g_storage) void VhdlDocGen::computeVhdlComponentRelations()
{ {
ClassSDict::Iterator cli(*Doxygen::classSDict); ClassSDict::Iterator cli(*Doxygen::classSDict);
for (cli.toFirst();cli.current();++cli) cli.current()->visited=FALSE; for (cli.toFirst();cli.current();++cli)
QDictIterator<EntryNav> edi(classEntries); {
EntryNav *rootNav; cli.current()->visited=FALSE;
for (;(rootNav=edi.current());++edi) ClassDef * cd = cli.current();
{ if ((VhdlDocGen::VhdlClasses)cd->protection()==VhdlDocGen::ARCHITECTURECLASS)
ClassDef *cd;
rootNav->loadEntry(g_storage);
Entry *root = rootNav->entry();
QCString bName=stripAnonymousNamespaceScope(rootNav->name());
if ((cd=getClass(bName)))
{ {
QListIterator<BaseInfo> bii(*root->extends); QCString bName=cd->name();
BaseInfo *bi=0; int i=bName.find("::");
for (bii.toFirst();(bi=bii.current());++bii) if (i>0)
{ {
ClassDef* baseDef=getClass(bi->name); QCString entityName=bName.left(i);
ClassDef *classEntity=Doxygen::classSDict->find(entityName);
if (baseDef && baseDef != cd) // entity for architecutre ?
{ if (classEntity)
QCString cc=VhdlDocGen::getClassName(cd); {
ClassDef *ccdef=getClass(cc); classEntity->insertBaseClass(cd,bName,Public,Normal,0);
if (ccdef==0) break; cd->insertSubClass(classEntity,Public,Normal,0);
}
int ii=ccdef->protection(); }
int jj=baseDef->protection(); }
}
if (ii==VhdlDocGen::ENTITYCLASS && jj==VhdlDocGen::ENTITYCLASS && (ccdef !=baseDef))
{
ccdef->insertBaseClass(baseDef,bi->name,Public,Normal,0);
baseDef->insertSubClass(ccdef,Public,bi->virt,0);
}
}
else
{
if (Config_getBool("WARNINGS"))
warn(rootNav->fileDef()->fileName().data(),root->startLine, "found component without entity: [%s]",bi->name.data());
}
}//for
}//if
rootNav->releaseEntry();
}// for
} // computeVhdlComponentRelations } // computeVhdlComponentRelations
......
...@@ -105,7 +105,7 @@ class VhdlDocGen ...@@ -105,7 +105,7 @@ class VhdlDocGen
static void debugClassName(ClassSDict*); static void debugClassName(ClassSDict*);
//static void MergeFuncDoc(Entry* p,Entry* root); //static void MergeFuncDoc(Entry* p,Entry* root);
static void computeVhdlComponentRelations(const QDict<EntryNav>&,FileStorage*); static void computeVhdlComponentRelations();
//static void addVariableToComponents(EntryNav *rootNav,ClassDef *cd, MemberDef::MemberType mtype, const QCString &name, bool fromAnnScope,MemberDef *fromAnnMemb,Protection prot,bool related); //static void addVariableToComponents(EntryNav *rootNav,ClassDef *cd, MemberDef::MemberType mtype, const QCString &name, bool fromAnnScope,MemberDef *fromAnnMemb,Protection prot,bool related);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment