summaryrefslogtreecommitdiffstats
path: root/src/htmldocvisitor.cpp
diff options
context:
space:
mode:
authordimitri <dimitri@afe2bf4a-e733-0410-8a33-86f594647bc7>2003-04-30 19:40:09 (GMT)
committerdimitri <dimitri@afe2bf4a-e733-0410-8a33-86f594647bc7>2003-04-30 19:40:09 (GMT)
commita9f41d99f3651cd66850e9020bc3af7cb559306e (patch)
tree88964bce49d3ab4b0f329d945d43a87b443ed019 /src/htmldocvisitor.cpp
parentebd0447bcc5d3d75214c847954bfda1d2e8c97f5 (diff)
downloadDoxygen-a9f41d99f3651cd66850e9020bc3af7cb559306e.zip
Doxygen-a9f41d99f3651cd66850e9020bc3af7cb559306e.tar.gz
Doxygen-a9f41d99f3651cd66850e9020bc3af7cb559306e.tar.bz2
Release-1.3-20030430
Diffstat (limited to 'src/htmldocvisitor.cpp')
-rw-r--r--src/htmldocvisitor.cpp17
1 files changed, 6 insertions, 11 deletions
diff --git a/src/htmldocvisitor.cpp b/src/htmldocvisitor.cpp
index 353194b..c234a8a 100644
--- a/src/htmldocvisitor.cpp
+++ b/src/htmldocvisitor.cpp
@@ -263,23 +263,18 @@ void HtmlDocVisitor::visit(DocIncOperator *op)
void HtmlDocVisitor::visit(DocFormula *f)
{
if (m_hide) return;
- if (f->text().at(0)=='\\') m_t << "<p><center>" << endl;
- m_t << "<img align=";
-#if !defined(_WIN32)
- m_t << "\"top\""; // assume Unix users use Netscape 4.x which does
- // not seem to support align == "middle" :-((
-#else
- m_t << "\"middle\""; // assume Windows users use IE or HtmlHelp which on
- // displays formulas nicely with align == "middle"
-#endif
+ bool bDisplay = f->text().at(0)=='\\';
+ if (bDisplay) m_t << "<p class=formulaDsp>" << endl;
+ m_t << "<img class=formula"
+ << (bDisplay ? "Dsp" : "Inl");
m_t << " alt=\"";
filterQuotedCdataAttr(f->text());
m_t << "\"";
/// @todo cache image dimensions on formula generation and give height/width
/// for faster preloading and better rendering of the page
m_t << " src=\"" << f->name() << ".png\">";
- if (f->text().at(0)=='\\')
- m_t << endl << "</center><p>" << endl;
+ if (bDisplay)
+ m_t << endl << "<p>" << endl;
else
m_t << " ";
}