diff options
author | Michi Henning <michi@zeroc.com> | 2006-12-20 07:03:32 +0000 |
---|---|---|
committer | Michi Henning <michi@zeroc.com> | 2006-12-20 07:03:32 +0000 |
commit | 10ca9874264bdc856a2a7ac3d059f9a55e2f720d (patch) | |
tree | 8f2ea33742f61b3370e8dbbb0a3d7ea432fdde54 /cpp/src | |
parent | Added missing doc comment. (diff) | |
download | ice-10ca9874264bdc856a2a7ac3d059f9a55e2f720d.tar.bz2 ice-10ca9874264bdc856a2a7ac3d059f9a55e2f720d.tar.xz ice-10ca9874264bdc856a2a7ac3d059f9a55e2f720d.zip |
More slice2html changes.
Diffstat (limited to 'cpp/src')
-rw-r--r-- | cpp/src/IceUtil/OutputUtil.cpp | 21 | ||||
-rw-r--r-- | cpp/src/slice2docbook/Gen.cpp | 1 | ||||
-rw-r--r-- | cpp/src/slice2html/Gen.cpp | 24 |
3 files changed, 12 insertions, 34 deletions
diff --git a/cpp/src/IceUtil/OutputUtil.cpp b/cpp/src/IceUtil/OutputUtil.cpp index 2d674303f5d..b6cdf3fd533 100644 --- a/cpp/src/IceUtil/OutputUtil.cpp +++ b/cpp/src/IceUtil/OutputUtil.cpp @@ -312,7 +312,6 @@ IceUtil::XMLOutput::XMLOutput() : OutputBase(), _se(false), _text(false), - _sgml(false), _escape(false) { } @@ -321,7 +320,6 @@ IceUtil::XMLOutput::XMLOutput(ostream& os) : OutputBase(os), _se(false), _text(false), - _sgml(false), _escape(false) { } @@ -330,18 +328,11 @@ IceUtil::XMLOutput::XMLOutput(const char* s) : OutputBase(s), _se(false), _text(false), - _sgml(false), _escape(false) { } void -IceUtil::XMLOutput::setSGML(bool sgml) -{ - _sgml = true; -} - -void IceUtil::XMLOutput::print(const char* s) { if(_se) @@ -418,17 +409,7 @@ IceUtil::XMLOutput::endElement() dec(); if(_se) { - // - // SGML (docbook) doesn't support <foo/>. - // - if(_sgml) - { - _out << "></" << element << '>'; - } - else - { - _out << "/>"; - } + _out << "></" << element << '>'; } else { diff --git a/cpp/src/slice2docbook/Gen.cpp b/cpp/src/slice2docbook/Gen.cpp index 9a7cb1f497e..a37d0ea0255 100644 --- a/cpp/src/slice2docbook/Gen.cpp +++ b/cpp/src/slice2docbook/Gen.cpp @@ -40,7 +40,6 @@ Slice::Gen::Gen(const string& name, const string& file, bool standAlone, bool ch cerr << name << ": can't open `" << file << "' for writing: " << strerror(errno) << endl; return; } - O.setSGML(true); } Slice::Gen::~Gen() diff --git a/cpp/src/slice2html/Gen.cpp b/cpp/src/slice2html/Gen.cpp index 6f28b6164b2..33ef2d3fecd 100644 --- a/cpp/src/slice2html/Gen.cpp +++ b/cpp/src/slice2html/Gen.cpp @@ -294,7 +294,7 @@ Slice::GeneratorBase::printComment(const ContainedPtr& p, const string& deprecat if(!deprecateReason.empty()) { - start("p"); + start("p", "Deprecated"); _out << nl << deprecateReason; end(); } @@ -337,7 +337,7 @@ Slice::GeneratorBase::printComment(const ContainedPtr& p, const string& deprecat start("h4"); _out << "Return Value"; end(); - start("p", "Symbol"); + start("p"); _out << ret.front(); end(); } @@ -381,7 +381,7 @@ Slice::GeneratorBase::printComment(const ContainedPtr& p, const string& deprecat } if(!derivedClasses.empty()) { - start("h4", "Heading"); + start("h4"); _out << "Derived Classes and Interfaces"; end(); start("dl"); @@ -418,10 +418,10 @@ Slice::GeneratorBase::printComment(const ContainedPtr& p, const string& deprecat usedBy = p->unit()->findUsedBy(ex); if(!usedBy.empty()) { - start("h4", "Heading"); + start("h4"); _out << "Used By"; end(); - start("dl", "UsedBy"); + start("dl"); // // We first extract the symbol names from the used-by list and sort // them, otherwise the symbols appear in random order. @@ -473,10 +473,10 @@ Slice::GeneratorBase::printComment(const ContainedPtr& p, const string& deprecat strings.sort(); strings.unique(); - start("h4", "Heading"); + start("h4"); _out << "Used By"; end(); - start("dl", "UsedBy"); + start("dl"); for(list<string>::const_iterator p = strings.begin(); p != strings.end(); ++p) { start("dt", "Symbol"); @@ -491,7 +491,7 @@ Slice::GeneratorBase::printComment(const ContainedPtr& p, const string& deprecat start("h4"); _out << "See Also"; end(); - start("dl", "UsedBy"); + start("dl"); for(StringList::const_iterator q = see.begin(); q != see.end(); ++q) { start("dt", "Symbol"); @@ -540,9 +540,7 @@ Slice::GeneratorBase::printSummary(const ContainedPtr& p, const ContainerPtr& mo } string summary = getComment(p, container, true, module); - start("dd", "Summary"); _out << nl << summary; - end(); if(deprecated) { @@ -697,7 +695,7 @@ Slice::GeneratorBase::toString(const SyntaxTreeBasePtr& p, const ContainerPtr& c return s; } - string ret = "<a "; + string ret = "<a class=\"Symbol\" "; ret += (asTarget ? "name" : "href"); ret += "=\""; if(asTarget) @@ -1170,7 +1168,7 @@ Slice::IndexGenerator::~IndexGenerator() start("dl"); for(ModuleDescriptions::const_iterator i = _modules.begin(); i != _modules.end(); ++i) { - start("dt"); + start("dt", "Symbol"); _out << i->first; end(); start("dd"); @@ -1926,7 +1924,7 @@ Slice::StructGenerator::generate(const StructPtr& s) } } - start("h2", "Heading"); + start("h2"); _out << "Overview"; end(); |