summaryrefslogtreecommitdiffstats
path: root/Doc/texinputs/python.sty
diff options
context:
space:
mode:
Diffstat (limited to 'Doc/texinputs/python.sty')
-rw-r--r--Doc/texinputs/python.sty1
1 files changed, 1 insertions, 0 deletions
diff --git a/Doc/texinputs/python.sty b/Doc/texinputs/python.sty
index d37682e..7a1c219 100644
--- a/Doc/texinputs/python.sty
+++ b/Doc/texinputs/python.sty
@@ -796,6 +796,7 @@
% but only if we actually used hyperref:
\ifpdf
\newcommand{\url}[1]{{%
+ \noindent%
\pdfstartlink attr{/Border [0 0 0]} user{/S /URI /URI (#1)}%
\py@LinkColor% color of the link text
\small\sf #1%
mmand, which is typically found in + another comment block. The main purpose of this pair of + commands is to (conditionally) exclude part of a file from processing + (in older version of doxygen this could only be achieved using C preprocessor commands). + + The section between \\condnot and \\endcond commands can be excluded by + adding its section label to the \ref cfg_enabled_sections "ENABLED_SECTIONS" + configuration option. + + For conditional sections within a comment block one should + use a \ref cmdif "\\if" ... \ref cmdendif "\\endif" block. + + Conditional sections can be nested. In this case a nested section will only + be shown if it and its containing section are included. + + \sa section \ref cmdcond "\\cond" and section \ref cmdendcond "\\endcond".
\section cmdcopyright \\copyright { copyright description } @@ -1197,9 +1220,9 @@ contains \c TEST, or \c DEV \section cmdendcond \\endcond \addindex \\endcond - Ends a conditional section that was started by \ref cmdcond "\\cond". + Ends a conditional section that was started by \ref cmdcond "\\cond" or \ref cmdcondnot "\\condnot". - \sa section \ref cmdcond "\\cond". + \sa section \ref cmdcond "\\cond" and section \ref cmdcondnot "\\condnot".
\section cmdendif \\endif diff --git a/doc/customize.doc b/doc/customize.doc index 610f8f4..b035826 100644 --- a/doc/customize.doc +++ b/doc/customize.doc @@ -109,12 +109,19 @@ This will create 3 files: a HTML page. Also here special commands can be used. This file contain the link to www.doxygen.org and the body and html end tags. - customdoxygen.css is the default cascading style sheet - used by doxygen. + used by doxygen. It is recommended only to look into this file and overrule + some settings you like by putting them in a separate stylesheet and + referencing that extra file + via \ref cfg_html_extra_stylesheet "HTML_EXTRA_STYLESHEET". You should edit these files and then reference them from the config file. - \ref cfg_html_header "HTML_HEADER" = \c header.html - \ref cfg_html_footer "HTML_FOOTER" = \c footer.html -- \ref cfg_html_stylesheet "HTML_STYLESHEET" = \c customdoxygen.css +- \ref cfg_html_stylesheet "HTML_STYLESHEET" = \c customdoxygen.css ←obsolete + +\note it is not longer recommended to use HTML_STYLESHEET this way, +as it make it difficult to upgrade to a newer version of doxygen. Use +\ref cfg_html_extra_stylesheet "HTML_EXTRA_STYLESHEET" instead. See the documentation of the \ref cfg_html_header "HTML_HEADER" tag for more information about the possible meta commands you can use inside diff --git a/doc/faq.doc b/doc/faq.doc index 0475aa7..cc8a9a4 100644 --- a/doc/faq.doc +++ b/doc/faq.doc @@ -80,7 +80,7 @@ document either the class or namespace.
  • How can I make doxygen ignore some code fragment? The new and easiest way is to add one comment block -with a \ref cmdcond "\\cond" command at the start and one comment block +with a \ref cmdcond "\\cond" or \ref cmdcondnot "\\condnot" command at the start and one comment block with a \ref cmdendcond "\\endcond" command at the end of the piece of code that should be ignored. This should be within the same file of course. diff --git a/doc/language.doc b/doc/language.doc index 83a0bfa..6052537 100644 --- a/doc/language.doc +++ b/doc/language.doc @@ -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 configuration file (with default name and known as Doxyfile). -Currently (version 1.8.1.2), 39 languages +Currently (version 1.8.2), 39 languages are supported (sorted alphabetically): Afrikaans, Arabic, Armenian, Brazilian Portuguese, Catalan, Chinese, Chinese Traditional, Croatian, Czech, Danish, Dutch, English, diff --git a/doc/translator_report.txt b/doc/translator_report.txt index 83f020a..a50ef27 100644 --- a/doc/translator_report.txt +++ b/doc/translator_report.txt @@ -1,4 +1,4 @@ -(1.8.1.2) +(1.8.2) Doxygen supports the following 39 languages (sorted alphabetically): diff --git a/qtools/qarray.h b/qtools/qarray.h index 90dcbb7..3d67fe9 100644 --- a/qtools/qarray.h +++ b/qtools/qarray.h @@ -55,19 +55,19 @@ protected: public: QArray() {} - QArray( int size ) : QGArray(size*sizeof(type)) {} + QArray( int size ) : QGArray(size*(int)sizeof(type)) {} QArray( const QArray &a ) : QGArray(a) {} ~QArray() {} QArray &operator=(const QArray &a) { return (QArray&)QGArray::assign(a); } type *data() const { return (type *)QGArray::data(); } uint nrefs() const { return QGArray::nrefs(); } - uint size() const { return QGArray::size()/sizeof(type); } + uint size() const { return QGArray::size()/(int)sizeof(type); } uint count() const { return size(); } bool isEmpty() const { return QGArray::size() == 0; } bool isNull() const { return QGArray::data() == 0; } - bool resize( uint size ) { return QGArray::resize(size*sizeof(type)); } - bool truncate( uint pos ) { return QGArray::resize(pos*sizeof(type)); } + bool resize( uint size ) { return QGArray::resize(size*(int)sizeof(type)); } + bool truncate( uint pos ) { return QGArray::resize(pos*(int)sizeof(type)); } bool fill( const type &d, int size = -1 ) { return QGArray::fill((char*)&d,size,sizeof(type) ); } void detach() { QGArray::detach(); } @@ -94,9 +94,9 @@ public: int bsearch( const type &d ) const { return QGArray::bsearch((const char*)&d,sizeof(type)); } type& operator[]( int i ) const - { return (type &)(*(type *)QGArray::at(i*sizeof(type))); } + { return (type &)(*(type *)QGArray::at(i*(int)sizeof(type))); } type& at( uint i ) const - { return (type &)(*(type *)QGArray::at(i*sizeof(type))); } + { return (type &)(*(type *)QGArray::at(i*(int)sizeof(type))); } operator const type*() const { return (const type *)QGArray::data(); } bool operator==( const QArray &a ) const { return isEqual(a); } bool operator!=( const QArray &a ) const { return !isEqual(a); } diff --git a/qtools/qbuffer.cpp b/qtools/qbuffer.cpp index beed0ba..f68ef54 100644 --- a/qtools/qbuffer.cpp +++ b/qtools/qbuffer.cpp @@ -375,7 +375,7 @@ int QBuffer::readLine( char *p, uint maxlen ) break; } *p = '\0'; - ioIndex = d - a.data(); + ioIndex = (int)(d - a.data()); return (uint)ioIndex - start; } diff --git a/qtools/qdatastream.cpp b/qtools/qdatastream.cpp index 7f63cbf..8505dd4 100644 --- a/qtools/qdatastream.cpp +++ b/qtools/qdatastream.cpp @@ -412,7 +412,7 @@ static Q_INT32 read_int_ascii( QDataStream *s ) n++; } buf[n] = '\0'; - return atol( buf ); + return (Q_INT32)atol( buf ); } diff --git a/qtools/qdir.cpp b/qtools/qdir.cpp index d0c1233..120abe7 100644 --- a/qtools/qdir.cpp +++ b/qtools/qdir.cpp @@ -1184,7 +1184,7 @@ int qt_cmp_si( const void *n1, const void *n2 ) if ( r == 0 ) { // Enforce an order - the order the items appear in the array - r = (char*)n1 - (char*)n2; + r = (int)((char*)n1 - (char*)n2); } if ( qt_cmp_si_sortSpec & QDir::Reversed ) diff --git a/qtools/qfile_unix.cpp b/qtools/qfile_unix.cpp index fa53d13..0422fb4 100644 --- a/qtools/qfile_unix.cpp +++ b/qtools/qfile_unix.cpp @@ -403,7 +403,7 @@ uint QFile::size() const } else { STAT( QFile::encodeName(fn), &st ); } - return st.st_size; + return (uint)st.st_size; } /*! @@ -500,13 +500,13 @@ int QFile::readBlock( char *p, uint len ) if ( nread < (int)len ) { if ( isRaw() ) { // raw file - nread += READ( fd, p, len-nread ); + nread += (int)READ( fd, p, len-nread ); if ( len && nread <= 0 ) { nread = 0; setStatus(IO_ReadError); } } else { // buffered file - nread += fread( p, 1, len-nread, fh ); + nread += (int)fread( p, 1, len-nread, fh ); if ( (uint)nread != len ) { if ( ferror( fh ) || nread==0 ) setStatus(IO_ReadError); @@ -552,9 +552,9 @@ int QFile::writeBlock( const char *p, uint len ) #endif int nwritten; // number of bytes written if ( isRaw() ) // raw file - nwritten = WRITE( fd, p, len ); + nwritten = (int)WRITE( fd, p, len ); else // buffered file - nwritten = fwrite( p, 1, len, fh ); + nwritten = (int)fwrite( p, 1, len, fh ); if ( nwritten != (int)len ) { // write error if ( errno == ENOSPC ) // disk is full setStatus( IO_ResourceError ); @@ -661,7 +661,7 @@ bool QFile::seek( int64 pos ) if (isOpen()) { // TODO: support 64 bit size - return fseek( fh, pos, SEEK_SET )!=-1; + return fseek( fh, (long)pos, SEEK_SET )!=-1; } return FALSE; } diff --git a/qtools/qfileinfo_unix.cpp b/qtools/qfileinfo_unix.cpp index 5a8fe04..f2b438c 100644 --- a/qtools/qfileinfo_unix.cpp +++ b/qtools/qfileinfo_unix.cpp @@ -124,7 +124,7 @@ QString QFileInfo::readLink() const char s[PATH_MAX+1]; if ( !isSymLink() ) return QString(); - int len = readlink( QFile::encodeName(fn).data(), s, PATH_MAX ); + int len = (int)readlink( QFile::encodeName(fn).data(), s, PATH_MAX ); if ( len >= 0 ) { s[len] = '\0'; r = QFile::decodeName(s); @@ -297,7 +297,7 @@ QDateTime QFileInfo::lastModified() const if ( !fic || !cache ) doStat(); if ( fic ) - dt.setTime_t( fic->st.st_mtime ); + dt.setTime_t( (uint)fic->st.st_mtime ); return dt; } @@ -316,7 +316,7 @@ QDateTime QFileInfo::lastRead() const if ( !fic || !cache ) doStat(); if ( fic ) - dt.setTime_t( fic->st.st_atime ); + dt.setTime_t( (uint)fic->st.st_atime ); return dt; } diff --git a/qtools/qregexp.cpp b/qtools/qregexp.cpp index 2b3770c..fcc8f11 100644 --- a/qtools/qregexp.cpp +++ b/qtools/qregexp.cpp @@ -525,7 +525,7 @@ static int matchstring( uint *rxd, const char *str, uint strlength, while ( p >= first_p ) { // go backwards int end = matchstring( d, p, pl, bol, cs ); if ( end >= 0 ) - return ( p - start ) + end; + return ( (int)(p - start) ) + end; if ( !p ) return -1; --p; @@ -587,7 +587,7 @@ static int matchstring( uint *rxd, const char *str, uint strlength, while ( p >= first_p ) { // go backwards int end = matchstring( d, p, pl, bol, cs ); if ( end >= 0 ) - return ( p - start ) + end; + return ( (int)(p - start) ) + end; if ( !p ) return -1; --p; @@ -600,7 +600,7 @@ static int matchstring( uint *rxd, const char *str, uint strlength, return -1; } } - return p - start; + return (int)(p - start); } @@ -1043,7 +1043,7 @@ void QRegExp::compile() error = PatSyntax; return; } - int ddiff = d - prev_d; + int ddiff = (int)(d - prev_d); if ( *p == '+' ) { // convert to Kleene closure if ( d + ddiff >= rxarray + maxlen ) { error = PatOverflow; // pattern too long @@ -1082,7 +1082,7 @@ void QRegExp::compile() } } GEN( END ); - int len = d - rxarray; + int len = (int)(d - rxarray); rxdata = new uint[ len ]; // copy from rxarray to rxdata CHECK_PTR( rxdata ); memcpy( rxdata, rxarray, len*sizeof(uint) ); diff --git a/qtools/qstring.cpp b/qtools/qstring.cpp index 889e936..11187f6 100644 --- a/qtools/qstring.cpp +++ b/qtools/qstring.cpp @@ -13535,7 +13535,7 @@ QString &QString::insert( uint index, const QChar* s, uint len ) uint olen = length(); int nlen = olen + len; - int df = s - d->unicode; // ### pointer subtraction, cast down to int + int df = (int)(s - d->unicode); // ### pointer subtraction, cast down to int if ( df >= 0 && (uint)df < d->maxl ) { // Part of me - take a copy. QChar *tmp = QT_ALLOC_QCHAR_VEC( len ); @@ -13679,7 +13679,7 @@ QString &QString::replace( uint index, uint len, const QChar* s, uint slen ) real_detach(); memcpy( d->unicode+index, s, len*sizeof(QChar) ); } else { - int df = s - d->unicode; // ### pointer subtraction, cast down to int + int df = (int)(s - d->unicode); // ### pointer subtraction, cast down to int if ( df >= 0 && (uint)df < d->maxl ) { // Part of me - take a copy. QChar *tmp = QT_ALLOC_QCHAR_VEC( slen ); @@ -15017,7 +15017,7 @@ QDataStream &operator<<( QDataStream &s, const QString &str ) if ( ub || s.version() < 3 ) { if ( QChar::networkOrdered() == (s.byteOrder()==QDataStream::BigEndian) ) { - s.writeBytes( ub, sizeof(QChar)*str.length() ); + s.writeBytes( ub, (int)sizeof(QChar)*str.length() ); } else { static const uint auto_size = 1024; char t[auto_size]; @@ -15034,7 +15034,7 @@ QDataStream &operator<<( QDataStream &s, const QString &str ) *c++ = ub[0]; ub+=sizeof(QChar); } - s.writeBytes( b, sizeof(QChar)*str.length() ); + s.writeBytes( b, (int)sizeof(QChar)*str.length() ); if ( str.length()*sizeof(QChar) > auto_size ) delete [] b; } diff --git a/qtools/qtextcodec.cpp b/qtools/qtextcodec.cpp index 4eb8ba5..bb8bff4 100644 --- a/qtools/qtextcodec.cpp +++ b/qtools/qtextcodec.cpp @@ -931,11 +931,11 @@ static int getByte(char* &cursor) int byte = 0; if ( *cursor ) { if ( cursor[1] == 'x' ) - byte = strtol(cursor+2,&cursor,16); + byte = (int)strtol(cursor+2,&cursor,16); else if ( cursor[1] == 'd' ) - byte = strtol(cursor+2,&cursor,10); + byte = (int)strtol(cursor+2,&cursor,10); else - byte = strtol(cursor+2,&cursor,8); + byte = (int)strtol(cursor+2,&cursor,8); } return byte&0xff; } @@ -1017,7 +1017,7 @@ public: cursor[2]>='0' && cursor[2]<='9' && cursor[3]>='0' && cursor[3]<='9') { - unicode = strtol(cursor+2,&cursor,16); + unicode = (int)strtol(cursor+2,&cursor,16); } else if (*cursor==esc) { diff --git a/qtools/qtextstream.cpp b/qtools/qtextstream.cpp index b12f86d..21b455e 100644 --- a/qtools/qtextstream.cpp +++ b/qtools/qtextstream.cpp @@ -308,7 +308,7 @@ bool QStringBuffer::open( int m ) s->truncate( 0 ); } if ( m & IO_Append ) { // append to end of buffer - ioIndex = s->length()*sizeof(QChar); + ioIndex = s->length()*(int)sizeof(QChar); } else { ioIndex = 0; } @@ -331,7 +331,7 @@ void QStringBuffer::flush() uint QStringBuffer::size() const { - return s ? s->length()*sizeof(QChar) : 0; + return s ? s->length()*(int)sizeof(QChar) : 0; } int QStringBuffer::at() const @@ -916,7 +916,7 @@ QTextStream &QTextStream::writeBlock( const char* p, uint len ) QChar *u = new QChar[len]; for (uint i=0; iwriteBlock( (char*)u, len*sizeof(QChar) ); + dev->writeBlock( (char*)u, len*(int)sizeof(QChar) ); delete [] u; } else { for (uint i=0; iwriteBlock( (char*)p, sizeof(QChar)*len ); + dev->writeBlock( (char*)p, (int)sizeof(QChar)*len ); } else { for (uint i=0; i #include #endif +#include #include #include @@ -118,6 +119,13 @@ void QThread::start() QMutexLocker locker(&d->mutex); if (d->running) return; + // Block the SIGINT signal. The threads will inherit the signal mask. + // This will avoid them catching SIGINT instead of this thread. + sigset_t sigset, oldset; + sigemptyset(&sigset); + sigaddset(&sigset, SIGINT); + pthread_sigmask(SIG_BLOCK, &sigset, &oldset); + d->running = TRUE; d->finished = FALSE; @@ -142,6 +150,11 @@ void QThread::start() d->finished = FALSE; d->thread_id = 0; } + else + { + // Restore the old signal mask only for this thread. + pthread_sigmask(SIG_SETMASK, &oldset, NULL); + } } void QThread::terminate() @@ -182,7 +195,7 @@ int QThread::idealThreadCount() int cores = -1; #if defined(_OS_MAC_) // Mac OS X - cores = MPProcessorsScheduled(); + cores = (int)MPProcessorsScheduled(); #elif defined(_OS_HPUX_) // HP-UX struct pst_dynamic psd; diff --git a/qtools/qutfcodec.cpp b/qtools/qutfcodec.cpp index b0caa76..c7094ad 100644 --- a/qtools/qutfcodec.cpp +++ b/qtools/qutfcodec.cpp @@ -65,7 +65,7 @@ QCString QUtf8Codec::fromUnicode(const QString& uc, int& len_in_out) const *cursor++ = 0x80 | (ch.cell()&0x3f); } } - len_in_out = cursor - (uchar*)rstr.data(); + len_in_out = (int)(cursor - (uchar*)rstr.data()); rstr.truncate(len_in_out); return rstr; } @@ -201,13 +201,13 @@ public: QCString fromUnicode(const QString& uc, int& len_in_out) { if ( headerdone ) { - len_in_out = uc.length()*sizeof(QChar); + len_in_out = uc.length()*(int)sizeof(QChar); QCString d(len_in_out); memcpy(d.data(),uc.unicode(),len_in_out); return d; } else { headerdone = TRUE; - len_in_out = (1+uc.length())*sizeof(QChar); + len_in_out = (1+uc.length())*(int)sizeof(QChar); QCString d(len_in_out); memcpy(d.data(),&QChar::byteOrderMark,sizeof(QChar)); memcpy(d.data()+sizeof(QChar),uc.unicode(),uc.length()*sizeof(QChar)); diff --git a/src/cite.cpp b/src/cite.cpp index 96e88ae..5612eb4 100644 --- a/src/cite.cpp +++ b/src/cite.cpp @@ -45,7 +45,7 @@ CiteDict::CiteDict(int size) : m_entries(size, FALSE) m_entries.setAutoDelete(TRUE); } -static QCString getListOfBibFiles(const QCString &sep,bool stripExtension) +static QCString getListOfBibFiles(const QCString &sep,bool namesOnly) { QCString result; QStrList &citeDataList = Config_getList("CITE_BIB_FILES"); @@ -54,17 +54,24 @@ static QCString getListOfBibFiles(const QCString &sep,bool stripExtension) { int i; QCString bibFile = bibdata; - if (stripExtension && bibFile.right(4)==".bib") + if (namesOnly && bibFile.right(4)==".bib") // strip extension { bibFile = bibFile.left(bibFile.length()-4); } - if (stripExtension && (i=bibFile.findRev('/'))!=-1) + if ((i=bibFile.findRev('/'))!=-1) // strip path { bibFile = bibFile.mid(i+1); } if (!bibFile.isEmpty()) { - result+=bibFile; + if (namesOnly) // bare names + { + result+=bibFile; + } + else // add quotes for paths with spaces + { + result+="\""+bibFile+"\""; + } bibdata = citeDataList.next(); if (bibdata) { @@ -162,12 +169,52 @@ void CiteDict::generatePage() const f.writeBlock(bstData, bstData.length()); f.close(); - // 4. run bib2xhtml perl script on the generated file which will insert the + // 4. for html we just copy the bib files to the output so that + // bibtex can find them without path (bibtex doesn't support path's + // with spaces!) + QList tempFiles; + tempFiles.setAutoDelete(TRUE); + QDir thisDir; + if (Config_getBool("GENERATE_HTML")) + { + // copy bib files to the latex output dir + QStrList &citeDataList = Config_getList("CITE_BIB_FILES"); + QCString bibOutputDir = outputDir+"/"; + QFileInfo fo(bibOutputDir); + const char *bibdata = citeDataList.first(); + while (bibdata) + { + QCString bibFile = bibdata; + if (!bibFile.isEmpty() && bibFile.right(4)!=".bib") bibFile+=".bib"; + QFileInfo fi(bibFile); + if (fi.exists() && fi.dirPath(TRUE)!=fo.absFilePath()) + { + if (!bibFile.isEmpty()) + { + QCString destFile=bibOutputDir+fi.fileName().data(); + copyFile(bibFile,destFile); + tempFiles.append(new QCString(destFile)); + } + } + else if (!fi.exists()) + { + err("Error: bib file %s not found!\n",bibFile.data()); + } + bibdata = citeDataList.next(); + } + } + + QCString oldDir = convertToQCString(QDir::currentDirPath()); + QDir::setCurrent(outputDir); + + // 5. run bib2xhtml perl script on the generated file which will insert the // bibliography in citelist.doc - portable_system("perl",bib2xhtmlFile+" "+getListOfBibFiles(" ",FALSE)+" "+ - citeListFile); + portable_system("perl","\""+bib2xhtmlFile+"\" "+getListOfBibFiles(" ",FALSE)+" \""+ + citeListFile+"\""); - // 5. read back the file + QDir::setCurrent(oldDir); + + // 6. read back the file f.setName(citeListFile); if (!f.open(IO_ReadOnly)) { @@ -212,11 +259,11 @@ void CiteDict::generatePage() const } //printf("doc=[%s]\n",doc.data()); - // 6. add it as a page + // 7. add it as a page addRelatedPage(CiteConsts::fileName, theTranslator->trCiteReferences(),doc,0,CiteConsts::fileName,1,0,0,0); - // 7. for latex we just copy the bib files to the output and let + // 8. for latex we just copy the bib files to the output and let // latex do this work. if (Config_getBool("GENERATE_LATEX")) { @@ -244,11 +291,14 @@ void CiteDict::generatePage() const } } - // 8. Remove temporary files - QDir thisDir; - thisDir.remove(citeListFile); - thisDir.remove(doxygenBstFile); - thisDir.remove(bib2xhtmlFile); - + // 9. Remove temporary files + //thisDir.remove(citeListFile); + //thisDir.remove(doxygenBstFile); + //thisDir.remove(bib2xhtmlFile); + //while (!tempFiles.isEmpty()) + //{ + // QCString *s=tempFiles.take(); + // thisDir.remove(*s); + //} } diff --git a/src/classdef.cpp b/src/classdef.cpp index bf95dbb..3dd562e 100644 --- a/src/classdef.cpp +++ b/src/classdef.cpp @@ -1507,6 +1507,7 @@ void ClassDef::writeSummaryLinks(OutputList &ol) for (li.toFirst();li.current();++li) { ol.writeSummaryLink(0,li.current()->data(),li.current()->data(),first); + first=FALSE; } } if (!first) @@ -2997,6 +2998,7 @@ void ClassDef::addUsedClass(ClassDef *cd,const char *accessName, Protection prot) { static bool extractPrivate = Config_getBool("EXTRACT_PRIVATE"); + static bool umlLook = Config_getBool("UML_LOOK"); if (prot==Private && !extractPrivate) return; //printf("%s::addUsedClass(%s,%s)\n",name().data(),cd->name().data(),accessName); if (m_impl->usesImplClassDict==0) @@ -3012,13 +3014,25 @@ void ClassDef::addUsedClass(ClassDef *cd,const char *accessName, //printf("Adding used class %s to class %s via accessor %s\n", // cd->name().data(),name().data(),accessName); } - ucd->addAccessor(accessName); + QCString acc = accessName; + if (umlLook) + { + switch(prot) + { + case Public: acc.prepend("+"); break; + case Private: acc.prepend("-"); break; + case Protected: acc.prepend("#"); break; + case Package: acc.prepend("~"); break; + } + } + ucd->addAccessor(acc); } void ClassDef::addUsedByClass(ClassDef *cd,const char *accessName, Protection prot) { static bool extractPrivate = Config_getBool("EXTRACT_PRIVATE"); + static bool umlLook = Config_getBool("UML_LOOK"); if (prot==Private && !extractPrivate) return; //printf("%s::addUsedByClass(%s,%s)\n",name().data(),cd->name().data(),accessName); if (m_impl->usedByImplClassDict==0) @@ -3034,7 +3048,18 @@ void ClassDef::addUsedByClass(ClassDef *cd,const char *accessName, //printf("Adding used by class %s to class %s\n", // cd->name().data(),name().data()); } - ucd->addAccessor(accessName); + QCString acc = accessName; + if (umlLook) + { + switch(prot) + { + case Public: acc.prepend("+"); break; + case Private: acc.prepend("-"); break; + case Protected: acc.prepend("#"); break; + case Package: acc.prepend("~"); break; + } + } + ucd->addAccessor(acc); } diff --git a/src/code.l b/src/code.l index d365c7c..9930f8a 100644 --- a/src/code.l +++ b/src/code.l @@ -565,7 +565,7 @@ static void codifyLines(const char *text) { g_yyLineNr++; //*(p-1)='\0'; - int l = p-sp-1; + int l = (int)(p-sp-1); char *tmp = (char*)malloc(l+1); memcpy(tmp,sp,l); tmp[l]='\0'; diff --git a/src/commentcnv.l b/src/commentcnv.l index 6da02db..e9fc74b 100644 --- a/src/commentcnv.l +++ b/src/commentcnv.l @@ -41,6 +41,12 @@ #define ADDCHAR(c) g_outBuf->addChar(c) #define ADDARRAY(a,s) g_outBuf->addArray(a,s) +enum GuardType +{ + Guard_Cond, + Guard_CondNot +}; + struct CondCtx { CondCtx(int line,QCString id,bool b) @@ -77,6 +83,7 @@ static bool g_lastEscaped; static int g_lastBlockContext; static bool g_pythonDocString; +static GuardType guardType; // kind of guard for conditional section static SrcLangExt g_lang; @@ -118,7 +125,7 @@ static void replaceCommentMarker(const char *s,int len) ADDCHAR(' '); } // copy comment line to output - ADDARRAY(p,len-(p-s)); + ADDARRAY(p,len-(int)(p-s)); } static inline int computeIndent(const char *s) @@ -172,14 +179,29 @@ static inline void copyToOutput(const char *s,int len) static void startCondSection(const char *sectId) { g_condStack.push(new CondCtx(g_lineNr,sectId,g_skip)); - if (Config_getList("ENABLED_SECTIONS").find(sectId)!=-1) + if (guardType == Guard_Cond) { - //printf("*** Section is enabled!\n"); + if (Config_getList("ENABLED_SECTIONS").find(sectId)!=-1) + { + //printf("*** Section is enabled!\n"); + } + else + { + //printf("*** Section is disabled!\n"); + g_skip=TRUE; + } } - else + else if (guardType == Guard_CondNot) { - //printf("*** Section is disabled!\n"); - g_skip=TRUE; + if (Config_getList("ENABLED_SECTIONS").find(sectId)!=-1) + { + //printf("*** Section is disabled!\n"); + g_skip=TRUE; + } + else + { + //printf("*** Section is enabled!\n"); + } } } @@ -660,6 +682,12 @@ void replaceComment(int offset); } [\\@]"cond"[ \t]+ { // conditional section g_condCtx = YY_START; + guardType = Guard_Cond; + BEGIN(CondLine); + } +[\\@]"condnot"[ \t]+ { // conditional section + g_condCtx = YY_START; + guardType = Guard_CondNot; BEGIN(CondLine); } [\\@]"endcond"/[^a-z_A-Z0-9] { // end of conditional section @@ -700,6 +728,7 @@ void replaceComment(int offset); [ \t]* [\\@]"cond"[ \t\r]*/\n | . { // forgot section id? + guardType = Guard_Cond; if (YY_START!=CondLine) g_condCtx=YY_START; bool oldSkip=g_skip; startCondSection(" "); // fake section id causing the section to be hidden unconditionally diff --git a/src/commentscan.l b/src/commentscan.l index 2d814eb..21f6f1c 100644 --- a/src/commentscan.l +++ b/src/commentscan.l @@ -1044,9 +1044,9 @@ RCSTAG "$"{ID}":"[^\n$]+"$" // rule matched. // for flex 2.5.33+ we should use YY_CURRENT_BUFFER_LVALUE #if YY_FLEX_MINOR_VERSION>=5 && YY_FLEX_SUBMINOR_VERSION>=33 - inputPosition=prevPosition + yy_bp - YY_CURRENT_BUFFER_LVALUE->yy_ch_buf; + inputPosition=prevPosition + (int)(yy_bp - YY_CURRENT_BUFFER_LVALUE->yy_ch_buf); #else - inputPosition=prevPosition + yy_bp - yy_current_buffer->yy_ch_buf; + inputPosition=prevPosition + (int)(yy_bp - yy_current_buffer->yy_ch_buf); #endif yyterminate(); } @@ -1106,9 +1106,9 @@ RCSTAG "$"{ID}":"[^\n$]+"$" parseMore=TRUE; needNewEntry = TRUE; #if YY_FLEX_MINOR_VERSION>=5 && YY_FLEX_SUBMINOR_VERSION>=33 - inputPosition=prevPosition + yy_bp - YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + strlen(yytext); + inputPosition=prevPosition + (int)(yy_bp - YY_CURRENT_BUFFER_LVALUE->yy_ch_buf) + strlen(yytext); #else - inputPosition=prevPosition + yy_bp - yy_current_buffer->yy_ch_buf + strlen(yytext); + inputPosition=prevPosition + (int)(yy_bp - yy_current_buffer->yy_ch_buf) + strlen(yytext); #endif yyterminate(); } @@ -2848,7 +2848,7 @@ static int findExistingGroup(int &groupId,const MemberGroupInfo *info) ) { //printf("Found it!\n"); - return di.currentKey(); // put the item in this group + return (int)di.currentKey(); // put the item in this group } } groupId++; // start new group diff --git a/src/config.xml b/src/config.xml index e0caa16..410f732 100644 --- a/src/config.xml +++ b/src/config.xml @@ -284,11 +284,11 @@ Doxygen will parse them like normal C++ but will assume all classes use public instead of private inheritance when no explicit protection keyword is present. ' defval='0'/>
  • \n"); diff --git a/src/definition.h b/src/definition.h index 563fb61..ed447fe 100644 --- a/src/definition.h +++ b/src/definition.h @@ -38,6 +38,8 @@ struct SectionInfo; class Definition; class DefinitionImpl; + + /** Data associated with a detailed description. */ struct DocInfo { @@ -382,4 +384,12 @@ class DefinitionListIterator : public QListIterator ~DefinitionListIterator() {} }; +/** Reads a fragment from file \a fileName starting with line \a startLine + * and ending with line \a endLine. The result is returned as a string + * via \a result. The function returns TRUE if successful and FALSE + * in case of an error. + */ +bool readCodeFragment(const char *fileName, + int &startLine,int &endLine, + QCString &result); #endif diff --git a/src/diagram.cpp b/src/diagram.cpp index b675b8d..67f63a0 100644 --- a/src/diagram.cpp +++ b/src/diagram.cpp @@ -606,7 +606,7 @@ void TreeDiagram::drawBoxes(FTextStream &t,Image *image, while (dr && !done) { int x=0,y=0; - float xf=0.0,yf=0.0; + float xf=0.0f,yf=0.0f; DiagramItem *di=dr->first(); if (di->isInList()) // put boxes in a list { @@ -623,8 +623,8 @@ void TreeDiagram::drawBoxes(FTextStream &t,Image *image, } else { - if (doBase) yf += 1.0; - else yf -= 1.0; + if (doBase) yf += 1.0f; + else yf -= 1.0f; } } else @@ -736,7 +736,7 @@ void TreeDiagram::drawConnectors(FTextStream &t,Image *image, if (di->isInList()) // row consists of list connectors { int x=0,y=0,ys=0; - float xf=0.0,yf=0.0,ysf=0.0; + float xf=0.0f,yf=0.0f,ysf=0.0f; while (di) { DiagramItem *pi=di->parentItem(); @@ -808,12 +808,12 @@ void TreeDiagram::drawConnectors(FTextStream &t,Image *image, if (doBase) { ysf = di->yPos()/(float)gridHeight+superRows-1; - yf = ysf + 0.5; + yf = ysf + 0.5f; } else { - ysf = (float)superRows-0.25-di->yPos()/(float)gridHeight; - yf = ysf - 0.25; + ysf = (float)superRows-0.25f-di->yPos()/(float)gridHeight; + yf = ysf - 0.25f; } } while (di!=last) // more children to add @@ -841,12 +841,12 @@ void TreeDiagram::drawConnectors(FTextStream &t,Image *image, if (doBase) { t << "1 " << xf << " " << yf << " hedge\n"; - yf += 1.0; + yf += 1.0f; } else { t << "0 " << xf << " " << yf << " hedge\n"; - yf -= 1.0; + yf -= 1.0f; } } di=dr->next(); @@ -1092,9 +1092,9 @@ void ClassDiagram::writeFigure(FTextStream &output,const char *path, uint estWidth = cols*(20+QMAX(baseMaxLabelWidth,superMaxLabelWidth)); //printf("Estimated size %d x %d\n",estWidth,estHeight); - const float pageWidth = 14.0; // estimated page width in cm. - // Somewhat lower to deal with estimation - // errors. + const float pageWidth = 14.0f; // estimated page width in cm. + // Somewhat lower to deal with estimation + // errors. // compute the image height in centimeters based on the estimates float realHeight = QMIN(rows,12); // real height in cm diff --git a/src/dirdef.cpp b/src/dirdef.cpp index ad403f0..e45aff9 100644 --- a/src/dirdef.cpp +++ b/src/dirdef.cpp @@ -34,7 +34,7 @@ DirDef::DirDef(const char *path) : Definition(path,1,path) } setLocalName(m_shortName); m_dispName = fullPathNames ? stripFromPath(path) : m_shortName; - if (m_dispName.at(m_dispName.length()-1)=='/') + if (m_dispName.length()>0 && m_dispName.at(m_dispName.length()-1)=='/') { // strip trailing / m_dispName = m_dispName.left(m_dispName.length()-1); } @@ -648,7 +648,7 @@ DirDef *DirDef::mergeDirectoryInTree(const QCString &path) while ((i=path.find('/',p))!=-1) { QCString part=path.left(i+1); - if (!matchPath(part,Config_getList("STRIP_FROM_PATH")) && part!="/") + if (!matchPath(part,Config_getList("STRIP_FROM_PATH")) && (part!="/" && part!="//")) { dir=createNewDir(part); } diff --git a/src/docparser.cpp b/src/docparser.cpp index e7a6261..02153f6 100644 --- a/src/docparser.cpp +++ b/src/docparser.cpp @@ -43,6 +43,7 @@ #include "portable.h" #include "cite.h" #include "arguments.h" +#include "vhdldocgen.h" // debug off #define DBG(x) do {} while(0) @@ -5399,6 +5400,7 @@ int DocPara::handleCommand(const QCString &cmdName) m_children.append(new DocVerbatim(this,g_context,g_token->verb,DocVerbatim::Msc,g_isExample,g_exampleName)); if (retval==0) warn_doc_error(g_fileName,doctokenizerYYlineno,"warning: msc section ended without end marker"); doctokenizerYYsetStatePara(); + VhdlDocGen::createFlowChart(g_memberDef); } break; case CMD_ENDCODE: diff --git a/src/docparser.h b/src/docparser.h index e1a630e..2fe68af 100644 --- a/src/docparser.h +++ b/src/docparser.h @@ -504,7 +504,7 @@ class DocIndexEntry : public DocNode { public: DocIndexEntry(DocNode *parent,Definition *scope,MemberDef *md) - : m_scope(scope), m_member(md) { m_parent = parent; } + : m_scope(scope), m_member(md){ m_parent = parent; } Kind kind() const { return Kind_IndexEntry; } int parse(); Definition *scope() const { return m_scope; } diff --git a/src/docsets.cpp b/src/docsets.cpp index e851383..2f0770b 100644 --- a/src/docsets.cpp +++ b/src/docsets.cpp @@ -263,7 +263,8 @@ void DocSets::addContentsItem(bool isDir, } } -void DocSets::addIndexItem(Definition *context,MemberDef *md,const char *) +void DocSets::addIndexItem(Definition *context,MemberDef *md, + const char *,const char *) { if (md==0 && context==0) return; diff --git a/src/docsets.h b/src/docsets.h index 799e289..8cf1d3d 100644 --- a/src/docsets.h +++ b/src/docsets.h @@ -49,7 +49,8 @@ class DocSets : public IndexIntf bool addToNavIndex, Definition *def ); - void addIndexItem(Definition *context,MemberDef *md,const char *title); + void addIndexItem(Definition *context,MemberDef *md, + const char *sectionAnchor,const char *title); void addIndexFile(const char *name); void addImageFile(const char *) {} void addStyleSheetFile(const char *) {} diff --git a/src/dot.cpp b/src/dot.cpp index 39bc844..adad589 100644 --- a/src/dot.cpp +++ b/src/dot.cpp @@ -1408,7 +1408,6 @@ bool DotManager::run() return TRUE; } - //-------------------------------------------------------------------- @@ -1682,6 +1681,18 @@ static void writeBoxMemberList(FTextStream &t, } } +static QCString stripProtectionPrefix(const QCString &s) +{ + if (!s.isEmpty() && (s[0]=='-' || s[0]=='+' || s[0]=='~' || s[0]=='#')) + { + return s.mid(1); + } + else + { + return s; + } +} + void DotNode::writeBox(FTextStream &t, GraphType gt, GraphOutputFormat /*format*/, @@ -1698,18 +1709,29 @@ void DotNode::writeBox(FTextStream &t, if (m_classDef && umlLook && (gt==Inheritance || gt==Collaboration)) { - // add names shown as relation to a dictionary, so we don't show + // add names shown as relations to a dictionary, so we don't show // them as attributes as well QDict arrowNames(17); if (m_edgeInfo) { + // for each edge QListIterator li(*m_edgeInfo); EdgeInfo *ei; for (li.toFirst();(ei=li.current());++li) { - if (!ei->m_label.isEmpty()) + if (!ei->m_label.isEmpty()) // labels joined by \n { - arrowNames.insert(ei->m_label,(void*)0x8); + int li=ei->m_label.find('\n'); + int p=0; + QCString lab; + while ((li=ei->m_label.find('\n',p))!=-1) + { + lab = stripProtectionPrefix(ei->m_label.mid(p,li-p)); + arrowNames.insert(lab,(void*)0x8); + p=li+1; + } + lab = stripProtectionPrefix(ei->m_label.right(ei->m_label.length()-p)); + arrowNames.insert(lab,(void*)0x8); } } } diff --git a/src/doxygen.cpp b/src/doxygen.cpp index afb2205..4397e77 100644 --- a/src/doxygen.cpp +++ b/src/doxygen.cpp @@ -4542,9 +4542,18 @@ static bool findClassRelation( { baseClass=new ClassDef(root->fileName,root->startLine, baseClassName,ClassDef::Class); - Doxygen::classSDict->append(baseClassName,baseClass); + //Doxygen::classSDict->append(baseClassName,baseClass); if (isArtificial) baseClass->setArtificial(TRUE); baseClass->setLanguage(root->lang); + int si = baseClassName.findRev("::"); + if (si!=-1) // class is nested + { + Definition *sd = findScopeFromQualifiedName(Doxygen::globalScope,baseClassName.left(si)); + if (sd==0 || sd==Doxygen::globalScope) // outer scope not found + { + baseClass->setArtificial(TRUE); // see bug678139 + } + } } } if (biName.right(2)=="-p") @@ -7430,7 +7439,6 @@ static void buildCompleteMemberLists() static void generateFileSources() { - if (documentedHtmlFiles==0) return; if (Doxygen::inputNameList->count()>0) { FileNameListIterator fnli(*Doxygen::inputNameList); @@ -9869,6 +9877,7 @@ static void stopDoxygen(int) { thisDir.remove(Doxygen::objDBFileName); } + killpg(0,SIGINT); exit(1); } #endif diff --git a/src/doxygen.css b/src/doxygen.css index ec994dd..de6fd81 100644 --- a/src/doxygen.css +++ b/src/doxygen.css @@ -1,4 +1,4 @@ -/* The standard CSS for doxygen */ +/* The standard CSS for doxygen $doxygenversion */ body, table, div, p, dl { font: 400 14px/19px Roboto,sans-serif; @@ -791,6 +791,14 @@ table.fieldtable { width: 100%; } +.fieldtable td.fielddoc p:first-child { + margin-top: 2px; +} + +.fieldtable td.fielddoc p:last-child { + margin-bottom: 2px; +} + .fieldtable tr:last-child td { border-bottom: none; } diff --git a/src/doxygen_css.h b/src/doxygen_css.h index cb8d69f..64a9f25 100644 --- a/src/doxygen_css.h +++ b/src/doxygen_css.h @@ -1,4 +1,4 @@ -"/* The standard CSS for doxygen */\n" +"/* The standard CSS for doxygen $doxygenversion */\n" "\n" "body, table, div, p, dl {\n" " font: 400 14px/19px Roboto,sans-serif;\n" @@ -791,6 +791,14 @@ " width: 100%;\n" "}\n" "\n" +".fieldtable td.fielddoc p:first-child {\n" +" margin-top: 2px;\n" +"} \n" +" \n" +".fieldtable td.fielddoc p:last-child {\n" +" margin-bottom: 2px;\n" +"}\n" +"\n" ".fieldtable tr:last-child td {\n" " border-bottom: none;\n" "}\n" diff --git a/src/dynsections.js b/src/dynsections.js index 116542f..ed092c7 100644 --- a/src/dynsections.js +++ b/src/dynsections.js @@ -44,24 +44,43 @@ function toggleLevel(level) }); updateStripes(); } -function toggleFolder(id) + +function toggleFolder(id) { - var n = $('[id^=row_'+id+']'); - var i = $('[id^=img_'+id+']'); - var a = $('[id^=arr_'+id+']'); - var c = n.slice(1); - if (c.filter(':first').is(':visible')===true) { - i.attr('src','ftv2folderclosed.png'); - a.attr('src','ftv2pnode.png'); - c.hide(); - } else { - i.attr('src','ftv2folderopen.png'); - a.attr('src','ftv2mnode.png'); - c.show(); + //The clicked row + var currentRow = $('#row_'+id); + var currentRowImages = currentRow.find("img"); + + //All rows after the clicked row + var rows = currentRow.nextAll("tr"); + + //Only match elements AFTER this one (can't hide elements before) + var childRows = rows.filter(function() { + var re = new RegExp('^row_'+id+'\\d+_$', "i"); //only one sub + return this.id.match(re); + }); + + //First row is visible we are HIDING + if (childRows.filter(':first').is(':visible')===true) { + currentRowImages.filter("[id^=arr]").attr('src', 'ftv2pnode.png'); + currentRowImages.filter("[id^=img]").attr('src', 'ftv2folderclosed.png'); + rows.filter("[id^=row_"+id+"]").hide(); + } else { //We are SHOWING + //All sub images + var childImages = childRows.find("img"); + var childImg = childImages.filter("[id^=img]"); + var childArr = childImages.filter("[id^=arr]"); + + currentRow.find("[id^=arr]").attr('src', 'ftv2mnode.png'); //open row + currentRow.find("[id^=img]").attr('src', 'ftv2folderopen.png'); //open row + childImg.attr('src','ftv2folderclosed.png'); //children closed + childArr.attr('src','ftv2pnode.png'); //children closed + childRows.show(); //show all children } updateStripes(); } + function toggleInherit(id) { var rows = $('tr.inherit.'+id); diff --git a/src/dynsections_js.h b/src/dynsections_js.h index c2f5767..c2fba04 100644 --- a/src/dynsections_js.h +++ b/src/dynsections_js.h @@ -44,24 +44,43 @@ " });\n" " updateStripes();\n" "}\n" -"function toggleFolder(id) \n" +"\n" +"function toggleFolder(id)\n" "{\n" -" var n = $('[id^=row_'+id+']');\n" -" var i = $('[id^=img_'+id+']');\n" -" var a = $('[id^=arr_'+id+']');\n" -" var c = n.slice(1);\n" -" if (c.filter(':first').is(':visible')===true) {\n" -" i.attr('src','ftv2folderclosed.png');\n" -" a.attr('src','ftv2pnode.png');\n" -" c.hide();\n" -" } else {\n" -" i.attr('src','ftv2folderopen.png');\n" -" a.attr('src','ftv2mnode.png');\n" -" c.show();\n" +" //The clicked row\n" +" var currentRow = $('#row_'+id);\n" +" var currentRowImages = currentRow.find(\"img\");\n" +"\n" +" //All rows after the clicked row\n" +" var rows = currentRow.nextAll(\"tr\");\n" +"\n" +" //Only match elements AFTER this one (can't hide elements before)\n" +" var childRows = rows.filter(function() {\n" +" var re = new RegExp('^row_'+id+'\\\\d+_$', \"i\"); //only one sub\n" +" return this.id.match(re);\n" +" });\n" +"\n" +" //First row is visible we are HIDING\n" +" if (childRows.filter(':first').is(':visible')===true) {\n" +" currentRowImages.filter(\"[id^=arr]\").attr('src', 'ftv2pnode.png');\n" +" currentRowImages.filter(\"[id^=img]\").attr('src', 'ftv2folderclosed.png');\n" +" rows.filter(\"[id^=row_\"+id+\"]\").hide();\n" +" } else { //We are SHOWING\n" +" //All sub images\n" +" var childImages = childRows.find(\"img\");\n" +" var childImg = childImages.filter(\"[id^=img]\");\n" +" var childArr = childImages.filter(\"[id^=arr]\");\n" +"\n" +" currentRow.find(\"[id^=arr]\").attr('src', 'ftv2mnode.png'); //open row\n" +" currentRow.find(\"[id^=img]\").attr('src', 'ftv2folderopen.png'); //open row\n" +" childImg.attr('src','ftv2folderclosed.png'); //children closed\n" +" childArr.attr('src','ftv2pnode.png'); //children closed\n" +" childRows.show(); //show all children\n" " }\n" " updateStripes();\n" "}\n" "\n" +"\n" "function toggleInherit(id)\n" "{\n" " var rows = $('tr.inherit.'+id);\n" diff --git a/src/eclipsehelp.cpp b/src/eclipsehelp.cpp index 71db4ab..7a4052d 100644 --- a/src/eclipsehelp.cpp +++ b/src/eclipsehelp.cpp @@ -189,6 +189,7 @@ void EclipseHelp::addContentsItem( void EclipseHelp::addIndexItem( Definition * /* context */, MemberDef * /* md */, + const char * /* sectionAnchor */, const char * /* title */) { } diff --git a/src/eclipsehelp.h b/src/eclipsehelp.h index 2531a9f..489aa98 100644 --- a/src/eclipsehelp.h +++ b/src/eclipsehelp.h @@ -52,7 +52,8 @@ class EclipseHelp : public IndexIntf virtual void addContentsItem(bool isDir, const char *name, const char *ref, const char *file, const char *anchor,bool separateIndex,bool addToNavIndex, Definition *def); - virtual void addIndexItem(Definition *context,MemberDef *md,const char *title); + virtual void addIndexItem(Definition *context,MemberDef *md, + const char *sectionAnchor,const char *title); virtual void addIndexFile(const char *name); virtual void addImageFile(const char *name); virtual void addStyleSheetFile(const char *name); diff --git a/src/filedef.cpp b/src/filedef.cpp index 41d564d..a2040ca 100644 --- a/src/filedef.cpp +++ b/src/filedef.cpp @@ -807,7 +807,7 @@ void FileDef::writeSource(OutputList &ol) { startFile(ol,getSourceFileBase(),0,pageTitle,HLI_FileVisible, !generateTreeView, - !isDocFile && genSourceFile ? 0 : getOutputFileBase()); + !isDocFile && genSourceFile ? QCString() : getOutputFileBase()); if (!generateTreeView) { getDirDef()->writeNavigationPath(ol); @@ -820,7 +820,7 @@ void FileDef::writeSource(OutputList &ol) else { startFile(ol,getSourceFileBase(),0,pageTitle,HLI_FileVisible,FALSE, - !isDocFile && genSourceFile ? 0 : getOutputFileBase()); + !isDocFile && genSourceFile ? QCString() : getOutputFileBase()); startTitle(ol,getSourceFileBase()); ol.parseText(title); endTitle(ol,getSourceFileBase(),0); @@ -1173,13 +1173,15 @@ bool FileDef::isIncluded(const QCString &name) const bool FileDef::generateSourceFile() const { + static bool sourceBrowser = Config_getBool("SOURCE_BROWSER"); + static bool verbatimHeaders = Config_getBool("VERBATIM_HEADERS"); QCString extension = name().right(4); return !isReference() && - (Config_getBool("SOURCE_BROWSER") || - (Config_getBool("VERBATIM_HEADERS") && guessSection(name())==Entry::HEADER_SEC) + (sourceBrowser || + (verbatimHeaders && guessSection(name())==Entry::HEADER_SEC) ) && extension!=".doc" && extension!=".txt" && extension!=".dox" && - extension!=".md" && extension!=".markdown"; + extension!=".md" && name().right(9)!=".markdown"; } @@ -1526,7 +1528,7 @@ void FileDef::acquireFileVersion() } const int bufSize=1024; char buf[bufSize]; - int numRead = fread(buf,1,bufSize,f); + int numRead = (int)fread(buf,1,bufSize,f); portable_pclose(f); if (numRead>0 && !(fileVersion=QCString(buf,numRead).stripWhiteSpace()).isEmpty()) { diff --git a/src/fortranscanner.l b/src/fortranscanner.l index e214217..938d182 100644 --- a/src/fortranscanner.l +++ b/src/fortranscanner.l @@ -220,7 +220,7 @@ static void newLine(); //----------------------------------------------------------------------------- #undef YY_INPUT #define YY_INPUT(buf,result,max_size) result=yyread(buf,max_size); -#define YY_USER_ACTION yyColNr+=yyleng; +#define YY_USER_ACTION yyColNr+=(int)yyleng; //----------------------------------------------------------------------------- %} @@ -312,8 +312,8 @@ PREFIX (RECURSIVE{BS_}|PURE{BS_}|ELEMENTAL{BS_}){0,2}(RECURSIVE|PURE|ELEMENTA //fprintf(stderr, "---%s", yytext); - int indexStart = getAmpersandAtTheStart(yytext, yyleng); - int indexEnd = getAmpOrExclAtTheEnd(yytext, yyleng); + int indexStart = getAmpersandAtTheStart(yytext, (int)yyleng); + int indexEnd = getAmpOrExclAtTheEnd(yytext, (int)yyleng); if (indexEnd>=0 && yytext[indexEnd]!='&') //we are only interested in amp indexEnd=-1; @@ -362,7 +362,7 @@ PREFIX (RECURSIVE{BS_}|PURE{BS_}|ELEMENTAL{BS_}){0,2}(RECURSIVE|PURE|ELEMENTA initializer+=yytext; } \"|\' { // string ends with next quote without previous backspace - if (yytext[0]!=stringStartSymbol) { yyColNr -= yyleng; REJECT; } // single vs double quote + if (yytext[0]!=stringStartSymbol) { yyColNr -= (int)yyleng; REJECT; } // single vs double quote if (yy_top_state() == Initialization || yy_top_state() == ArrayInitializer) initializer+=yytext; @@ -373,7 +373,7 @@ PREFIX (RECURSIVE{BS_}|PURE{BS_}|ELEMENTAL{BS_}){0,2}(RECURSIVE|PURE|ELEMENTA initializer+=yytext; } <*>\"|\' { /* string starts */ - if (YY_START == StrIgnore) { yyColNr -= yyleng; REJECT; }; // ignore in simple comments + if (YY_START == StrIgnore) { yyColNr -= (int)yyleng; REJECT; }; // ignore in simple comments yy_push_state(YY_START); if (yy_top_state() == Initialization || yy_top_state() == ArrayInitializer) @@ -384,7 +384,7 @@ PREFIX (RECURSIVE{BS_}|PURE{BS_}|ELEMENTAL{BS_}){0,2}(RECURSIVE|PURE|ELEMENTA /*------ ignore simple comment (not documentation comments) */ -<*>"!"/[^<>\n] { if (YY_START == String) { yyColNr -= yyleng; REJECT; } // "!" is ignored in strings +<*>"!"/[^<>\n] { if (YY_START == String) { yyColNr -= (int)yyleng; REJECT; } // "!" is ignored in strings // skip comment line (without docu comments "!>" "!<" ) /* ignore further "!" and ignore comments in Strings */ if ((YY_START != StrIgnore) && (YY_START != String)) @@ -709,7 +709,7 @@ private { } else { - yyColNr -= yyleng; + yyColNr -= (int)yyleng; REJECT; } } @@ -733,10 +733,10 @@ private { {BS} {} {ATTR_SPEC}. { /* update current modifierswhen it is an ATTR_SPEC and not a variable name */ /* bug_625519 */ - QChar chr = yytext[yyleng-1]; + QChar chr = yytext[(int)yyleng-1]; if (chr.isLetter() || chr.isDigit() || (chr == '_')) { - yyColNr -= yyleng; + yyColNr -= (int)yyleng; REJECT; } else @@ -744,7 +744,7 @@ private { QCString tmp = yytext; tmp = tmp.left(tmp.length() - 1); yyColNr -= 1; - unput(yytext[yyleng-1]); + unput(yytext[(int)yyleng-1]); currentModifiers |= (tmp); } } @@ -853,12 +853,12 @@ private { attr += yytext; modifiers[current_root][name.lower()] |= attr; } -{COMMA} { //printf("COMMA: %d<=..<=%d\n", yyColNr-yyleng, yyColNr); +{COMMA} { //printf("COMMA: %d<=..<=%d\n", yyColNr-(int)yyleng, yyColNr); // locate !< comment - updateVariablePrepassComment(yyColNr-yyleng, yyColNr); + updateVariablePrepassComment(yyColNr-(int)yyleng, yyColNr); } {BS}"=" { yy_push_state(YY_START); - initializer=""; + initializer="="; initializerScope = initializerArrayScope = 0; BEGIN(Initialization); } @@ -904,7 +904,7 @@ private { } {COMMA} { if (initializerScope == 0) { - updateVariablePrepassComment(yyColNr-yyleng, yyColNr); + updateVariablePrepassComment(yyColNr-(int)yyleng, yyColNr); yy_pop_state(); // end initialization if (v_type == V_VARIABLE) last_entry->initializer= initializer; } @@ -979,7 +979,7 @@ private { BEGIN(SubprogBody); } {COMMA}|{BS} { current->args += yytext; - CommentInPrepass *c = locatePrepassComment(yyColNr-yyleng, yyColNr); + CommentInPrepass *c = locatePrepassComment(yyColNr-(int)yyleng, yyColNr); if (c!=NULL) { if(current->argList->count()>0) { current->argList->at(current->argList->count()-1)->docs = c->str; @@ -1029,7 +1029,7 @@ private { else { /* handle out of place !< comment as a normal comment */ - if (YY_START == String) { yyColNr -= yyleng; REJECT; } // "!" is ignored in strings + if (YY_START == String) { yyColNr -= (int)yyleng; REJECT; } // "!" is ignored in strings // skip comment line (without docu comments "!>" "!<" ) /* ignore further "!" and ignore comments in Strings */ if ((YY_START != StrIgnore) && (YY_START != String)) diff --git a/src/ftvhelp.cpp b/src/ftvhelp.cpp index 190f3e5..c41ab07 100644 --- a/src/ftvhelp.cpp +++ b/src/ftvhelp.cpp @@ -1296,7 +1296,11 @@ void FTVHelp::generateTreeViewScripts() if (f.open(IO_WriteOnly)) { FTextStream t(&f); - t << replaceColorMarkers(navtree_css); + t << substitute( + replaceColorMarkers(navtree_css), + "$width", + QCString().setNum(Config_getInt("TREEVIEW_WIDTH"))+"px" + ); } } } diff --git a/src/ftvhelp.h b/src/ftvhelp.h index d28b506..be60a60 100644 --- a/src/ftvhelp.h +++ b/src/ftvhelp.h @@ -53,7 +53,7 @@ class FTVHelp : public IndexIntf bool separateIndex, bool addToNavIndex, Definition *def); - void addIndexItem(Definition *,MemberDef *,const char *) {} + void addIndexItem(Definition *,MemberDef *,const char *,const char *) {} void addIndexFile(const char *) {} void addImageFile(const char *) {} void addStyleSheetFile(const char *) {} diff --git a/src/groupdef.cpp b/src/groupdef.cpp index 4f688f1..da35641 100644 --- a/src/groupdef.cpp +++ b/src/groupdef.cpp @@ -948,7 +948,7 @@ void GroupDef::writeDocumentation(OutputList &ol) } } - Doxygen::indexList.addIndexItem(this,0,title); + Doxygen::indexList.addIndexItem(this,0,0,title); if (!Config_getString("GENERATE_TAGFILE").isEmpty()) { diff --git a/src/header.html b/src/header.html index 78730af..0a0194b 100644 --- a/src/header.html +++ b/src/header.html @@ -3,6 +3,7 @@ + $projectname: $title $title diff --git a/src/header_html.h b/src/header_html.h index b8a5d81..505960a 100644 --- a/src/header_html.h +++ b/src/header_html.h @@ -3,6 +3,7 @@ "\n" "\n" "\n" +"\n" "$projectname: $title\n" "$title\n" "\n" diff --git a/src/htmldocvisitor.cpp b/src/htmldocvisitor.cpp index 9ef5f5b..63cda59 100644 --- a/src/htmldocvisitor.cpp +++ b/src/htmldocvisitor.cpp @@ -29,7 +29,7 @@ #include "parserintf.h" #include "msc.h" #include "util.h" - +#include "vhdldocgen.h" static const int NUM_HTML_LIST_TYPES = 4; static const char types[][NUM_HTML_LIST_TYPES] = {"1", "a", "i", "A"}; @@ -476,13 +476,38 @@ void HtmlDocVisitor::visit(DocVerbatim *s) break; case DocVerbatim::Msc: { + forceEndParagraph(s); + +#if 0 // TODO: this should get its own command and not hijack the \msc + // command. This should also work for Latex and RTF output (or at + // least produce valid output there. + static bool optimizeForVhdl = Config_getBool("OPTIMIZE_OUTPUT_VHDL"); + if (optimizeForVhdl) + { + if (VhdlDocGen::getFlowMember()) // use VHDL flow chart creator + { + QCString fname=FlowNode::convertNameToFileName(); + m_t << "
    " << endl; + m_t << "

    "; + m_t << "flowchart:" ; + m_t << ""; + m_t << VhdlDocGen::getFlowMember()->name().data(); + m_t << "

    "; + m_t << s->text().data(); + m_t << "

    "; + VhdlDocGen::setFlowMember(NULL); + } + } +#endif static int mscindex = 1; QCString baseName(4096); baseName.sprintf("%s%d", (Config_getString("HTML_OUTPUT")+"/inline_mscgraph_").data(), mscindex++ - ); + ); QFile file(baseName+".msc"); if (!file.open(IO_WriteOnly)) { @@ -491,17 +516,16 @@ void HtmlDocVisitor::visit(DocVerbatim *s) QCString text = "msc {"; text+=s->text(); text+="}"; + file.writeBlock( text, text.length() ); file.close(); - forceEndParagraph(s); m_t << "
    " << endl; writeMscFile(baseName+".msc",s->relPath(),s->context()); - m_t << "
    " << endl; - forceStartParagraph(s); - if (Config_getBool("DOT_CLEANUP")) file.remove(); } + m_t << "
    " << endl; + forceStartParagraph(s); break; } } @@ -702,7 +726,7 @@ void HtmlDocVisitor::visit(DocIndexEntry *e) // e->scope() ? e->scope()->name().data() : "", // e->member() ? e->member()->name().data() : "" // ); - Doxygen::indexList.addIndexItem(e->scope(),e->member(),e->entry()); + Doxygen::indexList.addIndexItem(e->scope(),e->member(),anchor,e->entry()); } void HtmlDocVisitor::visit(DocSimpleSectSep *) diff --git a/src/htmlgen.cpp b/src/htmlgen.cpp index 93e5f3c..1c612ac 100644 --- a/src/htmlgen.cpp +++ b/src/htmlgen.cpp @@ -117,10 +117,10 @@ static unsigned char tab_a_png[36] = // normal tab background luma static unsigned char tab_b_png[36] = { - 221, 231, 238, 236, 233, 230, 228, 225, 224, - 221, 220, 218, 217, 216, 215, 214, 213, 212, - 212, 194, 195, 196, 197, 198, 199, 200, 201, - 202, 204, 206, 208, 210, 214, 216, 203, 185 + 218, 228, 235, 233, 230, 227, 225, 222, 221, + 218, 217, 215, 214, 213, 212, 211, 210, 209, + 209, 197, 198, 199, 200, 201, 202, 203, 204, + 205, 207, 209, 211, 213, 217, 219, 206, 188 }; // hovering tab background luma @@ -907,7 +907,7 @@ QCString substitute(const char *s,const char *src,const char *dst) { int count; for (count=0, p=s; (q=strstr(p,src))!=0; p=q+srcLen) count++; - resLen = p-s+strlen(p)+count*(dstLen-srcLen); + resLen = (int)(p-s)+strlen(p)+count*(dstLen-srcLen); } else // result has same size as s { @@ -939,7 +939,7 @@ QCString clearBlock(const char *s,const char *begin,const char *end) int resLen = 0; for (p=s; (q=strstr(p,begin))!=0; p=q+endLen) { - resLen+=q-p; + resLen+=(int)(q-p); p=q+beginLen; if ((q=strstr(p,end))==0) { @@ -1500,6 +1500,7 @@ void HtmlGenerator::writeSearchData(const char *dir) { FTextStream t(&f); QCString searchCss = replaceColorMarkers(search_styleSheet); + searchCss = substitute(searchCss,"$doxygenversion",versionString); if (Config_getBool("DISABLE_INDEX")) { // move up the search box if there are no tabs @@ -1513,29 +1514,21 @@ void HtmlGenerator::writeSearchData(const char *dir) void HtmlGenerator::writeStyleSheetFile(QFile &file) { FTextStream t(&file); - t << replaceColorMarkers(defaultStyleSheet); + t << replaceColorMarkers(substitute(defaultStyleSheet,"$doxygenversion",versionString)); } void HtmlGenerator::writeHeaderFile(QFile &file, const char * /*cssname*/) { FTextStream t(&file); + t << "" << endl; QCString contents(defaultHtmlHeader); t << contents; - -// QString relPathStr = "$relpath$"; - -// QCString id(file.name().utf8()); -// if (id.right(Doxygen::htmlFileExtension.length())==Doxygen::htmlFileExtension) -// { -// id=id.left(id.length()-Doxygen::htmlFileExtension.length()); -// } - -// t << substitute(defaultHtmlHeader, "$stylesheet", cssname); } void HtmlGenerator::writeFooterFile(QFile &file) { FTextStream t(&file); + t << "" << endl; QCString contents(defaultHtmlFooter); t << contents; } @@ -1675,7 +1668,7 @@ void HtmlGenerator::writeStyleInfo(int part) //t << "H1 { text-align: center; border-width: thin none thin none;" << endl; //t << " border-style : double; border-color : blue; padding-left : 1em; padding-right : 1em }" << endl; - t << replaceColorMarkers(defaultStyleSheet); + t << replaceColorMarkers(substitute(defaultStyleSheet,"$doxygenversion",versionString)); endPlainFile(); Doxygen::indexList.addStyleSheetFile("doxygen.css"); } diff --git a/src/htmlgen.h b/src/htmlgen.h index a28aa8b..b520c9e 100644 --- a/src/htmlgen.h +++ b/src/htmlgen.h @@ -262,16 +262,21 @@ class HtmlGenerator : public OutputGenerator void endContents(); void writeNonBreakableSpace(int); - void startDescTable() - { t << "" << endl; } + void startDescTable(const char *title) + //{ t << "
    " << endl; } + { t << "
    " << endl + << ""; + } void endDescTable() { t << "
    " << title << "
    " << endl; } void startDescTableTitle() - { t << ""; } + //{ t << ""; } + { t << ""; } void endDescTableTitle() { t << " "; } void startDescTableData() - { t << "" << endl; } + //{ t << "" << endl; } + { t << "" << endl; } void endDescTableData() { t << "" << endl; } diff --git a/src/htmlhelp.cpp b/src/htmlhelp.cpp index 744e86f..3df3774 100644 --- a/src/htmlhelp.cpp +++ b/src/htmlhelp.cpp @@ -621,7 +621,7 @@ QCString HtmlHelp::recode(const QCString &s) char *oPtr = output.data(); if (!portable_iconv(m_fromUtf8,&iPtr,&iLeft,&oPtr,&oLeft)) { - oSize -= oLeft; + oSize -= (int)oLeft; output.resize(oSize+1); output.at(oSize)='\0'; return output; @@ -692,7 +692,7 @@ void HtmlHelp::addContentsItem(bool isDir, void HtmlHelp::addIndexItem(Definition *context,MemberDef *md, - const char *word) + const char *sectionAnchor,const char *word) { if (md) { @@ -712,14 +712,14 @@ void HtmlHelp::addIndexItem(Definition *context,MemberDef *md, QCString level2 = md->name(); QCString contRef = separateMemberPages ? cfname : cfiname; QCString memRef = cfname; - QCString anchor = md->anchor(); + QCString anchor = sectionAnchor ? QCString(sectionAnchor) : md->anchor(); index->addItem(level1,level2,contRef,anchor,TRUE,FALSE); index->addItem(level2,level1,memRef,anchor,TRUE,TRUE); } else if (context) { QCString level1 = word ? QCString(word) : context->name(); - index->addItem(level1,0,context->getOutputFileBase(),0,TRUE,FALSE); + index->addItem(level1,0,context->getOutputFileBase(),sectionAnchor,TRUE,FALSE); } } diff --git a/src/htmlhelp.h b/src/htmlhelp.h index 524f8f1..8c0d317 100644 --- a/src/htmlhelp.h +++ b/src/htmlhelp.h @@ -79,7 +79,8 @@ class HtmlHelp : public IndexIntf bool separateIndex, bool addToNavIndex, Definition *def); - void addIndexItem(Definition *context,MemberDef *md,const char *title); + void addIndexItem(Definition *context,MemberDef *md, + const char *sectionAnchor, const char *title); void addIndexFile(const char *name); void addImageFile(const char *); void addStyleSheetFile(const char *) {} diff --git a/src/index.cpp b/src/index.cpp index 0e5294f..6424e44 100644 --- a/src/index.cpp +++ b/src/index.cpp @@ -1442,12 +1442,13 @@ static void writeNamespaceTree(NamespaceSDict *nsDict,FTVHelp *ftv, { bool hasChildren = containsVisibleChild(nd,showClasses); - + bool isLinkable = nd->isLinkableInProject(); + QCString ref; QCString file; - if (nd->isLinkableInProject()) + if (isLinkable) { - ref = nd->getReference(); + ref = nd->getReference(); file = nd->getOutputFileBase(); if (nd->getLanguage()==SrcLangExt_VHDL) // UGLY HACK { @@ -1455,7 +1456,7 @@ static void writeNamespaceTree(NamespaceSDict *nsDict,FTVHelp *ftv, } } - if (nd->isLinkable() || hasChildren) + if (isLinkable || hasChildren) { ftv->addContentsItem(hasChildren,nd->localName(),ref,file,0,FALSE,TRUE,nd); @@ -3970,7 +3971,7 @@ static void writeIndex(OutputList &ol) { Doxygen::indexList.addContentsItem(Doxygen::mainPage->hasSubPages(),title,0,indexName,0,Doxygen::mainPage->hasSubPages(),TRUE); } - if (Doxygen::mainPage->hasSubPages()) + if (Doxygen::mainPage->hasSubPages() || Doxygen::mainPage->hasSections()) { writePages(Doxygen::mainPage,0); } diff --git a/src/index.h b/src/index.h index 8eb93ce..122a9bb 100644 --- a/src/index.h +++ b/src/index.h @@ -39,7 +39,8 @@ class IndexIntf virtual void addContentsItem(bool isDir, const char *name, const char *ref, const char *file, const char *anchor, bool separateIndex, bool addToNavIndex,Definition *def) = 0; - virtual void addIndexItem(Definition *context,MemberDef *md,const char *title) = 0; + virtual void addIndexItem(Definition *context,MemberDef *md, + const char *sectionAnchor,const char *title) = 0; virtual void addIndexFile(const char *name) = 0; virtual void addImageFile(const char *name) = 0; virtual void addStyleSheetFile(const char *name) = 0; @@ -139,9 +140,9 @@ class IndexList : public IndexIntf Definition *def=0) { if (m_enabled) foreach (&IndexIntf::addContentsItem,isDir,name,ref,file,anchor,separateIndex,addToNavIndex,def); } - void addIndexItem(Definition *context,MemberDef *md,const char *title=0) - { if (m_enabled) foreach - (&IndexIntf::addIndexItem,context,md,title); } + void addIndexItem(Definition *context,MemberDef *md,const char *sectionAnchor=0,const char *title=0) + { if (m_enabled) foreach + (&IndexIntf::addIndexItem,context,md,sectionAnchor,title); } void addIndexFile(const char *name) { if (m_enabled) foreach(&IndexIntf::addIndexFile,name); } void addImageFile(const char *name) diff --git a/src/latexgen.cpp b/src/latexgen.cpp index a0188c8..d57764e 100644 --- a/src/latexgen.cpp +++ b/src/latexgen.cpp @@ -954,6 +954,7 @@ static void writeDefaultFooter(FTextStream &t) void LatexGenerator::writeHeaderFile(QFile &f) { FTextStream t(&f); + t << "% Latex header for doxygen " << versionString << endl; writeDefaultHeaderPart1(t); t << "Your title here"; writeDefaultHeaderPart2(t); @@ -964,12 +965,14 @@ void LatexGenerator::writeHeaderFile(QFile &f) void LatexGenerator::writeFooterFile(QFile &f) { FTextStream t(&f); + t << "% Latex footer for doxygen " << versionString << endl; writeDefaultFooter(t); } void LatexGenerator::writeStyleSheetFile(QFile &f) { FTextStream t(&f); + t << "% stylesheet for doxygen " << versionString << endl; writeDefaultStyleSheetPart1(t); QCString &projectName = Config_getString("PROJECT_NAME"); diff --git a/src/latexgen.h b/src/latexgen.h index f2cc193..1fe92dd 100644 --- a/src/latexgen.h +++ b/src/latexgen.h @@ -198,10 +198,15 @@ class LatexGenerator : public OutputGenerator void endContents() {} void writeNonBreakableSpace(int); - void startDescTable() - { t << "\\begin{description}" << endl; } + void startDescTable(const char *title) + { startSimpleSect(EnumValues,0,0,title); + startDescForItem(); + t << "\\begin{description}" << endl; } void endDescTable() - { t << "\\end{description}" << endl; } + { t << "\\end{description}" << endl; + endDescForItem(); + endSimpleSect(); + } void startDescTableTitle() { t << "\\item[{\\em " << endl; } void endDescTableTitle() diff --git a/src/layout.cpp b/src/layout.cpp index fa4ab42..adfb4e8 100644 --- a/src/layout.cpp +++ b/src/layout.cpp @@ -22,6 +22,7 @@ #include "vhdldocgen.h" #include "util.h" #include "doxygen.h" +#include "version.h" #include #include @@ -1372,7 +1373,7 @@ void writeDefaultLayoutFile(const char *fileName) return; } QTextStream t(&f); - t << layout_default; + t << substitute(layout_default,"$doxygenversion",versionString); } //---------------------------------------------------------------------------------- diff --git a/src/layout_default.h b/src/layout_default.h index 0950a94..d2dfce6 100644 --- a/src/layout_default.h +++ b/src/layout_default.h @@ -1,4 +1,5 @@ "\n" +" \n" " \n" " \n" " \n" diff --git a/src/layout_default.xml b/src/layout_default.xml index 7127664..b0bbec4 100644 --- a/src/layout_default.xml +++ b/src/layout_default.xml @@ -1,4 +1,5 @@ + diff --git a/src/lodepng.cpp b/src/lodepng.cpp index 638dbf4..df8378e 100644 --- a/src/lodepng.cpp +++ b/src/lodepng.cpp @@ -1765,13 +1765,13 @@ static unsigned Crc32_crc_table[256]; /*Make the table for a fast CRC.*/ static void Crc32_make_crc_table(void) { - unsigned c, k, n; + unsigned int c, k, n; for(n = 0; n < 256; n++) { c = n; for(k = 0; k < 8; k++) { - if(c & 1) c = 0xedb88320L ^ (c >> 1); + if(c & 1) c = (unsigned int)(0xedb88320L ^ (c >> 1)); else c = c >> 1; } Crc32_crc_table[n] = c; @@ -1782,9 +1782,9 @@ static void Crc32_make_crc_table(void) /*Update a running CRC with the bytes buf[0..len-1]--the CRC should be initialized to all 1's, and the transmitted value is the 1's complement of the final running CRC (see the crc() routine below).*/ -static unsigned Crc32_update_crc(const unsigned char* buf, unsigned crc, size_t len) +static unsigned Crc32_update_crc(const unsigned char* buf, unsigned int crc, size_t len) { - unsigned c = crc; + unsigned int c = crc; size_t n; if(!Crc32_crc_table_computed) Crc32_make_crc_table(); @@ -1798,7 +1798,7 @@ static unsigned Crc32_update_crc(const unsigned char* buf, unsigned crc, size_t /*Return the CRC of the bytes buf[0..len-1].*/ static unsigned Crc32_crc(const unsigned char* buf, size_t len) { - return Crc32_update_crc(buf, 0xffffffffL, len) ^ 0xffffffffL; + return Crc32_update_crc(buf, 0xffffffffu, len) ^ 0xffffffffu; } /* ////////////////////////////////////////////////////////////////////////// */ diff --git a/src/mangen.h b/src/mangen.h index e2d0965..a4af56c 100644 --- a/src/mangen.h +++ b/src/mangen.h @@ -195,8 +195,9 @@ class ManGenerator : public OutputGenerator void endContents() {} void writeNonBreakableSpace(int n) { int i; for (i=0;i block is put before declaration. ClassDef *category; MemberDef *categoryRelation; + + bool tagDataWritten; }; MemberDefImpl::MemberDefImpl() : @@ -627,6 +629,7 @@ void MemberDefImpl::init(Definition *def, hasDocumentedReturnType = FALSE; docProvider = 0; isDMember = def->getDefFileName().right(2).lower()==".d"; + tagDataWritten = FALSE; } @@ -1336,7 +1339,7 @@ void MemberDef::writeDeclaration(OutputList &ol, bool inGroup,ClassDef *inheritedFrom,const char *inheritId ) { - //printf("%s MemberDef::writeDeclaration() inGroup=%d\n",name().data(),inGroup); + //printf("%s MemberDef::writeDeclaration() inGroup=%d\n",qualifiedName().data(),inGroup); // hide enum value, since they appear already as part of the enum, unless they // are explicitly grouped. @@ -1350,60 +1353,7 @@ void MemberDef::writeDeclaration(OutputList &ol, ASSERT (cd!=0 || nd!=0 || fd!=0 || gd!=0); // member should belong to something if (cd) d=cd; else if (nd) d=nd; else if (fd) d=fd; else d=gd; - // write tag file information of this member - if (!Config_getString("GENERATE_TAGFILE").isEmpty() && !isReference()) - { - Doxygen::tagFile << " mtype) - { - case Define: Doxygen::tagFile << "define"; break; - case EnumValue: Doxygen::tagFile << "enumvalue"; break; - case Property: Doxygen::tagFile << "property"; break; - case Event: Doxygen::tagFile << "event"; break; - case Variable: Doxygen::tagFile << "variable"; break; - case Typedef: Doxygen::tagFile << "typedef"; break; - case Enumeration: Doxygen::tagFile << "enumeration"; break; - case Function: Doxygen::tagFile << "function"; break; - case Signal: Doxygen::tagFile << "signal"; break; - //case Prototype: Doxygen::tagFile << "prototype"; break; - case Friend: Doxygen::tagFile << "friend"; break; - case DCOP: Doxygen::tagFile << "dcop"; break; - case Slot: Doxygen::tagFile << "slot"; break; - } - if (m_impl->prot!=Public) - { - Doxygen::tagFile << "\" protection=\""; - if (m_impl->prot==Protected) Doxygen::tagFile << "protected"; - else if (m_impl->prot==Package) Doxygen::tagFile << "package"; - else /* Private */ Doxygen::tagFile << "private"; - } - if (m_impl->virt!=Normal) - { - Doxygen::tagFile << "\" virtualness=\""; - if (m_impl->virt==Virtual) Doxygen::tagFile << "virtual"; - else /* Pure */ Doxygen::tagFile << "pure"; - } - if (isStatic()) - { - Doxygen::tagFile << "\" static=\"yes"; - } - Doxygen::tagFile << "\">" << endl; - Doxygen::tagFile << " " << convertToXML(typeString()) << "" << endl; - Doxygen::tagFile << " " << convertToXML(name()) << "" << endl; - Doxygen::tagFile << " " << convertToXML(getOutputFileBase()+Doxygen::htmlFileExtension) << "" << endl; - Doxygen::tagFile << " " << convertToXML(anchor()) << "" << endl; - Doxygen::tagFile << " " << convertToXML(argsString()) << "" << endl; - writeDocAnchorsToTagFile(); - Doxygen::tagFile << " " << endl; - } - - // write search index info - if (Doxygen::searchIndex && isLinkableInProject()) - { - Doxygen::searchIndex->setCurrentDoc(this,anchor(),FALSE); - Doxygen::searchIndex->addWord(localName(),TRUE); - Doxygen::searchIndex->addWord(qualifiedName(),FALSE); - } + _writeTagData(); QCString cname = d->name(); QCString cdname = d->displayName(); @@ -2262,9 +2212,9 @@ void MemberDef::_writeEnumValues(OutputList &ol,Definition *container, { if (first) { - ol.startSimpleSect(BaseOutputDocInterface::EnumValues,0,0,theTranslator->trEnumerationValues()+": "); - ol.startDescForItem(); - ol.startDescTable(); + //ol.startSimpleSect(BaseOutputDocInterface::EnumValues,0,0,theTranslator->trEnumerationValues()+": "); + //ol.startDescForItem(); + ol.startDescTable(theTranslator->trEnumerationValues()); } ol.addIndexItem(fmd->name(),ciname); @@ -2294,9 +2244,14 @@ void MemberDef::_writeEnumValues(OutputList &ol,Definition *container, //ol.newParagraph(); ol.startDescTableData(); - if (!fmd->briefDescription().isEmpty()) + bool hasBrief = !fmd->briefDescription().isEmpty(); + bool hasDetails = !fmd->documentation().isEmpty(); + + if (hasBrief) { - ol.parseDoc(fmd->briefFile(),fmd->briefLine(),getOuterScope()?getOuterScope():container,fmd,fmd->briefDescription(),TRUE,FALSE); + ol.parseDoc(fmd->briefFile(),fmd->briefLine(), + getOuterScope()?getOuterScope():container, + fmd,fmd->briefDescription(),TRUE,FALSE); } // FIXME:PARA //if (!fmd->briefDescription().isEmpty() && @@ -2304,9 +2259,11 @@ void MemberDef::_writeEnumValues(OutputList &ol,Definition *container, //{ // ol.newParagraph(); //} - if (!fmd->documentation().isEmpty()) + if (hasDetails) { - ol.parseDoc(fmd->docFile(),fmd->docLine(),getOuterScope()?getOuterScope():container,fmd,fmd->documentation()+"\n",TRUE,FALSE); + ol.parseDoc(fmd->docFile(),fmd->docLine(), + getOuterScope()?getOuterScope():container, + fmd,fmd->documentation()+"\n",TRUE,FALSE); } ol.endDescTableData(); } @@ -2317,9 +2274,9 @@ void MemberDef::_writeEnumValues(OutputList &ol,Definition *container, { //ol.endItemList(); ol.endDescTable(); - ol.endDescForItem(); - ol.endSimpleSect(); - ol.writeChar('\n'); + //ol.endDescForItem(); + //ol.endSimpleSect(); + //ol.writeChar('\n'); } } } @@ -2430,7 +2387,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol, linkifyText(TextGeneratorOLImpl(ol),container,getBodyDef(),this,ldef.left(i)); vmd->writeEnumDeclaration(ol,getClassDef(),getNamespaceDef(),getFileDef(),getGroupDef()); linkifyText(TextGeneratorOLImpl(ol),container,getBodyDef(),this,ldef.right(ldef.length()-i-l)); - + found=TRUE; } } @@ -3376,6 +3333,81 @@ Specifier MemberDef::virtualness(int count) const return v; } +void MemberDef::_writeTagData() +{ + if (m_impl->tagDataWritten) return; + static bool generateTagFile = !Config_getString("GENERATE_TAGFILE").isEmpty(); + // write tag file information of this member + if (generateTagFile && isLinkableInProject()) + { + Doxygen::tagFile << " mtype) + { + case Define: Doxygen::tagFile << "define"; break; + case EnumValue: Doxygen::tagFile << "enumvalue"; break; + case Property: Doxygen::tagFile << "property"; break; + case Event: Doxygen::tagFile << "event"; break; + case Variable: Doxygen::tagFile << "variable"; break; + case Typedef: Doxygen::tagFile << "typedef"; break; + case Enumeration: Doxygen::tagFile << "enumeration"; break; + case Function: Doxygen::tagFile << "function"; break; + case Signal: Doxygen::tagFile << "signal"; break; + case Friend: Doxygen::tagFile << "friend"; break; + case DCOP: Doxygen::tagFile << "dcop"; break; + case Slot: Doxygen::tagFile << "slot"; break; + } + if (m_impl->prot!=Public) + { + Doxygen::tagFile << "\" protection=\""; + if (m_impl->prot==Protected) Doxygen::tagFile << "protected"; + else if (m_impl->prot==Package) Doxygen::tagFile << "package"; + else /* Private */ Doxygen::tagFile << "private"; + } + if (m_impl->virt!=Normal) + { + Doxygen::tagFile << "\" virtualness=\""; + if (m_impl->virt==Virtual) Doxygen::tagFile << "virtual"; + else /* Pure */ Doxygen::tagFile << "pure"; + } + if (isStatic()) + { + Doxygen::tagFile << "\" static=\"yes"; + } + Doxygen::tagFile << "\">" << endl; + Doxygen::tagFile << " " << convertToXML(typeString()) << "" << endl; + Doxygen::tagFile << " " << convertToXML(name()) << "" << endl; + Doxygen::tagFile << " " << convertToXML(getOutputFileBase()+Doxygen::htmlFileExtension) << "" << endl; + Doxygen::tagFile << " " << convertToXML(anchor()) << "" << endl; + Doxygen::tagFile << " " << convertToXML(argsString()) << "" << endl; + writeDocAnchorsToTagFile(); + Doxygen::tagFile << " " << endl; + _addToSearchIndex(); + } + MemberList *fmdl=m_impl->enumFields; + if (fmdl) + { + MemberListIterator mli(*fmdl); + MemberDef *fmd; + for (mli.toFirst();(fmd=mli.current());++mli) + { + if (!fmd->isReference()) + { + if (!Config_getString("GENERATE_TAGFILE").isEmpty()) + { + Doxygen::tagFile << " " << endl; + Doxygen::tagFile << " " << convertToXML(fmd->name()) << "" << endl; + Doxygen::tagFile << " " << convertToXML(getOutputFileBase()+Doxygen::htmlFileExtension) << "" << endl; + Doxygen::tagFile << " " << convertToXML(fmd->anchor()) << "" << endl; + Doxygen::tagFile << " " << convertToXML(fmd->argsString()) << "" << endl; + Doxygen::tagFile << " " << endl; + fmd->_addToSearchIndex(); + } + } + } + } + m_impl->tagDataWritten=TRUE; +} + void MemberDef::_computeIsConstructor() { KEEP_RESIDENT_DURING_CALL; @@ -3503,15 +3535,7 @@ void MemberDef::writeEnumDeclaration(OutputList &typeDecl, { if (isLinkableInProject() || hasDocumentedEnumValues()) { - if (!Config_getString("GENERATE_TAGFILE").isEmpty() && !isReference()) - { - Doxygen::tagFile << " " << endl; - Doxygen::tagFile << " " << convertToXML(name()) << "" << endl; - Doxygen::tagFile << " " << convertToXML(getOutputFileBase()+Doxygen::htmlFileExtension) << "" << endl; - Doxygen::tagFile << " " << convertToXML(anchor()) << "" << endl; - Doxygen::tagFile << " " << convertToXML(argsString()) << "" << endl; - Doxygen::tagFile << " " << endl; - } + _writeTagData(); writeLink(typeDecl,cd,nd,fd,gd); } else @@ -3558,15 +3582,7 @@ void MemberDef::writeEnumDeclaration(OutputList &typeDecl, if (fmd->hasDocumentation()) // enum value has docs { - if (!Config_getString("GENERATE_TAGFILE").isEmpty() && !fmd->isReference()) - { - Doxygen::tagFile << " " << endl; - Doxygen::tagFile << " " << convertToXML(fmd->name()) << "" << endl; - Doxygen::tagFile << " " << convertToXML(getOutputFileBase()+Doxygen::htmlFileExtension) << "" << endl; - Doxygen::tagFile << " " << convertToXML(fmd->anchor()) << "" << endl; - Doxygen::tagFile << " " << convertToXML(fmd->argsString()) << "" << endl; - Doxygen::tagFile << " " << endl; - } + fmd->_writeTagData(); fmd->writeLink(typeDecl,cd,nd,fd,gd); } else // no docs for this enum value @@ -4759,6 +4775,7 @@ void MemberDef::flushToDisk() const marshalBool (Doxygen::symbolStorage,m_impl->docsForDefinition); marshalObjPointer (Doxygen::symbolStorage,m_impl->category); marshalObjPointer (Doxygen::symbolStorage,m_impl->categoryRelation); + marshalBool (Doxygen::symbolStorage,m_impl->tagDataWritten); marshalUInt(Doxygen::symbolStorage,END_MARKER); // function doesn't modify the object conceptually but compiler doesn't know this. @@ -4862,6 +4879,7 @@ void MemberDef::loadFromDisk() const m_impl->docsForDefinition = unmarshalBool (Doxygen::symbolStorage); m_impl->category = (ClassDef*)unmarshalObjPointer (Doxygen::symbolStorage); m_impl->categoryRelation = (MemberDef*)unmarshalObjPointer (Doxygen::symbolStorage); + m_impl->tagDataWritten = unmarshalBool (Doxygen::symbolStorage); marker = unmarshalUInt(Doxygen::symbolStorage); assert(marker==END_MARKER); @@ -4956,6 +4974,23 @@ QCString MemberDef::displayName(bool) const return Definition::name(); } +void MemberDef::_addToSearchIndex() +{ + // write search index info + if (Doxygen::searchIndex && isLinkableInProject()) + { + Doxygen::searchIndex->setCurrentDoc(this,anchor(),FALSE); + QCString ln=localName(),qn=qualifiedName(); + Doxygen::searchIndex->addWord(ln,TRUE); + if (ln!=qn) + { + Doxygen::searchIndex->addWord(qn,TRUE); + } + } +} + + + //---------------- static void transferArgumentDocumentation(ArgumentList *decAl,ArgumentList *defAl) diff --git a/src/memberdef.h b/src/memberdef.h index 8850035..e1db828 100644 --- a/src/memberdef.h +++ b/src/memberdef.h @@ -397,6 +397,8 @@ class MemberDef : public Definition const QCString &cfname,const QCString &ciname, const QCString &cname); void _writeCategoryRelation(OutputList &ol); + void _writeTagData(); + void _addToSearchIndex(); static int s_indentLevel; // disable copying of member defs diff --git a/src/namespacedef.cpp b/src/namespacedef.cpp index 2512502..0bb63a7 100644 --- a/src/namespacedef.cpp +++ b/src/namespacedef.cpp @@ -878,7 +878,7 @@ void NamespaceSDict::writeDeclaration(OutputList &ol,const char *title,bool loca name = nd->displayName(); } ol.writeObjectLink(nd->getReference(),nd->getOutputFileBase(),0,name); - if (!Config_getString("GENERATE_TAGFILE").isEmpty() && !nd->isReference()) + if (!Config_getString("GENERATE_TAGFILE").isEmpty() && nd->isLinkableInProject()) { Doxygen::tagFile << " " << convertToXML(nd->name()) << "" << endl; } diff --git a/src/navtree.css b/src/navtree.css index eb2aa70..a2ae30a 100644 --- a/src/navtree.css +++ b/src/navtree.css @@ -86,7 +86,7 @@ display:block; position: absolute; left: 0px; - width: 300px; + width: $width; } .ui-resizable .ui-resizable-handle { diff --git a/src/navtree_css.h b/src/navtree_css.h index 00a889f..6e42061 100644 --- a/src/navtree_css.h +++ b/src/navtree_css.h @@ -86,7 +86,7 @@ " display:block;\n" " position: absolute;\n" " left: 0px;\n" -" width: 300px;\n" +" width: $width;\n" "}\n" "\n" ".ui-resizable .ui-resizable-handle {\n" diff --git a/src/objcache.cpp b/src/objcache.cpp index a08d649..4258397 100644 --- a/src/objcache.cpp +++ b/src/objcache.cpp @@ -184,7 +184,7 @@ unsigned int ObjCache::hash(void *addr) key ^= (key >> 15); key += ~(key << 27); key ^= (key >> 31); - return key & (m_size-1); + return (unsigned int)(key & (m_size-1)); } else { @@ -196,7 +196,7 @@ unsigned int ObjCache::hash(void *addr) key ^= (key >> 6); key += ~(key << 11); key ^= (key >> 16); - return key & (m_size-1); + return (unsigned int)(key & (m_size-1)); } } diff --git a/src/outputgen.h b/src/outputgen.h index e9e1d25..be9c208 100644 --- a/src/outputgen.h +++ b/src/outputgen.h @@ -245,7 +245,7 @@ class BaseOutputDocInterface : public CodeOutputInterface virtual void addIndexItem(const char *s1,const char *s2) = 0; virtual void writeNonBreakableSpace(int) = 0; - virtual void startDescTable() = 0; + virtual void startDescTable(const char *title) = 0; virtual void endDescTable() = 0; virtual void startDescTableTitle() = 0; virtual void endDescTableTitle() = 0; diff --git a/src/outputlist.h b/src/outputlist.h index 72662a5..784b16b 100644 --- a/src/outputlist.h +++ b/src/outputlist.h @@ -363,8 +363,8 @@ class OutputList : public OutputDocInterface { forall(&OutputGenerator::endContents); } void writeNonBreakableSpace(int num) { forall(&OutputGenerator::writeNonBreakableSpace,num); } - void startDescTable() - { forall(&OutputGenerator::startDescTable); } + void startDescTable(const char *title) + { forall(&OutputGenerator::startDescTable,title); } void endDescTable() { forall(&OutputGenerator::endDescTable); } void startDescTableTitle() diff --git a/src/pagedef.cpp b/src/pagedef.cpp index 1442ce1..0d98184 100644 --- a/src/pagedef.cpp +++ b/src/pagedef.cpp @@ -184,7 +184,7 @@ void PageDef::writeDocumentation(OutputList &ol) } } - Doxygen::indexList.addIndexItem(this,0,filterTitle(title())); + Doxygen::indexList.addIndexItem(this,0,0,filterTitle(title())); } void PageDef::writePageDocumentation(OutputList &ol) diff --git a/src/portable.cpp b/src/portable.cpp index 49f7bf1..bb13ddb 100644 --- a/src/portable.cpp +++ b/src/portable.cpp @@ -198,7 +198,8 @@ void portable_setenv(const char *name,const char *value) { for (ep = environ; *ep; ++ep) { - if (!strncmp (*ep, name, namelen) && (*ep)[namelen] == '=') + if (!strncmp (*ep, name, (uint)namelen) && + (*ep)[namelen] == '=') break; else ++size; @@ -281,7 +282,7 @@ void portable_unsetenv(const char *variable) ep = environ; while (*ep != NULL) { - if (!strncmp(*ep, variable, len) && (*ep)[len]=='=') + if (!strncmp(*ep, variable, (uint)len) && (*ep)[len]=='=') { /* Found it. Remove this pointer by moving later ones back. */ char **dp = ep; diff --git a/src/pre.l b/src/pre.l index 5d00c18..8b8c093 100644 --- a/src/pre.l +++ b/src/pre.l @@ -51,7 +51,11 @@ #include "entry.h" #define YY_NEVER_INTERACTIVE 1 - +enum GuardType +{ + Guard_Cond, + Guard_CondNot +}; struct FileState { @@ -356,6 +360,7 @@ static bool g_isSource; static bool g_lexInit = FALSE; +static GuardType guardType; // kind of guard for conditional section //DefineDict* getGlobalDefineDict() //{ // return g_globalDefineDict; @@ -1651,9 +1656,19 @@ static void readIncludeFile(const QCString &inc) static void startCondSection(const char *sectId) { g_condStack.push(new bool(g_skip)); - if (Config_getList("ENABLED_SECTIONS").find(sectId)==-1) + if (guardType == Guard_Cond) { - g_skip=TRUE; + if (Config_getList("ENABLED_SECTIONS").find(sectId)==-1) + { + g_skip=TRUE; + } + } + else if (guardType == Guard_CondNot) + { + if (Config_getList("ENABLED_SECTIONS").find(sectId)!=-1) + { + g_skip=TRUE; + } } } @@ -1779,12 +1794,12 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) } ^{B}*"#" { BEGIN(Command); } ^{B}*/[^#] { - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); BEGIN(CopyLine); } ^{B}*[_A-Z][_A-Z0-9]*{B}*"("[^\)\n]*")"/{BN}{1,10}*[:{] { // constructors? int i; - for (i=yyleng-1;i>=0;i--) + for (i=(int)yyleng-1;i>=0;i--) { unput(yytext[i]); } @@ -1814,7 +1829,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) else // don't skip { int i; - for (i=yyleng-1;i>=0;i--) + for (i=(int)yyleng-1;i>=0;i--) { unput(yytext[i]); } @@ -1824,7 +1839,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) "extern"{BN}{0,80}"\"C\""*{BN}{0,80}"{" { QCString text=yytext; g_yyLineNr+=text.contains('\n'); - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); } "{" { // count brackets inside the main file if (g_includeStack.isEmpty()) @@ -1841,23 +1856,23 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) outputChar(*yytext); } "'"\\[0-7]{1,3}"'" { - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); } "'"\\."'" { - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); } "'"."'" { - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); } \" { outputChar(*yytext); BEGIN( CopyString ); } [^\"\\\r\n]+ { - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); } \\. { - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); } \" { outputChar(*yytext); @@ -1897,7 +1912,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) } else { - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); } } {ID} { @@ -1915,7 +1930,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) } else { - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); } } "\\"\r?/\n { // strip line continuation characters @@ -2404,7 +2419,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) BEGIN(CopyCComment); } "//"[!/]? { - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); g_lastCPPContext=YY_START; g_defLitText+=' '; BEGIN(SkipCPPComment); @@ -2424,21 +2439,21 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) } } "//"("/")* { - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); } "/*" { outputChar('/');outputChar('*'); //g_commentCount++; } [\\@][\\@]("f{"|"f$"|"f[") { - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); } [\\@][\\@]("verbatim"|"latexonly"|"htmlonly"|"xmlonly"|"rtfonly"|"manonly"|"dot"|"code"){BN}+ { - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); g_yyLineNr+=QCString(yytext).contains('\n'); } [\\@]("verbatim"|"latexonly"|"htmlonly"|"xmlonly"|"rtfonly"|"manonly"|"dot"|"code"){BN}+ { - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); g_yyLineNr+=QCString(yytext).contains('\n'); if (yytext[1]=='f') { @@ -2451,18 +2466,26 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) BEGIN(SkipVerbatim); } [\\@]"cond"[ \t]+ { // conditional section + guardType = Guard_Cond; g_condCtx = YY_START; outputArray(yytext,yyleng); BEGIN(CondLine); } +[\\@]"condnot"[ \t]+ { // conditional section + guardType = Guard_CondNot; + g_condCtx = YY_START; + outputArray(yytext,(int)yyleng); + BEGIN(CondLine); + } [a-z_A-Z][a-z_A-Z0-9.\-]* { startCondSection(yytext); - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); BEGIN(g_condCtx); } [\\@]"cond"[ \t\r]*/\n { + guardType = Guard_Cond; g_condCtx = YY_START; - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); } . { unput(*yytext); @@ -2470,11 +2493,11 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) BEGIN(g_condCtx); } [\\@]"endcond"/[^a-z_A-Z0-9] { - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); endCondSection(); } [\\@]("endverbatim"|"endlatexonly"|"endhtmlonly"|"endxmlonly"|"endrtfonly"|"endmanonly"|"enddot"|"endcode"|"f$"|"f]"|"f}") { /* end of verbatim block */ - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); if (yytext[1]=='f' && g_blockName=="f") { BEGIN(SkipCComment); @@ -2485,10 +2508,10 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) } } "*/"|"/*" { - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); } [^*\\@\x06\n\/]+ { - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); } \n { g_yyLineNr++; @@ -2528,7 +2551,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) \n { g_yyLineNr++; outputChar('\n'); } . [^\n\/\\@]+ { - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); } \n { unput(*yytext); @@ -2541,7 +2564,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) outputChar('/');outputChar('/'); } [^\x06\@\\\n]+ { - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); } . { outputChar(*yytext); @@ -2715,14 +2738,14 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) } <*>"/*"/"*/" | <*>"/*"[*]? { - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); g_lastCContext=YY_START; g_commentCount=1; if (yyleng==3) g_lastGuardName.resize(0); // reset guard in case the #define is documented! BEGIN(SkipCComment); } <*>"//"[/]? { - outputArray(yytext,yyleng); + outputArray(yytext,(int)yyleng); g_lastCPPContext=YY_START; if (yyleng==3) g_lastGuardName.resize(0); // reset guard in case t