summaryrefslogtreecommitdiffstats
path: root/src/gui/image
Commit message (Collapse)AuthorAgeFilesLines
* Factor out qt_getImageText() and qt_getImageTextFromDescription()Anton Kudryavtsev2016-07-144-30/+40
| | | | | | | ... and re-use them in QImageReader, QJpegHandler, QPngHandler. Change-Id: Iec89e47205f3c420e1e7eb4a2d3c1fbfe887fd8c Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* Fix/adapt the uses of {to,set,from}Time_t in the qtbase source codeThiago Macieira2016-07-061-1/+1
| | | | | | | | | Move those to the equivalent {to,set,from}SecsSinceEpoch(), except for the cases that did QDateTime::currentDateTime{,Utc}().toTime_t. Those are best implemented with QDateTime::currentSecsSinceEpoch(). Change-Id: Ib57b52598e2f452985e9fffd145a366c92cfda20 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* Add qtguiglobal.h and qtguiglobal_p.hLars Knoll2016-07-0329-7/+31
| | | | | | | | | | | | | | | | | | | | The new modular configuration system requires one global header per module, that is included by all other files in this module. A similar scheme and naming convention is already being used for many other modules (e.g. printsupport, qml, quick). That header will later on #include the configuration file for Qt Gui. For now it defines the Q_GUI_EXPORT macro for this library. In addition, add a private global header, qtguiglobal_p.h, that can later on include the private config header for Qt Gui for things we don't want to export to the world. Change-Id: Id9ce2a4f3d2962c3592c35e3d080574789195f24 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
* Merge remote-tracking branch 'origin/5.7' into devLiang Qi2016-06-214-13/+16
|\ | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/global/qglobal.cpp src/corelib/global/qsysinfo.h src/corelib/kernel/qcoreapplication_win.cpp src/gui/text/qdistancefield.cpp src/gui/text/qdistancefield_p.h src/plugins/platforms/windows/qwindowsglcontext.cpp src/plugins/platforms/windows/qwindowsglcontext.h Change-Id: Ib3500acc2b28553bde06758cd9a2e19eb7fe2978
| * Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-06-204-13/+16
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | And blacklisted a few tests in tst_QUdpSocket. Conflicts: src/android/jar/src/org/qtproject/qt5/android/QtNative.java src/corelib/global/qglobal.cpp src/corelib/global/qsystemdetection.h src/corelib/io/qfileselector.cpp src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_egldevice/qeglfskmsegldeviceintegration.cpp tests/auto/network/socket/qudpsocket/BLACKLIST Task-number: QTBUG-54205 Change-Id: I11dd1c90186eb1b847d45be87a26041f61d89ef6
| | * Finally fix crash in inplace-modified data-constructed imagesEirik Aavitsland2016-06-152-11/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Avoid all inplace modification of images using external data buffers. Since the QImage methods are documented to create a (modified) copy, there is afterwards no API requirement on the lifetime of the data buffer. This patch supersedes 509bc7e59c69937900cf258e64889a6e88edbcf0 Task-number: QTBUG-53721 Change-Id: I3ccc01619eb61d8630104449394e0b76df0af695 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
| | * QIconLoader: Fix typo in directoryMatchesSize()Palo Kisa2016-06-151-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For QIconDirInfo::Scalable directories condition for directoryMatchesSize was mistyped. In particular only the minSize was considered which could lead to false positive checks. [ChangeLog][QtGui][QIconLoaderEngine] Fixed theme lookup for scalable entries Change-Id: Ic7e06cc0a2e4be69e6633847cef8c2c5686378ea Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
| | * Fixed developer build for MinGWOliver Wolff2016-06-151-1/+1
| | | | | | | | | | | | | | | | | | | | | 0 must not be used as a null pointer constant Change-Id: I082d0e99c105fb02980b9cf390e7f6e4c9ad0869 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | | Merge remote-tracking branch 'origin/5.7' into devLiang Qi2016-06-137-41/+56
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: config_help.txt configure mkspecs/features/uikit/sdk.prf src/corelib/global/qhooks.cpp src/corelib/io/qfilesystemwatcher.cpp src/corelib/io/qlockfile_unix.cpp src/corelib/tools/qalgorithms.h src/gui/kernel/qwindowsysteminterface.h src/gui/text/qtextdocument_p.cpp src/network/access/access.pri src/network/access/qnetworkaccessmanager.cpp src/network/access/qnetworkreplynsurlconnectionimpl.mm src/src.pro src/testlib/qtestcase.cpp src/widgets/kernel/qwidgetbackingstore_p.h src/widgets/styles/qwindowscestyle.cpp src/widgets/styles/qwindowsmobilestyle.cpp tests/auto/corelib/io/qdiriterator/qdiriterator.pro tests/auto/corelib/io/qfileinfo/qfileinfo.pro tests/auto/gui/kernel/qwindow/BLACKLIST tests/auto/widgets/dialogs/qfilesystemmodel/tst_qfilesystemmodel.cpp tools/configure/configureapp.cpp Change-Id: Ibf7fb9c8cf263a810ade82f821345d0725c57c67
| * | Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-06-062-7/+15
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf config.tests/unix/nis/nis.cpp mkspecs/unsupported/freebsd-g++/qplatformdefs.h src/corelib/tools/qdatetime.cpp src/corelib/tools/qsimd.cpp src/corelib/tools/qsimd_p.h src/network/access/access.pri src/network/access/qnetworkreplynsurlconnectionimpl.mm src/network/access/qnetworkreplynsurlconnectionimpl_p.h src/plugins/platforms/cocoa/qnsview.mm src/plugins/printsupport/windows/qwindowsprintdevice.cpp tests/auto/corelib/kernel/qobject/tst_qobject.cpp tests/auto/network/access/qnetworkreply/BLACKLIST tests/auto/widgets/widgets/qopenglwidget/BLACKLIST Change-Id: I4b32055bbf922392ef0264fd403405416fffee57
| | * Merge remote-tracking branch 'origin/5.6.1' into 5.6Liang Qi2016-06-021-7/+9
| | |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This merge also blacklists a flaky tst_QGL::clipTest test on OpenSUSE 13.1. Conflicts: src/network/socket/qnativesocketengine_winrt.cpp tests/auto/opengl/qgl/BLACKLIST Task-number: QTBUG-53133 Change-Id: I14b431aa5a189b7dd1d3e2dfff767d15df20fde3
| | | * Really fix crash on certain malformed bmp imagesEirik Aavitsland2016-05-251-7/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is an improvement of e4f71b0c. By using the QImageReader::read() overload taking a QImage pointer, and ignoring the return value, one could still end up with a corrupt QImage object. Avoid the subsequent crashes by closing that hole. Change-Id: I5dca10e4808ac3365e3ddba6689edecb7444948f Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com> Reviewed-by: Richard J. Moore <rich@kde.org>
| | * | Turn off optimization for checkForAlphaPixels on Windows ARMMaurice Kalinowski2016-05-231-0/+6
| | |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This function is optimized in a way that it returns bad results with the arm msvc compiler. Task-number: QTBUG-52007 Change-Id: Ica4517dfb7dde5a78d563f9253c4c907090c9459 Reviewed-by: Andreas Holzammer <andreas.holzammer@kdab.com> Reviewed-by: Kevin Funk <kevin.funk@kdab.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
| * | QtGui: use QStringRef to optimize memory allocationAnton Kudryavtsev2016-06-021-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Replace substring functions that return QString with corresponding functions that return QStringRef where it's possible. Create QString from QStringRef only where necessary. Change-Id: Id83c60cc7568b20ef008b51c582cfdf466a47e35 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
| * | Gui: use const (and const APIs) moreAnton Kudryavtsev2016-06-014-12/+12
| | | | | | | | | | | | | | | | | | | | | For CoW types, prefer const methods to avoid needless detach()ing. Change-Id: I88d08d499e1be72c1f6d983fecdcee513df18aa2 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
| * | Optimize QImage checkForAlphaPixelsAllan Sandfeld Jensen2016-05-231-21/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This routine is often called to down-convert pixmaps and backing stores to RGB32. This patch replaces a comparison in each pixel, with a single AND in each pixel and a comparison at each line. The new form is also auto- vectorized by at least GCC. Change-Id: I3e07585a3ec12f888321d35da57ac99b561dbec4 Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* | | Optimize QIconLoader::findIconHelper()John Lindgren2016-05-241-10/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Profiling QIconLoader::findIconHelper() shows that a significant portion of CPU time is being spent in QDir::exists(), which creates a new QFileInfo object for the sole purpose of determining whether the passed-in file path is relative or absolute, and then calls QFile::exists(). In this context, we can just as easily generate the absolute path and call QFile::exists() directly, avoiding the creation of extra QDir and QFileInfo objects. Change-Id: Ib0b4568b6c16d423eb6c1b15158e44ff141e6175 Task-number: QTBUG-46767 Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* | | Merge remote-tracking branch 'origin/5.7' into devLiang Qi2016-05-123-8/+20
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: config_help.txt configure src/corelib/io/qprocess_wince.cpp src/plugins/platforms/windows/qwindowstheme.cpp src/plugins/platforms/xcb/qxcbbackingstore.cpp tests/auto/corelib/tools/qtimezone/BLACKLIST tests/auto/network/socket/qudpsocket/tst_qudpsocket.cpp tests/auto/widgets/kernel/qwidget/tst_qwidget.cpp Change-Id: I26644d1cb3b78412c8ff285e2a55bea1bd641c01
| * | QImage::setPixelColor: warn about invalid colorsMitch Curtis2016-05-111-1/+7
| | | | | | | | | | | | | | | | | | Task-number: QTBUG-52142 Change-Id: I9f390bd332f8edabaece75a6b36830c691ff4b9e Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
| * | QImageWriter: use new QJsonObject::value(QLatin1String)Marc Mutz2016-05-101-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | Allows to get rid of some QStringLiterals, reducing QtGui text size by ~200b. Change-Id: I0f3a84c1c8ee6771d8e1f2c6284d314b3fc0c28a Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
| * | Optimize convert_Indexed8_to_X32Allan Sandfeld Jensen2016-04-271-4/+10
| | | | | | | | | | | | | | | | | | | | | | | | Basic optimization of conversion from indexed8. Task-number: QTBUG-35747 Change-Id: Ic9d32789769eadb05fbecfebf2d2f2c87d66610b Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* | | QtGui: Introduce delegating constructors.Friedemann Kleint2016-05-094-20/+5
| | | | | | | | | | | | | | | | | | | | | | | | Reduce code duplication by chaining constructors. Change-Id: Ida25105e33cc3ef870f416931212e2216e9c6dfb Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com> Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* | | Merge remote-tracking branch 'origin/5.7' into devLiang Qi2016-05-031-1/+0
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: configure src/3rdparty/double-conversion/include/double-conversion/utils.h src/corelib/global/qnamespace.qdoc src/corelib/tools/qsimd_p.h tests/auto/corelib/io/qfile/tst_qfile.cpp Change-Id: I3ca1007bab5355d251c13002a18e93d81c254d34
| * | Fix some qdoc-warnings in 5.7.Friedemann Kleint2016-04-131-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | qtbase/src/corelib/global/qnamespace.qdoc:101: warning: Undocumented enum item 'AA_SynthesizeMouseForUnhandledTabletEvents' in Qt::ApplicationAttribute qtbase/src/corelib/global/qnamespace.qdoc:2554: warning: Undocumented enum item 'ImAnchorRectangle' in Qt::InputMethodQuery qtbase/src/corelib/statemachine/qsignaltransition.cpp:154: warning: Can't link to 'Q_COMPILER_DELEGATING_CONSTRUCTORS' qtbase/src/gui/image/qiconloader.cpp:160: warning: Cannot find 'QIconCacheGtkReader' specified with '\class' in any header file qtbase/src/gui/painting/qpaintengine_raster.cpp:1382: warning: No documentation for 'QRasterPaintEngine::fillPath(const QPainterPath &path, QSpanData *fillData)' qtbase/src/testlib/qtest.h:176: warning: No documentation for 'QTest::toString(const QHostAddress &addr)' qtbase/src/testlib/qtest_gui.h:77: warning: No documentation for 'QTest::toString(const QColor &color)' Change-Id: If9ac0807accf2530ec7fc2ca7db71a110f9f79bb Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com> Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
* | | QtBase: use printf-style qWarning/qDebug where possible (II)Marc Mutz2016-05-031-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The printf-style version of QDebug expands to a lot less code than the std::ostream-style version. Of course, you pay in type safety (but compilers warn about it these days), you cannot stream complex Qt types and streaming QStrings is awkward, but in many cases you actually improve on readability. But the main reason is that something that's not supposed to be executed under normal operation has no business bloating executable code size. This is not an attempt at converting all qWarnings() to printf-style, only the low-hanging fruit. In this second part, replace qWarning() << "" << non-QString with qWarning("..%.", non-QString). QString (and QUrl etc) have special escaping handling when streamed into QDebug, so leave those alone. They also seem to expand to less code than the qPrintable() alternative, so there's no reason to replace them. Saves 2KiB, 3.4KiB, ~750b and ~450b in text size in QtCore, Gui, Network and Widgets, resp., on optimized GCC 5.3 AMD64 builds. Change-Id: Iae6823e543544347e628ca1060d6d51e3b04d3f4 Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* | | Implement ordered dithering for image format conversionsAllan Sandfeld Jensen2016-04-122-7/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QImage::convertToFormat was ignoring its conversion flag argument, only performing dithering when converting to indexed formats. This patch updates the documentation and implements ordered dithering for other conversions. Change-Id: I807353d61669694185b7e595ef262d80d9fbb3f1 Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* | | Cleanup conversion parametersAllan Sandfeld Jensen2016-04-115-13/+14
| | | | | | | | | | | | | | | | | | | | | | | | Removes the now unused QPixelLayout parameter, simplifies the colorTable passing and prepares for adding dithering. Change-Id: Iaf7698b248b857804d8921bf118e7cfabbabff87 Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* | | Always build JPEG and GIF support as pluginsLars Knoll2016-04-0710-2636/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Our handling of plugins when Qt is build statically is nowadays good enough, so we don't need to build the JPEG and GIF support directly into Qt for static builds. Let's simply always build them as plugins. Also simplify the logic in configure, and get rid of the no-gif, no-jpeg and no-png config variables. [ChangelLog][Build system] JPEG and GIF image support is now always built as a plugin. Removed -imageformat-[jpeg|gif] arguments to configure. Change-Id: Ic01559ff406c966807b3be8761252e8802adcdf7 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
* | | Merge remote-tracking branch 'origin/5.7' into devLiang Qi2016-04-052-25/+34
|\| | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: examples/corelib/ipc/ipc.pro src/plugins/platforms/xcb/qxcbbackingstore.cpp tests/auto/corelib/tools/qcommandlineparser/tst_qcommandlineparser.cpp Change-Id: Ia006e10ff1732fe78f90138c41f05b59b49486cf
| * | Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-04-042-25/+34
| |\| | | | | | | | | | Change-Id: I35ca979395620e104e50b06366d0869433a4ffc2
| | * Fix possible crash in QImage::pixel()Eskil Abrahamsen Blomfeldt2016-03-312-25/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QImage::pixel() assumed that the color table was valid for the values in the bitmap. This was always wrong for indexed images with explicit no color table set and was wrong for mono images that were constructed from preexisting data. For mono images, we default to a black/white color table, like we do when constructing with uninitialized data. For indexed image, we always default to no color table, but instead of crashing in pixel(), we warn and return an undefined value. [ChangeLog][QtGui][Image] Fixed possible crash in QImage::pixel() for mono or indexed images. Change-Id: Ieaf19c03984badddfd06e1855a7e287b862adc70 Task-number: QTBUG-50745 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com> Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* | | QtGui: Remove Windows CE.Friedemann Kleint2016-03-303-191/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | Remove #ifdef sections for Q_OS_WINCE and wince .pro file clauses in library, and tests. Task-number: QTBUG-51673 Change-Id: I55f61845c3b54027c467a5c59c122e7d16955358 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* | | Merge remote-tracking branch 'origin/5.7' into devLiang Qi2016-03-224-4/+6
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: configure mkspecs/common/wince/qplatformdefs.h src/plugins/platforms/directfb/qdirectfbbackingstore.cpp src/plugins/platforms/xcb/qxcbbackingstore.cpp Change-Id: Ied4d31264a9afca9514b51a7eb1494c28712793c
| * | Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-03-111-1/+2
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change partially reverts 1bfc7f68 about QT_HAS_BUILTIN define and undef in src/corelib/tools/qsimd_p.h. This change is also squashed with "Fall back to c++11 standard compiler flag for host builds" which is done by Peter Seiderer. Conflicts: mkspecs/features/default_post.prf src/3rdparty/sqlite/0001-Fixing-the-SQLite3-build-for-WEC2013-again.patch src/3rdparty/sqlite/sqlite3.c src/corelib/tools/qsimd_p.h src/gui/kernel/qevent.cpp src/gui/kernel/qwindowsysteminterface.cpp src/gui/kernel/qwindowsysteminterface_p.h src/plugins/bearer/blackberry/blackberry.pro src/plugins/platforms/cocoa/qcocoasystemsettings.mm src/plugins/platformthemes/gtk2/gtk2.pro src/plugins/styles/bb10style/bb10style.pro src/sql/drivers/sqlite2/qsql_sqlite2.cpp tools/configure/configureapp.cpp Task-number: QTBUG-51644 Done-with: Peter Seiderer <ps.report@gmx.net> Change-Id: I6100d6ace31b2e8d41a95f0b5d5ebf8f1fd88b44
| | * Only copy the data if the image is not nullAndy Shaw2016-03-011-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If the image was unable to do the smooth scaling due to running out of memory then it will return a null QImage, so this should be checked before copying the data to prevent a crash. Change-Id: I82a6443ce2d701c45110b5dd3c5ed4813d078312 Reviewed-by: aavit <eirik.aavitsland@theqtcompany.com> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
| * | QtGui: use printf-style qWarning/qDebug where possible (I)Marc Mutz2016-03-042-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The printf-style version of QDebug expands to a lot less code than the std::ostream-style version. Of course, you pay in type safety (but compilers warn about it these days), you cannot stream complex Qt types and streaming QStrings is awkward, but in many cases you actually improve on readability. But the main reason is that something that's not supposed to be executed under normal operation has no business bloating executable code size. This is not an attempt at converting all qWarnings() to printf-style, only the low-hanging fruit. In this first part, replace qWarning() << "..."; with qWarning("..."); In QTransform shared warning strings. Saves 3KiB in text size on optimized GCC 5.3 AMD64 builds. Change-Id: I142a8020eaab043d78465178192f2c8c6d1cc4f9 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
| * | QtGui: mark some more types as movable/primitiveMarc Mutz2016-03-031-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These are already held in QVectors. Public API types need to wait until Qt 6, for BC reasons. Even though Q_RELOCATABLE_TYPE deals with most of them, we lack a way to mark a type as primitive, but still isStatic - for QList. Change-Id: I91392b01ae6f94cc847007636e12d4e64c43b2bc Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@theqtcompany.com>
* | | Merge remote-tracking branch 'origin/5.7' into devLiang Qi2016-03-011-1/+1
|\| | | | | | | | | | | Change-Id: Ic7aaa06f4a14b1aed61faa1a6e7f527ee0eeb96b
| * | Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-02-291-1/+1
| |\| | | | | | | | | | | | | | | | | | | Conflicts: tests/auto/corelib/io/qprocess/tst_qprocess.cpp Change-Id: Ib6955eb874b516b185b45d6c38cec646fbaa95f4
| | * QPixmap: check data ptr in isQBitmap()Anton Kudryavtsev2016-02-241-1/+1
| | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-51271 Change-Id: I670e074ced1217d2614fa334eb365e40ef80b8b1 Reviewed-by: Edward Welbourne <edward.welbourne@theqtcompany.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* | | QtGui: use new QRegion::begin()/end() instead of rect()Marc Mutz2016-02-281-4/+2
|/ / | | | | | | | | | | | | Saves ~1100b in text size on optimized GCC 5.3 Linux AMD64 builds. Change-Id: I928be44314dde06d5fdd2486a3417870bda64af4 Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
* | Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-02-241-1/+1
|\| | | | | | | | | | | | | | | | | | | | | Conflicts: src/android/jar/src/org/qtproject/qt5/android/QtActivityDelegate.java src/plugins/platforms/windows/qwindowsfontengine.cpp src/plugins/platforms/windows/qwindowsnativeimage.cpp tests/auto/gui/kernel/qwindow/BLACKLIST tests/auto/gui/kernel/qwindow/tst_qwindow.cpp Change-Id: I649b32b260ce0ed2d6a5089021daa0d6a8db85f7
| * Make public headers compile with -Wzero-as-null-pointer-constantMarc Mutz2016-02-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | ... or similar. This amends previous commits that converted the majority of cases. Task-number: QTBUG-45291 Change-Id: I219cdeddca7063a56efeb4fee0e5bb2cbdc7732b Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com> Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
* | Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-02-188-11/+17
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This also reverts commit 018e670a26ff5a61b949100ae080f5e654e7bee8. The change was introduced in 5.6. After the refactoring, 14960f52, in 5.7 branch and a merge, it is not needed any more. Conflicts: .qmake.conf src/corelib/io/qstandardpaths_mac.mm src/corelib/tools/qsharedpointer_impl.h tests/auto/widgets/itemviews/qlistview/tst_qlistview.cpp Change-Id: If4fdff0ebf2b9b5df9f9db93ea0022d5ee3da2a4
| * Merge remote-tracking branch 'origin/5.6.0' into 5.6Liang Qi2016-02-152-1/+7
| |\ | | | | | | | | | Change-Id: I0b190005377a23a91da3563428e223b8a3b18333
| | * Crash fix: reject certain malformed bmp imagesEirik Aavitsland2016-02-051-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A malformed bmp file header could specify a negative color table size. The bmp handler would then return a QImage that claimed to be valid, but actually was invalid, having an empty color table. This would cause crash later, e.g. when attempting to paint it. Change-Id: I7df7c40867557a82dbcee44c7de061226ff232c0 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com> Reviewed-by: Richard J. Moore <rich@kde.org>
| | * Do not change depth for the backingstore's underlying imageLaszlo Agocs2016-02-051-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The depth cannot change. This means that RGB16 cannot be upgraded to 8565 for example as that would be a 24 bit format whereas the backingstores and the underlying platform may expect a 16 bit format. Task-number: QTBUG-50869 Change-Id: I648b39287d43a80fae8097a33bbf3b8bbdcb8816 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: Andreas Holzammer <andreas.holzammer@kdab.com> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
| * | QtGui: Use QImage::constBits()/constScanLine() in non-const contexts.Friedemann Kleint2016-02-136-10/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | Prevent potential detaching by using constBits()/constScanLine() instead of bits()/scanLine(). Change-Id: If03f8d4d3b8ed4c07aed5eff7f580e57ca771919 Reviewed-by: Gunnar Sletta <gunnar@sletta.org> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* | | QIcon::fromTheme(): add support for absolute paths.David Faure2016-02-151-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | This allows methods that return an icon name, to sometimes also return an icon full path (e.g. because the icon was dynamically generated and stored into a local cache on disk) Change-Id: Ib01c3955f4b64236463846241d9814b2d0686634 Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
* | | QBitmap: restore nothrow move special membersMarc Mutz2016-02-122-0/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The user-defined dtor inhibits the move special member functions. We cannot do something about it in Qt 5, because the class is exported (which it shouldn't be), and because it's polymorphic (which it also shouldn't be), so we need to supply all the missing member functions manually. Add a note to remove the inheritance from QPixmap in Qt 6. Change-Id: I86a1a3fe7b84247b3e604cb008aa17bb673c8468 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>