Doc: Simplify qtbase qdocconfs.
authorCasper van Donderen <casper.vandonderen@nokia.com>
Thu, 30 Aug 2012 15:51:30 +0000 (17:51 +0200)
committerQt by Nokia <qt-info@nokia.com>
Thu, 30 Aug 2012 23:16:56 +0000 (01:16 +0200)
We should be using the global qdocconf for the common variables. This
change also allows you to just specify -installdir without using a
templatedir.

Change-Id: I207d279d9b5199212e896fc5ccab5c212b1896c6
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>
13 files changed:
doc/global/qt-html-templates-offline.qdocconf
src/concurrent/doc/qtconcurrent.qdocconf
src/corelib/doc/qtcore.qdocconf
src/dbus/doc/qtdbus.qdocconf
src/gui/doc/qtgui.qdocconf
src/network/doc/qtnetwork.qdocconf
src/opengl/doc/qtopengl.qdocconf
src/printsupport/doc/qtprintsupport.qdocconf
src/sql/doc/qtsql.qdocconf
src/testlib/doc/qttest.qdocconf
src/tools/qdoc/generator.cpp
src/widgets/doc/qtwidgets.qdocconf
src/xml/doc/qtxml.qdocconf

index 3943554..08eb291 100644 (file)
@@ -1,3 +1,14 @@
+HTML.generatemacrefs    = "true"
+HTML.nobreadcrumbs      = "true"
+
+HTML.stylesheets = global/style/offline.css
+
+HTML.headerstyles = \
+    "  <link rel=\"stylesheet\" type=\"text/css\" href=\"style/offline.css\" />\n"
+
+HTML.endheader = \
+    "</head>\n" \
+
 HTML.footer = \
     "<div class=\"footer\">\n" \
     "    <p>\n" \
index a20d0b4..4d5bc91 100644 (file)
@@ -1,5 +1,5 @@
-include(../../../doc/global/qt-html-templates-offline.qdocconf)
-include(../../../doc/global/qt-cpp-ignore.qdocconf)
+include(global/qt-html-templates-offline.qdocconf)
+include(global/qt-cpp-ignore.qdocconf)
 
 project                 = QtConcurrent
 description             = Qt Concurrent Reference Documentation
@@ -48,19 +48,6 @@ examples.imageextensions = "*.png"
 outputdir               = ../../../doc/qtconcurrent
 tagfile                 = ../../../doc/qtconcurrent/qtconcurrent.tags
 
-HTML.generatemacrefs    = "true"
-HTML.nobreadcrumbs      = "true"
-
-HTML.templatedir = .
-
-HTML.stylesheets = ../../../doc/global/style/offline.css
-
-HTML.headerstyles = \
-    "  <link rel=\"stylesheet\" type=\"text/css\" href=\"style/offline.css\" />\n"
-
-HTML.endheader = \
-    "</head>\n" \
-
 defines                 = Q_QDOC \
                           QT_.*_SUPPORT \
                           QT_.*_LIB \
index 1e5da05..69c753b 100644 (file)
@@ -1,5 +1,5 @@
-include(../../../doc/global/qt-html-templates-offline.qdocconf)
-include(../../../doc/global/qt-cpp-ignore.qdocconf)
+include(global/qt-html-templates-offline.qdocconf)
+include(global/qt-cpp-ignore.qdocconf)
 
 project                 = QtCore
 description             = Qt Core Reference Documentation
@@ -48,19 +48,6 @@ examples.imageextensions = "*.png"
 outputdir               = ../../../doc/qtcore
 tagfile                 = ../../../doc/qtcore/qtcore.tags
 
-HTML.generatemacrefs    = "true"
-HTML.nobreadcrumbs      = "true"
-
-HTML.templatedir = .
-
-HTML.stylesheets = ../../../doc/global/style/offline.css
-
-HTML.headerstyles = \
-    "  <link rel=\"stylesheet\" type=\"text/css\" href=\"style/offline.css\" />\n"
-
-HTML.endheader = \
-    "</head>\n" \
-
 defines                 = Q_QDOC \
                           QT_.*_SUPPORT \
                           QT_.*_LIB \
