diff options
author | Justin McPherson <justin.mcpherson@nokia.com> | 2010-04-22 23:54:51 (GMT) |
---|---|---|
committer | Justin McPherson <justin.mcpherson@nokia.com> | 2010-04-22 23:54:51 (GMT) |
commit | 478e914638f2131d1547c4e2dc4659723657194d (patch) | |
tree | c9f63e6bd79dce411ae059b1bb65a66db6584264 /tools | |
parent | 6b30ee9d2219308605e0d1b15ea1c74dc5cb67fe (diff) | |
parent | 4894e6dd57c31e0196c6fdae4d1b2fb16b9f1b16 (diff) | |
download | Qt-478e914638f2131d1547c4e2dc4659723657194d.zip Qt-478e914638f2131d1547c4e2dc4659723657194d.tar.gz Qt-478e914638f2131d1547c4e2dc4659723657194d.tar.bz2 |
Merge branch '4.7' of ../../qt/4.7 into 4.7
Conflicts:
demos/multimedia/player/player.pro
Diffstat (limited to 'tools')
22 files changed, 530 insertions, 272 deletions
diff --git a/tools/assistant/tools/assistant/helpviewer.cpp b/tools/assistant/tools/assistant/helpviewer.cpp index 0c51a02..22b3f30 100644 --- a/tools/assistant/tools/assistant/helpviewer.cpp +++ b/tools/assistant/tools/assistant/helpviewer.cpp @@ -52,6 +52,10 @@ QT_BEGIN_NAMESPACE +QString AbstractHelpViewer::DocPath = QString::fromLatin1("qthelp://com." + "trolltech.qt.%1/").arg(QString(QLatin1String(QT_VERSION_STR)) + .replace(QLatin1String("."), QLatin1String(""))); + QString AbstractHelpViewer::AboutBlank = QCoreApplication::translate("HelpViewer", "<title>about:blank</title>"); @@ -128,11 +132,12 @@ bool AbstractHelpViewer::canOpenPage(const QString &url) return !mimeFromUrl(url).isEmpty(); } -QString AbstractHelpViewer::mimeFromUrl(const QString &url) +QString AbstractHelpViewer::mimeFromUrl(const QUrl &url) { TRACE_OBJ - const int index = url.lastIndexOf(QLatin1Char('.')); - const QByteArray &ext = url.mid(index).toUtf8().toLower(); + const QString &path = url.path(); + const int index = path.lastIndexOf(QLatin1Char('.')); + const QByteArray &ext = path.mid(index).toUtf8().toLower(); const ExtensionMap *e = extensionMap; while (e->extension) { diff --git a/tools/assistant/tools/assistant/helpviewer.h b/tools/assistant/tools/assistant/helpviewer.h index 6f1f48d..80a6f87 100644 --- a/tools/assistant/tools/assistant/helpviewer.h +++ b/tools/assistant/tools/assistant/helpviewer.h @@ -67,13 +67,14 @@ public: virtual bool handleForwardBackwardMouseButtons(QMouseEvent *e) = 0; + static QString DocPath; static QString AboutBlank; static QString LocalHelpFile; static QString PageNotFoundMessage; static bool isLocalUrl(const QUrl &url); static bool canOpenPage(const QString &url); - static QString mimeFromUrl(const QString &url); + static QString mimeFromUrl(const QUrl &url); static bool launchWithExternalApp(const QUrl &url); }; diff --git a/tools/assistant/tools/assistant/helpviewer_qwv.cpp b/tools/assistant/tools/assistant/helpviewer_qwv.cpp index db1cd58..a19b29a 100644 --- a/tools/assistant/tools/assistant/helpviewer_qwv.cpp +++ b/tools/assistant/tools/assistant/helpviewer_qwv.cpp @@ -129,13 +129,27 @@ QNetworkReply *HelpNetworkAccessManager::createRequest(Operation /*op*/, const QNetworkRequest &request, QIODevice* /*outgoingData*/) { TRACE_OBJ - const QUrl &url = request.url(); - const QString &mimeType = AbstractHelpViewer::mimeFromUrl(url.toString()); - + QString url = request.url().toString(); HelpEngineWrapper &helpEngine = HelpEngineWrapper::instance(); + + // TODO: For some reason the url to load is already wrong (passed from webkit) + // though the css file and the references inside should work that way. One + // possible problem might be that the css is loaded at the same level as the + // html, thus a path inside the css like (../images/foo.png) might cd out of + // the virtual folder + if (!helpEngine.findFile(url).isValid()) { + if (url.startsWith(AbstractHelpViewer::DocPath)) { + if (!url.startsWith(AbstractHelpViewer::DocPath + QLatin1String("qdoc/"))) { + url = url.replace(AbstractHelpViewer::DocPath, + AbstractHelpViewer::DocPath + QLatin1String("qdoc/")); + } + } + } + + const QString &mimeType = AbstractHelpViewer::mimeFromUrl(url); const QByteArray &data = helpEngine.findFile(url).isValid() ? helpEngine.fileData(url) - : AbstractHelpViewer::PageNotFoundMessage.arg(url.toString()).toUtf8(); + : AbstractHelpViewer::PageNotFoundMessage.arg(url).toUtf8(); return new HelpNetworkReply(request, data, mimeType.isEmpty() ? QLatin1String("application/octet-stream") : mimeType); } diff --git a/tools/designer/src/components/propertyeditor/propertyeditor.cpp b/tools/designer/src/components/propertyeditor/propertyeditor.cpp index 86d7bdf..a8ca8ad 100644 --- a/tools/designer/src/components/propertyeditor/propertyeditor.cpp +++ b/tools/designer/src/components/propertyeditor/propertyeditor.cpp @@ -135,7 +135,7 @@ QSize ElidingLabel::sizeHint() const return size; } -void ElidingLabel::paintEvent(QPaintEvent *e) { +void ElidingLabel::paintEvent(QPaintEvent *) { QPainter painter(this); painter.setPen(QColor(0, 0, 0, 60)); painter.setBrush(QColor(255, 255, 255, 40)); diff --git a/tools/designer/src/lib/shared/filterwidget.cpp b/tools/designer/src/lib/shared/filterwidget.cpp index f485346..07af901 100644 --- a/tools/designer/src/lib/shared/filterwidget.cpp +++ b/tools/designer/src/lib/shared/filterwidget.cpp @@ -80,8 +80,11 @@ void IconButton::paintEvent(QPaintEvent *) QPainter painter(this); // Note isDown should really use the active state but in most styles // this has no proper feedback - QPixmap iconpixmap = icon().pixmap(ICONBUTTON_SIZE, ICONBUTTON_SIZE, isDown() ? - QIcon::Selected : QIcon::Normal); + QIcon::Mode state = QIcon::Disabled; + if (isEnabled()) + state = isDown() ? QIcon::Selected : QIcon::Normal; + QPixmap iconpixmap = icon().pixmap(QSize(ICONBUTTON_SIZE, ICONBUTTON_SIZE), + state, QIcon::Off); QRect pixmapRect = QRect(0, 0, iconpixmap.width(), iconpixmap.height()); pixmapRect.moveCenter(rect().center()); painter.setOpacity(m_fader); @@ -204,9 +207,12 @@ QString FilterWidget::text() const return m_editor->text(); } -void FilterWidget::checkButton(const QString &) +void FilterWidget::checkButton(const QString &text) { - m_button->animateShow(!m_editor->text().isEmpty()); + static QString oldtext; + if (oldtext.isEmpty() || text.isEmpty()) + m_button->animateShow(!m_editor->text().isEmpty()); + oldtext = text; } void FilterWidget::reset() diff --git a/tools/pixeltool/qpixeltool.cpp b/tools/pixeltool/qpixeltool.cpp index c684688..f64dfba 100644 --- a/tools/pixeltool/qpixeltool.cpp +++ b/tools/pixeltool/qpixeltool.cpp @@ -356,7 +356,7 @@ void QPixelTool::contextMenuEvent(QContextMenuEvent *e) freeze.setCheckable(true); freeze.setChecked(tmpFreeze); freeze.setShortcut(QKeySequence(Qt::Key_Space)); - QAction autoUpdate(QLatin1String("Continous update"), &menu); + QAction autoUpdate(QLatin1String("Continuous update"), &menu); autoUpdate.setCheckable(true); autoUpdate.setChecked(m_autoUpdate); autoUpdate.setShortcut(QKeySequence(Qt::Key_A)); diff --git a/tools/qdoc3/config.h b/tools/qdoc3/config.h index 980d1fb..c29becc 100644 --- a/tools/qdoc3/config.h +++ b/tools/qdoc3/config.h @@ -142,6 +142,7 @@ class Config #define CONFIG_MACRO "macro" #define CONFIG_NATURALLANGUAGE "naturallanguage" #define CONFIG_OBSOLETELINKS "obsoletelinks" +#define CONFIG_ONLINE "online" #define CONFIG_OUTPUTDIR "outputdir" #define CONFIG_OUTPUTENCODING "outputencoding" #define CONFIG_OUTPUTLANGUAGE "outputlanguage" diff --git a/tools/qdoc3/doc.cpp b/tools/qdoc3/doc.cpp index ad4cdde..5716626 100644 --- a/tools/qdoc3/doc.cpp +++ b/tools/qdoc3/doc.cpp @@ -3036,7 +3036,7 @@ QString Doc::canonicalTitle(const QString &title) QString result; result.reserve(title.size()); - bool slurping = false; + bool dashAppended = false; bool begun = false; int lastAlnum = 0; for (int i = 0; i != title.size(); ++i) { @@ -3047,18 +3047,21 @@ QString Doc::canonicalTitle(const QString &title) if (alnum) { result += QLatin1Char(c); begun = true; - slurping = false; + dashAppended = false; lastAlnum = result.size(); } - else if (!slurping) { + else if (!dashAppended) { if (begun) result += QLatin1Char('-'); - slurping = true; + dashAppended = true; } +#if 0 + // This was screwing things up. else { result += title[i]; lastAlnum = result.size(); } +#endif } result.truncate(lastAlnum); return result; diff --git a/tools/qdoc3/htmlgenerator.cpp b/tools/qdoc3/htmlgenerator.cpp index a5dc7b7..bf2f724 100644 --- a/tools/qdoc3/htmlgenerator.cpp +++ b/tools/qdoc3/htmlgenerator.cpp @@ -204,10 +204,18 @@ static void addLink(const QString &linkTarget, HtmlGenerator::HtmlGenerator() - : helpProjectWriter(0), inLink(false), inContents(false), - inSectionHeading(false), inTableHeader(false), numTableRows(0), - threeColumnEnumValueTable(true), funcLeftParen("\\S(\\()"), - myTree(0), slow(false), obsoleteLinks(false) + : helpProjectWriter(0), + inLink(false), + inContents(false), + inSectionHeading(false), + inTableHeader(false), + numTableRows(0), + threeColumnEnumValueTable(true), + offlineDocs(true), + funcLeftParen("\\S(\\()"), + myTree(0), + slow(false), + obsoleteLinks(false) { } @@ -262,7 +270,7 @@ void HtmlGenerator::initializeGenerator(const Config &config) HTMLGENERATOR_GENERATEMACREFS); project = config.getString(CONFIG_PROJECT); - + offlineDocs = !config.getBool(CONFIG_ONLINE); projectDescription = config.getString(CONFIG_DESCRIPTION); if (projectDescription.isEmpty() && !project.isEmpty()) projectDescription = project + " Reference Documentation"; @@ -406,9 +414,7 @@ void HtmlGenerator::generateTree(const Tree *tree, CodeMarker *marker) generateIndex(fileBase, projectUrl, projectDescription); generatePageIndex(outputDir() + "/" + fileBase + ".pageindex", marker); - //qDebug() << "start helpProjectWriter->generate(myTree)"; helpProjectWriter->generate(myTree); - //qDebug() << "end helpProjectWriter->generate(myTree)"; } void HtmlGenerator::startText(const Node * /* relative */, @@ -506,14 +512,14 @@ int HtmlGenerator::generateAtom(const Atom *atom, out() << formattingRightMap()[ATOM_FORMATTING_TELETYPE]; break; case Atom::Code: - out() << "<pre>" + out() << "<pre class=\"highlightedCode\">" << trimmedTrailing(highlightedCode(indent(codeIndent,atom->string()), marker,relative)) << "</pre>\n"; break; #ifdef QDOC_QML case Atom::Qml: - out() << "<pre>" + out() << "<pre class=\"highlightedCode\">" << trimmedTrailing(highlightedCode(indent(codeIndent,atom->string()), marker,relative)) << "</pre>\n"; @@ -521,7 +527,7 @@ int HtmlGenerator::generateAtom(const Atom *atom, #endif case Atom::CodeNew: out() << "<p>you can rewrite it as</p>\n" - << "<pre>" + << "<pre class=\"highlightedCode\">" << trimmedTrailing(highlightedCode(indent(codeIndent,atom->string()), marker,relative)) << "</pre>\n"; @@ -530,9 +536,9 @@ int HtmlGenerator::generateAtom(const Atom *atom, out() << "<p>For example, if you have code like</p>\n"; // fallthrough case Atom::CodeBad: - out() << "<pre><font color=\"#404040\">" + out() << "<pre class=\"highlightedCode\">" << trimmedTrailing(protectEnc(plainCode(indent(codeIndent,atom->string())))) - << "</font></pre>\n"; + << "</pre>\n"; break; case Atom::FootnoteLeft: // ### For now @@ -841,7 +847,7 @@ int HtmlGenerator::generateAtom(const Atom *atom, if (atom->next() != 0) text = atom->next()->string(); if (atom->type() == Atom::Image) - out() << "<p align=\"center\">"; + out() << "<p class=\"centerAlign\">"; if (fileName.isEmpty()) { out() << "<font color=\"red\">[Missing image " << protectEnc(atom->string()) << "]</font>"; @@ -860,7 +866,7 @@ int HtmlGenerator::generateAtom(const Atom *atom, case Atom::ImageText: break; case Atom::LegaleseLeft: - out() << "<div style=\"padding: 0.5em; background: #e0e0e0; color: black\">"; + out() << "<div class=\"LegaleseLeft\">"; break; case Atom::LegaleseRight: out() << "</div>"; @@ -902,13 +908,13 @@ int HtmlGenerator::generateAtom(const Atom *atom, else if (atom->string() == ATOM_LIST_VALUE) { threeColumnEnumValueTable = isThreeColumnEnumValueTable(atom); if (threeColumnEnumValueTable) { - out() << "<p><table class=\"valuelist\">" + out() << "<table class=\"valuelist\">" << "<tr><th>Constant</th>" << "<th>Value</th>" << "<th>Description</th></tr>\n"; } else { - out() << "<p><table class=\"valuelist\">" + out() << "<table class=\"valuelist\">" << "<tr><th>Constant</th><th>Value</th></tr>\n"; } } @@ -943,10 +949,10 @@ int HtmlGenerator::generateAtom(const Atom *atom, else { // (atom->string() == ATOM_LIST_VALUE) // ### Trenton - out() << "<tr><td valign=\"top\"><tt>" + out() << "<tr><td class=\"topAlign\"><tt>" << protectEnc(plainCode(marker->markedUpEnumValue(atom->next()->string(), relative))) - << "</tt></td><td align=\"center\" valign=\"top\">"; + << "</tt></td><td class=\"centerAlign topAlign\">"; QString itemValue; if (relative->type() == Node::Enum) { @@ -972,7 +978,7 @@ int HtmlGenerator::generateAtom(const Atom *atom, } else if (atom->string() == ATOM_LIST_VALUE) { if (threeColumnEnumValueTable) { - out() << "</td><td valign=\"top\">"; + out() << "</td><td class=\"topAlign\">"; if (matchAhead(atom, Atom::ListItemRight)) out() << " "; } @@ -1002,7 +1008,7 @@ int HtmlGenerator::generateAtom(const Atom *atom, out() << "</dl>\n"; } else if (atom->string() == ATOM_LIST_VALUE) { - out() << "</table></p>\n"; + out() << "</table>\n"; } else { out() << "</ol>\n"; @@ -1083,29 +1089,28 @@ int HtmlGenerator::generateAtom(const Atom *atom, } if (!atom->string().isEmpty()) { if (atom->string().contains("%")) - out() << "<p><table class=\"generic\" width=\"" << atom->string() << "\" " - << "align=\"center\">\n"; + out() << "<table class=\"generic centerAlign\" width=\"" << atom->string() << "\">\n "; else { - out() << "<p><table class=\"generic\" align=\"center\">\n"; + out() << "<table class=\"generic centerAlign\">\n"; } } else { - out() << "<p><table class=\"generic\" align=\"center\">\n"; + out() << "<table class=\"generic centerAlign\">\n"; } numTableRows = 0; break; case Atom::TableRight: - out() << "</table></p>\n"; + out() << "</table>\n"; break; case Atom::TableHeaderLeft: - out() << "<thead><tr valign=\"top\" class=\"qt-style\">"; + out() << "<thead><tr class=\"qt-style topAlign\">"; inTableHeader = true; break; case Atom::TableHeaderRight: out() << "</tr>"; if (matchAhead(atom, Atom::TableHeaderLeft)) { skipAhead = 1; - out() << "\n<tr valign=\"top\" class=\"qt-style\">"; + out() << "\n<tr class=\"qt-style topAlign\">"; } else { out() << "</thead>\n"; @@ -1114,9 +1119,9 @@ int HtmlGenerator::generateAtom(const Atom *atom, break; case Atom::TableRowLeft: if (++numTableRows % 2 == 1) - out() << "<tr valign=\"top\" class=\"odd\">"; + out() << "<tr class=\"odd topAlign\">"; else - out() << "<tr valign=\"top\" class=\"even\">"; + out() << "<tr class=\"even topAlign\">"; break; case Atom::TableRowRight: out() << "</tr>\n"; @@ -1181,11 +1186,11 @@ int HtmlGenerator::generateAtom(const Atom *atom, out() << "<a name=\"" << Doc::canonicalTitle(atom->string()) << "\"></a>"; break; case Atom::UnhandledFormat: - out() << "<font color=\"red\"><b><Missing HTML></b></font>"; + out() << "<b class=\"redFont\"><Missing HTML></b>"; break; case Atom::UnknownCommand: - out() << "<font color=\"red\"><b><code>\\" << protectEnc(atom->string()) - << "</code></b></font>"; + out() << "<b class=\"redFont\"><code>\\" << protectEnc(atom->string()) + << "</code></b>"; break; #ifdef QDOC_QML case Atom::QmlText: @@ -1737,146 +1742,17 @@ void HtmlGenerator::generateHeader(const QString& title, out() << " <script src=\"scripts/jquery.js\" type=\"text/javascript\"></script>\n"; out() << " <script src=\"scripts/functions.js\" type=\"text/javascript\"></script>\n"; out() << "</head>\n"; - -#if 0 - out() << "<!DOCTYPE html\n" - " PUBLIC \"-//W3C//DTD XHTML 1.0 Strict//EN\" \"DTD/xhtml1-strict.dtd\">\n"; - out() << QString("<html xmlns=\"http://www.w3.org/1999/xhtml\" xml:lang=\"%1\" lang=\"%1\">\n").arg(naturalLanguage); - - QString shortVersion; - if ((project != "Qtopia") && (project != "Qt Extended")) { - shortVersion = project + " " + shortVersion + ": "; - if (node && !node->doc().location().isEmpty()) - out() << "<!-- " << node->doc().location().fileName() << " -->\n"; - - shortVersion = myTree->version(); - if (shortVersion.count(QChar('.')) == 2) - shortVersion.truncate(shortVersion.lastIndexOf(QChar('.'))); - if (!shortVersion.isEmpty()) { - if (project == "QSA") - shortVersion = "QSA " + shortVersion + ": "; - else - shortVersion = "Qt " + shortVersion + ": "; - } - } - - out() << "<head>\n" - " <title>" << shortVersion << protectEnc(title) << "</title>\n"; - out() << QString("<meta http-equiv=\"Content-type\" content=\"text/html; charset=%1\" />").arg(outputEncoding); - - if (!style.isEmpty()) - out() << " <style type=\"text/css\">" << style << "</style>\n"; - - const QMap<QString, QString> &metaMap = node->doc().metaTagMap(); - if (!metaMap.isEmpty()) { - QMapIterator<QString, QString> i(metaMap); - while (i.hasNext()) { - i.next(); - out() << " <meta name=\"" << protectEnc(i.key()) << "\" contents=\"" - << protectEnc(i.value()) << "\" />\n"; - } - } - - navigationLinks.clear(); - - if (node && !node->links().empty()) { - QPair<QString,QString> linkPair; - QPair<QString,QString> anchorPair; - const Node *linkNode; - - if (node->links().contains(Node::PreviousLink)) { - linkPair = node->links()[Node::PreviousLink]; - linkNode = findNodeForTarget(linkPair.first, node, marker); - if (!linkNode || linkNode == node) - anchorPair = linkPair; - else - anchorPair = anchorForNode(linkNode); - - out() << " <link rel=\"prev\" href=\"" - << anchorPair.first << "\" />\n"; - - navigationLinks += "[Previous: <a href=\"" + anchorPair.first + "\">"; - if (linkPair.first == linkPair.second && !anchorPair.second.isEmpty()) - navigationLinks += protectEnc(anchorPair.second); - else - navigationLinks += protectEnc(linkPair.second); - navigationLinks += "</a>]\n"; - } - if (node->links().contains(Node::ContentsLink)) { - linkPair = node->links()[Node::ContentsLink]; - linkNode = findNodeForTarget(linkPair.first, node, marker); - if (!linkNode || linkNode == node) - anchorPair = linkPair; - else - anchorPair = anchorForNode(linkNode); - - out() << " <link rel=\"contents\" href=\"" - << anchorPair.first << "\" />\n"; - navigationLinks += "[<a href=\"" + anchorPair.first + "\">"; - if (linkPair.first == linkPair.second && !anchorPair.second.isEmpty()) - navigationLinks += protectEnc(anchorPair.second); - else - navigationLinks += protectEnc(linkPair.second); - navigationLinks += "</a>]\n"; - } - if (node->links().contains(Node::NextLink)) { - linkPair = node->links()[Node::NextLink]; - linkNode = findNodeForTarget(linkPair.first, node, marker); - if (!linkNode || linkNode == node) - anchorPair = linkPair; - else - anchorPair = anchorForNode(linkNode); - - out() << " <link rel=\"next\" href=\"" - << anchorPair.first << "\" />\n"; - - navigationLinks += "[Next: <a href=\"" + anchorPair.first + "\">"; - if (linkPair.first == linkPair.second && !anchorPair.second.isEmpty()) - navigationLinks += protectEnc(anchorPair.second); - else - navigationLinks += protectEnc(linkPair.second); - navigationLinks += "</a>]\n"; - } - if (node->links().contains(Node::IndexLink)) { - linkPair = node->links()[Node::IndexLink]; - linkNode = findNodeForTarget(linkPair.first, node, marker); - if (!linkNode || linkNode == node) - anchorPair = linkPair; - else - anchorPair = anchorForNode(linkNode); - out() << " <link rel=\"index\" href=\"" - << anchorPair.first << "\" />\n"; - } - if (node->links().contains(Node::StartLink)) { - linkPair = node->links()[Node::StartLink]; - linkNode = findNodeForTarget(linkPair.first, node, marker); - if (!linkNode || linkNode == node) - anchorPair = linkPair; - else - anchorPair = anchorForNode(linkNode); - out() << " <link rel=\"start\" href=\"" - << anchorPair.first << "\" />\n"; - } - } - - foreach (const QString &stylesheet, stylesheets) { - out() << " <link href=\"" << stylesheet << "\" rel=\"stylesheet\" " - << "type=\"text/css\" />\n"; - } - - foreach (const QString &customHeadElement, customHeadElements) { - out() << " " << customHeadElement << "\n"; - } - - out() << "</head>\n" - #endif + if (offlineDocs) + out() << "<body class=\"offline\">\n"; + else out() << "<body class=\"\">\n"; + if (mainPage) generateMacRef(node, marker); out() << QString(postHeader).replace("\\" + COMMAND_VERSION, myTree->version()); -#if 0 +#if 0 // Removed for new docf format. MWS if (node && !node->links().empty()) out() << "<p>\n" << navigationLinks << "</p>\n"; #endif @@ -1932,7 +1808,7 @@ void HtmlGenerator::generateBrief(const Node *node, CodeMarker *marker, void HtmlGenerator::generateIncludes(const InnerNode *inner, CodeMarker *marker) { if (!inner->includes().isEmpty()) { - out() << "<pre>" + out() << "<pre clas=\"highlightedCode\">" << trimmedTrailing(highlightedCode(indent(codeIndent, marker->markedUpIncludes(inner->includes())), marker,inner)) @@ -1966,8 +1842,8 @@ void HtmlGenerator::generateTableOfContents(const Node *node, QString tdTag; if (numColumns > 1) { - tdTag = "<td width=\"" + QString::number((100 + numColumns - 1) / numColumns) + "%\">"; - out() << "<p><table class=\"toc\" width=\"100%\">\n<tr valign=\"top\">" + tdTag = "<td>"; /* width=\"" + QString::number((100 + numColumns - 1) / numColumns) + "%\">";*/ + out() << "<table class=\"toc\">\n<tr class=\"topAlign\">" << tdTag << "\n"; } @@ -2019,7 +1895,7 @@ void HtmlGenerator::generateTableOfContents(const Node *node, } if (numColumns > 1) - out() << "</td></tr></table></p>\n"; + out() << "</td></tr></table>\n"; inContents = false; inLink = false; @@ -2104,10 +1980,12 @@ void HtmlGenerator::generateTableOfContents(const Node *node, } int numAtoms; Text headingText = Text::sectionHeading(atom); + QString s = headingText.toString(); out() << "<li>"; out() << "<a href=\"" << "#" - << Doc::canonicalTitle(headingText.toString()) + //<< registerRef(s) + << Doc::canonicalTitle(s) << "\">"; generateAtomList(headingText.firstAtom(), node, marker, true, numAtoms); out() << "</a></li>\n"; @@ -2128,7 +2006,7 @@ void HtmlGenerator::generateNavigationBar(const NavigationBar& bar, { if (bar.prev.begin() != 0 || bar.current.begin() != 0 || bar.next.begin() != 0) { - out() << "<p align=\"right\">"; + out() << "<p class=\"rightAlign\">"; if (bar.prev.begin() != 0) { #if 0 out() << "[<a href=\"" << section.previousBaseName() @@ -2304,7 +2182,7 @@ void HtmlGenerator::generateAnnotatedList(const Node *relative, CodeMarker *marker, const NodeMap &nodeMap) { - out() << "<p><table class=\"annotated\">\n"; + out() << "<table class=\"annotated\">\n"; int row = 0; foreach (const QString &name, nodeMap.keys()) { @@ -2314,9 +2192,9 @@ void HtmlGenerator::generateAnnotatedList(const Node *relative, continue; if (++row % 2 == 1) - out() << "<tr valign=\"top\" class=\"odd\">"; + out() << "<tr class=\"odd topAlign\">"; else - out() << "<tr valign=\"top\" class=\"even\">"; + out() << "<tr class=\"even topAlign\">"; out() << "<th>"; generateFullName(node, relative, marker); out() << "</th>"; @@ -2336,7 +2214,7 @@ void HtmlGenerator::generateAnnotatedList(const Node *relative, } out() << "</tr>\n"; } - out() << "</table></p>\n"; + out() << "</table>\n"; } /*! @@ -2489,7 +2367,7 @@ void HtmlGenerator::generateCompactList(const Node *relative, } firstOffset[NumColumns] = classMap.count(); - out() << "<p><table class=\"generic\">\n"; + out() << "<table class=\"generic\">\n"; for (k = 0; k < numRows; k++) { out() << "<tr>\n"; for (i = 0; i < NumColumns; i++) { @@ -2510,7 +2388,7 @@ void HtmlGenerator::generateCompactList(const Node *relative, currentParagraphNo[i] = NumParagraphs - 1; } #endif - out() << "<td align=\"right\">"; + out() << "<td class=\"rightAlign\">"; if (currentOffsetInParagraph[i] == 0) { // start a new paragraph out() << "<b>" @@ -2553,18 +2431,18 @@ void HtmlGenerator::generateCompactList(const Node *relative, } out() << "</tr>\n"; } - out() << "</table></p>\n"; + out() << "</table>\n"; } void HtmlGenerator::generateFunctionIndex(const Node *relative, CodeMarker *marker) { - out() << "<p align=\"center\"><font size=\"+1\"><b>"; + out() << "<p class=\"centerAlign functionIndex\"><b>"; for (int i = 0; i < 26; i++) { QChar ch('a' + i); out() << QString("<a href=\"#%1\">%2</a> ").arg(ch).arg(ch.toUpper()); } - out() << "</b></font></p>\n"; + out() << "</b></p>\n"; char nextLetter = 'a'; char currentLetter; @@ -2832,8 +2710,8 @@ void HtmlGenerator::generateSection(const NodeList& nl, } else { if (twoColumn) - out() << "<p><table class=\"propsummary\">\n" - << "<tr><td valign=\"top\">"; + out() << "<table class=\"propsummary\">\n" + << "<tr><td class=\"topAlign\">"; out() << "<ul>\n"; } @@ -2846,12 +2724,11 @@ void HtmlGenerator::generateSection(const NodeList& nl, } if (name_alignment) { - out() << "<tr><td class=\"memItemLeft\" " - << "align=\"right\" valign=\"top\">"; + out() << "<tr><td class=\"memItemLeft rightAlign topAlign\"> "; } else { if (twoColumn && i == (int) (nl.count() + 1) / 2) - out() << "</ul></td><td valign=\"top\"><ul>\n"; + out() << "</ul></td><td class=\"topAlign\"><ul>\n"; out() << "<li><div class=\"fn\">"; } @@ -2868,7 +2745,7 @@ void HtmlGenerator::generateSection(const NodeList& nl, else { out() << "</ul>\n"; if (twoColumn) - out() << "</td></tr>\n</table></p>\n"; + out() << "</td></tr>\n</table>\n"; } } } @@ -2894,8 +2771,8 @@ void HtmlGenerator::generateSectionList(const Section& section, } else { if (twoColumn) - out() << "<p><table class=\"propsummary\">\n" - << "<tr><td valign=\"top\">"; + out() << "<table class=\"propsummary\">\n" + << "<tr><td class=\"topAlign\">"; out() << "<ul>\n"; } @@ -2908,12 +2785,11 @@ void HtmlGenerator::generateSectionList(const Section& section, } if (name_alignment) { - out() << "<tr><td class=\"memItemLeft\" " - << "align=\"right\" valign=\"top\">"; + out() << "<tr><td class=\"memItemLeft topAlign rightAlign\"> "; } else { if (twoColumn && i == (int) (section.members.count() + 1) / 2) - out() << "</ul></td><td valign=\"top\"><ul>\n"; + out() << "</ul></td><td class=\"topAlign\"><ul>\n"; out() << "<li><div class=\"fn\">"; } @@ -2930,7 +2806,7 @@ void HtmlGenerator::generateSectionList(const Section& section, else { out() << "</ul>\n"; if (twoColumn) - out() << "</td></tr>\n</table></p>\n"; + out() << "</td></tr>\n</table>\n"; } } @@ -3027,7 +2903,7 @@ QString HtmlGenerator::highlightedCode(const QString& markedCode, for (int i = 0, n = src.size(); i < n;) { if (src.at(i) == charLangle && src.at(i + 1).unicode() == '@') { if (nameAlignment && !done) {// && (i != 0)) Why was this here? - html += "</td><td class=\"memItemRight\" valign=\"bottom\">"; + html += "</td><td class=\"memItemRight bottomAlign\">"; done = true; } i += 2; @@ -3192,8 +3068,8 @@ void HtmlGenerator::generateSectionList(const Section& section, twoColumn = (section.members.count() >= 5); } if (twoColumn) - out() << "<p><table class=\"generic\">\n" - << "<tr><td valign=\"top\">"; + out() << "<table class=\"generic\">\n" + << "<tr><td class=\"topAlign\">"; out() << "<ul>\n"; int i = 0; @@ -3205,7 +3081,7 @@ void HtmlGenerator::generateSectionList(const Section& section, } if (twoColumn && i == (int) (section.members.count() + 1) / 2) - out() << "</ul></td><td valign=\"top\"><ul>\n"; + out() << "</ul></td><td class=\"topAlign\"><ul>\n"; out() << "<li><div class=\"fn\"></div>"; if (style == CodeMarker::Accessors) @@ -3219,7 +3095,7 @@ void HtmlGenerator::generateSectionList(const Section& section, } out() << "</ul>\n"; if (twoColumn) - out() << "</td></tr>\n</table></p>\n"; + out() << "</td></tr>\n</table>\n"; } if (style == CodeMarker::Summary && !section.inherited.isEmpty()) { @@ -4371,8 +4247,6 @@ void HtmlGenerator::endLink() inObsoleteLink = false; } -QT_END_NAMESPACE - #ifdef QDOC_QML /*! @@ -4393,15 +4267,15 @@ void HtmlGenerator::generateQmlSummary(const Section& section, twoColumn = (count >= 5); } if (twoColumn) - out() << "<p><table class=\"qmlsummary\">\n" - << "<tr><td valign=\"top\">"; + out() << "<table class=\"qmlsummary\">\n" + << "<tr><td class=\"topAlign\">"; out() << "<ul>\n"; int row = 0; m = section.members.begin(); while (m != section.members.end()) { if (twoColumn && row == (int) (count + 1) / 2) - out() << "</ul></td><td valign=\"top\"><ul>\n"; + out() << "</ul></td><td class=\"topAlign\"><ul>\n"; out() << "<li><div class=\"fn\"></div>"; generateQmlItem(*m,relative,marker,true); out() << "</li>\n"; @@ -4410,7 +4284,7 @@ void HtmlGenerator::generateQmlSummary(const Section& section, } out() << "</ul>\n"; if (twoColumn) - out() << "</td></tr>\n</table></p>\n"; + out() << "</td></tr>\n</table>\n"; } } @@ -4502,7 +4376,7 @@ void HtmlGenerator::generateQmlInherits(const QmlClassNode* cn, const Node* n = myTree->findNode(strList,Node::Fake); if (n && n->subType() == Node::QmlClass) { const QmlClassNode* qcn = static_cast<const QmlClassNode*>(n); - out() << "<p style=\"text-align: center\">"; + out() << "<p class=\"centerAlign\">"; Text text; text << "[Inherits "; text << Atom(Atom::LinkNode,CodeMarker::stringForNode(qcn)); @@ -4549,7 +4423,7 @@ void HtmlGenerator::generateQmlInstantiates(const QmlClassNode* qcn, { const ClassNode* cn = qcn->classNode(); if (cn && (cn->status() != Node::Internal)) { - out() << "<p style=\"text-align: center\">"; + out() << "<p class=\"centerAlign\">"; Text text; text << "["; text << Atom(Atom::LinkNode,CodeMarker::stringForNode(qcn)); @@ -4580,7 +4454,7 @@ void HtmlGenerator::generateInstantiatedBy(const ClassNode* cn, if (cn && cn->status() != Node::Internal && !cn->qmlElement().isEmpty()) { const Node* n = myTree->root()->findNode(cn->qmlElement(),Node::Fake); if (n && n->subType() == Node::QmlClass) { - out() << "<p style=\"text-align: center\">"; + out() << "<p class=\"centerAlign\">"; Text text; text << "["; text << Atom(Atom::LinkNode,CodeMarker::stringForNode(cn)); @@ -4724,3 +4598,139 @@ void HtmlGenerator::generatePageIndex(const QString& fileName, CodeMarker* marke } #endif + +#if 0 // fossil removed for new doc format MWS 19/04/2010 + out() << "<!DOCTYPE html\n" + " PUBLIC \"-//W3C//DTD XHTML 1.0 Strict//EN\" \"DTD/xhtml1-strict.dtd\">\n"; + out() << QString("<html xmlns=\"http://www.w3.org/1999/xhtml\" xml:lang=\"%1\" lang=\"%1\">\n").arg(naturalLanguage); + + QString shortVersion; + if ((project != "Qtopia") && (project != "Qt Extended")) { + shortVersion = project + " " + shortVersion + ": "; + if (node && !node->doc().location().isEmpty()) + out() << "<!-- " << node->doc().location().fileName() << " -->\n"; + + shortVersion = myTree->version(); + if (shortVersion.count(QChar('.')) == 2) + shortVersion.truncate(shortVersion.lastIndexOf(QChar('.'))); + if (!shortVersion.isEmpty()) { + if (project == "QSA") + shortVersion = "QSA " + shortVersion + ": "; + else + shortVersion = "Qt " + shortVersion + ": "; + } + } + + out() << "<head>\n" + " <title>" << shortVersion << protectEnc(title) << "</title>\n"; + out() << QString("<meta http-equiv=\"Content-type\" content=\"text/html; charset=%1\" />").arg(outputEncoding); + + if (!style.isEmpty()) + out() << " <style type=\"text/css\">" << style << "</style>\n"; + + const QMap<QString, QString> &metaMap = node->doc().metaTagMap(); + if (!metaMap.isEmpty()) { + QMapIterator<QString, QString> i(metaMap); + while (i.hasNext()) { + i.next(); + out() << " <meta name=\"" << protectEnc(i.key()) << "\" contents=\"" + << protectEnc(i.value()) << "\" />\n"; + } + } + + navigationLinks.clear(); + + if (node && !node->links().empty()) { + QPair<QString,QString> linkPair; + QPair<QString,QString> anchorPair; + const Node *linkNode; + + if (node->links().contains(Node::PreviousLink)) { + linkPair = node->links()[Node::PreviousLink]; + linkNode = findNodeForTarget(linkPair.first, node, marker); + if (!linkNode || linkNode == node) + anchorPair = linkPair; + else + anchorPair = anchorForNode(linkNode); + + out() << " <link rel=\"prev\" href=\"" + << anchorPair.first << "\" />\n"; + + navigationLinks += "[Previous: <a href=\"" + anchorPair.first + "\">"; + if (linkPair.first == linkPair.second && !anchorPair.second.isEmpty()) + navigationLinks += protectEnc(anchorPair.second); + else + navigationLinks += protectEnc(linkPair.second); + navigationLinks += "</a>]\n"; + } + if (node->links().contains(Node::ContentsLink)) { + linkPair = node->links()[Node::ContentsLink]; + linkNode = findNodeForTarget(linkPair.first, node, marker); + if (!linkNode || linkNode == node) + anchorPair = linkPair; + else + anchorPair = anchorForNode(linkNode); + + out() << " <link rel=\"contents\" href=\"" + << anchorPair.first << "\" />\n"; + + navigationLinks += "[<a href=\"" + anchorPair.first + "\">"; + if (linkPair.first == linkPair.second && !anchorPair.second.isEmpty()) + navigationLinks += protectEnc(anchorPair.second); + else + navigationLinks += protectEnc(linkPair.second); + navigationLinks += "</a>]\n"; + } + if (node->links().contains(Node::NextLink)) { + linkPair = node->links()[Node::NextLink]; + linkNode = findNodeForTarget(linkPair.first, node, marker); + if (!linkNode || linkNode == node) + anchorPair = linkPair; + else + anchorPair = anchorForNode(linkNode); + + out() << " <link rel=\"next\" href=\"" + << anchorPair.first << "\" />\n"; + + navigationLinks += "[Next: <a href=\"" + anchorPair.first + "\">"; + if (linkPair.first == linkPair.second && !anchorPair.second.isEmpty()) + navigationLinks += protectEnc(anchorPair.second); + else + navigationLinks += protectEnc(linkPair.second); + navigationLinks += "</a>]\n"; + } + if (node->links().contains(Node::IndexLink)) { + linkPair = node->links()[Node::IndexLink]; + linkNode = findNodeForTarget(linkPair.first, node, marker); + if (!linkNode || linkNode == node) + anchorPair = linkPair; + else + anchorPair = anchorForNode(linkNode); + out() << " <link rel=\"index\" href=\"" + << anchorPair.first << "\" />\n"; + } + if (node->links().contains(Node::StartLink)) { + linkPair = node->links()[Node::StartLink]; + linkNode = findNodeForTarget(linkPair.first, node, marker); + if (!linkNode || linkNode == node) + anchorPair = linkPair; + else + anchorPair = anchorForNode(linkNode); + out() << " <link rel=\"start\" href=\"" + << anchorPair.first << "\" />\n"; + } + } + + foreach (const QString &stylesheet, stylesheets) { + out() << " <link href=\"" << stylesheet << "\" rel=\"stylesheet\" " + << "type=\"text/css\" />\n"; + } + + foreach (const QString &customHeadElement, customHeadElements) { + out() << " " << customHeadElement << "\n"; + } + + out() << "</head>\n" + #endif + + QT_END_NAMESPACE diff --git a/tools/qdoc3/htmlgenerator.h b/tools/qdoc3/htmlgenerator.h index 559c968..2a365e9 100644 --- a/tools/qdoc3/htmlgenerator.h +++ b/tools/qdoc3/htmlgenerator.h @@ -297,6 +297,7 @@ class HtmlGenerator : public PageGenerator bool inTableHeader; int numTableRows; bool threeColumnEnumValueTable; + bool offlineDocs; QString link; QStringList sectionNumber; QRegExp funcLeftParen; diff --git a/tools/qdoc3/test/assistant.qdocconf b/tools/qdoc3/test/assistant.qdocconf index 5308afd..1deefce 100644 --- a/tools/qdoc3/test/assistant.qdocconf +++ b/tools/qdoc3/test/assistant.qdocconf @@ -16,7 +16,45 @@ qhp.Assistant.file = assistant.qhp qhp.Assistant.namespace = com.trolltech.assistant.470 qhp.Assistant.virtualFolder = qdoc qhp.Assistant.indexTitle = Qt Assistant Manual -qhp.Assistant.extraFiles = classic.css images/qt-logo.png images/trolltech-logo.png +qhp.Assistant.extraFiles = images/api_examples.png \ + images/api_lookup.png \ + images/api_topics.png \ + images/bg_l_blank.png \ + images/bg_ll_blank.png \ + images/bg_ll.png \ + images/bg_l.png \ + images/bg_lr.png \ + images/bg_r.png \ + images/bg_ul_blank.png \ + images/bg_ul.png \ + images/bg_ur_blank.png \ + images/bg_ur.png \ + images/box_bg.png \ + images/breadcrumb.png \ + images/bullet_dn.png \ + images/bullet_gt.png \ + images/bullet_sq.png \ + images/bullet_up.png \ + images/coloreditorfactoryimage.png \ + images/content_bg.png \ + images/dynamiclayouts-example.png \ + images/feedbackground.png \ + images/form_bg.png \ + images/horBar.png \ + images/page_bg.png \ + images/print.png \ + images/qt_guide.png \ + images/qt_icon.png \ + images/qt-logo.png \ + images/qt_ref_doc.png \ + images/qt_tools.png \ + images/sep.png \ + images/sprites-combined.png \ + images/stylesheet-coffee-plastique.png \ + images/taskmenuextension-example.png \ + scripts/functions.js \ + scripts/jquery.js \ + style/style.css qhp.Assistant.filterAttributes = qt 4.7.0 tools assistant qhp.Assistant.customFilters.Assistant.name = Qt Assistant Manual qhp.Assistant.customFilters.Assistant.filterAttributes = qt tools assistant diff --git a/tools/qdoc3/test/designer.qdocconf b/tools/qdoc3/test/designer.qdocconf index 2eb3d96..513801a 100644 --- a/tools/qdoc3/test/designer.qdocconf +++ b/tools/qdoc3/test/designer.qdocconf @@ -16,7 +16,45 @@ qhp.Designer.file = designer.qhp qhp.Designer.namespace = com.trolltech.designer.470 qhp.Designer.virtualFolder = qdoc qhp.Designer.indexTitle = Qt Designer Manual -qhp.Designer.extraFiles = classic.css images/qt-logo.png images/trolltech-logo.png +qhp.Designer.extraFiles = images/api_examples.png \ + images/api_lookup.png \ + images/api_topics.png \ + images/bg_l_blank.png \ + images/bg_ll_blank.png \ + images/bg_ll.png \ + images/bg_l.png \ + images/bg_lr.png \ + images/bg_r.png \ + images/bg_ul_blank.png \ + images/bg_ul.png \ + images/bg_ur_blank.png \ + images/bg_ur.png \ + images/box_bg.png \ + images/breadcrumb.png \ + images/bullet_dn.png \ + images/bullet_gt.png \ + images/bullet_sq.png \ + images/bullet_up.png \ + images/coloreditorfactoryimage.png \ + images/content_bg.png \ + images/dynamiclayouts-example.png \ + images/feedbackground.png \ + images/form_bg.png \ + images/horBar.png \ + images/page_bg.png \ + images/print.png \ + images/qt_guide.png \ + images/qt_icon.png \ + images/qt-logo.png \ + images/qt_ref_doc.png \ + images/qt_tools.png \ + images/sep.png \ + images/sprites-combined.png \ + images/stylesheet-coffee-plastique.png \ + images/taskmenuextension-example.png \ + scripts/functions.js \ + scripts/jquery.js \ + style/style.css qhp.Designer.filterAttributes = qt 4.7.0 tools designer qhp.Designer.customFilters.Designer.name = Qt Designer Manual qhp.Designer.customFilters.Designer.filterAttributes = qt tools designer diff --git a/tools/qdoc3/test/linguist.qdocconf b/tools/qdoc3/test/linguist.qdocconf index ac536be..a3f4f00 100644 --- a/tools/qdoc3/test/linguist.qdocconf +++ b/tools/qdoc3/test/linguist.qdocconf @@ -16,7 +16,45 @@ qhp.Linguist.file = linguist.qhp qhp.Linguist.namespace = com.trolltech.linguist.470 qhp.Linguist.virtualFolder = qdoc qhp.Linguist.indexTitle = Qt Linguist Manual -qhp.Linguist.extraFiles = classic.css images/qt-logo.png images/trolltech-logo.png +qhp.Linguist.extraFiles = images/api_examples.png \ + images/api_lookup.png \ + images/api_topics.png \ + images/bg_l_blank.png \ + images/bg_ll_blank.png \ + images/bg_ll.png \ + images/bg_l.png \ + images/bg_lr.png \ + images/bg_r.png \ + images/bg_ul_blank.png \ + images/bg_ul.png \ + images/bg_ur_blank.png \ + images/bg_ur.png \ + images/box_bg.png \ + images/breadcrumb.png \ + images/bullet_dn.png \ + images/bullet_gt.png \ + images/bullet_sq.png \ + images/bullet_up.png \ + images/coloreditorfactoryimage.png \ + images/content_bg.png \ + images/dynamiclayouts-example.png \ + images/feedbackground.png \ + images/form_bg.png \ + images/horBar.png \ + images/page_bg.png \ + images/print.png \ + images/qt_guide.png \ + images/qt_icon.png \ + images/qt-logo.png \ + images/qt_ref_doc.png \ + images/qt_tools.png \ + images/sep.png \ + images/sprites-combined.png \ + images/stylesheet-coffee-plastique.png \ + images/taskmenuextension-example.png \ + scripts/functions.js \ + scripts/jquery.js \ + style/style.css qhp.Linguist.filterAttributes = qt 4.7.0 tools linguist qhp.Linguist.customFilters.Linguist.name = Qt Linguist Manual qhp.Linguist.customFilters.Linguist.filterAttributes = qt tools linguist diff --git a/tools/qdoc3/test/qdeclarative.qdocconf b/tools/qdoc3/test/qdeclarative.qdocconf index 03514c1..125a410 100644 --- a/tools/qdoc3/test/qdeclarative.qdocconf +++ b/tools/qdoc3/test/qdeclarative.qdocconf @@ -27,8 +27,45 @@ qhp.Qml.indexTitle = Qml Reference # Files not referenced in any qdoc file # See also extraimages.HTML -qhp.Qml.extraFiles = classic.css \ - images/qt-logo.png +qhp.Qml.extraFiles = images/api_examples.png \ + images/api_lookup.png \ + images/api_topics.png \ + images/bg_l_blank.png \ + images/bg_ll_blank.png \ + images/bg_ll.png \ + images/bg_l.png \ + images/bg_lr.png \ + images/bg_r.png \ + images/bg_ul_blank.png \ + images/bg_ul.png \ + images/bg_ur_blank.png \ + images/bg_ur.png \ + images/box_bg.png \ + images/breadcrumb.png \ + images/bullet_dn.png \ + images/bullet_gt.png \ + images/bullet_sq.png \ + images/bullet_up.png \ + images/coloreditorfactoryimage.png \ + images/content_bg.png \ + images/dynamiclayouts-example.png \ + images/feedbackground.png \ + images/form_bg.png \ + images/horBar.png \ + images/page_bg.png \ + images/print.png \ + images/qt_guide.png \ + images/qt_icon.png \ + images/qt-logo.png \ + images/qt_ref_doc.png \ + images/qt_tools.png \ + images/sep.png \ + images/sprites-combined.png \ + images/stylesheet-coffee-plastique.png \ + images/taskmenuextension-example.png \ + scripts/functions.js \ + scripts/jquery.js \ + style/style.css qhp.Qml.filterAttributes = qt 4.6.0 qtrefdoc qhp.Qml.customFilters.Qt.name = Qt 4.6.0 diff --git a/tools/qdoc3/test/qmake.qdocconf b/tools/qdoc3/test/qmake.qdocconf index bd47028..f38a2a4 100644 --- a/tools/qdoc3/test/qmake.qdocconf +++ b/tools/qdoc3/test/qmake.qdocconf @@ -16,7 +16,45 @@ qhp.qmake.file = qmake.qhp qhp.qmake.namespace = com.trolltech.qmake.470 qhp.qmake.virtualFolder = qdoc qhp.qmake.indexTitle = QMake Manual -qhp.qmake.extraFiles = classic.css images/qt-logo.png images/trolltech-logo.png +qhp.qmake.extraFiles = images/api_examples.png \ + images/api_lookup.png \ + images/api_topics.png \ + images/bg_l_blank.png \ + images/bg_ll_blank.png \ + images/bg_ll.png \ + images/bg_l.png \ + images/bg_lr.png \ + images/bg_r.png \ + images/bg_ul_blank.png \ + images/bg_ul.png \ + images/bg_ur_blank.png \ + images/bg_ur.png \ + images/box_bg.png \ + images/breadcrumb.png \ + images/bullet_dn.png \ + images/bullet_gt.png \ + images/bullet_sq.png \ + images/bullet_up.png \ + images/coloreditorfactoryimage.png \ + images/content_bg.png \ + images/dynamiclayouts-example.png \ + images/feedbackground.png \ + images/form_bg.png \ + images/horBar.png \ + images/page_bg.png \ + images/print.png \ + images/qt_guide.png \ + images/qt_icon.png \ + images/qt-logo.png \ + images/qt_ref_doc.png \ + images/qt_tools.png \ + images/sep.png \ + images/sprites-combined.png \ + images/stylesheet-coffee-plastique.png \ + images/taskmenuextension-example.png \ + scripts/functions.js \ + scripts/jquery.js \ + style/style.css qhp.qmake.filterAttributes = qt 4.7.0 tools qmake qhp.qmake.customFilters.qmake.name = qmake Manual qhp.qmake.customFilters.qmake.filterAttributes = qt tools qmake diff --git a/tools/qdoc3/test/qt-build-docs.qdocconf b/tools/qdoc3/test/qt-build-docs.qdocconf index dbff4e2..0694748 100644 --- a/tools/qdoc3/test/qt-build-docs.qdocconf +++ b/tools/qdoc3/test/qt-build-docs.qdocconf @@ -22,14 +22,12 @@ qhp.Qt.indexTitle = Qt Reference Documentation # Files not referenced in any qdoc file (last four are needed by qtdemo) # See also extraimages.HTML qhp.Qt.extraFiles = index.html \ - style/style.css \ - scripts/functions.js \ - scripts/jquery.js \ images/api_examples.png \ images/api_lookup.png \ images/api_topics.png \ - images/bg_ll.png \ images/bg_l_blank.png \ + images/bg_ll_blank.png \ + images/bg_ll.png \ images/bg_l.png \ images/bg_lr.png \ images/bg_r.png \ @@ -37,24 +35,33 @@ qhp.Qt.extraFiles = index.html \ images/bg_ul.png \ images/bg_ur_blank.png \ images/bg_ur.png \ + images/box_bg.png \ images/breadcrumb.png \ images/bullet_dn.png \ images/bullet_gt.png \ + images/bullet_sq.png \ + images/bullet_up.png \ + images/coloreditorfactoryimage.png \ + images/content_bg.png \ + images/dynamiclayouts-example.png \ images/feedbackground.png \ images/form_bg.png \ images/horBar.png \ images/page_bg.png \ images/print.png \ images/qt_guide.png \ + images/qt_icon.png \ images/qt-logo.png \ images/qt_ref_doc.png \ images/qt_tools.png \ images/sep.png \ images/sprites-combined.png \ + images/stylesheet-coffee-plastique.png \ images/taskmenuextension-example.png \ - images/coloreditorfactoryimage.png \ - images/dynamiclayouts-example.png \ - images/stylesheet-coffee-plastique.png + scripts/functions.js \ + scripts/jquery.js \ + style/style.css + qhp.Qt.filterAttributes = qt 4.7.0 qtrefdoc diff --git a/tools/qdoc3/test/qt-build-docs_zh_CN.qdocconf b/tools/qdoc3/test/qt-build-docs_zh_CN.qdocconf index 461c069..5a3d726 100644 --- a/tools/qdoc3/test/qt-build-docs_zh_CN.qdocconf +++ b/tools/qdoc3/test/qt-build-docs_zh_CN.qdocconf @@ -30,14 +30,12 @@ qhp.Qt.customFilters.Qt.filterAttributes = qt 4.7.0 # Files not referenced in any qdoc file (last four are needed by qtdemo) # See also extraimages.HTML qhp.Qt.extraFiles = index.html \ - style/style.css \ - scripts/functions.js \ - scripts/jquery.js \ images/api_examples.png \ images/api_lookup.png \ images/api_topics.png \ - images/bg_ll.png \ images/bg_l_blank.png \ + images/bg_ll_blank.png \ + images/bg_ll.png \ images/bg_l.png \ images/bg_lr.png \ images/bg_r.png \ @@ -45,24 +43,32 @@ qhp.Qt.extraFiles = index.html \ images/bg_ul.png \ images/bg_ur_blank.png \ images/bg_ur.png \ + images/box_bg.png \ images/breadcrumb.png \ images/bullet_dn.png \ images/bullet_gt.png \ + images/bullet_sq.png \ + images/bullet_up.png \ + images/coloreditorfactoryimage.png \ + images/content_bg.png \ + images/dynamiclayouts-example.png \ images/feedbackground.png \ images/form_bg.png \ images/horBar.png \ images/page_bg.png \ images/print.png \ images/qt_guide.png \ + images/qt_icon.png \ images/qt-logo.png \ images/qt_ref_doc.png \ images/qt_tools.png \ images/sep.png \ images/sprites-combined.png \ + images/stylesheet-coffee-plastique.png \ images/taskmenuextension-example.png \ - images/coloreditorfactoryimage.png \ - images/dynamiclayouts-example.png \ - images/stylesheet-coffee-plastique.png + scripts/functions.js \ + scripts/jquery.js \ + style/style.css language = Cpp diff --git a/tools/qdoc3/test/qt-html-templates.qdocconf b/tools/qdoc3/test/qt-html-templates.qdocconf index 67a25f3..158aef3 100644 --- a/tools/qdoc3/test/qt-html-templates.qdocconf +++ b/tools/qdoc3/test/qt-html-templates.qdocconf @@ -2,7 +2,7 @@ HTML.stylesheets = style/style.css HTML.postheader = " <div class=\"header\" id=\"qtdocheader\">\n" \ " <div id=\"nav-logo\">\n" \ " <a href=\"index.html\">Home</a></div>\n" \ - " <a href=\"#\" class=\"qtref\"><span>Qt Reference Documentation</span></a>\n" \ + " <a href=\"index.html\" class=\"qtref\"><span>Qt Reference Documentation</span></a>\n" \ " <div id=\"nav-topright\">\n" \ " <ul>\n" \ " <li class=\"nav-topright-home\"><a href=\"http://qt.nokia.com/\">Qt HOME</a></li>\n" \ @@ -16,8 +16,8 @@ HTML.postheader = " <div class=\"header\" id=\"qtdocheader\">\n" \ " </div>\n" \ " <div id=\"shortCut\">\n" \ " <ul>\n" \ - " <li class=\"shortCut-topleft-inactive\"><span><a href=\"index.html\">VERSION 4.7</a></span></li>\n" \ - " <li class=\"shortCut-topleft-active\"><a href=\"http://qt.nokia.com/doc/\">ALL QT VERSIONS" \ + " <li class=\"shortCut-topleft-inactive\"><span><a href=\"index.html\">Qt 4.7</a></span></li>\n" \ + " <li class=\"shortCut-topleft-active\"><a href=\"http://qt.nokia.com/doc/\">ALL Qt VERSIONS" \ " </a></li>\n" \ " </ul>\n" \ " </div>\n" \ @@ -73,9 +73,9 @@ HTML.postheader = " <div class=\"header\" id=\"qtdocheader\">\n" \ " <ul>\n" \ " <li><a href=\"examples.html\">All examples</a></li>\n" \ " <li><a href=\"tutorials.html\">All tutorials</a></li>\n" \ - " <li><a href=\"#\">Qt Quick examples</a></li>\n" \ - " <li><a href=\"#\">Desktop examples</a></li>\n" \ - " <li><a href=\"#\">Device examples</a></li>\n" \ + " <li><a href=\"examples.html\">Qt Quick examples</a></li>\n" \ + " <li><a href=\"examples.html\">Desktop examples</a></li>\n" \ + " <li><a href=\"examples.html\">Device examples</a></li>\n" \ " </ul>\n" \ " </div>\n" \ " <div class=\"live\">\n" \ @@ -96,7 +96,7 @@ HTML.postheader = " <div class=\"header\" id=\"qtdocheader\">\n" \ " <li id=\"medA\" class=\"t_button active\">A</li>\n" \ " <li id=\"bigA\" class=\"t_button\">A</li>\n" \ " <li id=\"print\" class=\"t_button\"><a href=\"javascript:this.print();\">\n" \ - " <img src=\"images/sep.png\" /><img id=\"printIcon\" src=\"images/print.png\" alt=\"Print this page\" /></a></li>\n" \ + " <img src=\"images/sep.png\" alt=\"\" /><img id=\"printIcon\" src=\"images/print.png\" alt=\"Print this page\" /></a></li>\n" \ " </ul>\n" \ " </div>\n" \ " </div>\n" \ @@ -110,7 +110,6 @@ HTML.footer = " </div>\n" \ " <div class=\"ft\">\n" \ " <span></span>\n" \ " </div>\n" \ - " </div>\n" \ " <div class=\"footer\">\n" \ " <p>\n" \ " <acronym title=\"Copyright\">©</acronym> 2008-2010 Nokia Corporation and/or its\n" \ @@ -121,10 +120,10 @@ HTML.footer = " </div>\n" \ " href=\"http://qt.nokia.com/about/privacy-policy\">Privacy Policy</a></p>\n" \ " </div>\n" \ " <div id=\"feedbackBox\">\n" \ - " <form action=\"#\">\n" \ " <div id=\"feedcloseX\">\n" \ " <a href=\"#\" onclick=\"\$(\'#feedbackBox\').hide();\$(\'#blurpage\').hide()\">X</a>\n" \ " </div>\n" \ + " <form action=\"#\">\n" \ " <textarea id=\"feedbox\" rows=\"5\" cols=\"40\">Please submit you feedback...</textarea>\n" \ " <input id=\"feedsubmit\" type=\"submit\" onclick=\"\$(\'#feedbackBox\').hide();\$(\'#blurpage\').hide()\"\n" \ " name=\"feedback\" />\n" \ @@ -132,7 +131,6 @@ HTML.footer = " </div>\n" \ " </div>\n" \ " <div id=\"blurpage\">\n" \ " </div>\n" \ - " <script src=\"scripts/functions.js\" type=\"text/javascript\"></script>\n" \ "<script type=\"text/javascript\">\n" \ " var _gaq = _gaq || [];\n" \ " _gaq.push([\'_setAccount\', \'UA-4457116-5\']);\n" \ diff --git a/tools/qdoc3/test/qt.qdocconf b/tools/qdoc3/test/qt.qdocconf index cc3e436..69ab4e1 100644 --- a/tools/qdoc3/test/qt.qdocconf +++ b/tools/qdoc3/test/qt.qdocconf @@ -9,6 +9,7 @@ versionsym = version = %VERSION% description = Qt Reference Documentation url = http://qt.nokia.com/doc/4.7 +online = true sourceencoding = UTF-8 outputencoding = UTF-8 @@ -25,14 +26,12 @@ qhp.Qt.indexRoot = # Files not referenced in any qdoc file (last four are needed by qtdemo) # See also extraimages.HTML qhp.Qt.extraFiles = index.html \ - style/style.css \ - scripts/functions.js \ - scripts/jquery.js \ images/api_examples.png \ images/api_lookup.png \ images/api_topics.png \ - images/bg_ll.png \ images/bg_l_blank.png \ + images/bg_ll_blank.png \ + images/bg_ll.png \ images/bg_l.png \ images/bg_lr.png \ images/bg_r.png \ @@ -40,24 +39,32 @@ qhp.Qt.extraFiles = index.html \ images/bg_ul.png \ images/bg_ur_blank.png \ images/bg_ur.png \ + images/box_bg.png \ images/breadcrumb.png \ images/bullet_dn.png \ images/bullet_gt.png \ + images/bullet_sq.png \ + images/bullet_up.png \ + images/coloreditorfactoryimage.png \ + images/content_bg.png \ + images/dynamiclayouts-example.png \ images/feedbackground.png \ images/form_bg.png \ images/horBar.png \ images/page_bg.png \ images/print.png \ images/qt_guide.png \ + images/qt_icon.png \ images/qt-logo.png \ images/qt_ref_doc.png \ images/qt_tools.png \ images/sep.png \ images/sprites-combined.png \ + images/stylesheet-coffee-plastique.png \ images/taskmenuextension-example.png \ - images/coloreditorfactoryimage.png \ - images/dynamiclayouts-example.png \ - images/stylesheet-coffee-plastique.png + scripts/functions.js \ + scripts/jquery.js \ + style/style.css qhp.Qt.filterAttributes = qt 4.7.0 qtrefdoc qhp.Qt.customFilters.Qt.name = Qt 4.7.0 diff --git a/tools/qdoc3/test/qt_zh_CN.qdocconf b/tools/qdoc3/test/qt_zh_CN.qdocconf index c5d2c88..a5a65d8 100644 --- a/tools/qdoc3/test/qt_zh_CN.qdocconf +++ b/tools/qdoc3/test/qt_zh_CN.qdocconf @@ -32,14 +32,12 @@ qhp.Qt.customFilters.Qt.filterAttributes = qt 4.7.0 # Files not referenced in any qdoc file (last four are needed by qtdemo) # See also extraimages.HTML qhp.Qt.extraFiles = index.html \ - style/style.css \ - scripts/functions.js \ - scripts/jquery.js \ images/api_examples.png \ images/api_lookup.png \ images/api_topics.png \ - images/bg_ll.png \ images/bg_l_blank.png \ + images/bg_ll_blank.png \ + images/bg_ll.png \ images/bg_l.png \ images/bg_lr.png \ images/bg_r.png \ @@ -47,24 +45,32 @@ qhp.Qt.extraFiles = index.html \ images/bg_ul.png \ images/bg_ur_blank.png \ images/bg_ur.png \ + images/box_bg.png \ images/breadcrumb.png \ images/bullet_dn.png \ images/bullet_gt.png \ + images/bullet_sq.png \ + images/bullet_up.png \ + images/coloreditorfactoryimage.png \ + images/content_bg.png \ + images/dynamiclayouts-example.png \ images/feedbackground.png \ images/form_bg.png \ images/horBar.png \ images/page_bg.png \ images/print.png \ images/qt_guide.png \ + images/qt_icon.png \ images/qt-logo.png \ images/qt_ref_doc.png \ images/qt_tools.png \ images/sep.png \ images/sprites-combined.png \ + images/stylesheet-coffee-plastique.png \ images/taskmenuextension-example.png \ - images/coloreditorfactoryimage.png \ - images/dynamiclayouts-example.png \ - images/stylesheet-coffee-plastique.png + scripts/functions.js \ + scripts/jquery.js \ + style/style.css language = Cpp diff --git a/tools/qtconfig/mainwindow.cpp b/tools/qtconfig/mainwindow.cpp index 0de4b43..9675f99 100644 --- a/tools/qtconfig/mainwindow.cpp +++ b/tools/qtconfig/mainwindow.cpp @@ -432,7 +432,7 @@ MainWindow::MainWindow() #endif #ifndef QT_NO_OPENGL videomodeCombo->addItem(tr("OpenGL"), QLatin1String("OpenGL")); - videomodeCombo->setItemData(videomodeCombo->findText(tr("OpenGL")), tr("Use OpenGL if avaiable"), Qt::ToolTipRole); + videomodeCombo->setItemData(videomodeCombo->findText(tr("OpenGL")), tr("Use OpenGL if available"), Qt::ToolTipRole); #endif videomodeCombo->addItem(tr("Software"), QLatin1String("Software")); videomodeCombo->setItemData(videomodeCombo->findText(tr("Software")), tr("Use simple software rendering"), Qt::ToolTipRole); diff --git a/tools/qtestlib/wince/cetest/main.cpp b/tools/qtestlib/wince/cetest/main.cpp index 9fe5f02..4272a83 100644 --- a/tools/qtestlib/wince/cetest/main.cpp +++ b/tools/qtestlib/wince/cetest/main.cpp @@ -285,10 +285,14 @@ int main(int argc, char **argv) } // Check wether the project is still in debug/release mode after reading // If .pro specifies to be one mode only, we need to accept this - if (project.isActiveConfig("debug")) + if (project.isActiveConfig("debug") && !project.isActiveConfig("release")) { TestConfiguration::testDebug = true; - else + debugOutput("ActiveConfig: debug only in .pro.", 1); + } + if (!project.isActiveConfig("debug") && project.isActiveConfig("release")) { TestConfiguration::testDebug = false; + debugOutput("ActiveConfig: release only in .pro.", 1); + } // determine what is the real mkspec to use if the default mkspec is being used if (Option::mkfile::qmakespec.endsWith("/default")) |