diff options
author | Thiago Macieira <thiago.macieira@nokia.com> | 2009-10-16 16:26:06 (GMT) |
---|---|---|
committer | Thiago Macieira <thiago.macieira@nokia.com> | 2009-10-16 16:26:06 (GMT) |
commit | af1fa7fe766980210d7363c1559197f34b10d834 (patch) | |
tree | e2964649ca8469269950a265060b3d1e7e6026f6 /tools | |
parent | c5bfbe27f5bbdb1f3e76af8ca5e0f4df27875a06 (diff) | |
parent | 1433a2c8682cb1c8f89ceaf97ad7a509ac686879 (diff) | |
download | Qt-af1fa7fe766980210d7363c1559197f34b10d834.zip Qt-af1fa7fe766980210d7363c1559197f34b10d834.tar.gz Qt-af1fa7fe766980210d7363c1559197f34b10d834.tar.bz2 |
Merge branch '4.6'
Conflicts:
translations/assistant_adp_pl.ts
translations/assistant_adp_ru.ts
Diffstat (limited to 'tools')
-rw-r--r-- | tools/configure/configureapp.cpp | 5 | ||||
-rw-r--r-- | tools/qdoc3/htmlgenerator.cpp | 157 | ||||
-rw-r--r-- | tools/qdoc3/htmlgenerator.h | 9 | ||||
-rw-r--r-- | tools/qdoc3/test/qt-api-only-with-xcode.qdocconf | 29 | ||||
-rw-r--r-- | tools/qdoc3/test/qt-build-docs-with-xcode.qdocconf | 3 | ||||
-rw-r--r-- | tools/qdoc3/test/qt-with-xcode.qdocconf | 3 | ||||
-rw-r--r-- | tools/qtestlib/wince/cetest/main.cpp | 2 |
7 files changed, 108 insertions, 100 deletions
diff --git a/tools/configure/configureapp.cpp b/tools/configure/configureapp.cpp index b9f8ed8..f57f3a8 100644 --- a/tools/configure/configureapp.cpp +++ b/tools/configure/configureapp.cpp @@ -1465,6 +1465,9 @@ void Configure::applySpecSpecifics() dictionary[ "SQL_SQLITE" ] = "yes"; dictionary[ "SQL_SQLITE_LIB" ] = "system"; + // Disable building docs and translations for now + disabledBuildParts << "docs" << "translations"; + } else if(dictionary[ "XQMAKESPEC" ].startsWith("linux")) { //TODO actually wrong. //TODO dictionary[ "STYLE_WINDOWSXP" ] = "no"; @@ -3717,7 +3720,7 @@ void Configure::readLicense() (dictionary.value("QMAKESPEC").startsWith("wince") || dictionary.value("XQMAKESPEC").startsWith("wince"))) dictionary["PLATFORM NAME"] = "Qt for Windows CE"; else if (dictionary.value("XQMAKESPEC").startsWith("symbian")) - dictionary["PLATFORM NAME"] = "Qt for S60"; + dictionary["PLATFORM NAME"] = "Qt for Symbian"; else dictionary["PLATFORM NAME"] = "Qt for Windows"; dictionary["LICENSE FILE"] = sourcePath; diff --git a/tools/qdoc3/htmlgenerator.cpp b/tools/qdoc3/htmlgenerator.cpp index 033c62c..c02dc2e 100644 --- a/tools/qdoc3/htmlgenerator.cpp +++ b/tools/qdoc3/htmlgenerator.cpp @@ -672,18 +672,18 @@ int HtmlGenerator::generateAtom(const Atom *atom, break; case Atom::SinceList: { - NodeMultiMapMap::const_iterator v; - v = nodeMultiMapMap.find(atom->string()); - NodeMapMap::const_iterator nc; - nc = nodeMapMap.find(atom->string()); - if ((v != nodeMultiMapMap.constEnd()) && !v.value().isEmpty()) { + NewSinceMaps::const_iterator nsmap; + nsmap = newSinceMaps.find(atom->string()); + NewClassMaps::const_iterator ncmap; + ncmap = newClassMaps.find(atom->string()); + if ((nsmap != newSinceMaps.constEnd()) && !nsmap.value().isEmpty()) { QList<Section> sections; QList<Section>::ConstIterator s; for (int i=0; i<LastSinceType; ++i) sections.append(Section(sinceTitle(i),QString(),QString())); - NodeMultiMap::const_iterator n = v.value().constBegin(); - while (n != v.value().constEnd()) { + NodeMultiMap::const_iterator n = nsmap.value().constBegin(); + while (n != nsmap.value().constEnd()) { const Node* node = n.value(); switch (node->type()) { case Node::Namespace: @@ -741,35 +741,63 @@ int HtmlGenerator::generateAtom(const Atom *atom, } ++n; } + + /* + First generate the table of contents. + */ + out() << "<ul>\n"; + s = sections.constBegin(); + while (s != sections.constEnd()) { + if (!(*s).members.isEmpty()) { + + out() << "<li>" + << "<a href=\"#" + << Doc::canonicalTitle((*s).name) + << "\">" + << (*s).name + << "</a></li>\n"; + } + ++s; + } + out() << "</ul>\n"; + int idx = 0; s = sections.constBegin(); while (s != sections.constEnd()) { if (!(*s).members.isEmpty()) { out() << "<a name=\"" - << registerRef((*s).name.toLower()) + << Doc::canonicalTitle((*s).name) << "\"></a>\n"; out() << "<h3>" << protect((*s).name) << "</h3>\n"; if (idx == Class) - generateCompactList(0, marker, nc.value(), QString("Q")); + generateCompactList(0, marker, ncmap.value(), QString("Q")); else if (idx == MemberFunction) { - NodeMultiMapMap nodemultimapmap; - NodeMultiMapMap::iterator nmmap; + ParentMaps parentmaps; + ParentMaps::iterator pmap; NodeList::const_iterator i = s->members.constBegin(); while (i != s->members.constEnd()) { Node* p = (*i)->parent(); - nmmap = nodemultimapmap.find(p->name()); - if (nmmap == nodemultimapmap.end()) - nmmap = nodemultimapmap.insert(p->name(),NodeMultiMap()); - nmmap->insert((*i)->name(),(*i)); + pmap = parentmaps.find(p); + if (pmap == parentmaps.end()) + pmap = parentmaps.insert(p,NodeMultiMap()); + pmap->insert((*i)->name(),(*i)); ++i; } - nmmap = nodemultimapmap.begin(); - while (nmmap != nodemultimapmap.end()) { - NodeList nlist = nmmap->values(); - out() << "<p>New functions in " << protect(nmmap.key()) << ":</p>\n"; + pmap = parentmaps.begin(); + while (pmap != parentmaps.end()) { + NodeList nlist = pmap->values(); + out() << "<p>Class "; + + out() << "<a href=\"" + << linkForNode(pmap.key(), 0) + << "\">"; + QStringList pieces = fullName(pmap.key(), 0, marker).split("::"); + out() << protect(pieces.last()); + out() << "</a>" << ":</p>\n"; + generateSection(nlist, 0, marker, CodeMarker::Summary); out() << "<br />"; - ++nmmap; + ++pmap; } } else @@ -1124,7 +1152,10 @@ int HtmlGenerator::generateAtom(const Atom *atom, } if (node) - generateTableOfContents(node, marker, sectioningUnit, numColumns, + generateTableOfContents(node, + marker, + sectioningUnit, + numColumns, relative); } break; @@ -2112,7 +2143,8 @@ void HtmlGenerator::generateCompactList(const Node *relative, /* If commonPrefix is not empty, then the caller knows what - the common prefix is, so just use that. + the common prefix is and has passed it in, so just use that + one. */ int commonPrefixLen = commonPrefix.length(); if (commonPrefixLen == 0) { @@ -2120,10 +2152,15 @@ void HtmlGenerator::generateCompactList(const Node *relative, QString last; /* - First, find out the common prefix of all non-namespaced - classes. For Qt, the prefix is Q. It can easily be derived - from the first and last classes in alphabetical order - (QAccel and QXtWidget in Qt 2.1). + The caller didn't pass in a common prefix, so get the common + prefix by looking at the class names of the first and last + classes in the class map. Discard any namespace names and + just use the bare class names. For Qt, the prefix is "Q". + + Note that the algorithm used here to derive the common prefix + from the first and last classes in alphabetical order (QAccel + and QXtWidget in Qt 2.1), fails if either class name does not + begin with Q. */ NodeMap::const_iterator iter = classMap.begin(); @@ -2164,8 +2201,7 @@ void HtmlGenerator::generateCompactList(const Node *relative, Divide the data into 37 paragraphs: 0, ..., 9, A, ..., Z, underscore (_). QAccel will fall in paragraph 10 (A) and QXtWidget in paragraph 33 (X). This is the only place where we - assume that NumParagraphs is 37. Each paragraph is a - NodeMap. + assume that NumParagraphs is 37. Each paragraph is a NodeMap. */ NodeMap paragraph[NumParagraphs+1]; QString paragraphName[NumParagraphs+1]; @@ -3644,53 +3680,54 @@ void HtmlGenerator::findAllClasses(const InnerNode *node) } /*! - For generating the "Since x.y" page. + For generating the "New Classes... in 4.6" section on the + What's New in 4.6" page. */ void HtmlGenerator::findAllSince(const InnerNode *node) { - NodeList::const_iterator c = node->childNodes().constBegin(); - while (c != node->childNodes().constEnd()) { - QString sinceVersion = (*c)->since(); - if (((*c)->access() != Node::Private) && !sinceVersion.isEmpty()) { - NodeMultiMapMap::iterator vmap = nodeMultiMapMap.find(sinceVersion); - if (vmap == nodeMultiMapMap.end()) - vmap = nodeMultiMapMap.insert(sinceVersion,NodeMultiMap()); - NodeMapMap::iterator ncmap = nodeMapMap.find(sinceVersion); - if (ncmap == nodeMapMap.end()) - ncmap = nodeMapMap.insert(sinceVersion,NodeMap()); + NodeList::const_iterator child = node->childNodes().constBegin(); + while (child != node->childNodes().constEnd()) { + QString sinceVersion = (*child)->since(); + if (((*child)->access() != Node::Private) && !sinceVersion.isEmpty()) { + NewSinceMaps::iterator nsmap = newSinceMaps.find(sinceVersion); + if (nsmap == newSinceMaps.end()) + nsmap = newSinceMaps.insert(sinceVersion,NodeMultiMap()); + NewClassMaps::iterator ncmap = newClassMaps.find(sinceVersion); + if (ncmap == newClassMaps.end()) + ncmap = newClassMaps.insert(sinceVersion,NodeMap()); - if ((*c)->type() == Node::Function) { - FunctionNode *func = static_cast<FunctionNode *>(*c); + if ((*child)->type() == Node::Function) { + FunctionNode *func = static_cast<FunctionNode *>(*child); if ((func->status() > Node::Obsolete) && (func->metaness() != FunctionNode::Ctor) && (func->metaness() != FunctionNode::Dtor)) { - vmap.value().insert(func->name(),(*c)); + nsmap.value().insert(func->name(),(*child)); } } - else if ((*c)->url().isEmpty()) { - if ((*c)->type() == Node::Class && !(*c)->doc().isEmpty()) { - QString className = (*c)->name(); - if ((*c)->parent() && - (*c)->parent()->type() == Node::Namespace && - !(*c)->parent()->name().isEmpty()) - className = (*c)->parent()->name()+"::"+className; - vmap.value().insert(className,(*c)); - ncmap.value().insert(className,(*c)); + else if ((*child)->url().isEmpty()) { + if ((*child)->type() == Node::Class && !(*child)->doc().isEmpty()) { + QString className = (*child)->name(); + if ((*child)->parent() && + (*child)->parent()->type() == Node::Namespace && + !(*child)->parent()->name().isEmpty()) + className = (*child)->parent()->name()+"::"+className; + nsmap.value().insert(className,(*child)); + ncmap.value().insert(className,(*child)); } } else { - QString name = (*c)->name(); - if ((*c)->parent() && - (*c)->parent()->type() == Node::Namespace && - !(*c)->parent()->name().isEmpty()) - name = (*c)->parent()->name()+"::"+name; - vmap.value().insert(name,(*c)); + QString name = (*child)->name(); + if ((*child)->parent() && + (*child)->parent()->type() == Node::Namespace && + !(*child)->parent()->name().isEmpty()) + name = (*child)->parent()->name()+"::"+name; + nsmap.value().insert(name,(*child)); } - if ((*c)->isInnerNode()) { - findAllSince(static_cast<InnerNode *>(*c)); + if ((*child)->isInnerNode()) { + findAllSince(static_cast<InnerNode *>(*child)); } } - ++c; + ++child; } } diff --git a/tools/qdoc3/htmlgenerator.h b/tools/qdoc3/htmlgenerator.h index fabfed1..40117df 100644 --- a/tools/qdoc3/htmlgenerator.h +++ b/tools/qdoc3/htmlgenerator.h @@ -68,9 +68,10 @@ struct NavigationBar #endif typedef QMultiMap<QString, Node*> NodeMultiMap; -typedef QMap<QString, NodeMultiMap> NodeMultiMapMap; +typedef QMap<QString, NodeMultiMap> NewSinceMaps; +typedef QMap<Node*, NodeMultiMap> ParentMaps; typedef QMap<QString, const Node*> NodeMap; -typedef QMap<QString, NodeMap> NodeMapMap; +typedef QMap<QString, NodeMap> NewClassMaps; class HelpProjectWriter; @@ -311,9 +312,9 @@ class HtmlGenerator : public PageGenerator #endif QMap<QString, NodeMap > funcIndex; QMap<Text, const Node *> legaleseTexts; - NodeMultiMapMap nodeMultiMapMap; + NewSinceMaps newSinceMaps; static QString sinceTitles[]; - NodeMapMap nodeMapMap; + NewClassMaps newClassMaps; }; #define HTMLGENERATOR_ADDRESS "address" diff --git a/tools/qdoc3/test/qt-api-only-with-xcode.qdocconf b/tools/qdoc3/test/qt-api-only-with-xcode.qdocconf deleted file mode 100644 index 0d78cda..0000000 --- a/tools/qdoc3/test/qt-api-only-with-xcode.qdocconf +++ /dev/null @@ -1,29 +0,0 @@ -include(qt-build-docs-with-xcode.qdocconf) - -# Ensures that the generated index contains a URL that can be used by the -# tools documentation (assistant.qdocconf, designer.qdocconf, linguist.qdocconf, -# qmake.qdocconf). - -url = ./ - -# Ensures that the documentation for the tools is not included in the generated -# .qhp file. - -qhp.Qt.excluded = $QT_SOURCE_TREE/doc/src/development/assistant-manual.qdoc \ - $QT_SOURCE_TREE/doc/src/examples/simpletextviewer.qdoc \ - $QT_SOURCE_TREE/doc/src/development/designer-manual.qdoc \ - $QT_SOURCE_TREE/doc/src/examples/calculatorbuilder.qdoc \ - $QT_SOURCE_TREE/doc/src/examples/calculatorform.qdoc \ - $QT_SOURCE_TREE/doc/src/examples/customwidgetplugin.qdoc \ - $QT_SOURCE_TREE/doc/src/examples/taskmenuextension.qdoc \ - $QT_SOURCE_TREE/doc/src/examples/containerextension.qdoc \ - $QT_SOURCE_TREE/doc/src/examples/worldtimeclockbuilder.qdoc \ - $QT_SOURCE_TREE/doc/src/examples/worldtimeclockplugin.qdoc \ - $QT_SOURCE_TREE/doc/src/internationalization/linguist-manual.qdoc \ - $QT_SOURCE_TREE/doc/src/examples/hellotr.qdoc \ - $QT_SOURCE_TREE/doc/src/examples/arrowpad.qdoc \ - $QT_SOURCE_TREE/doc/src/examples/trollprint.qdoc \ - $QT_SOURCE_TREE/doc/src/development/qmake-manual.qdoc - -outputdir = $QT_BUILD_TREE/doc-build/html-qt -base = file:$QT_BUILD_TREE/doc-build/html-qt diff --git a/tools/qdoc3/test/qt-build-docs-with-xcode.qdocconf b/tools/qdoc3/test/qt-build-docs-with-xcode.qdocconf deleted file mode 100644 index e4be476..0000000 --- a/tools/qdoc3/test/qt-build-docs-with-xcode.qdocconf +++ /dev/null @@ -1,3 +0,0 @@ -include( qt-build-docs.qdocconf ) - -HTML.generatemacrefs = "true" diff --git a/tools/qdoc3/test/qt-with-xcode.qdocconf b/tools/qdoc3/test/qt-with-xcode.qdocconf deleted file mode 100644 index 932f6d9..0000000 --- a/tools/qdoc3/test/qt-with-xcode.qdocconf +++ /dev/null @@ -1,3 +0,0 @@ -include( qt.qdocconf ) - -HTML.generatemacrefs = "true" diff --git a/tools/qtestlib/wince/cetest/main.cpp b/tools/qtestlib/wince/cetest/main.cpp index 9df70e7..e00c0e7 100644 --- a/tools/qtestlib/wince/cetest/main.cpp +++ b/tools/qtestlib/wince/cetest/main.cpp @@ -237,6 +237,8 @@ int main(int argc, char **argv) debugOutput(QString::fromLatin1("Using Project File:").append(proFile),1); } + Option::before_user_vars.append("CONFIG+=build_pass"); + // read target and deployment rules int qmakeArgc = 1; char* qmakeArgv[] = { "qmake.exe" }; |