index b4bfdc7..e789fb3 100644 (file)
@@ -1,5 +1,5 @@
-include(../../../doc/global/qt-html-templates-offline.qdocconf)
-include(../../../doc/global/qt-cpp-ignore.qdocconf)
+include(global/qt-html-templates-offline.qdocconf)
+include(global/qt-cpp-ignore.qdocconf)
 
 project                 = QtDBus
 description             = Qt DBus Reference Documentation
@@ -48,19 +48,6 @@ examples.imageextensions = "*.png"
 outputdir               = ../../../doc/qtdbus
 tagfile                 = ../../../doc/qtdbus/qtdbus.tags
 
-HTML.generatemacrefs    = "true"
-HTML.nobreadcrumbs      = "true"
-
-HTML.templatedir = .
-
-HTML.stylesheets = ../../../doc/global/style/offline.css
-
-HTML.headerstyles = \
-    "  <link rel=\"stylesheet\" type=\"text/css\" href=\"style/offline.css\" />\n"
-
-HTML.endheader = \
-    "</head>\n" \
-
 defines                 = Q_QDOC \
                           QT_.*_SUPPORT \
                           QT_.*_LIB \
index da2122a..5fdc9b7 100644 (file)
@@ -1,5 +1,5 @@
-include(../../../doc/global/qt-html-templates-offline.qdocconf)
-include(../../../doc/global/qt-cpp-ignore.qdocconf)
+include(global/qt-html-templates-offline.qdocconf)
+include(global/qt-cpp-ignore.qdocconf)
 
 project                 = QtGui
 description             = Qt GUI Reference Documentation
@@ -48,19 +48,6 @@ examples.imageextensions = "*.png"
 outputdir               = ../../../doc/qtgui
 tagfile                 = ../../../doc/qtgui/qtgui.tags
 
-HTML.generatemacrefs    = "true"
-HTML.nobreadcrumbs      = "true"
-
-HTML.templatedir = .
-
-HTML.stylesheets = ../../../doc/global/style/offline.css
-
-HTML.headerstyles = \
-    "  <link rel=\"stylesheet\" type=\"text/css\" href=\"style/offline.css\" />\n"
-
-HTML.endheader = \
-    "</head>\n" \
-
 defines                 = Q_QDOC \
                           QT_.*_SUPPORT \
                           QT_.*_LIB \
index d95e415..1e9d743 100644 (file)
@@ -1,5 +1,5 @@
-include(../../../doc/global/qt-html-templates-offline.qdocconf)
-include(../../../doc/global/qt-cpp-ignore.qdocconf)
+include(global/qt-html-templates-offline.qdocconf)
+include(global/qt-cpp-ignore.qdocconf)
 
 project                 = QtNetwork
 description             = Qt Network Reference Documentation
@@ -48,19 +48,6 @@ examples.imageextensions = "*.png"
 outputdir               = ../../../doc/qtnetwork
 tagfile                 = ../../../doc/qtnetwork/qtnetwork.tags
 
-HTML.generatemacrefs    = "true"
-HTML.nobreadcrumbs      = "true"
-
-HTML.templatedir = .
-
-HTML.stylesheets = ../../../doc/global/style/offline.css
-
-HTML.headerstyles = \
-    "  <link rel=\"stylesheet\" type=\"text/css\" href=\"style/offline.css\" />\n"
-
-HTML.endheader = \
-    "</head>\n" \
-
 defines                 = Q_QDOC \
                           QT_.*_SUPPORT \
                           QT_.*_LIB \
index 644cf57..58ead7c 100644 (file)
@@ -1,5 +1,5 @@
-include(../../../doc/global/qt-html-templates-offline.qdocconf)
-include(../../../doc/global/qt-cpp-ignore.qdocconf)
+include(global/qt-html-templates-offline.qdocconf)
+include(global/qt-cpp-ignore.qdocconf)
 
 project                 = QtOpenGL
 description             = Qt OpenGL Reference Documentation
