diff options
Diffstat (limited to 'src/util.cpp')
-rw-r--r-- | src/util.cpp | 55 |
1 files changed, 51 insertions, 4 deletions
diff --git a/src/util.cpp b/src/util.cpp index 00173fb..4c74493 100644 --- a/src/util.cpp +++ b/src/util.cpp @@ -1741,9 +1741,11 @@ nextChar: } else if (i>0 && ( - (s.at(i-1)==')' && isId(c)) + (s.at(i-1)==')' && isId(c)) // ")id" -> ") id" || - (c=='\'' && s.at(i-1)==' ') + (c=='\'' && s.at(i-1)==' ') // "'id" -> "' id" + || + (i>1 && s.at(i-2)==' ' && s.at(i-1)==' ') // " id" -> " id" ) ) { @@ -2229,6 +2231,11 @@ QCString tempArgListToString(ArgumentList *al,SrcLangExt lang) result+=a->type; } } + if (!a->typeConstraint.isEmpty() && lang==SrcLangExt_Java) + { + result+=" extends "; // TODO: now Java specific, C# has where... + result+=a->typeConstraint; + } ++ali; a=ali.current(); if (a) result+=", "; @@ -6452,6 +6459,8 @@ void filterLatexString(FTextStream &t,const char *str, //printf("filterLatexString(%s)\n",str); //if (strlen(str)<2) stackTrace(); const unsigned char *p=(const unsigned char *)str; + const unsigned char *q; + int cnt; unsigned char c; unsigned char pc='\0'; while (*p) @@ -6478,7 +6487,35 @@ void filterLatexString(FTextStream &t,const char *str, case '$': t << "\\$"; break; case '%': t << "\\%"; break; case '^': t << "$^\\wedge$"; break; - case '&': t << "\\&"; break; + case '&': // possibility to have a special symbol + q = p; + cnt = 2; // we have to count & and ; as well + while ((*q >= 'a' && *q <= 'z') || (*q >= 'A' && *q <= 'Z') || (*q >= '0' && *q <= '9')) + { + cnt++; + q++; + } + if (*q == ';') + { + --p; // we need & as well + DocSymbol::SymType res = HtmlEntityMapper::instance()->name2sym(QCString((char *)p).left(cnt)); + if (res == DocSymbol::Sym_Unknown) + { + p++; + t << "\\&"; + } + else + { + t << HtmlEntityMapper::instance()->latex(res); + q++; + p = q; + } + } + else + { + t << "\\&"; + } + break; case '*': t << "$\\ast$"; break; case '_': if (!insideTabbing) t << "\\+"; t << "\\_"; @@ -7646,8 +7683,12 @@ QCString externalRef(const QCString &relPath,const QCString &ref,bool href) if (!relPath.isEmpty() && l>0 && result.at(0)=='.') { // relative path -> prepend relPath. result.prepend(relPath); + l+=relPath.length(); + } + if (!href){ + result.prepend("doxygen=\""+ref+":"); + l+=10+ref.length(); } - if (!href) result.prepend("doxygen=\""+ref+":"); if (l>0 && result.at(l-1)!='/') result+='/'; if (!href) result.append("\" "); } @@ -8337,3 +8378,9 @@ bool mainPageHasTitle() return TRUE; } +QCString getDotImageExtension(void) +{ + QCString imgExt = Config_getEnum("DOT_IMAGE_FORMAT"); + imgExt = imgExt.replace( QRegExp(":.*"), "" ); + return imgExt; +} |