--- FeepingCreaturism/Jargon.cpp 2004/09/02 10:41:06 209 +++ FeepingCreaturism/Jargon.cpp 2004/09/06 05:45:32 221 @@ -33,18 +33,13 @@ void Jargon::display(ios::PrintWriter& p xhtml.OpenElement("strong"); xhtml.OutputText(word + ":"); xhtml.CloseElement(); - xhtml.OutputText(" " + pronunciation); - if (!grammar.IsEmpty()) xhtml.OutputText(", " + grammar); + if (!pronunciation.IsEmpty()) xhtml.OutputText(" " + pronunciation); + if (!pronunciation.IsEmpty() && !grammar.IsEmpty()) xhtml.OutputText(","); + if (!grammar.IsEmpty()) xhtml.OutputText(" " + grammar); } - for (xml::NodeSet::ConstIterator node(definition.Begin()); - node != definition.End(); ++node) - { - xml::ScopeElement p(xhtml, "p"); - - xhtml.OutputText(**node); - } + definition.WriteTo(xhtml); } struct Section @@ -59,7 +54,7 @@ ios::PrintWriter& operator<<(ios::PrintW { if (jargon.include) { - xml::TextWriter xhtml(pout); + xml::TextWriter xhtml(pout, false); jargon.display(pout, xhtml); @@ -69,7 +64,7 @@ ios::PrintWriter& operator<<(ios::PrintW pout << "\n"; - xml::TextWriter xhtml(pout); + xml::TextWriter xhtml(pout, false); xml::ScopeElement html(xhtml, "html"); xhtml.SetAttribute("xmlns", "http://www.w3.org/1999/xhtml");