@@ -48,19 +48,6 @@ examples.imageextensions = "*.png"
 outputdir               = ../../../doc/qtopengl
 tagfile                 = ../../../doc/qtopengl/qtopengl.tags
 
-HTML.generatemacrefs    = "true"
-HTML.nobreadcrumbs      = "true"
-
-HTML.templatedir = .
-
-HTML.stylesheets = ../../../doc/global/style/offline.css
-
-HTML.headerstyles = \
-    "  <link rel=\"stylesheet\" type=\"text/css\" href=\"style/offline.css\" />\n"
-
-HTML.endheader = \
-    "</head>\n" \
-
 defines                 = Q_QDOC \
                           QT_.*_SUPPORT \
                           QT_.*_LIB \
index 00e9c9f..e2d4875 100644 (file)
@@ -1,5 +1,5 @@
-include(../../../doc/global/qt-html-templates-offline.qdocconf)
-include(../../../doc/global/qt-cpp-ignore.qdocconf)
+include(global/qt-html-templates-offline.qdocconf)
+include(global/qt-cpp-ignore.qdocconf)
 
 project                 = QtPrintSupport
 description             = Qt Print Support Reference Documentation
@@ -48,19 +48,6 @@ examples.imageextensions = "*.png"
 outputdir               = ../../../doc/qtprintsupport
 tagfile                 = ../../../doc/qtprintsupport/qtprintsupport.tags
 
-HTML.generatemacrefs    = "true"
-HTML.nobreadcrumbs      = "true"
-
-HTML.templatedir = .
-
-HTML.stylesheets = ../../../doc/global/style/offline.css
-
-HTML.headerstyles = \
-    "  <link rel=\"stylesheet\" type=\"text/css\" href=\"style/offline.css\" />\n"
-
-HTML.endheader = \
-    "</head>\n" \
-
 defines                 = Q_QDOC \
                           QT_.*_SUPPORT \
                           QT_.*_LIB \
index d801e1c..e4abfbe 100644 (file)
@@ -1,5 +1,5 @@
-include(../../../doc/global/qt-html-templates-offline.qdocconf)
-include(../../../doc/global/qt-cpp-ignore.qdocconf)
+include(global/qt-html-templates-offline.qdocconf)
+include(global/qt-cpp-ignore.qdocconf)
 
 project                 = QtSql
 description             = Qt SQL Reference Documentation
@@ -48,19 +48,6 @@ examples.imageextensions = "*.png"
 outputdir               = ../../../doc/qtsql
 tagfile                 = ../../../doc/qtsql/qtsql.tags
 
-HTML.generatemacrefs    = "true"
-HTML.nobreadcrumbs      = "true"
-
-HTML.templatedir = .
-
-HTML.stylesheets = ../../../doc/global/style/offline.css
-
-HTML.headerstyles = \
-    "  <link rel=\"stylesheet\" type=\"text/css\" href=\"style/offline.css\" />\n"
-
-HTML.endheader = \
-    "</head>\n" \
-
 defines                 = Q_QDOC \
                           QT_.*_SUPPORT \
                           QT_.*_LIB \
index 8bcc60a..7505717 100644 (file)
@@ -1,5 +1,5 @@
-include(../../../doc/global/qt-html-templates-offline.qdocconf)
-include(../../../doc/global/qt-cpp-ignore.qdocconf)
+include(global/qt-html-templates-offline.qdocconf)
+include(global/qt-cpp-ignore.qdocconf)
 
 project                 = QtTest
 description             = Qt Test Reference Documentation
@@ -48,19 +48,6 @@ examples.imageextensions = "*.png"
 outputdir               = ../../../doc/qttest
 tagfile                 = ../../../doc/qttest/qttest.tags
 
