From 90b4f0ca7b9fe21f6c4b39a80f8f9cf98626690a Mon Sep 17 00:00:00 2001
From: Simon Hausmann
Date: Tue, 19 May 2009 17:53:38 +0200
Subject: Revert "Makes the layout of many of the areas be in aligned columns
to immensely increase readability"
This was pushed accidentially.
This reverts commit ffecdf0bf9f25f7ab9aa4f69e37507dd595fecea.
---
tools/qdoc3/htmlgenerator.cpp | 29 +++++++++++++++++++++--------
1 file changed, 21 insertions(+), 8 deletions(-)
diff --git a/tools/qdoc3/htmlgenerator.cpp b/tools/qdoc3/htmlgenerator.cpp
index 7702628..13d52bf 100644
--- a/tools/qdoc3/htmlgenerator.cpp
+++ b/tools/qdoc3/htmlgenerator.cpp
@@ -2079,7 +2079,17 @@ void HtmlGenerator::generateSectionList(const Section& section, const Node *rela
CodeMarker *marker, CodeMarker::SynopsisStyle style)
{
if (!section.members.isEmpty()) {
- out() << "\n";
+ bool twoColumn = false;
+ if (style == CodeMarker::SeparateList) {
+ twoColumn = (section.members.count() >= 16);
+ } else if (section.members.first()->type() == Node::Property) {
+ twoColumn = (section.members.count() >= 5);
+ }
+ if (twoColumn)
+ out() << "\n"
+ << "";
+ out() << "\n";
int i = 0;
NodeList::ConstIterator m = section.members.begin();
@@ -2089,17 +2099,22 @@ void HtmlGenerator::generateSectionList(const Section& section, const Node *rela
continue;
}
- out() << "";
+ if (twoColumn && i == (int) (section.members.count() + 1) / 2)
+ out() << " | \n";
+
+ out() << "- ";
if (style == CodeMarker::Accessors)
out() << "";
generateSynopsis(*m, relative, marker, style);
if (style == CodeMarker::Accessors)
out() << "";
- out() << "
| \n";
+ out() << "\n";
i++;
++m;
}
- out() << " |
\n";
+ out() << "\n";
+ if (twoColumn)
+ out() << "\n
\n";
}
if (style == CodeMarker::Summary && !section.inherited.isEmpty()) {
@@ -2114,7 +2129,7 @@ void HtmlGenerator::generateSectionInheritedList(const Section& section, const N
{
QList >::ConstIterator p = section.inherited.begin();
while (p != section.inherited.end()) {
- out() << "";
+ out() << "";
out() << (*p).second << " ";
if ((*p).second == 1) {
out() << section.singularMember;
@@ -2410,9 +2425,7 @@ QString HtmlGenerator::highlightedCode(const QString& markedCode,
// replace all <@link> tags: "(<@link node=\"([^\"]+)\">).*(@link>)"
static const QString linkTag("link");
for (int i = 0, n = src.size(); i < n;) {
- if (src.at(i) == charLangle && src.at(i + 1).unicode() == '@') {
- if (i != 0)
- html += " ";
+ if (src.at(i) == charLangle && src.at(i + 1) == charAt) {
i += 2;
if (parseArg(src, linkTag, &i, n, &arg, &par1)) {
QString link = linkForNode(
--
cgit v0.12
|