summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDimitri van Heesch <dimitri@stack.nl>2004-05-07 12:56:01 (GMT)
committerDimitri van Heesch <dimitri@stack.nl>2004-05-07 12:56:01 (GMT)
commit64ab36082a9cb658fd54c2b76fdf1a9b40ed7b74 (patch)
treec35eb3a8d51696f3a4cddc5f0e8d484466382833 /src
parent08b4b96ea20ded173b851aeb452c5d3c98e08cc4 (diff)
downloadDoxygen-64ab36082a9cb658fd54c2b76fdf1a9b40ed7b74.zip
Doxygen-64ab36082a9cb658fd54c2b76fdf1a9b40ed7b74.tar.gz
Doxygen-64ab36082a9cb658fd54c2b76fdf1a9b40ed7b74.tar.bz2
Release-1.3.7
Diffstat (limited to 'src')
-rw-r--r--src/classdef.cpp4
-rw-r--r--src/code.l2
-rw-r--r--src/defargs.l2
-rw-r--r--src/definition.cpp32
-rw-r--r--src/definition.h90
-rw-r--r--src/dot.cpp18
-rw-r--r--src/doxygen.cpp2
-rw-r--r--src/doxygen.h1
-rw-r--r--src/entry.cpp46
-rw-r--r--src/entry.h12
-rw-r--r--src/example.h18
-rw-r--r--src/groupdef.cpp1
-rw-r--r--src/main.cpp1
-rw-r--r--src/memberdef.cpp46
-rw-r--r--src/pngenc.h8
-rw-r--r--src/scanner.l11
-rw-r--r--src/translator_fr.h602
-rw-r--r--src/util.cpp58
-rw-r--r--src/util.h7
-rw-r--r--src/xmldocvisitor.cpp4
-rw-r--r--src/xmlgen.cpp2
21 files changed, 566 insertions, 401 deletions
diff --git a/src/classdef.cpp b/src/classdef.cpp
index 67fe145..a30a774 100644
--- a/src/classdef.cpp
+++ b/src/classdef.cpp
@@ -986,7 +986,11 @@ void ClassDef::writeDocumentation(OutputList &ol)
}
ol.endTextLink();
ol.popGeneratorState();
+
+ ol.pushGeneratorState();
+ ol.disable(OutputGenerator::RTF);
ol.newParagraph();
+ ol.popGeneratorState();
}
}
ol.writeSynopsis();
diff --git a/src/code.l b/src/code.l
index 366d007..1943589 100644
--- a/src/code.l
+++ b/src/code.l
@@ -1999,7 +1999,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^' \\\n]{1,4}"'"))
<SkipString>"//"|"/*" {
g_code->codify(yytext);
}
-<SkipString>\" {
+<SkipString>@?\" {
g_code->codify(yytext);
endFontClass();
BEGIN( g_lastStringContext );
diff --git a/src/defargs.l b/src/defargs.l
index db8f000..0a5d5ec 100644
--- a/src/defargs.l
+++ b/src/defargs.l
@@ -300,9 +300,9 @@ ID [a-z_A-Z][a-z_A-Z0-9]*
{
a->type = removeRedundantWhiteSpace(g_curArgTypeName);
}
- //printf("a->type=%s a->name=%s a->array=%s\n",a->type.data(),a->name.data());
a->array += removeRedundantWhiteSpace(g_curArgArray);
a->defval = g_curArgDefValue.copy();
+ //printf("a->type=%s a->name=%s a->defval=\"%s\"\n",a->type.data(),a->name.data(),a->defval.data());
a->docs = g_curArgDocs.stripWhiteSpace();
//printf("Argument `%s' `%s' adding docs=`%s'\n",a->type.data(),a->name.data(),a->docs.data());
g_argList->append(a);
diff --git a/src/definition.cpp b/src/definition.cpp
index aa20c7b..9bf6acd 100644
--- a/src/definition.cpp
+++ b/src/definition.cpp
@@ -76,7 +76,6 @@ static void removeFromMap(Definition *d)
Definition::Definition(const char *df,int dl,
const char *name,const char *b,
const char *d,bool isSymbol)
- : m_reachableDefs(17)
{
//QCString ns;
m_defFileName = df;
@@ -112,8 +111,6 @@ Definition::Definition(const char *df,int dl,
m_docFile=(QCString)"<"+name+">";
m_isSymbol = isSymbol;
if (m_isSymbol) addToMap(name,this);
- m_reachableDefs.setAutoDelete(TRUE);
- m_reachabilityComputed=FALSE;
}
Definition::~Definition()
@@ -761,32 +758,3 @@ QCString Definition::convertNameToFile(const char *name,bool allowDots) const
}
}
-void Definition::addReachableDef(Definition *def,int distance)
-{
- if (m_reachableDefs.find(def->qualifiedName()))
- {
- m_reachableDefs.insert(def->qualifiedName(),new ReachableDefinition(def,distance));
- }
-}
-
-void Definition::computeReachability()
-{
- if (m_reachabilityComputed) return;
- addReachableDef(this,0);
- Definition *parent = getOuterScope();
- int i=1;
- while (parent)
- {
- parent->computeReachability();
- QDictIterator<ReachableDefinition> dli(m_reachableDefs);
- ReachableDefinition *rd;
- for (dli.toFirst();(rd=dli.current());++dli)
- {
- addReachableDef(rd->def,i);
- }
- parent=parent->getOuterScope();
- i++;
- }
- m_reachabilityComputed=TRUE;
-}
-
diff --git a/src/definition.h b/src/definition.h
index a0a3cd9..c9c8d69 100644
--- a/src/definition.h
+++ b/src/definition.h
@@ -25,8 +25,6 @@
class FileDef;
class OutputList;
class SectionDict;
-//class MemberList;
-//class MemberDict;
class MemberSDict;
class MemberDef;
class GroupDef;
@@ -52,7 +50,7 @@ class Definition
TypeClass, TypeMember, TypeFile, TypeGroup,
TypeNamespace, TypePackage, TypePage
};
- /*! Use this for dynamic inspection of the derived class */
+ /*! Use this for dynamic inspection of the type of the derived class */
virtual DefType definitionType() = 0;
/*! Create a new definition */
@@ -60,51 +58,110 @@ class Definition
const char *defFileName,int defLine,
const char *name,const char *b=0,const char *d=0,
bool isSymbol=TRUE);
+
/*! Destroys the definition */
virtual ~Definition();
+
/*! Returns the name of the definition */
const QCString& name() const { return m_name; }
+
/*! Returns the base name of the output file that contains this
* definition.
*/
virtual QCString qualifiedName();
+
+ /*! Returns the local name without any scope qualifiers. */
QCString localName() const;
+
+ /*! Returns the base file name (without extension) of this definition.
+ * as it is referenced to/written to disk.
+ */
virtual QCString getOutputFileBase() const = 0;
+
/*! Returns the name of the source listing of this file. */
const QCString getSourceFileBase() const { ASSERT(0); return "NULL"; }
+
/*! Returns the detailed description of this definition */
const QCString& documentation() const { return m_doc; }
+
/*! Returns the brief description of this definition */
const QCString& briefDescription() const { return m_brief; }
+
/*! Sets a new \a name for the definition */
void setName(const char *name) { m_name=name; }
+
/*! Sets the documentation of this definition to \a d. */
void setDocumentation(const char *d,const char *docFile,int docLine,bool stripWhiteSpace=TRUE);
+
+ /*! Returns the line number at which the detailed documentation was found. */
int docLine() const { return m_docLine; }
+
+ /*! Returns the file in which the detailed documentation block was found.
+ * This can differ from getDefFileName().
+ */
QCString docFile() const { return m_docFile; }
+
/*! Sets the brief description of this definition to \a b.
* A dot is added to the sentence if not available.
*/
void setBriefDescription(const char *b,const char *briefFile,int briefLine);
+
+ /*! Returns the line number at which the brief description was found. */
int briefLine() const { return m_briefLine; }
+
+ /*! Returns the file in which the brief description was found.
+ * This can differ from getDefFileName().
+ */
QCString briefFile() const { return m_briefFile; }
+
+ /*! returns the file in which this definition was found */
+ QCString getDefFileName() const { return m_defFileName; }
+
+ /*! returns the line number at which the definition was found */
+ int getDefLine() const { return m_defLine; }
+
/*! Returns TRUE iff the definition is documented */
virtual bool hasDocumentation() const;
+
+ /*! Returns TRUE iff it is possible to link to this item within this
+ * project.
+ */
virtual bool isLinkableInProject() const = 0;
+
+ /*! Returns TRUE iff it is possible to link to this item. This can
+ * be a link to another project imported via a tag file.
+ */
virtual bool isLinkable() const = 0;
- virtual QCString getReference() const { return m_ref; }
- // symbols
- QCString symbolName() const { return m_symbolName; }
- void setSymbolName(const QCString &name) { m_symbolName=name; }
+ /*! If this definition was imported via a tag file, this function
+ * returns the tagfile for the external project. This can be
+ * translated into an external link target via
+ * Doxygen::tagDestinationDict
+ */
+ virtual QCString getReference() const { return m_ref; }
+ /*! Returns TRUE if this definition is imported via a tag file. */
virtual bool isReference() const { return !m_ref.isEmpty(); }
+
+ /*! Sets the tag file id via which this definition was imported. */
void setReference(const char *r) { m_ref=r; }
+ /*! Returns the name of this definition as it appears in the symbol map.
+ */
+ QCString symbolName() const { return m_symbolName; }
+
+ /*! Sets the name of this definition as it should appear in the symbol map.
+ */
+ void setSymbolName(const QCString &name) { m_symbolName=name; }
+
/*! Add the list of anchors that mark the sections that are found in the
* documentation.
*/
void addSectionsToDefinition(QList<SectionInfo> *anchorList);
+
+ /*! Writes the documentation anchors of the definition to
+ * the Doxygen::tagFile stream.
+ */
void writeDocAnchorsToTagFile();
// source references
@@ -120,28 +177,14 @@ class Definition
void addSourceReferencedBy(MemberDef *d);
void addSourceReferences(MemberDef *d);
- //{
- // if (todoId!=0) m_todoId=todoId;
- // if (testId!=0) m_testId=testId;
- // if (bugId!=0) m_bugId=bugId;
- //}
- //int todoId() const { return m_todoId; }
- //int testId() const { return m_testId; }
- //int bugId() const { return m_bugId; }
void setRefItems(const QList<ListItemInfo> *sli);
void mergeRefItems(Definition *d);
const QList<ListItemInfo> *xrefListItems() const;
- /*! returns the file in which this definition was found */
- QCString getDefFileName() const { return m_defFileName; }
- /*! returns the line number at which the definition was found */
- int getDefLine() const { return m_defLine; }
-
virtual Definition *findInnerCompound(const char *name);
virtual Definition *getOuterScope() const { return m_outerScope; }
virtual void addInnerCompound(Definition *d);
virtual void setOuterScope(Definition *d) { m_outerScope = d; }
- virtual void computeReachability();
MemberSDict *getReferencesMembers() const { return m_sourceRefsDict; }
MemberSDict *getReferencedByMembers() const { return m_sourceRefByDict; }
@@ -149,7 +192,6 @@ class Definition
void makePartOfGroup(GroupDef *gd);
GroupList *partOfGroups() const { return m_partOfGroups; }
QCString convertNameToFile(const char *name,bool allowDots=FALSE) const;
- void addReachableDef(Definition *d,int distance);
protected:
int m_startBodyLine; // line number of the start of the definition
@@ -169,10 +211,6 @@ class Definition
/*! List of groups this definition is part of */
GroupList *m_partOfGroups;
- // reachability of other definitions from this one
- QDict<ReachableDefinition> m_reachableDefs;
- bool m_reachabilityComputed;
-
private:
int getXRefListId(const char *listName) const;
void writeSourceRefList(OutputList &ol,const char *scopeName,
diff --git a/src/dot.cpp b/src/dot.cpp
index 16c5d07..1429645 100644
--- a/src/dot.cpp
+++ b/src/dot.cpp
@@ -82,12 +82,14 @@ static void writeGraphFooter(QTextStream &t)
* site image map.
* \param t the stream to which the result is written.
* \param mapName the name of the map file.
+ * \param relPath the relative path to the root of the output directory
+ * (used in case CREATE_SUBDIRS is enabled).
* \param urlOnly if FALSE the url field in the map contains an external
* references followed by a $ and then the URL.
* \returns TRUE if succesful.
*/
static bool convertMapFile(QTextStream &t,const char *mapName,
- bool urlOnly=FALSE)
+ const QCString relPath, bool urlOnly=FALSE)
{
QFile f(mapName);
if (!f.open(IO_ReadOnly))
@@ -146,7 +148,7 @@ static bool convertMapFile(QTextStream &t,const char *mapName,
{
if ((dest=Doxygen::tagDestinationDict[df->ref()])) t << *dest << "/";
}
- if (!df->file().isEmpty()) t << df->file() << Doxygen::htmlFileExtension;
+ if (!df->file().isEmpty()) t << relPath << df->file() << Doxygen::htmlFileExtension;
if (!df->anchor().isEmpty()) t << "#" << df->anchor();
}
else
@@ -175,7 +177,7 @@ static bool convertMapFile(QTextStream &t,const char *mapName,
if ((dest=Doxygen::tagDestinationDict[refPtr])) t << *dest << "/";
t << "\" ";
}
- t << "href=\"";
+ t << "href=\"" << relPath;
if (*refPtr!='\0')
{
if ((dest=Doxygen::tagDestinationDict[refPtr])) t << *dest << "/";
@@ -1004,7 +1006,7 @@ void DotGfxHierarchyTable::writeGraph(QTextStream &out,const char *path)
out << "<tr><td><img src=\"" << imgName << "\" border=\"0\" alt=\"\" usemap=\"#"
<< mapLabel << "_map\">" << endl;
out << "<map name=\"" << mapLabel << "_map\">" << endl;
- convertMapFile(out,mapName);
+ convertMapFile(out,mapName,"");
out << "</map></td></tr>" << endl;
//thisDir.remove(mapName);
}
@@ -1740,7 +1742,7 @@ QCString DotClassGraph::writeGraph(QTextStream &out,
out << "\"></center>" << endl;
QString tmpstr;
QTextOStream tmpout(&tmpstr);
- convertMapFile(tmpout,baseName+".map");
+ convertMapFile(tmpout,baseName+".map",relPath);
if (!tmpstr.isEmpty())
{
out << "<map name=\"" << mapLabel << "\">" << endl;
@@ -2004,7 +2006,7 @@ QCString DotInclDepGraph::writeGraph(QTextStream &out,
out << "</center>" << endl;
QString tmpstr;
QTextOStream tmpout(&tmpstr);
- convertMapFile(tmpout,baseName+".map");
+ convertMapFile(tmpout,baseName+".map",relPath);
if (!tmpstr.isEmpty())
{
out << "<map name=\"" << mapName << "_map\">" << endl;
@@ -2185,7 +2187,7 @@ QCString DotCallGraph::writeGraph(QTextStream &out, GraphOutputFormat format,
out << "</center>" << endl;
QString tmpstr;
QTextOStream tmpout(&tmpstr);
- convertMapFile(tmpout,baseName+".map");
+ convertMapFile(tmpout,baseName+".map",relPath);
if (!tmpstr.isEmpty())
{
out << "<map name=\"" << mapName << "_map\">" << endl;
@@ -2421,7 +2423,7 @@ QString getDotImageMapFromFile(const QString& inFile, const QString& outDir)
}
QString result;
QTextOStream tmpout(&result);
- convertMapFile(tmpout, outFile, TRUE);
+ convertMapFile(tmpout, outFile, "",TRUE);
QDir().remove(outFile);
// printf("result=%s\n",result.data());
diff --git a/src/doxygen.cpp b/src/doxygen.cpp
index 6ca2c29..ba10bb9 100644
--- a/src/doxygen.cpp
+++ b/src/doxygen.cpp
@@ -3679,7 +3679,7 @@ static void computeClassRelations()
if ((cd==0 || (!cd->hasDocumentation() && !cd->isReference())) &&
bName.right(2)!="::")
{
- if (!root->name.isEmpty() && root->name[0]!='@' && // normal name
+ if (!root->name.isEmpty() && root->name.find('@')==-1 && // normal name
(guessSection(root->fileName)==Entry::HEADER_SEC ||
Config_getBool("EXTRACT_LOCAL_CLASSES")) && // not defined in source file
(root->protection!=Private || Config_getBool("EXTRACT_PRIVATE")) && // hidden by protection
diff --git a/src/doxygen.h b/src/doxygen.h
index f16efed..b526495 100644
--- a/src/doxygen.h
+++ b/src/doxygen.h
@@ -34,7 +34,6 @@
#include "section.h"
#include "membergroup.h"
#include "reflist.h"
-//#include "packagedef.h"
class PageSList;
class PageSDict;
diff --git a/src/entry.cpp b/src/entry.cpp
index 3bcaf31..2f2f237 100644
--- a/src/entry.cpp
+++ b/src/entry.cpp
@@ -38,7 +38,6 @@ Entry::Entry()
argList->setAutoDelete(TRUE);
//printf("Entry::Entry() tArgList=0\n");
tArgLists = 0;
- //mtArgList = 0;
mGrpId = -1;
tagInfo = 0;
sli = 0;
@@ -88,9 +87,6 @@ Entry::Entry(const Entry &e)
initLines = e.initLines;
callGraph = e.callGraph;
objc = e.objc;
- //todoId = e.todoId;
- //testId = e.testId;
- //bugId = e.bugId;
tagInfo = e.tagInfo;
sublist = new QList<Entry>;
sublist->setAutoDelete(TRUE);
@@ -152,19 +148,6 @@ Entry::Entry(const Entry &e)
tArgLists = copyArgumentLists(e.tArgLists);
}
- // deep copy template argument list
- //if (e.mtArgList)
- //{
- // mtArgList = new ArgumentList;
- // mtArgList->setAutoDelete(TRUE);
- // //printf("Entry::Entry(copy) new tArgList=%p\n",tArgList);
- // QListIterator<Argument> mtali(*e.mtArgList);
- // for (;(a=mtali.current());++mtali)
- // {
- // mtArgList->append(new Argument(*a));
- // //printf("appending argument %s %s\n",a->type.data(),a->name.data());
- // }
- //}
if (e.sli)
{
sli = new QList<ListItemInfo>;
@@ -206,17 +189,6 @@ void Entry::addSubEntry(Entry *current)
//printf("Entry::addSubEntry(%s) %p\n",current->name.data(),current->tArgList);
current->parent=this;
sublist->append(current);
-
- //if (current->tArgList)
- //{
- // Argument * a=current->tArgList->first();
- // while (a)
- // {
- // printf("type=%s name=%s\n",a->type.data(),a->name.data());
- // a=current->tArgList->next();
- // }
- //}
-
}
void Entry::reset()
@@ -227,7 +199,6 @@ void Entry::reset()
bitfields.resize(0);
exception.resize(0);
program.resize(0);
- //body.resize(0);
includeFile.resize(0);
includeName.resize(0);
doc.resize(0);
@@ -243,8 +214,6 @@ void Entry::reset()
inbodyLine=-1;
inside.resize(0);
fileName.resize(0);
- //scopeSpec.resize(0);
- //memberSpec.resize(0);
initializer.resize(0);
initLines = -1;
startLine = 1;
@@ -252,9 +221,6 @@ void Entry::reset()
endBodyLine = -1;
mGrpId = -1;
callGraph = FALSE;
- //todoId = 0;
- //testId = 0;
- //bugId = 0;
section = EMPTY_SEC;
mtype = Method;
virt = Normal;
@@ -347,18 +313,6 @@ int Entry::getSize()
al=tArgLists->next();
}
}
- //if (mtArgList)
- //{
- // a=mtArgList->first();
- // while (e)
- // {
- // size+=sizeof(Argument);
- // size+=a->type.length()+1
- // +a->name.length()+1
- // +a->defval.length()+1;
- // a=mtArgList->next();
- // }
- //}
return size;
}
diff --git a/src/entry.h b/src/entry.h
index 63ead7e..d18d7e7 100644
--- a/src/entry.h
+++ b/src/entry.h
@@ -136,9 +136,9 @@ struct Grouping
{
GROUPING_LOWEST,
GROUPING_AUTO_WEAK =
- GROUPING_LOWEST, //!< membership in group was defined via \@weakgroup
- GROUPING_AUTO_ADD, //!< membership in group was defined via \@add[to]group
- GROUPING_AUTO_DEF, //!< membership in group was defined via \@defgroup
+ GROUPING_LOWEST, //!< membership in group was defined via \@weakgroup
+ GROUPING_AUTO_ADD, //!< membership in group was defined via \@add[to]group
+ GROUPING_AUTO_DEF, //!< membership in group was defined via \@defgroup
GROUPING_AUTO_HIGHEST = GROUPING_AUTO_DEF,
GROUPING_INGROUP, //!< membership in group was defined by \@ingroup
GROUPING_HIGHEST = GROUPING_INGROUP
@@ -306,9 +306,9 @@ class Entry
bool objc; //!< Objective-C construct
enum
{
- GROUPDOC_NORMAL, //<! defgroup
- GROUPDOC_ADD, //<! addgroup
- GROUPDOC_WEAK //<! weakgroup
+ GROUPDOC_NORMAL, //!< defgroup
+ GROUPDOC_ADD, //!< addgroup
+ GROUPDOC_WEAK //!< weakgroup
} groupDocType; //!< kind of group
/// return the command name used to define GROUPDOC_SEC
const char *groupDocCmd() const
diff --git a/src/example.h b/src/example.h
index 5adf26a..466816f 100644
--- a/src/example.h
+++ b/src/example.h
@@ -31,24 +31,6 @@ struct Example
QCString file;
};
-//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:
diff --git a/src/groupdef.cpp b/src/groupdef.cpp
index e9507ad..54b0bbd 100644
--- a/src/groupdef.cpp
+++ b/src/groupdef.cpp
@@ -573,6 +573,7 @@ void GroupDef::writeDocumentation(OutputList &ol)
{
ol.startMemberItem(0);
ol.docify(theTranslator->trGroup(FALSE,TRUE));
+ ol.docify(" ");
ol.insertMemberAlign();
ol.writeObjectLink(gd->getReference(),gd->getOutputFileBase(),0,gd->groupTitle());
if (!Config_getString("GENERATE_TAGFILE").isEmpty())
diff --git a/src/main.cpp b/src/main.cpp
index 0cb8b72..9817b76 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -37,3 +37,4 @@ int main(int argc,char **argv)
generateOutput();
return 0;
}
+
diff --git a/src/memberdef.cpp b/src/memberdef.cpp
index 9676557..fd4ff55 100644
--- a/src/memberdef.cpp
+++ b/src/memberdef.cpp
@@ -188,7 +188,11 @@ static bool writeDefArgumentList(OutputList &ol,ClassDef *cd,
QCString n=a->defval;
if (!cName.isEmpty()) n=addTemplateNames(n,cd->name(),cName);
ol.docify(" = ");
- linkifyText(TextGeneratorOLImpl(ol),cd,md->getBodyDef(),md->name(),n);
+
+ ol.startTypewriter();
+ linkifyText(TextGeneratorOLImpl(ol),cd,md->getBodyDef(),md->name(),n,FALSE,TRUE,TRUE);
+ ol.endTypewriter();
+
}
a=defArgList->next();
if (a)
@@ -618,21 +622,11 @@ void MemberDef::setDefinitionTemplateParameterLists(QList<ArgumentList> *lists)
void MemberDef::writeLink(OutputList &ol,ClassDef *,NamespaceDef *,
FileDef *,GroupDef *gd)
{
- //Definition *d=0;
- //if (cd) d=cd; else if (nd) d=nd; else if (fd) d=fd; else if (gd) d=gd;
- //if (d==0) { err("Member %s without definition! Please report this bug!\n",name().data()); return; }
- //if (group!=0 && gd==0) // forward link to the group
- //{
- // ol.writeObjectLink(group->getReference(),group->getOutputFileBase(),anchor(),name());
- //}
- //else // local link
- //{
- QCString sep = Config_getBool("OPTIMIZE_OUTPUT_JAVA") ? "." : "::";
- QCString n = name();
- if (classDef && gd) n.prepend(classDef->name()+sep);
- else if (nspace && gd) n.prepend(nspace->name()+sep);
- ol.writeObjectLink(getReference(),getOutputFileBase(),anchor(),n);
- //}
+ QCString sep = Config_getBool("OPTIMIZE_OUTPUT_JAVA") ? "." : "::";
+ QCString n = name();
+ if (classDef && gd) n.prepend(classDef->name()+sep);
+ else if (nspace && gd) n.prepend(nspace->name()+sep);
+ ol.writeObjectLink(getReference(),getOutputFileBase(),anchor(),n);
}
/*! If this member has an anonymous class/struct/union as its type, then
@@ -985,7 +979,11 @@ void MemberDef::writeDeclaration(OutputList &ol,
if (!name().isEmpty() && name().at(0)!='@') // hide annonymous stuff
{
//printf("Member name=`%s gd=%p md->groupDef=%p inGroup=%d isLinkable()=%d\n",name().data(),gd,getGroupDef(),inGroup,isLinkable());
- if (isLinkable())
+ if (!(name().isEmpty() || name().at(0)=='@') && // name valid
+ (hasDocumentation() || isReference()) && // has docs
+ !(prot==Private && !Config_getBool("EXTRACT_PRIVATE") && mtype!=Friend) && // hidden due to protection
+ !(isStatic() && classDef==0 && !Config_getBool("EXTRACT_STATIC")) // hidden due to static-ness
+ )
{
if (annMemb)
{
@@ -1075,8 +1073,9 @@ void MemberDef::writeDeclaration(OutputList &ol,
// write brief description
if (!briefDescription().isEmpty() &&
- Config_getBool("BRIEF_MEMBER_DESC") &&
- !annMemb)
+ Config_getBool("BRIEF_MEMBER_DESC")
+ /* && !annMemb */
+ )
{
ol.startMemberDescription();
ol.parseDoc(briefFile(),briefLine(),getOuterScope()?getOuterScope():d,this,briefDescription(),TRUE,FALSE);
@@ -1144,7 +1143,7 @@ bool MemberDef::isDetailedSectionLinkable() const
// member is part of an anonymous scope that is the type of
// another member in the list.
//
- bool inAnonymousScope = !briefDescription().isEmpty() && annUsed;
+ //bool inAnonymousScope = !briefDescription().isEmpty() && annUsed;
// hide friend (class|struct|union) member if HIDE_FRIEND_COMPOUNDS
// is true
@@ -1156,7 +1155,7 @@ bool MemberDef::isDetailedSectionLinkable() const
)
);
- return ((docFilter && staticFilter && privateFilter && friendCompoundFilter) || inAnonymousScope);
+ return ((docFilter && staticFilter && privateFilter && friendCompoundFilter) /*|| inAnonymousScope*/);
}
bool MemberDef::isDetailedSectionVisible(bool inGroup) const
@@ -2050,7 +2049,10 @@ Specifier MemberDef::virtualness() const
bool MemberDef::isConstructor() const
{
- return classDef ? name()==classDef->localName() : FALSE;
+ if (classDef)
+ return name()==classDef->localName();
+ else
+ return FALSE;
}
bool MemberDef::isDestructor() const
diff --git a/src/pngenc.h b/src/pngenc.h
index c86cbce..66379cb 100644
--- a/src/pngenc.h
+++ b/src/pngenc.h
@@ -22,6 +22,7 @@
typedef unsigned char Byte;
+/*! \brief Entry in the color palette of a PNG image */
struct Color
{
Byte red;
@@ -29,6 +30,11 @@ struct Color
Byte blue;
};
+/*! \brief PNG image encoder
+ *
+ * This class allows to encode a raw image to a compressed PNG.
+ * Use write() to save the result to disk.
+ */
class PngEncoder
{
public:
@@ -36,8 +42,6 @@ class PngEncoder
~PngEncoder();
void write(const char *fileName);
- protected:
-
private:
// image variables
Byte *data; // pointer to the image data (one byte per pixel)
diff --git a/src/scanner.l b/src/scanner.l
index f8c7033..3470a18 100644
--- a/src/scanner.l
+++ b/src/scanner.l
@@ -2154,7 +2154,8 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;]
current->type = current->type.mid(3);
}
current->type=current->type.simplifyWhiteSpace();
- current->args=current->args.simplifyWhiteSpace();
+ current->args=removeRedundantWhiteSpace(current->args);
+ // was: current->args.simplifyWhiteSpace();
current->name=current->name.stripWhiteSpace();
//if (!current->name.isEmpty() && current->type.left(8)=="typedef ")
//{
@@ -2338,7 +2339,8 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;]
current->program+=','; // add field terminator
}
// add compound definition to the tree
- current->args = current->args.simplifyWhiteSpace();
+ current->args=removeRedundantWhiteSpace(current->args);
+ // was: current->args.simplifyWhiteSpace();
current->type = current->type.simplifyWhiteSpace();
current->name = current->name.stripWhiteSpace();
//printf("adding `%s' `%s' `%s' brief=%s insideObjC=%d %x\n",current->type.data(),current->name.data(),current->args.data(),current->brief.data(),insideObjC,current->section);
@@ -3082,7 +3084,8 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;]
<Function>[;{,] {
current->name=current->name.simplifyWhiteSpace();
current->type=current->type.simplifyWhiteSpace();
- current->args=current->args.simplifyWhiteSpace();
+ current->args=removeRedundantWhiteSpace(current->args);
+ // was: current->args.simplifyWhiteSpace();
current->fileName = yyFileName;
current->startLine = yyLineNr;
if (*yytext!=';' || (current_root->section&Entry::COMPOUND_MASK) )
@@ -3694,7 +3697,7 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;]
}
<Comment>"/*" { current->program += yytext ; }
<Comment>"//" { current->program += yytext ; }
-<Comment>[^\n\*]+ { current->program += yytext ; }
+<Comment>[^\n\/\*]+ { current->program += yytext ; }
<Comment>"*/" { current->program += yytext ;
BEGIN( lastContext ) ;
}
diff --git a/src/translator_fr.h b/src/translator_fr.h
index 9a05607..f959a4f 100644
--- a/src/translator_fr.h
+++ b/src/translator_fr.h
@@ -52,15 +52,54 @@
* -------------+------------------------------------------------------------
* 2003-09-12 | Update for new since 1.3.3
* -------------+------------------------------------------------------------
+ * 2004-04-30 | Updates by Jacques Bouchard <jacques.bouchard@noos.fr>:
+ * | - spaces between ':' removed (should be added by the renderer)
+ * | - missing spaces added
+ * | - missing tests for OPTIMIZE_OUTPUT_FOR_C added
+ * | - translations corrected
+ * | - translator_fr.h now conforms exactly to translator_en.h
+ * | (try: gvim -d translator_en.h translator_fr.h)
+ * -------------+------------------------------------------------------------
*/
#ifndef TRANSLATOR_FR_H
#define TRANSLATOR_FR_H
+// When defining a translator class for the new language, follow
+// the description in the documentation. One of the steps says
+// that you should copy the translator_en.h (this) file to your
+// translator_xx.h new file. Your new language should use the
+// Translator class as the base class. This means that you need to
+// implement exactly the same (pure virtual) methods as the
+// TranslatorEnglish does. Because of this, it is a good idea to
+// start with the copy of TranslatorEnglish and replace the strings
+// one by one.
+//
+// It is not necessary to include "translator.h" or
+// "translator_adapter.h" here. The files are included in the
+// language.cpp correctly. Not including any of the mentioned
+// files frees the maintainer from thinking about whether the
+// first, the second, or both files should be included or not, and
+// why. This holds namely for localized translators because their
+// base class is changed occasionaly to adapter classes when the
+// Translator class changes the interface, or back to the
+// Translator class (by the local maintainer) when the localized
+// translator is made up-to-date again.
+
class TranslatorFrench : public Translator
{
public:
- QCString idLanguage()
+
+ // --- 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 "french"; }
+
/*! Used to get the LaTeX command(s) for the language support.
* This method should return string with commands that switch
* LaTeX to the desired language. For example
@@ -71,11 +110,8 @@ class TranslatorFrench : public Translator
* "\\usepackage[latin2]{inputenc}\n"
* "\\usepackage[T1]{fontenc}\n"
* </pre>
- *
- * The Dutch LaTeX does not use such commands. Because of this
- * the empty string is returned in this implementation.
*/
- QCString latexLanguageSupportCommand()
+ virtual QCString latexLanguageSupportCommand()
{
return "\\usepackage[french]{babel}\n";
}
@@ -86,58 +122,69 @@ class TranslatorFrench : public Translator
return "iso-8859-1";
}
+ // --- Language translation methods -------------------
+
/*! used in the compound documentation before a list of related functions. */
- QCString trRelatedFunctions()
+ virtual QCString trRelatedFunctions()
{ return "Fonctions associées"; }
/*! subscript for the related functions. */
- QCString trRelatedSubscript()
- { return "(Noter que ces fonctions ne sont pas des méthodes de la classe)"; }
+ virtual QCString trRelatedSubscript()
+ { return "(Noter que ce ne sont pas des fonctions membres)"; }
/*! header that is put before the detailed description of files, classes and namespaces. */
- QCString trDetailedDescription()
+ virtual QCString trDetailedDescription()
{ return "Description détaillée"; }
/*! header that is put before the list of typedefs. */
- QCString trMemberTypedefDocumentation()
- { return "Documentation des types imbriqués"; }
+ virtual QCString trMemberTypedefDocumentation()
+ { return "Documentation des typedef membres"; }
/*! header that is put before the list of enumerations. */
- QCString trMemberEnumerationDocumentation()
- { return "Documentation des énumérations imbriquées"; }
+ virtual QCString trMemberEnumerationDocumentation()
+ { return "Documentation des énumérations membres"; }
/*! header that is put before the list of member functions. */
- QCString trMemberFunctionDocumentation()
- { return "Documentation des méthodes"; }
+ virtual QCString trMemberFunctionDocumentation()
+ { return "Documentation des fonctions membres"; }
/*! header that is put before the list of member attributes. */
- QCString trMemberDataDocumentation()
- { return "Documentation des données imbriquées"; }
+ virtual QCString trMemberDataDocumentation()
+ {
+ if (Config_getBool("OPTIMIZE_OUTPUT_FOR_C"))
+ {
+ return "Documentation des champs";
+ }
+ else
+ {
+ return "Documentation des données membres";
+ }
+ }
/*! this is the text of a link put after brief descriptions. */
- QCString trMore()
+ virtual QCString trMore()
{ return "Plus de détails..."; }
/*! put in the class documentation */
- QCString trListOfAllMembers()
+ virtual QCString trListOfAllMembers()
{ return "Liste de tous les membres"; }
/*! used as the title of the "list of all members" page of a class */
- QCString trMemberList()
+ virtual QCString trMemberList()
{ return "Liste des membres"; }
/*! this is the first part of a sentence that is followed by a class name */
- QCString trThisIsTheListOfAllMembers()
- { return "Ceci est la liste complète des membres de "; }
+ virtual QCString trThisIsTheListOfAllMembers()
+ { return "Liste complète des membres de "; }
/*! this is the remainder of the sentence after the class name */
- QCString trIncludingInheritedMembers()
- { return " y compris des membres des classes héritées."; }
+ virtual QCString trIncludingInheritedMembers()
+ { return ", y compris les membres hérités:"; }
/*! this is put at the author sections at the bottom of man pages.
* parameter s is name of the project name.
*/
- QCString trGeneratedAutomatically(const char *s)
+ virtual QCString trGeneratedAutomatically(const char *s)
{ QCString result="Généré automatiquement par Doxygen";
if (s) result+=(QCString)" pour "+s;
result+=" à partir du code source.";
@@ -145,15 +192,15 @@ class TranslatorFrench : public Translator
}
/*! put after an enum name in the list of all members */
- QCString trEnumName()
+ virtual QCString trEnumName()
{ return "énumération"; }
/*! put after an enum value in the list of all members */
- QCString trEnumValue()
- { return "élément d'une énumération"; }
+ virtual QCString trEnumValue()
+ { return "valeur énumérée"; }
/*! put after an undocumented member in the list of all members */
- QCString trDefinedIn()
+ virtual QCString trDefinedIn()
{ return "défini dans"; }
// quick reference sections
@@ -161,337 +208,444 @@ class TranslatorFrench : public Translator
/*! This is put above each page as a link to the list of all groups of
* compounds or files (see the \\group command).
*/
- QCString trModules()
+ virtual QCString trModules()
{ return "Modules"; }
/*! This is put above each page as a link to the class hierarchy */
- QCString trClassHierarchy()
+ virtual QCString trClassHierarchy()
{ return "Hiérarchie des classes"; }
/*! This is put above each page as a link to the list of annotated classes */
- QCString trCompoundList()
- { return "Liste des composants";
+ virtual QCString trCompoundList()
+ {
+ if (Config_getBool("OPTIMIZE_OUTPUT_FOR_C"))
+ {
+ return "Structures de données";
+ }
+ else
+ {
+ return "Liste des classes";
+ }
+ }
- /*! This is put above each page as a link to the list of documented files */}
- QCString trFileList()
+ /*! This is put above each page as a link to the list of documented files */
+ virtual QCString trFileList()
{ return "Liste des fichiers"; }
/*! This is put above each page as a link to the list of all verbatim headers */
- QCString trHeaderFiles()
+ virtual QCString trHeaderFiles()
{ return "Fichiers d'en-tête"; }
/*! This is put above each page as a link to all members of compounds. */
- QCString trCompoundMembers()
- { return "Composants"; }
+ virtual QCString trCompoundMembers()
+ {
+ if (Config_getBool("OPTIMIZE_OUTPUT_FOR_C"))
+ {
+ return "Champs de donnée";
+ }
+ else
+ {
+ return "Membres de classe";
+ }
+ }
/*! This is put above each page as a link to all members of files. */
- QCString trFileMembers()
- { return "Déclarations"; }
+ virtual QCString trFileMembers()
+ {
+ if (Config_getBool("OPTIMIZE_OUTPUT_FOR_C"))
+ {
+ return "Portée globale";
+ }
+ else
+ {
+ return "Membres de fichier";
+ }
+ }
/*! This is put above each page as a link to all related pages. */
- QCString trRelatedPages()
+ virtual QCString trRelatedPages()
{ return "Pages associées"; }
/*! This is put above each page as a link to all examples. */
- QCString trExamples()
+ virtual QCString trExamples()
{ return "Exemples"; }
/*! This is put above each page as a link to the search engine. */
- QCString trSearch()
+ virtual QCString trSearch()
{ return "Recherche"; }
/*! This is an introduction to the class hierarchy. */
- QCString trClassHierarchyDescription()
- { return "Cette liste d'héritage est, autant que possible, "
- "classée par ordre alphabétique"; }
+ virtual QCString trClassHierarchyDescription()
+ { return "Cette liste d'héritage est classée "
+ "approximativement par ordre alphabétique:";
+ }
/*! This is an introduction to the list with all files. */
- QCString trFileListDescription(bool extractAll)
+ virtual QCString trFileListDescription(bool extractAll)
{
QCString result="Liste de tous les fichiers ";
if (!extractAll) result+="documentés ";
- result+="avec une brève description :";
+ result+="avec une brève description:";
return result;
}
/*! This is an introduction to the annotated compound list. */
- QCString trCompoundListDescription()
- { return "Liste des classes, des structures et des unions "
- "avec une brève description :";
+ virtual QCString trCompoundListDescription()
+ {
+
+ if (Config_getBool("OPTIMIZE_OUTPUT_FOR_C"))
+ {
+ return "Liste des structures de données avec une brève description:";
+ }
+ else
+ {
+ return "Liste des classes, structures, "
+ "unions et interfaces avec une brève description:";
+ }
}
/*! This is an introduction to the page with all class members. */
- QCString trCompoundMembersDescription(bool extractAll)
+ virtual QCString trCompoundMembersDescription(bool extractAll)
{
- QCString result="Liste de tous les membres de classe ";
- if (!extractAll) result+="documentés ";
- result+="avec les liens vers ";
- if (!extractAll) result+="la documentation de la classe correspondante :";
- else result+="les classes auxquelles ils appartiennent :";
+ QCString result="Liste de tous les ";
+ if (Config_getBool("OPTIMIZE_OUTPUT_FOR_C"))
+ {
+ result+="champs de structure et d'union ";
+ }
+ else
+ {
+ result+="membres de classe ";
+ }
+ if (!extractAll)
+ {
+ result+="documentés ";
+ }
+ result+="avec liens vers ";
+ if (!extractAll)
+ {
+ if (Config_getBool("OPTIMIZE_OUTPUT_FOR_C"))
+ {
+ result+="la documentation de structure/union de chaque champ:";
+ }
+ else
+ {
+ result+="la documentation de classe de chaque membre:";
+ }
+ }
+ else
+ {
+ if (Config_getBool("OPTIMIZE_OUTPUT_FOR_C"))
+ {
+ result+="les structures/unions auxquelles ils appartiennent:";
+ }
+ else
+ {
+ result+="les classes auxquelles ils appartiennent:";
+ }
+ }
return result;
}
/*! This is an introduction to the page with all file members. */
- QCString trFileMembersDescription(bool extractAll)
- {
- QCString result="Liste de toutes les déclarations";
- if (!extractAll) result+="documentées ";
- result+="avec liens sur ";
- if (extractAll) result+="la documentation du fichier correspondant "
- "pour chacune :";
- else result+="les fichiers dans lesquels elles sont définies :";
+ virtual QCString trFileMembersDescription(bool extractAll)
+ {
+ QCString result="Liste ";
+
+ if (Config_getBool("OPTIMIZE_OUTPUT_FOR_C"))
+ {
+ result+="des fonctions, variables, macros, enumérations, et typedefs ";
+ }
+ else
+ {
+ result+="de tous les membres de fichier ";
+ }
+ if (!extractAll) result+="documentés ";
+ result+="avec liens vers ";
+ if (extractAll)
+ result+="les fichiers auxquels ils appartiennent:";
+ else
+ result+="la documentation:";
return result;
}
/*! This is an introduction to the page with the list of all header files. */
- QCString trHeaderFilesDescription()
- { return "Liste de tous les fichiers d'en-tête constituant "
- "l'interface de programmation :"; }
+ virtual QCString trHeaderFilesDescription()
+ { return "Liste des fichiers d'en-tête constituant l'interface de programmation:"; }
/*! This is an introduction to the page with the list of all examples */
- QCString trExamplesDescription()
- { return "Liste de tous les exemples :"; }
+ virtual QCString trExamplesDescription()
+ { return "Liste de tous les exemples:"; }
/*! This is an introduction to the page with the list of related pages */
- QCString trRelatedPagesDescription()
- { return "Liste de toutes les pages de documentation associées :"; }
+ virtual QCString trRelatedPagesDescription()
+ { return "Liste de toutes les pages de documentation associées:"; }
/*! This is an introduction to the page with the list of class/file groups */
- QCString trModulesDescription()
- { return "Liste de tous les modules"; }
+ virtual QCString trModulesDescription()
+ { return "Liste de tous les modules:"; }
/*! This sentences is used in the annotated class/file lists if no brief
* description is given.
*/
- QCString trNoDescriptionAvailable()
- { return "Aucune description n'est disponible"; }
+ virtual QCString trNoDescriptionAvailable()
+ { return "Aucune description disponible"; }
// index titles (the project name is prepended for these)
/*! This is used in HTML as the title of index.html. */
- QCString trDocumentation()
+ virtual QCString trDocumentation()
{ return "Documentation"; }
/*! This is used in LaTeX as the title of the chapter with the
* index of all groups.
*/
- QCString trModuleIndex()
+ virtual QCString trModuleIndex()
{ return "Index des modules"; }
/*! This is used in LaTeX as the title of the chapter with the
* class hierarchy.
*/
- QCString trHierarchicalIndex()
+ virtual QCString trHierarchicalIndex()
{ return "Index hiérarchique"; }
/*! This is used in LaTeX as the title of the chapter with the
* annotated compound index.
*/
- QCString trCompoundIndex()
- { return "Index des composants"; }
+ virtual QCString trCompoundIndex()
+ {
+ if (Config_getBool("OPTIMIZE_OUTPUT_FOR_C"))
+ {
+ return "Index des structures de données";
+ }
+ else
+ {
+ return "Index des classes";
+ }
+ }
/*! This is used in LaTeX as the title of the chapter with the
* list of all files.
*/
- QCString trFileIndex()
+ virtual QCString trFileIndex()
{ return "Index des fichiers"; }
/*! This is used in LaTeX as the title of the chapter containing
* the documentation of all groups.
*/
- QCString trModuleDocumentation()
- { return "Documentation du module"; }
+ virtual QCString trModuleDocumentation()
+ { return "Documentation des modules"; }
/*! This is used in LaTeX as the title of the chapter containing
* the documentation of all classes, structs and unions.
*/
- QCString trClassDocumentation()
- { return "Documentation de la classe"; }
+ virtual QCString trClassDocumentation()
+ {
+ if (Config_getBool("OPTIMIZE_OUTPUT_FOR_C"))
+ {
+ return "Documentation des structures de données";
+ }
+ else
+ {
+ return "Documentation des classes";
+ }
+ }
/*! This is used in LaTeX as the title of the chapter containing
* the documentation of all files.
*/
- QCString trFileDocumentation()
- { return "Documentation du fichier"; }
+ virtual QCString trFileDocumentation()
+ { return "Documentation des fichiers"; }
/*! This is used in LaTeX as the title of the chapter containing
* the documentation of all examples.
*/
- QCString trExampleDocumentation()
- { return "Documentation de l'exemple"; }
+ virtual QCString trExampleDocumentation()
+ { return "Documentation des exemples"; }
/*! This is used in LaTeX as the title of the chapter containing
* the documentation of all related pages.
*/
- QCString trPageDocumentation()
- { return "Documentation de la page"; }
+ virtual QCString trPageDocumentation()
+ { return "Documentation des pages associées"; }
/*! This is used in LaTeX as the title of the document */
- QCString trReferenceManual()
+ virtual QCString trReferenceManual()
{ return "Manuel de référence"; }
/*! This is used in the documentation of a file as a header before the
* list of defines
*/
- QCString trDefines()
- { return "Définitions des macros"; }
+ virtual QCString trDefines()
+ { return "Macros"; }
/*! This is used in the documentation of a file as a header before the
* list of function prototypes
*/
- QCString trFuncProtos()
- { return "Prototypes des fonctions"; }
+ virtual QCString trFuncProtos()
+ { return "Prototypes de fonction"; }
/*! This is used in the documentation of a file as a header before the
* list of typedefs
*/
- QCString trTypedefs()
- { return "Définitions des types"; }
+ virtual QCString trTypedefs()
+ { return "Typedefs"; }
/*! This is used in the documentation of a file as a header before the
* list of enumerations
*/
- QCString trEnumerations()
+ virtual QCString trEnumerations()
{ return "Énumérations"; }
/*! This is used in the documentation of a file as a header before the
* list of (global) functions
*/
- QCString trFunctions()
+ virtual QCString trFunctions()
{ return "Fonctions"; }
/*! This is used in the documentation of a file as a header before the
* list of (global) variables
*/
- QCString trVariables()
+ virtual QCString trVariables()
{ return "Variables"; }
/*! This is used in the documentation of a file as a header before the
* list of (global) variables
*/
- QCString trEnumerationValues()
- { return "Éléments énumérés"; }
+ virtual QCString trEnumerationValues()
+ { return "Valeurs énumérées"; }
/*! This is used in the documentation of a file before the list of
* documentation blocks for defines
*/
- QCString trDefineDocumentation()
- { return "Documentation de la macro"; }
+ virtual QCString trDefineDocumentation()
+ { return "Documentation des macro"; }
/*! This is used in the documentation of a file/namespace before the list
* of documentation blocks for function prototypes
*/
- QCString trFunctionPrototypeDocumentation()
- { return "Documentation du prototype de la fonction"; }
+ virtual QCString trFunctionPrototypeDocumentation()
+ { return "Documentation des prototypes de fonction"; }
/*! This is used in the documentation of a file/namespace before the list
* of documentation blocks for typedefs
*/
- QCString trTypedefDocumentation()
- { return "Documentation du type"; }
+ virtual QCString trTypedefDocumentation()
+ { return "Documentation des typedef"; }
/*! This is used in the documentation of a file/namespace before the list
* of documentation blocks for enumeration types
*/
- QCString trEnumerationTypeDocumentation()
+ virtual QCString trEnumerationTypeDocumentation()
{ return "Documentation du type de l'énumération"; }
/*! This is used in the documentation of a file/namespace before the list
* of documentation blocks for enumeration values
*/
- QCString trEnumerationValueDocumentation()
- { return "Documentation de l'élément de l'énumeration"; }
+ virtual QCString trEnumerationValueDocumentation()
+ { return "Documentation de la valeur énumérée"; }
/*! This is used in the documentation of a file/namespace before the list
* of documentation blocks for functions
*/
- QCString trFunctionDocumentation()
- { return "Documentation de la fonction"; }
+ virtual QCString trFunctionDocumentation()
+ { return "Documentation des fonctions"; }
/*! This is used in the documentation of a file/namespace before the list
* of documentation blocks for variables
*/
- QCString trVariableDocumentation()
- { return "Documentation de la variable"; }
+ virtual QCString trVariableDocumentation()
+ { return "Documentation des variables"; }
/*! This is used in the documentation of a file/namespace/group before
* the list of links to documented compounds
*/
- QCString trCompounds()
- { return "Composants"; }
+ virtual QCString trCompounds()
+ {
+ if (Config_getBool("OPTIMIZE_OUTPUT_FOR_C"))
+ {
+ return "Structures de données";
+ }
+ else
+ {
+ return "Classes";
+ }
+ }
/*! This is used in the standard footer of each page and indicates when
* the page was generated
*/
- QCString trGeneratedAt(const char *date,const char *projName)
+ virtual QCString trGeneratedAt(const char *date,const char *projName)
{
QCString result=(QCString)"Généré le "+date;
if (projName) result+=(QCString)" pour "+projName;
- result+=(QCString)" par ";
+ result+=(QCString)" par";
return result;
}
/*! This is part of the sentence used in the standard footer of each page.
*/
- QCString trWrittenBy()
+ virtual QCString trWrittenBy()
{
return "écrit par";
}
/*! this text is put before a class diagram */
- QCString trClassDiagram(const char *clName)
+ virtual QCString trClassDiagram(const char *clName)
{
- return (QCString)"Graphe d'héritage de la classe "+clName;
+ return (QCString)"Graphe d'héritage de "+clName+":";
}
/*! this text is generated when the \\internal command is used. */
- QCString trForInternalUseOnly()
+ virtual QCString trForInternalUseOnly()
{ return "À usage interne uniquement."; }
/*! this text is generated when the \\reimp command is used. */
- QCString trReimplementedForInternalReasons()
- { return "Redéfini pour des raisons internes; "
- "l'interface n'est pas modifiée";
+ virtual QCString trReimplementedForInternalReasons()
+ { return "Réimplémenté pour des raisons internes; "
+ "l'interface de programmation n'est pas modifiée.";
}
/*! this text is generated when the \\warning command is used. */
- QCString trWarning()
+ virtual QCString trWarning()
{ return "Avertissement"; }
/*! this text is generated when the \\bug command is used. */
- QCString trBugsAndLimitations()
+ virtual QCString trBugsAndLimitations()
{ return "Bogues et limitations"; }
/*! this text is generated when the \\version command is used. */
- QCString trVersion()
+ virtual QCString trVersion()
{ return "Version"; }
/*! this text is generated when the \\date command is used. */
- QCString trDate()
+ virtual QCString trDate()
{ return "Date"; }
/*! this text is generated when the \\return command is used. */
- QCString trReturns()
+ virtual QCString trReturns()
{ return "Renvoie"; }
/*! this text is generated when the \\sa command is used. */
- QCString trSeeAlso()
+ virtual QCString trSeeAlso()
{ return "Voir également"; }
/*! this text is generated when the \\param command is used. */
- QCString trParameters()
+ virtual QCString trParameters()
{ return "Paramètres"; }
/*! this text is generated when the \\exception command is used. */
- QCString trExceptions()
+ virtual QCString trExceptions()
{ return "Exceptions"; }
/*! this text is used in the title page of a LaTeX document. */
- QCString trGeneratedBy()
+ virtual QCString trGeneratedBy()
{ return "Généré par"; }
- // new since 0.49-990307
-
+//////////////////////////////////////////////////////////////////////////
+// new since 0.49-990307
+//////////////////////////////////////////////////////////////////////////
+
+ /*! used as the title of page containing all the index of all namespaces. */
virtual QCString trNamespaceList()
{ return "Liste des namespaces"; }
@@ -500,7 +654,7 @@ class TranslatorFrench : public Translator
{
QCString result="Liste de tous les namespaces ";
if (!extractAll) result+="documentés ";
- result+="avec une brève description :";
+ result+="avec une brève description:";
return result;
}
@@ -508,7 +662,7 @@ class TranslatorFrench : public Translator
* friends of a class
*/
virtual QCString trFriends()
- { return "Amis (friends)"; }
+ { return "Amis"; }
//////////////////////////////////////////////////////////////////////////
// new since 0.49-990405
@@ -527,7 +681,7 @@ class TranslatorFrench : public Translator
/*! used as the title of the HTML page of a class/struct/union */
virtual QCString trCompoundReference(const char *clName,
ClassDef::CompoundType compType,
- bool /*isTemplate*/)
+ bool isTemplate)
{
QCString result="Référence de ";
switch(compType)
@@ -540,8 +694,8 @@ class TranslatorFrench : public Translator
case ClassDef::Category: result+="la catégorie "; break;
case ClassDef::Exception: result+="l'exception "; break;
}
-
result+=(QCString)clName;
+ if (isTemplate) result+=" (modèle)";
return result;
}
@@ -549,7 +703,7 @@ class TranslatorFrench : public Translator
virtual QCString trFileReference(const char *fileName)
{
QCString result= "Référence du fichier ";
- result += fileName;
+ result+=fileName;
return result;
}
@@ -557,31 +711,30 @@ class TranslatorFrench : public Translator
virtual QCString trNamespaceReference(const char *namespaceName)
{
QCString result= "Référence du namespace ";
- result += namespaceName;
+ result+=namespaceName;
return result;
}
- /* these are for the member sections of a class, struct or union */
virtual QCString trPublicMembers()
- { return "Membres publics"; }
+ { return "Fonctions membres publiques"; }
virtual QCString trPublicSlots()
{ return "Connecteurs publics"; }
virtual QCString trSignals()
{ return "Signaux"; }
virtual QCString trStaticPublicMembers()
- { return "Membres publics statiques"; }
+ { return "Fonctions membres publiques statiques"; }
virtual QCString trProtectedMembers()
- { return "Membres protégés"; }
+ { return "Fonctions membres protégées"; }
virtual QCString trProtectedSlots()
{ return "Connecteurs protégés"; }
virtual QCString trStaticProtectedMembers()
- { return "Membres protégés statiques"; }
+ { return "Fonctions membres protégées statiques"; }
virtual QCString trPrivateMembers()
- { return "Membres privés"; }
+ { return "Fonctions membres privées"; }
virtual QCString trPrivateSlots()
{ return "Connecteurs privés"; }
virtual QCString trStaticPrivateMembers()
- { return "Membres privés statiques"; }
+ { return "Fonctions membres privées statiques"; }
/*! this function is used to produce a comma-separated list of items.
* use generateMarker(i) to indicate where item i should be put.
@@ -629,7 +782,7 @@ class TranslatorFrench : public Translator
*/
virtual QCString trReimplementedFromList(int numEntries)
{
- return "Redéfinie à partir de "+trWriteList(numEntries)+".";
+ return "Réimplémentée à partir de "+trWriteList(numEntries)+".";
}
/*! used in member documentation blocks to produce a list of
@@ -637,23 +790,23 @@ class TranslatorFrench : public Translator
*/
virtual QCString trReimplementedInList(int numEntries)
{
- return "Redéfinie dans "+trWriteList(numEntries)+".";
+ return "Réimplémentée dans "+trWriteList(numEntries)+".";
}
/*! This is put above each page as a link to all members of namespaces. */
virtual QCString trNamespaceMembers()
- { return "Membres des namespaces"; }
+ { return "Membres de namespace"; }
/*! This is an introduction to the page with all namespace members */
virtual QCString trNamespaceMemberDescription(bool extractAll)
{
- QCString result="Voici une liste de tous les membres de namespace";
+ QCString result="Liste de tous les membres de namespace ";
if (!extractAll) result+="documentés ";
- result+=" avec liens vers ";
+ result+="avec liens vers ";
if (extractAll)
- result+="les documentations des namespaces associés :";
+ result+="la documentation de namespace de chaque membre:";
else
- result+="les namespaces auxquels ils appartiennent :";
+ result+="les namespaces auxquels ils appartiennent:";
return result;
}
/*! This is used in LaTeX as the title of the chapter with the
@@ -676,7 +829,7 @@ class TranslatorFrench : public Translator
* namespaces in a file.
*/
virtual QCString trNamespaces()
- { return "Espaces de nommage (namespaces)"; }
+ { return "Namespaces"; }
//////////////////////////////////////////////////////////////////////////
// new since 0.49-990728
@@ -689,20 +842,20 @@ class TranslatorFrench : public Translator
bool single)
{ // here s is one of " Class", " Struct" or " Union"
// single is true implies a single file
- QCString result=(QCString)"La documentation associée à cette ";
+ QCString result=(QCString)"La documentation de ";
switch(compType)
{
- case ClassDef::Class: result+="classe"; break;
- case ClassDef::Struct: result+="structure"; break;
- case ClassDef::Union: result+="union"; break;
- case ClassDef::Interface: result+="interface"; break;
- case ClassDef::Protocol: result+="protocol"; break;
- case ClassDef::Category: result+="category"; break;
- case ClassDef::Exception: result+="exception"; break;
+ case ClassDef::Class: result+="cette classe"; break;
+ case ClassDef::Struct: result+="cette structure"; break;
+ case ClassDef::Union: result+="cette union"; break;
+ case ClassDef::Interface: result+="cette interface"; break;
+ case ClassDef::Protocol: result+="ce protocol"; break;
+ case ClassDef::Category: result+="cette catégorie"; break;
+ case ClassDef::Exception: result+="cette exception"; break;
}
result+=" a été générée à partir ";
- if (single) result+=" du fichier suivant :";
- else result+="des fichiers suivants :";
+ if (single) result+="du fichier suivant:";
+ else result+="des fichiers suivants:";
return result;
}
@@ -710,10 +863,7 @@ class TranslatorFrench : public Translator
* list.
*/
virtual QCString trAlphabeticalList()
- {
- return "Liste par ordre alphabétique";
- }
-
+ { return "Liste alphabétique"; }
//////////////////////////////////////////////////////////////////////////
// new since 0.49-990901
@@ -732,7 +882,7 @@ class TranslatorFrench : public Translator
* documentation. It should be an abbreviation of the word page.
*/
virtual QCString trPageAbbreviation()
- { return "p. "; }
+ { return "p."; }
//////////////////////////////////////////////////////////////////////////
// new since 0.49-991003
@@ -750,6 +900,7 @@ class TranslatorFrench : public Translator
{
return "Définition dans le fichier @0.";
}
+
//////////////////////////////////////////////////////////////////////////
// new since 0.49-991205
//////////////////////////////////////////////////////////////////////////
@@ -766,17 +917,17 @@ class TranslatorFrench : public Translator
/*! this text is put before a collaboration diagram */
virtual QCString trCollaborationDiagram(const char *clName)
{
- return (QCString)"Diagramme de collaboration de "+clName+":";
+ return (QCString)"Graphe de collaboration de "+clName+":";
}
/*! this text is put before an include dependency graph */
virtual QCString trInclDepGraph(const char *fName)
{
- return (QCString)"Graphe des dépendances par inclusion pour "+fName+":";
+ return (QCString)"Graphe des dépendances par inclusion de "+fName+":";
}
/*! header that is put before the list of constructor/destructors. */
virtual QCString trConstructorDocumentation()
{
- return "Documentation des contructeurs et destructeurs";
+ return "Documentation des contructeurs et destructeur";
}
/*! Used in the file documentation to point to the corresponding sources. */
virtual QCString trGotoSourceCode()
@@ -806,7 +957,7 @@ class TranslatorFrench : public Translator
/*! Text shown before a multi-line variable/enum initialization */
virtual QCString trInitialValue()
{
- return "Initialisation:";
+ return "Valeur initiale:";
}
/*! Text used the source code in the file index */
virtual QCString trCode()
@@ -815,15 +966,15 @@ class TranslatorFrench : public Translator
}
virtual QCString trGraphicalHierarchy()
{
- return "Diagramme hiérarchique des classes";
+ return "Graphe hiérarchique des classes";
}
virtual QCString trGotoGraphicalHierarchy()
{
- return "Aller au diagramme hiérarchique des classes";
+ return "Aller au graphe hiérarchique des classes";
}
virtual QCString trGotoTextualHierarchy()
{
- return "Aller à la hiérarchie des classes en texte";
+ return "Aller à la hiérarchie des classes en mode texte";
}
virtual QCString trPageIndex()
{
@@ -840,49 +991,56 @@ class TranslatorFrench : public Translator
}
virtual QCString trPublicTypes()
{
- return "Types Publics";
+ return "Types publics";
}
virtual QCString trPublicAttribs()
{
- return "Attributs Publics";
+ if (Config_getBool("OPTIMIZE_OUTPUT_FOR_C"))
+ {
+ return "Champs de données";
+ }
+ else
+ {
+ return "Attributs publics";
+ }
}
virtual QCString trStaticPublicAttribs()
{
- return "Attributs Publics Statiques";
+ return "Attributs publics statiques";
}
virtual QCString trProtectedTypes()
{
- return "Types Protégés";
+ return "Types protégés";
}
virtual QCString trProtectedAttribs()
{
- return "Attributs Protégés";
+ return "Attributs protégés";
}
virtual QCString trStaticProtectedAttribs()
{
- return "Attributs Protégés Statiques";
+ return "Attributs protégés statiques";
}
virtual QCString trPrivateTypes()
{
- return "Types Privés";
+ return "Types privés";
}
virtual QCString trPrivateAttribs()
{
- return "Attributs Privés";
+ return "Attributs privés";
}
virtual QCString trStaticPrivateAttribs()
{
- return "Attributs Privés Statiques";
+ return "Attributs privés statiques";
}
//////////////////////////////////////////////////////////////////////////
// new since 1.1.3
//////////////////////////////////////////////////////////////////////////
- /*! 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()
{
- return "À Faire";
+ return "À faire";
}
/*! Used as the header of the todo list */
virtual QCString trTodoList()
@@ -925,13 +1083,14 @@ class TranslatorFrench : public Translator
{
return "Légende du graphe";
}
- /*! page explaining how the dot graph's should be interpreted */
+ /*! page explaining how the dot graph's should be interpreted
+ * The %A in the text below are to prevent link to classes called "A".
+ */
virtual QCString trLegendDocs()
{
return
- "Cette page explique comment interpréter les graphes générés "
- "par doxygen.<p>\n"
-
+ "Cette page explique comment interpréter les graphes générés "
+ "par doxygen.<p>\n"
"Considérez l'exemple suivant:\n"
"\\code\n"
"/*! Classe invisible à cause d'une troncature */\n"
@@ -942,6 +1101,8 @@ class TranslatorFrench : public Translator
"class Undocumented { };\n\n"
"/*! Classe dérivée par héritage public */\n"
"class PublicBase : public Truncated { };\n\n"
+ "/*! Un modèle de classe */\n"
+ "template<class T> class Templ { };\n\n"
"/*! Classe dérivée par héritage protégé */\n"
"class ProtectedBase { };\n\n"
"/*! Classe dérivée par héritage privé */\n"
@@ -953,41 +1114,46 @@ class TranslatorFrench : public Translator
" protected ProtectedBase,\n"
" private PrivateBase,\n"
" public Undocumented\n"
+ " public Templ<int>\n"
"{\n"
" private:\n"
" Used *m_usedClass;\n"
"};\n"
"\\endcode\n"
- "Si la valeur 200 est attribuée au tag \\c MAX_DOT_GRAPH_HEIGHT "
- "du fichier de configuration, cela génèrera le graphe suivant:"
- "<p><center><img src=\"graph_legend."+Config_getEnum("DOT_IMAGE_FORMAT")+"\"></center>\n"
+ "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:"
+ "<p><center><img alt=\"\" src=\"graph_legend."+Config_getEnum("DOT_IMAGE_FORMAT")+"\"></center>\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"
"<ul>\n"
"<li>Un rectangle plein noir représente la structure ou la classe pour laquelle "
"le graphe est généré.\n"
"<li>Un rectangle avec un bord noir indique une classe ou une structure documentée.\n"
"<li>Un rectangle avec un bord gris indique une classe ou une structure non documentée.\n"
"<li>Un rectangle avec un bord rouge indique une structure ou une classe documentée\n"
- "pour laquelle des relations d'héritage ou de collaboration manquent. Un graphe est "
- "tronqué s'il ne rentre pas dans les limites spécifiées."
+ "pour laquelle des relations d'héritage ou de collaboration manquent. Un graphe est "
+ "tronqué s'il n'entre pas dans les limites spécifiées."
"</ul>\n"
"Les flèches ont la signification suivante:\n"
"<ul>\n"
"<li>Une flèche bleu foncé est utilisée pour visualiser une relation d'héritage public "
- "entre deux classes.\n"
+ "entre deux classes.\n"
"<li>Une flèche vert foncé est utilisée pour une relation d'héritage protégé.\n"
"<li>Une flèche rouge foncé est utilisée pour une relation d'héritage privé.\n"
- "<li>Une flèche violette en pointillés est utilisée si une classe est contenue ou "
- "utilisée par une autre classe. La flèche est étiquetée avec la ou les variable(s) "
- "qui permettent d'accéder à la classe ou structure pointée. \n"
+ "<li>Une flèche violette en pointillés est utilisée si une classe est contenue ou "
+ "utilisée par une autre classe. La flèche est étiquetée avec la ou les variable(s) "
+ "qui permettent d'accéder à la classe ou structure pointée. \n"
+ "<li>Une flèche verte en pointillés indique une relation entre une classe instanciée et "
+ "le modèle de classe utilisé. La flèche est étiquetée avec "
+ "les paramètres de modèle de la classe instanciée.\n"
"</ul>\n";
}
/*! text for the link to the legend page */
virtual QCString trLegend()
{
- return "Légende";
+ return "légende";
}
+
//////////////////////////////////////////////////////////////////////////
// new since 1.2.0
//////////////////////////////////////////////////////////////////////////
@@ -1010,7 +1176,7 @@ class TranslatorFrench : public Translator
/*! Used as a section header for KDE-2 IDL methods */
virtual QCString trDCOPMethods()
{
- return "Méthodes DCOP";
+ return "Fonctions membres DCOP";
}
//////////////////////////////////////////////////////////////////////////
@@ -1255,6 +1421,7 @@ class TranslatorFrench : public Translator
{
return "Références";
}
+
//////////////////////////////////////////////////////////////////////////
// new since 1.2.13
//////////////////////////////////////////////////////////////////////////
@@ -1268,7 +1435,7 @@ class TranslatorFrench : public Translator
}
/*! used in member documentation blocks to produce a list of
- * all members that implementation this member.
+ * all members that implement this abstract member.
*/
virtual QCString trImplementedInList(int numEntries)
{
@@ -1296,7 +1463,7 @@ class TranslatorFrench : public Translator
*/
virtual QCString trDeprecatedList()
{
- return "Liste obsolète";
+ return "Liste des éléments obsolètes";
}
//////////////////////////////////////////////////////////////////////////
@@ -1308,12 +1475,12 @@ class TranslatorFrench : public Translator
*/
virtual QCString trEvents()
{
- return "Evènements";
+ return "Evénements";
}
/*! Header used for the documentation section of a class' events. */
virtual QCString trEventDocumentation()
{
- return "Documentation des évènements";
+ return "Documentation des événements";
}
//////////////////////////////////////////////////////////////////////////
@@ -1331,14 +1498,14 @@ class TranslatorFrench : public Translator
*/
virtual QCString trPackageMembers()
{
- return "Méthodes de paquetage";
+ return "Fonctions de paquetage";
}
/*! Used as a heading for a list of static Java class functions with
* package scope.
*/
virtual QCString trStaticPackageMembers()
{
- return "Méthodes statiques de paquetage";
+ return "Fonctions statiques de paquetage";
}
/*! Used as a heading for a list of Java class variables with package
* scope.
@@ -1369,7 +1536,7 @@ class TranslatorFrench : public Translator
/*! Put in front of the call graph for a function. */
virtual QCString trCallGraph()
{
- return "Voici le graphique d'appel pour cette fonction:";
+ return "Voici le graphe d'appel pour cette fonction:";
}
//////////////////////////////////////////////////////////////////////////
@@ -1389,7 +1556,7 @@ class TranslatorFrench : public Translator
*/
virtual QCString trSearchResultsTitle()
{
- return "Resultats de la recherche";
+ return "Résultats de la recherche";
}
/*! This string is put just before listing the search results. The
* text can be different depending on the number of documents found.
@@ -1426,4 +1593,3 @@ class TranslatorFrench : public Translator
};
#endif
-
diff --git a/src/util.cpp b/src/util.cpp
index f962c1f..ca30377 100644
--- a/src/util.cpp
+++ b/src/util.cpp
@@ -78,9 +78,27 @@ TextGeneratorOLImpl::TextGeneratorOLImpl(OutputDocInterface &od) : m_od(od)
{
}
-void TextGeneratorOLImpl::writeString(const char *s) const
+void TextGeneratorOLImpl::writeString(const char *s,bool keepSpaces) const
{
- m_od.docify(s);
+ if (keepSpaces)
+ {
+ const char *p=s;
+ if (p)
+ {
+ char cs[2];
+ char c;
+ cs[1]='\0';
+ while ((c=*p++))
+ {
+ if (c==' ') m_od.writeNonBreakableSpace(1);
+ else cs[0]=c,m_od.docify(cs);
+ }
+ }
+ }
+ else
+ {
+ m_od.docify(s);
+ }
}
void TextGeneratorOLImpl::writeBreak() const
@@ -1171,9 +1189,26 @@ QCString removeRedundantWhiteSpace(const QCString &s)
uint csp=0;
for (i=0;i<l;i++)
{
+nextChar:
char c=s.at(i);
if (csp<6 && c==constScope[csp]) csp++; else csp=0;
- if (i<l-2 && c=='<' && // current char is a <
+ if (c=='"') // quoted string
+ {
+ i++;
+ result+=c;
+ while (i<l)
+ {
+ char cc=s.at(i);
+ result+=cc;
+ if (cc=='\\') // escaped character
+ { result+=s.at(i+1); i+=2; }
+ else if (cc=='"') // end of string
+ { i++; goto nextChar; }
+ else // any other character
+ { i++; }
+ }
+ }
+ else if (i<l-2 && c=='<' && // current char is a <
(isId(s.at(i+1)) || isspace((uchar)s.at(i+1))) && // next char is an id char or space
(i<8 || !findOperator(s,i)) // string in front is not "operator"
)
@@ -1252,7 +1287,10 @@ bool leftScopeMatch(const QCString &scope, const QCString &name)
}
-void linkifyText(const TextGeneratorIntf &out,Definition *scope,FileDef *fileScope,const char * /*name*/,const char *text,bool autoBreak,bool external)
+void linkifyText(const TextGeneratorIntf &out,Definition *scope,
+ FileDef *fileScope,const char *,
+ const char *text, bool autoBreak,bool external,
+ bool keepSpaces)
{
//printf("`%s'\n",text);
static QRegExp regExp("[a-z_A-Z][a-z_A-Z0-9:]*");
@@ -1290,20 +1328,20 @@ void linkifyText(const TextGeneratorIntf &out,Definition *scope,FileDef *fileSco
if (i==-1) i=splitText.find(' ');
if (i!=-1) // add a link-break at i in case of Html output
{
- out.writeString(splitText.left(i+1));
+ out.writeString(splitText.left(i+1),keepSpaces);
out.writeBreak();
- out.writeString(splitText.right(splitLength-i-1));
+ out.writeString(splitText.right(splitLength-i-1),keepSpaces);
}
else
{
- out.writeString(splitText);
+ out.writeString(splitText,keepSpaces);
}
floatingIndex=splitLength-i-1;
}
else
{
//ol.docify(txtStr.mid(skipIndex,newIndex-skipIndex));
- out.writeString(txtStr.mid(skipIndex,newIndex-skipIndex));
+ out.writeString(txtStr.mid(skipIndex,newIndex-skipIndex),keepSpaces);
}
// get word from string
QCString word=txtStr.mid(newIndex,matchLen);
@@ -1370,7 +1408,7 @@ void linkifyText(const TextGeneratorIntf &out,Definition *scope,FileDef *fileSco
if (!found) // add word to the result
{
//ol.docify(word);
- out.writeString(word);
+ out.writeString(word,keepSpaces);
}
// set next start point in the string
//printf("index=%d/%d\n",index,txtStr.length());
@@ -1379,7 +1417,7 @@ void linkifyText(const TextGeneratorIntf &out,Definition *scope,FileDef *fileSco
}
// add last part of the string to the result.
//ol.docify(txtStr.right(txtStr.length()-skipIndex));
- out.writeString(txtStr.right(txtStr.length()-skipIndex));
+ out.writeString(txtStr.right(txtStr.length()-skipIndex),keepSpaces);
}
diff --git a/src/util.h b/src/util.h
index 248f640..9223696 100644
--- a/src/util.h
+++ b/src/util.h
@@ -57,7 +57,7 @@ class Definition;
class TextGeneratorIntf
{
public:
- virtual void writeString(const char *) const = 0;
+ virtual void writeString(const char *,bool) const = 0;
virtual void writeBreak() const = 0;
virtual void writeLink(const char *extRef,const char *file,
const char *anchor,const char *text
@@ -68,7 +68,7 @@ class TextGeneratorOLImpl : public TextGeneratorIntf
{
public:
TextGeneratorOLImpl(OutputDocInterface &od);
- void writeString(const char *s) const;
+ void writeString(const char *s,bool keepSpaces) const;
void writeBreak() const;
void writeLink(const char *extRef,const char *file,
const char *anchor,const char *text
@@ -85,7 +85,8 @@ void linkifyText(const TextGeneratorIntf &ol,
const char *name,
const char *text,
bool autoBreak=FALSE,
- bool external=TRUE
+ bool external=TRUE,
+ bool keepSpaces=FALSE
);
void setAnchors(ClassDef *cd,char id,MemberList *ml,int groupId=-1);
QCString fileToString(const char *name,bool filter=FALSE);
diff --git a/src/xmldocvisitor.cpp b/src/xmldocvisitor.cpp
index a128a00..ae853b4 100644
--- a/src/xmldocvisitor.cpp
+++ b/src/xmldocvisitor.cpp
@@ -445,7 +445,9 @@ void XmlDocVisitor::visitPost(DocSimpleListItem *)
void XmlDocVisitor::visitPre(DocSection *s)
{
if (m_hide) return;
- m_t << "<sect" << s->level() << " id=\"" << s->id() << "\">" << endl;
+ m_t << "<sect" << s->level() << " id=\"" << s->file();
+ if (!s->anchor().isEmpty()) m_t << "_1" << s->anchor();
+ m_t << "\">" << endl;
m_t << "<title>";
filter(s->title());
m_t << "</title>" << endl;
diff --git a/src/xmlgen.cpp b/src/xmlgen.cpp
index ef45139..aca2094 100644
--- a/src/xmlgen.cpp
+++ b/src/xmlgen.cpp
@@ -153,7 +153,7 @@ class TextGeneratorXMLImpl : public TextGeneratorIntf
{
public:
TextGeneratorXMLImpl(QTextStream &t): m_t(t) {}
- void writeString(const char *s) const
+ void writeString(const char *s,bool /*keepSpaces*/) const
{
writeXMLString(m_t,s);
}