-HTML.generatemacrefs    = "true"
-HTML.nobreadcrumbs      = "true"
-
-HTML.templatedir = .
-
-HTML.stylesheets = ../../../doc/global/style/offline.css
-
-HTML.headerstyles = \
-    "  <link rel=\"stylesheet\" type=\"text/css\" href=\"style/offline.css\" />\n"
-
-HTML.endheader = \
-    "</head>\n" \
-
 defines                 = Q_QDOC \
                           QT_.*_SUPPORT \
                           QT_.*_LIB \
index 323737f..9bde42b 100644 (file)
@@ -1648,9 +1648,16 @@ void Generator::initialize(const Config &config)
             QString templateDir = config.getString(
                         (*g)->format() + Config::dot + CONFIG_TEMPLATEDIR);
 
+            QStringList searchDirs;
             if (!templateDir.isEmpty()) {
+                searchDirs.append(templateDir);
+            }
+            if (!Config::installDir.isEmpty()) {
+                searchDirs.append(Config::installDir);
+            }
+
+            if (!searchDirs.isEmpty()) {
                 QStringList noExts;
-                QStringList searchDirs = QStringList() << templateDir;
                 QStringList scripts =
                         config.getCleanPathList((*g)->format()+Config::dot+CONFIG_SCRIPTS);
                 e = scripts.constBegin();
@@ -1671,10 +1678,6 @@ void Generator::initialize(const Config &config)
                     ++e;
                 }
 
-                if (!Config::installDir.isEmpty()) {
-                    searchDirs.append(Config::installDir);
-                }
-
                 QStringList styles =
                         config.getCleanPathList((*g)->format()+Config::dot+CONFIG_STYLESHEETS);
                 e = styles.constBegin();
index 87da14d..5f5a511 100644 (file)
@@ -1,5 +1,5 @@
-include(../../../doc/global/qt-html-templates-offline.qdocconf)
-include(../../../doc/global/qt-cpp-ignore.qdocconf)
+include(global/qt-html-templates-offline.qdocconf)
+include(global/qt-cpp-ignore.qdocconf)
 
 project                 = QtWidgets
 description             = Qt Widgets Reference Documentation
@@ -48,19 +48,6 @@ examples.imageextensions = "*.png"
 outputdir               = ../../../doc/qtwidgets
 tagfile                 = ../../../doc/qtwidgets/qtwidgets.tags
 
-HTML.generatemacrefs    = "true"
-HTML.nobreadcrumbs      = "true"
-
-HTML.templatedir = .
-
-HTML.stylesheets = ../../../doc/global/style/offline.css
-
-HTML.headerstyles = \
-    "  <link rel=\"stylesheet\" type=\"text/css\" href=\"style/offline.css\" />\n"
-
-HTML.endheader = \
-    "</head>\n" \
-
 defines                 = Q_QDOC \
                           QT_.*_SUPPORT \
                           QT_.*_LIB \
index 7800b6a..cafc2fa 100644 (file)
@@ -1,5 +1,5 @@
-include(../../../doc/global/qt-html-templates-offline.qdocconf)
-include(../../../doc/global/qt-cpp-ignore.qdocconf)
+include(global/qt-html-templates-offline.qdocconf)
+include(global/qt-cpp-ignore.qdocconf)
 
 project                 = QtXml
 description             = Qt XML Reference Documentation
@@ -48,19 +48,6 @@ examples.imageextensions = "*.png"
 outputdir               = ../../../doc/qtxml
 tagfile                 = ../../../doc/qtxml/qtxml.tags
 
-HTML.generatemacrefs    = "true"
-HTML.nobreadcrumbs      = "true"
-
-HTML.templatedir = .
-
-HTML.stylesheets = ../../../doc/global/style/offline.css
-
-HTML.headerstyles = \
-    "  <link rel=\"stylesheet\" type=\"text/css\" href=\"style/offline.css\" />\n"
-
-HTML.endheader = \
-    "</head>\n" \
-
 defines                 = Q_QDOC \
                           QT_.*_SUPPORT \
                           QT_.*_LIB \