diff --git a/CMakeLists.txt b/CMakeLists.txt index 0991c7213..ed0738161 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -393,17 +393,15 @@ foreach(script exec dbus xvfb dbg) endforeach() # optional packages -if(NOT WITH_FONTCONFIG OR NOT FONTCONFIG_FOUND) - katie_config(QT_NO_FONTCONFIG) -endif() - -if(NOT WITH_DBUS OR NOT DBUS_FOUND) - katie_config(QT_NO_DBUS) -else() +if(WITH_DBUS AND DBUS_FOUND) set(KATIE_COMPONENTS "${KATIE_COMPONENTS} DBus") set(KATIE_TOOLS "${KATIE_TOOLS} qdbus qdbusxml2cpp qdbuscpp2xml qdbusviewer") endif() +if(NOT WITH_FONTCONFIG OR NOT FONTCONFIG_FOUND) + katie_config(QT_NO_FONTCONFIG) +endif() + if(NOT WITH_CUPS OR NOT CUPS_FOUND) katie_config(QT_NO_CUPS) endif() diff --git a/src/core/global/qconfig.h.cmake b/src/core/global/qconfig.h.cmake index 0fdf104a1..8560ccbe4 100644 --- a/src/core/global/qconfig.h.cmake +++ b/src/core/global/qconfig.h.cmake @@ -71,7 +71,6 @@ // External packages dependant #cmakedefine QT_NO_CUPS -#cmakedefine QT_NO_DBUS #cmakedefine QT_NO_EXECINFO #cmakedefine QT_NO_FONTCONFIG #cmakedefine QT_NO_SESSIONMANAGER @@ -190,8 +189,6 @@ #cmakedefine QT_NO_STYLE_PROXY #cmakedefine QT_NO_STYLE_STYLESHEET #cmakedefine QT_NO_STYLE_WINDOWS -#cmakedefine QT_NO_SVG -#cmakedefine QT_NO_SVGRENDERER #cmakedefine QT_NO_SYNTAXHIGHLIGHTER #cmakedefine QT_NO_SYSTEMSEMAPHORE #cmakedefine QT_NO_SYSTEMTRAYICON @@ -303,11 +300,6 @@ # define QT_NO_CONTEXTMENU #endif -// QtDBus module -#if !defined(QT_NO_DBUS) && (defined(QT_NO_PROPERTIES) || defined(QT_NO_DOM)) -# define QT_NO_DBUS -#endif - // QScrollArea #if !defined(QT_NO_SCROLLAREA) && defined(QT_NO_SCROLLBAR) # define QT_NO_SCROLLAREA @@ -363,11 +355,6 @@ # define QT_NO_STYLE_STYLESHEET #endif -// QtSvg module -#if !defined(QT_NO_SVG) && (defined(QT_NO_XMLSTREAMREADER) || defined(QT_NO_CSSPARSER)) -# define QT_NO_SVG -#endif - // QColorDialog #if !defined(QT_NO_COLORDIALOG) && defined(QT_NO_SPINBOX) # define QT_NO_COLORDIALOG @@ -388,11 +375,6 @@ # define QT_NO_MENUBAR #endif -// QSvgRenderer -#if !defined(QT_NO_SVGRENDERER) && defined(QT_NO_SVG) -# define QT_NO_SVGRENDERER -#endif - // QTabWidget #if !defined(QT_NO_TABWIDGET) && (defined(QT_NO_TABBAR) || defined(QT_NO_STACKEDWIDGET)) # define QT_NO_TABWIDGET diff --git a/src/plugins/iconengines/svgiconengine/qsvgiconengine.cpp b/src/plugins/iconengines/svgiconengine/qsvgiconengine.cpp index b2cd1afa2..40ae1a7c2 100644 --- a/src/plugins/iconengines/svgiconengine/qsvgiconengine.cpp +++ b/src/plugins/iconengines/svgiconengine/qsvgiconengine.cpp @@ -20,8 +20,6 @@ ****************************************************************************/ #include "qsvgiconengine.h" -#ifndef QT_NO_SVGRENDERER - #include "qpainter.h" #include "qpixmap.h" #include "qsvgrenderer.h" @@ -264,5 +262,3 @@ bool QSvgIconEngine::write(QDataStream &out) const } QT_END_NAMESPACE - -#endif // QT_NO_SVGRENDERER diff --git a/src/plugins/iconengines/svgiconengine/qsvgiconengine.h b/src/plugins/iconengines/svgiconengine/qsvgiconengine.h index 0d5adcaa2..8795db801 100644 --- a/src/plugins/iconengines/svgiconengine/qsvgiconengine.h +++ b/src/plugins/iconengines/svgiconengine/qsvgiconengine.h @@ -25,8 +25,6 @@ #include #include -#ifndef QT_NO_SVG - QT_BEGIN_NAMESPACE class QSvgIconEnginePrivate; @@ -60,5 +58,4 @@ private: QT_END_NAMESPACE -#endif // QT_NO_SVG -#endif +#endif // QSVGICONENGINE_H diff --git a/src/plugins/iconengines/svgiconengine/svgiconplugin.cpp b/src/plugins/iconengines/svgiconengine/svgiconplugin.cpp index 1bfdf6002..27c35b969 100644 --- a/src/plugins/iconengines/svgiconengine/svgiconplugin.cpp +++ b/src/plugins/iconengines/svgiconengine/svgiconplugin.cpp @@ -21,9 +21,6 @@ #include "qiconengineplugin.h" #include "qstringlist.h" - -#if !defined(QT_NO_SVG) - #include "qsvgiconengine.h" #include "qiodevice.h" #include "qbytearray.h" @@ -58,5 +55,3 @@ QIconEngine *QSvgIconPlugin::create(const QString &file) Q_EXPORT_PLUGIN2(qsvgicon, QSvgIconPlugin) QT_END_NAMESPACE - -#endif // !QT_NO_SVG diff --git a/src/plugins/imageformats/svg/qsvgiohandler.cpp b/src/plugins/imageformats/svg/qsvgiohandler.cpp index 181493e00..7b74f00ba 100644 --- a/src/plugins/imageformats/svg/qsvgiohandler.cpp +++ b/src/plugins/imageformats/svg/qsvgiohandler.cpp @@ -20,9 +20,6 @@ ****************************************************************************/ #include "qsvgiohandler.h" - -#ifndef QT_NO_SVGRENDERER - #include "qsvgrenderer.h" #include "qimage.h" #include "qpixmap.h" @@ -228,5 +225,3 @@ bool QSvgIOHandler::canRead(QIODevice *device) } QT_END_NAMESPACE - -#endif // QT_NO_SVGRENDERER diff --git a/src/plugins/imageformats/svg/qsvgiohandler.h b/src/plugins/imageformats/svg/qsvgiohandler.h index c694b1bc7..2291c5544 100644 --- a/src/plugins/imageformats/svg/qsvgiohandler.h +++ b/src/plugins/imageformats/svg/qsvgiohandler.h @@ -24,8 +24,6 @@ #include -#ifndef QT_NO_SVGRENDERER - QT_BEGIN_NAMESPACE class QImage; @@ -53,5 +51,4 @@ private: QT_END_NAMESPACE -#endif // QT_NO_SVGRENDERER #endif // QSVGIOHANDLER_H diff --git a/src/plugins/imageformats/svg/qsvgplugin.cpp b/src/plugins/imageformats/svg/qsvgplugin.cpp index 322cbb555..28b31d8ef 100644 --- a/src/plugins/imageformats/svg/qsvgplugin.cpp +++ b/src/plugins/imageformats/svg/qsvgplugin.cpp @@ -21,9 +21,6 @@ #include "qimageiohandler.h" #include "qstringlist.h" - -#if !defined(QT_NO_SVGRENDERER) - #include "qsvgiohandler.h" #include "qiodevice.h" #include "qbytearray.h" @@ -71,5 +68,3 @@ QImageIOHandler *QSvgPlugin::create(QIODevice *device, const QByteArray &format) Q_EXPORT_PLUGIN2(qsvg, QSvgPlugin) QT_END_NAMESPACE - -#endif // !QT_NO_SVGRENDERER diff --git a/src/plugins/script/qtdbus/dbmain.cpp b/src/plugins/script/qtdbus/dbmain.cpp index c0ead647a..6137f5536 100644 --- a/src/plugins/script/qtdbus/dbmain.cpp +++ b/src/plugins/script/qtdbus/dbmain.cpp @@ -24,8 +24,6 @@ #include #include -#ifndef QT_NO_DBUS - QT_USE_NAMESPACE static QScriptValue setupDBusInterface(QScriptEngine *engine, QDBusAbstractInterface *iface); @@ -378,6 +376,4 @@ void QtDBusScriptPlugin::initialize(const QString &key, QScriptEngine *engine) Q_EXPORT_PLUGIN2(qtscriptdbus, QtDBusScriptPlugin) -#endif // QT_NO_DBUS - #include "moc_dbmain.h" diff --git a/src/plugins/script/qtdbus/dbmain.h b/src/plugins/script/qtdbus/dbmain.h index 53b6aa7e2..1f35d3cab 100644 --- a/src/plugins/script/qtdbus/dbmain.h +++ b/src/plugins/script/qtdbus/dbmain.h @@ -31,8 +31,6 @@ #include #include -#ifndef QT_NO_DBUS - QT_USE_NAMESPACE class QDBusConnectionConstructor : public QObject, @@ -162,5 +160,4 @@ private: QScriptValue proto; }; -#endif // QT_NO_DBUS #endif // QDBUSBINDING_H diff --git a/src/scripttools/debugging/qscriptedit.cpp b/src/scripttools/debugging/qscriptedit.cpp index 942e43040..e51f27529 100644 --- a/src/scripttools/debugging/qscriptedit.cpp +++ b/src/scripttools/debugging/qscriptedit.cpp @@ -303,15 +303,7 @@ void QScriptEdit::extraAreaPaintEvent(QPaintEvent *e) qreal top = blockBoundingGeometry(block).translated(contentOffset()).top(); qreal bottom = top + blockBoundingRect(block).height(); - QString imagesPath = QString::fromLatin1(":/qt/scripttools/debugging/images"); - QString imageExt; -// SVGs don't work on all platforms, even when QT_NO_SVG is not defined, so disable SVG usage for now. -// #ifndef QT_NO_SVG -#if 0 - imageExt = QString::fromLatin1("svg"); -#else - imageExt = QString::fromLatin1("png"); -#endif + static QString imagesPath = QString::fromLatin1(":/qt/scripttools/debugging/images"); while (block.isValid() && top <= rect.bottom()) { if (block.isVisible() && bottom >= rect.top()) { @@ -321,14 +313,14 @@ void QScriptEdit::extraAreaPaintEvent(QPaintEvent *e) int radius = fm.lineSpacing() - 1; QRect r(rect.x(), (int)top, radius, radius); QIcon icon(m_breakpoints[lineNumber].enabled - ? QString::fromLatin1("%0/breakpoint.%1").arg(imagesPath).arg(imageExt) - : QString::fromLatin1("%0/d_breakpoint.%1").arg(imagesPath).arg(imageExt)); + ? QString::fromLatin1("%1/breakpoint.png").arg(imagesPath)) + : QString::fromLatin1("%1/d_breakpoint.png").arg(imagesPath)); icon.paint(&painter, r, Qt::AlignCenter); } if (m_executionLineNumber == lineNumber) { int radius = fm.lineSpacing() - 1; QRect r(rect.x(), (int)top, radius, radius); - QIcon icon(QString::fromLatin1("%0/location.%1").arg(imagesPath).arg(imageExt)); + QIcon icon(QString::fromLatin1("%1/location.png").arg(imagesPath)); icon.paint(&painter, r, Qt::AlignCenter); } diff --git a/src/svg/qsvgfont.cpp b/src/svg/qsvgfont.cpp index 0c6304a1e..50cf00f00 100644 --- a/src/svg/qsvgfont.cpp +++ b/src/svg/qsvgfont.cpp @@ -21,8 +21,6 @@ #include "qsvgfont_p.h" -#ifndef QT_NO_SVG - #include "qpainter.h" #include "qpen.h" #include "qdebug.h" @@ -117,5 +115,3 @@ void QSvgFont::setUnitsPerEm(qreal upem) } QT_END_NAMESPACE - -#endif // QT_NO_SVG diff --git a/src/svg/qsvgfont_p.h b/src/svg/qsvgfont_p.h index 4736409c7..8d542fda6 100644 --- a/src/svg/qsvgfont_p.h +++ b/src/svg/qsvgfont_p.h @@ -34,9 +34,6 @@ // #include "qpainterpath.h" - -#ifndef QT_NO_SVG - #include "qhash.h" #include "qstring.h" #include "qsvgstyle_p.h" @@ -77,5 +74,4 @@ private: QT_END_NAMESPACE -#endif // QT_NO_SVG #endif // QSVGFONT_P_H diff --git a/src/svg/qsvggraphics.cpp b/src/svg/qsvggraphics.cpp index 35bb8851c..9073f5ab0 100644 --- a/src/svg/qsvggraphics.cpp +++ b/src/svg/qsvggraphics.cpp @@ -20,11 +20,7 @@ ****************************************************************************/ #include "qsvggraphics_p.h" - -#ifndef QT_NO_SVG - #include "qsvgfont_p.h" - #include "qpainter.h" #include "qtextdocument.h" #include "qabstracttextdocumentlayout.h" @@ -590,9 +586,3 @@ QRectF QSvgLine::bounds(QPainter *p, QSvgExtraStates &) const } QT_END_NAMESPACE - -#endif // QT_NO_SVG - - - - diff --git a/src/svg/qsvggraphics_p.h b/src/svg/qsvggraphics_p.h index 3d4acf8b1..8df7130a3 100644 --- a/src/svg/qsvggraphics_p.h +++ b/src/svg/qsvggraphics_p.h @@ -34,9 +34,6 @@ // #include "qsvgnode_p.h" - -#ifndef QT_NO_SVG - #include "QtGui/qpainterpath.h" #include "QtGui/qimage.h" #include "QtGui/qtextlayout.h" @@ -232,5 +229,4 @@ public: QT_END_NAMESPACE -#endif // QT_NO_SVG #endif // QSVGGRAPHICS_P_H diff --git a/src/svg/qsvghandler.cpp b/src/svg/qsvghandler.cpp index 404d2b8a0..a96bbb352 100644 --- a/src/svg/qsvghandler.cpp +++ b/src/svg/qsvghandler.cpp @@ -20,11 +20,7 @@ ****************************************************************************/ #include "qplatformdefs.h" - #include "qsvghandler_p.h" - -#ifndef QT_NO_SVG - #include "qsvgtinydocument_p.h" #include "qsvgstructure_p.h" #include "qsvggraphics_p.h" @@ -3745,5 +3741,3 @@ QSvgHandler::~QSvgHandler() } QT_END_NAMESPACE - -#endif // QT_NO_SVG diff --git a/src/svg/qsvghandler_p.h b/src/svg/qsvghandler_p.h index 740d59735..ca7636589 100644 --- a/src/svg/qsvghandler_p.h +++ b/src/svg/qsvghandler_p.h @@ -34,9 +34,6 @@ // #include "QtXml/qxmlstream.h" - -#ifndef QT_NO_SVG - #include "QtCore/qhash.h" #include "QtCore/qstack.h" #include "qsvgstyle_p.h" @@ -148,5 +145,4 @@ private: QT_END_NAMESPACE -#endif // QT_NO_SVG #endif // QSVGHANDLER_P_H diff --git a/src/svg/qsvgnode.cpp b/src/svg/qsvgnode.cpp index 9d46ce4af..f0fc0a4c9 100644 --- a/src/svg/qsvgnode.cpp +++ b/src/svg/qsvgnode.cpp @@ -21,9 +21,6 @@ #include "qsvgnode_p.h" #include "qsvgtinydocument_p.h" - -#ifndef QT_NO_SVG - #include "qdebug.h" #include "qstack.h" @@ -331,9 +328,3 @@ qreal QSvgNode::strokeWidth(QPainter *p) } QT_END_NAMESPACE - -#endif // QT_NO_SVG - - - - diff --git a/src/svg/qsvgnode_p.h b/src/svg/qsvgnode_p.h index c3326e8af..16d51cab1 100644 --- a/src/svg/qsvgnode_p.h +++ b/src/svg/qsvgnode_p.h @@ -34,9 +34,6 @@ // #include "qsvgstyle_p.h" - -#ifndef QT_NO_SVG - #include "QtCore/qstring.h" #include "QtCore/qhash.h" @@ -182,5 +179,4 @@ inline QString QSvgNode::xmlClass() const QT_END_NAMESPACE -#endif // QT_NO_SVG #endif // QSVGNODE_P_H diff --git a/src/svg/qsvgrenderer.cpp b/src/svg/qsvgrenderer.cpp index 00ff5ca8b..d220621db 100644 --- a/src/svg/qsvgrenderer.cpp +++ b/src/svg/qsvgrenderer.cpp @@ -20,11 +20,7 @@ ****************************************************************************/ #include "qsvgrenderer.h" - -#ifndef QT_NO_SVGRENDERER - #include "qsvgtinydocument_p.h" - #include "qbytearray.h" #include "qtimer.h" #include "qdebug.h" @@ -477,6 +473,4 @@ QMatrix QSvgRenderer::matrixForElement(const QString &id) const QT_END_NAMESPACE -#endif // QT_NO_SVGRENDERER - #include "moc_qsvgrenderer.h" diff --git a/src/svg/qsvgrenderer.h b/src/svg/qsvgrenderer.h index 009d5a1c2..a9aa6e83b 100644 --- a/src/svg/qsvgrenderer.h +++ b/src/svg/qsvgrenderer.h @@ -23,9 +23,6 @@ #define QSVGRENDERER_H #include - -#ifndef QT_NO_SVGRENDERER - #include #include #include @@ -92,6 +89,4 @@ private: QT_END_NAMESPACE - -#endif // QT_NO_SVGRENDERER #endif // QSVGRENDERER_H diff --git a/src/svg/qsvgstructure.cpp b/src/svg/qsvgstructure.cpp index d27a13079..e7e492671 100644 --- a/src/svg/qsvgstructure.cpp +++ b/src/svg/qsvgstructure.cpp @@ -20,13 +20,9 @@ ****************************************************************************/ #include "qsvgstructure_p.h" - -#ifndef QT_NO_SVG - #include "qsvgnode_p.h" #include "qsvgstyle_p.h" #include "qsvgtinydocument_p.h" - #include "qpainter.h" #include "qlocale.h" #include "qdebug.h" @@ -227,9 +223,3 @@ QSvgNode * QSvgStructureNode::previousSiblingNode(QSvgNode *n) const } QT_END_NAMESPACE - -#endif // QT_NO_SVG - - - - diff --git a/src/svg/qsvgstructure_p.h b/src/svg/qsvgstructure_p.h index 808b9d3ec..b4aaf1682 100644 --- a/src/svg/qsvgstructure_p.h +++ b/src/svg/qsvgstructure_p.h @@ -34,9 +34,6 @@ // #include "qsvgnode_p.h" - -#ifndef QT_NO_SVG - #include "QtCore/qlist.h" #include "QtCore/qhash.h" @@ -90,5 +87,4 @@ private: QT_END_NAMESPACE -#endif // QT_NO_SVG #endif // QSVGSTRUCTURE_P_H diff --git a/src/svg/qsvgstyle.cpp b/src/svg/qsvgstyle.cpp index 489fbdd41..68221282a 100644 --- a/src/svg/qsvgstyle.cpp +++ b/src/svg/qsvgstyle.cpp @@ -20,9 +20,6 @@ ****************************************************************************/ #include "qsvgstyle_p.h" - -#ifndef QT_NO_SVG - #include "qsvgfont_p.h" #include "qsvggraphics_p.h" #include "qsvgnode_p.h" @@ -928,9 +925,3 @@ void QSvgGradientStyle::resolveStops() } QT_END_NAMESPACE - -#endif // QT_NO_SVG - - - - diff --git a/src/svg/qsvgstyle_p.h b/src/svg/qsvgstyle_p.h index 9207cf2d7..fb29003e8 100644 --- a/src/svg/qsvgstyle_p.h +++ b/src/svg/qsvgstyle_p.h @@ -34,9 +34,6 @@ // #include "QtGui/qpainter.h" - -#ifndef QT_NO_SVG - #include "QtGui/qpen.h" #include "QtGui/qbrush.h" #include "QtGui/qmatrix.h" @@ -795,5 +792,4 @@ public: QT_END_NAMESPACE -#endif // QT_NO_SVG #endif // QSVGSTYLE_P_H diff --git a/src/svg/qsvgtinydocument.cpp b/src/svg/qsvgtinydocument.cpp index 5a58a2bae..67d81805f 100644 --- a/src/svg/qsvgtinydocument.cpp +++ b/src/svg/qsvgtinydocument.cpp @@ -20,9 +20,6 @@ ****************************************************************************/ #include "qsvgtinydocument_p.h" - -#ifndef QT_NO_SVG - #include "qsvghandler_p.h" #include "qsvgfont_p.h" #include "qplatformdefs.h" @@ -343,9 +340,3 @@ void QSvgTinyDocument::setFramesPerSecond(int num) } QT_END_NAMESPACE - -#endif // QT_NO_SVG - - - - diff --git a/src/svg/qsvgtinydocument_p.h b/src/svg/qsvgtinydocument_p.h index 1ef6a1875..d24130c33 100644 --- a/src/svg/qsvgtinydocument_p.h +++ b/src/svg/qsvgtinydocument_p.h @@ -34,9 +34,6 @@ // #include "qsvgstructure_p.h" - -#ifndef QT_NO_SVG - #include "QtCore/qrect.h" #include "QtCore/qlist.h" #include "QtCore/qhash.h" @@ -153,5 +150,4 @@ inline int QSvgTinyDocument::animationDuration() const QT_END_NAMESPACE -#endif // QT_NO_SVG #endif // QSVGTINYDOCUMENT_P_H