From 2e7f06c9bcae5bcaefb99750aabd5bb860948e77 Mon Sep 17 00:00:00 2001 From: Casper van Donderen Date: Thu, 30 Aug 2012 17:51:30 +0200 Subject: Doc: Simplify qtbase qdocconfs. 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 Reviewed-by: Frederik Gladhorn --- doc/global/qt-html-templates-offline.qdocconf | 11 +++++++++++ src/concurrent/doc/qtconcurrent.qdocconf | 17 ++--------------- src/corelib/doc/qtcore.qdocconf | 17 ++--------------- src/dbus/doc/qtdbus.qdocconf | 17 ++--------------- src/gui/doc/qtgui.qdocconf | 17 ++--------------- src/network/doc/qtnetwork.qdocconf | 17 ++--------------- src/opengl/doc/qtopengl.qdocconf | 17 ++--------------- src/printsupport/doc/qtprintsupport.qdocconf | 17 ++--------------- src/sql/doc/qtsql.qdocconf | 17 ++--------------- src/testlib/doc/qttest.qdocconf | 17 ++--------------- src/tools/qdoc/generator.cpp | 13 ++++++++----- src/widgets/doc/qtwidgets.qdocconf | 17 ++--------------- src/xml/doc/qtxml.qdocconf | 17 ++--------------- 13 files changed, 41 insertions(+), 170 deletions(-) diff --git a/doc/global/qt-html-templates-offline.qdocconf b/doc/global/qt-html-templates-offline.qdocconf index 3943554018..08eb291b5f 100644 --- a/doc/global/qt-html-templates-offline.qdocconf +++ b/doc/global/qt-html-templates-offline.qdocconf @@ -1,3 +1,14 @@ +HTML.generatemacrefs = "true" +HTML.nobreadcrumbs = "true" + +HTML.stylesheets = global/style/offline.css + +HTML.headerstyles = \ + " \n" + +HTML.endheader = \ + "\n" \ + HTML.footer = \ "
\n" \ "

\n" \ diff --git a/src/concurrent/doc/qtconcurrent.qdocconf b/src/concurrent/doc/qtconcurrent.qdocconf index a20d0b499b..4d5bc91838 100644 --- a/src/concurrent/doc/qtconcurrent.qdocconf +++ b/src/concurrent/doc/qtconcurrent.qdocconf @@ -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 = \ - " \n" - -HTML.endheader = \ - "\n" \ - defines = Q_QDOC \ QT_.*_SUPPORT \ QT_.*_LIB \ diff --git a/src/corelib/doc/qtcore.qdocconf b/src/corelib/doc/qtcore.qdocconf index 1e5da052e8..69c753b951 100644 --- a/src/corelib/doc/qtcore.qdocconf +++ b/src/corelib/doc/qtcore.qdocconf @@ -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 = \ - " \n" - -HTML.endheader = \ - "\n" \ - defines = Q_QDOC \ QT_.*_SUPPORT \ QT_.*_LIB \ diff --git a/src/dbus/doc/qtdbus.qdocconf b/src/dbus/doc/qtdbus.qdocconf index b4bfdc76c7..e789fb32df 100644 --- a/src/dbus/doc/qtdbus.qdocconf +++ b/src/dbus/doc/qtdbus.qdocconf @@ -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 = \ - " \n" - -HTML.endheader = \ - "\n" \ - defines = Q_QDOC \ QT_.*_SUPPORT \ QT_.*_LIB \ diff --git a/src/gui/doc/qtgui.qdocconf b/src/gui/doc/qtgui.qdocconf index da2122a320..5fdc9b7818 100644 --- a/src/gui/doc/qtgui.qdocconf +++ b/src/gui/doc/qtgui.qdocconf @@ -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 = \ - " \n" - -HTML.endheader = \ - "\n" \ - defines = Q_QDOC \ QT_.*_SUPPORT \ QT_.*_LIB \ diff --git a/src/network/doc/qtnetwork.qdocconf b/src/network/doc/qtnetwork.qdocconf index d95e4155a6..1e9d74314d 100644 --- a/src/network/doc/qtnetwork.qdocconf +++ b/src/network/doc/qtnetwork.qdocconf @@ -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 = \ - " \n" - -HTML.endheader = \ - "\n" \ - defines = Q_QDOC \ QT_.*_SUPPORT \ QT_.*_LIB \ diff --git a/src/opengl/doc/qtopengl.qdocconf b/src/opengl/doc/qtopengl.qdocconf index 644cf5794b..58ead7c62e 100644 --- a/src/opengl/doc/qtopengl.qdocconf +++ b/src/opengl/doc/qtopengl.qdocconf @@ -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 = \ - " \n" - -HTML.endheader = \ - "\n" \ - defines = Q_QDOC \ QT_.*_SUPPORT \ QT_.*_LIB \ diff --git a/src/printsupport/doc/qtprintsupport.qdocconf b/src/printsupport/doc/qtprintsupport.qdocconf index 00e9c9fdff..e2d4875ee9 100644 --- a/src/printsupport/doc/qtprintsupport.qdocconf +++ b/src/printsupport/doc/qtprintsupport.qdocconf @@ -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 = \ - " \n" - -HTML.endheader = \ - "\n" \ - defines = Q_QDOC \ QT_.*_SUPPORT \ QT_.*_LIB \ diff --git a/src/sql/doc/qtsql.qdocconf b/src/sql/doc/qtsql.qdocconf index d801e1c2fe..e4abfbe236 100644 --- a/src/sql/doc/qtsql.qdocconf +++ b/src/sql/doc/qtsql.qdocconf @@ -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 = \ - " \n" - -HTML.endheader = \ - "\n" \ - defines = Q_QDOC \ QT_.*_SUPPORT \ QT_.*_LIB \ diff --git a/src/testlib/doc/qttest.qdocconf b/src/testlib/doc/qttest.qdocconf index 8bcc60ae72..7505717503 100644 --- a/src/testlib/doc/qttest.qdocconf +++ b/src/testlib/doc/qttest.qdocconf @@ -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 = \ - " \n" - -HTML.endheader = \ - "\n" \ - defines = Q_QDOC \ QT_.*_SUPPORT \ QT_.*_LIB \ diff --git a/src/tools/qdoc/generator.cpp b/src/tools/qdoc/generator.cpp index 323737f700..9bde42bae2 100644 --- a/src/tools/qdoc/generator.cpp +++ b/src/tools/qdoc/generator.cpp @@ -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(); diff --git a/src/widgets/doc/qtwidgets.qdocconf b/src/widgets/doc/qtwidgets.qdocconf index 87da14ded0..5f5a5116aa 100644 --- a/src/widgets/doc/qtwidgets.qdocconf +++ b/src/widgets/doc/qtwidgets.qdocconf @@ -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 = \ - " \n" - -HTML.endheader = \ - "\n" \ - defines = Q_QDOC \ QT_.*_SUPPORT \ QT_.*_LIB \ diff --git a/src/xml/doc/qtxml.qdocconf b/src/xml/doc/qtxml.qdocconf index 7800b6a740..cafc2fa7f7 100644 --- a/src/xml/doc/qtxml.qdocconf +++ b/src/xml/doc/qtxml.qdocconf @@ -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 = \ - " \n" - -HTML.endheader = \ - "\n" \ - defines = Q_QDOC \ QT_.*_SUPPORT \ QT_.*_LIB \ -- cgit v1.2.3