summaryrefslogtreecommitdiffstats
path: root/src/gui/painting
Commit message (Collapse)AuthorAgeFilesLines
* Fix some qdoc warningsFriedemann Kleint2019-03-151-1/+1
| | | | | | | | | | | | | | | | | | src/network/ssl/qsslsocket.cpp:1501: (qdoc) warning: Can't link to 'QSslConfiguration::defaultCaCertificates()' src/network/ssl/qsslsocket.cpp:1482: (qdoc) warning: Can't link to 'QSslConfiguration::defaultCaCertificates()' src/network/ssl/qsslsocket.cpp:1513: (qdoc) warning: Can't link to 'QSslConfiguration::defaultCaCertificates()' src/network/ssl/qsslsocket.cpp:1119: (qdoc) warning: Can't link to 'QSslConfiguration::setDefaultCiphers()' src/network/ssl/qsslsocket.cpp:1119: (qdoc) warning: Can't link to 'QSslConfiguration::defaultCiphers()' src/gui/opengl/qopengltexture.cpp:4137: (qdoc) warning: Can't link to 'setComparisonFunction()' src/widgets/dialogs/qfilesystemmodel.cpp:1215: (qdoc) warning: Undocumented return value (hint: use 'return' or 'returns' in the text src/widgets/graphicsview/qgraphicswidget.cpp:1229: (qdoc) warning: Undocumented return value (hint: use 'return' or 'returns' in the text src/widgets/graphicsview/qgraphicsscene.cpp:3313: (qdoc) warning: Undocumented return value (hint: use 'return' or 'returns' in the text src/gui/painting/qpaintengine_raster.cpp:3438: (qdoc) warning: Undocumented return value (hint: use 'return' or 'returns' in the text src/widgets/widgets/qtextedit.cpp:2544: (qdoc) warning: Overrides a previous doc src/widgets/widgets/qplaintextedit.cpp:2932: (qdoc) warning: (The previous doc is here) Change-Id: I0c68c59a87eb6a5d9e974f857af6aca0c6e0672d Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Merge remote-tracking branch 'origin/5.12' into 5.13Liang Qi2019-03-061-2/+3
|\ | | | | | | | | | | | | Conflicts: src/network/access/http2/hpacktable_p.h Change-Id: Ie0c296667dfdebba84f4858056a1ac80c24ee7df
| * Don't split bezier curves that are already just a lineAllan Sandfeld Jensen2019-03-051-2/+3
| | | | | | | | | | | | | | | | | | Otherwise we can end up in an infinite loop of splitting the curve and then discarding the half of the new curve, etc. Fixes: QTBUG-74172 Change-Id: I1984b7fd33cd98f65866f1c57c6ab20114615803 Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
* | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-02-261-3/+1
|\| | | | | | | Change-Id: Id511850002d9274d17891c063376ac4b3ff939dd
| * Fix assert when drawing lines with extreme coordinatesEirik Aavitsland2019-02-251-3/+1
| | | | | | | | | | | | | | | | | | | | For extreme coordinates, the rasterizer's width parameter could become NaN, which compares false with everything and hence would trigger an assert. Fixes: QTBUG-56434 Change-Id: I27abae6ab0bc94ce042be86ea0587095cdb7d487 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | QtGui/Network/OpenGl/Widgets/Xml: use \nullptr in documentationChristian Ehrlicher2019-02-201-1/+1
| | | | | | | | | | | | | | Replace null and '\c nullptr' with \nullptr in the documentation. Change-Id: I58934eea06943309ba895833f1991629870ab45b Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-02-151-10/+31
|\| | | | | | | Change-Id: I8cad26f17834dbc9f7151edc0f17786f9e32025d
| * QBackingStore: Make QPlatformBackingStore creation lazyTor Arne Vestbø2019-02-131-10/+13
| | | | | | | | | | | | | | | | | | Some platform backing stores may require that the window has been created, so let's defer the platform backingstore creation until absolutely necessary. Change-Id: Ib93151c6473e3bbe77d994782d84289c2f63bcf2 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
| * Don't allow backingstore flush to non-raster surfacesTor Arne Vestbø2019-02-121-0/+18
| | | | | | | | | | | | Change-Id: I8e85706727a8c5f7585e34e3864c8a9f48481b92 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* | QtGui: compile with QT_DISABLE_DEPRECATED_BEFORE=0x050d00Christian Ehrlicher2019-02-131-0/+2
| | | | | | | | | | | | | | | | | | Don't call or implement functions which are not available when compiling with QT_DISABLE_DEPRECATED_BEFORE=0x050d00 Change-Id: I763a1c60d7cc080677736447dc358299d8f7ab04 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | Add faster path for scaling QRegion with multiple regionsJoni Poikelin2019-02-131-2/+17
| | | | | | | | | | | | Fixes: QTBUG-72821 Change-Id: Ic4fa349087239337a77b0e280be551b46c75af71 Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
* | Fix some QPainter-related deprecation warningsFriedemann Kleint2019-02-083-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | text/qtextdocument.cpp:2666:48: warning: ‘QString QTextCharFormat::anchorName() const’ is deprecated: Use anchorNames() instead [-Wdeprecated-declarations] text/qtextdocumentfragment.cpp:545:87: warning: ‘QString QTextCharFormat::anchorName() const’ is deprecated: Use anchorNames() instead [-Wdeprecated-declarations] text/qtextdocumentfragment.cpp:546:68: warning: ‘QString QTextCharFormat::anchorName() const’ is deprecated: Use anchorNames() instead [-Wdeprecated-declarations] painting/qpainterpath.cpp:3321:34: warning: ‘void QPainterPath::addRoundRect(const QRectF&, int, int)’ is deprecated: Use addRoundedRect(..., Qt::RelativeSize) instead [-Wdeprecated-declarations] painting/qpainterpath.cpp:3342:48: warning: ‘void QPainterPath::addRoundRect(const QRectF&, int, int)’ is deprecated: Use addRoundedRect(..., Qt::RelativeSize) instead [-Wdeprecated-declarations] painting/qpainterpath.cpp:3366:47: warning: ‘void QPainterPath::addRoundRect(const QRectF&, int)’ is deprecated: Use addRoundedRect(..., Qt::RelativeSize) instead [-Wdeprecated-declarations] painting/qpainter.cpp:4233:49: warning: ‘void QPainter::drawRoundRect(const QRectF&, int, int)’ is deprecated: Use drawRoundedRect(..., Qt::RelativeSize) instead [-Wdeprecated-declarations] painting/qpainter.cpp:8349:27: warning: ‘void QPainter::setMatrixEnabled(bool)’ is deprecated: Use setWorldMatrixEnabled() instead [-Wdeprecated-declarations] painting/qpdf.cpp:1545:28: warning: ‘void QDataStream::unsetDevice()’ is deprecated: Use QDataStream::setDevice(nullptr) instead [-Wdeprecated-declarations] widgets/qtabbar.cpp:2096:17: warning: ‘void QPainter::initFrom(const QPaintDevice*)’ is deprecated: Use begin(QPaintDevice*) instead [-Wdeprecated-declarations] Change-Id: I76d98ea8146e7586d3763a5610781c7736d37204 Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
* | Merge remote-tracking branch 'origin/5.12' into 5.13Liang Qi2019-02-084-61/+75
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/android/templates/AndroidManifest.xml src/network/ssl/qsslsocket_mac.cpp src/widgets/styles/qstylesheetstyle.cpp tests/auto/corelib/kernel/qtimer/BLACKLIST tests/auto/testlib/selftests/blacklisted/tst_blacklisted.cpp tests/auto/testlib/selftests/expected_blacklisted.lightxml tests/auto/testlib/selftests/expected_blacklisted.tap tests/auto/testlib/selftests/expected_blacklisted.teamcity tests/auto/testlib/selftests/expected_blacklisted.txt tests/auto/testlib/selftests/expected_blacklisted.xml tests/auto/testlib/selftests/expected_blacklisted.xunitxml tests/auto/testlib/selftests/expected_float.tap tests/auto/testlib/selftests/expected_float.teamcity tests/auto/testlib/selftests/expected_float.txt tests/auto/testlib/selftests/expected_float.xunitxml Done-With: Christian Ehrlicher <ch.ehrlicher@gmx.de> Done-With: Edward Welbourne <edward.welbourne@qt.io> Done-With: Timur Pocheptsov <timur.pocheptsov@qt.io> Change-Id: If93cc432a56ae3ac1b6533d0028e4dc497415a52
| * Doc: decrease confusion about HSV vs HSL in QColorEirik Aavitsland2019-02-051-29/+37
| | | | | | | | | | | | | | | | | | | | The non-qualified hue() and saturation() etc. refers to those values in the HSV, not HSL, color model. Make this more explicit in the documentation to avoid confusion. Task-number: QTBUG-73129 Change-Id: Ief337672966ac72d0d0c3606d8d68acf01ffe7ee Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
| * Fix QColor::toCmyk() for rgb(0, 0, 0)Eirik Aavitsland2019-02-051-17/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | We translate all pure gray colors into cmyk having c,m,y=0 and only the k value expressing the darkness. But a fix introduced to avoid division by 0 caused rgb(0, 0, 0) to be an exception to this; it ended up being translated as c,m,y,k=1 instead. Fix by catching the potential div-by-0 situation earlier and directly set the orthodox cmyk translation: c,m,y=0,k=1. Fixes: QTBUG-73171 Change-Id: I3774eaf9d96e096ac5c47c55d28881bea2bd1309 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| * Painter path stroking: fix capping of beziers ending in tight turnsEirik Aavitsland2019-02-051-13/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | For some overly tight beziers where the start or end point and the next control point are closer than the pen width, the stroker's shifting algorithm will produce a start/end tangent pointing in the opposite direction from what is expected, for one of the sides. This would break the square and round capping logic. Fix by detecting the situation in the capping function and reversing the tangent when necessary. Change-Id: I48f4f017403d7b289b0483dd2b3a7ff1bbd0cf2a Reviewed-by: Lars Knoll <lars.knoll@qt.io>
| * QtGui: Unify license headersKai Koehne2019-01-292-2/+2
| | | | | | | | | | Change-Id: I0a2553b95b099fdfa83d42e71bdf9a192a6588c7 Reviewed-by: Jani Heikkinen <jani.heikkinen@qt.io>
* | Improve ARGB32ToRGBA64 conversionsAllan Sandfeld Jensen2019-02-072-35/+29
| | | | | | | | | | | | | | Improves the precision so 255 values map to 65535 exactly. Change-Id: I366f408e8c6047d52acbed35e9d665249bbaba2b Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Add deprecation exclusion around deprecated calls in deprecated codeFriedemann Kleint2019-02-061-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | Fix: io/qdir.cpp:1087:16: warning: ‘static void QResource::addSearchPath(const QString&)’ is deprecated: Use QDir::addSearchPath() instead [-Wdeprecated-declarations] io/qprocess.cpp:1178:34: warning: ‘void QProcess::finished(int)’ is deprecated: Use QProcess::finished(int, QProcess::ExitStatus) instead [-Wdeprecated-declarations] image/qpixmap.cpp:997:48: warning: ‘static QPixmap QPixmap::grabWidget(QObject*, const QRect&)’ is deprecated: Use QWidget::grab() instead [-Wdeprecated-declarations] text/qfont.cpp:2218:29: warning: ‘QString QFont::lastResortFamily() const’ is deprecated [-Wdeprecated-declarations] itemviews/qitemdelegate.cpp:1008:41: warning: ‘static QPixmap* QPixmapCache::find(const QString&)’ is deprecated: Use bool find(const QString &, QPixmap *) instead [-Wdeprecated-declarations] Change-Id: I51259edc175b1f55f61ded3af50ebfffd8c304a8 Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
* | Switch epilogues of AVX2 conversions to single stepAllan Sandfeld Jensen2019-02-061-79/+79
| | | | | | | | | | | | | | | | Not only is it fewer instructions but all the logic except for load and store can be identical to the main loop. Change-Id: I2caac0c7504d94e404bd8cfe5080aff07ba2d465 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Fix convertARGBToARGB32PM_avx2 and convertARGBToRGBA64PM_avx2Allan Sandfeld Jensen2019-02-051-2/+2
| | | | | | | | | | | | | | | | The tails was off since f370410097f8cb8d8fdf6174b799497fe7fe0adf Fixes: QTBUG-73440 Change-Id: If86178c6cad3f87d9b5f0f89e90354d49cd386a4 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | QtGui: replace 0 with \nullptr in documentationChristian Ehrlicher2019-02-021-1/+1
| | | | | | | | | | | | | | | | | | Replace 0 with \nullptr in the documentation. As a drive-by also replace some 0 with nullptr in the corresponding code. Change-Id: Ieffbfffa76e3018257b667a3e8ad6e3b88486cde Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* | QtGui/QPainterPath: mark obsolete functions as deprecatedChristian Ehrlicher2019-02-022-29/+39
| | | | | | | | | | | | | | | | | | | | Mark some long obsolete functions as deprecated so the can be removed with Qt6: - addRoundRect() - subtractedInverted() Change-Id: I4707c07e983a4ac65ec3706d25b09ec01a9de62c Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
* | QtGui/QPainter: mark obsolete functions as deprecatedChristian Ehrlicher2019-02-022-18/+51
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Mark some long obsolete functions as deprecated so the can be removed with Qt6: - initFrom() - setMatrix()/matrix()/deviceMatrix()/resetMatrix() - setWorldMatrix()/worldMatrix()/combinedMatrix() - setMatrixEnabled()/matrixEnabled() - drawRoundRect() - setRedirected()/redirected()/restoreRedirected() Change-Id: I0daed72c0ef06c192309f02366a7201154e75ac9 Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
* | QtGui: mark obsolete QPixmapCache::find() functions as deprecatedChristian Ehrlicher2019-02-022-2/+2
| | | | | | | | | | | | | | | | | | QPixmapCache::find(QString) and QPixmapCache::find(QString, QPixmap&) are deprecated since Qt4 times. Explicit mark them as deprecated so they can be removed with Qt6. Change-Id: Iaf185f69afe02203559a1c812fbb4a95c9049a1d Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
* | QtGui: mark some image functions as obsoleteChristian Ehrlicher2019-01-282-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Mark functions which were obsolete since Qt4 times as deprecated so they can be removed with Qt6: - QBitmap::transformed(QMatrix) - QImageIOHandler::name() - QImageWriter::setDescription() - QImageWriter::description() - QPixmap::fill() - QPixmap::grabWindow() - QPixmap::grabWidget() - QTransform::det() Change-Id: I8523065eb59a3242c4c4c195f31ae15c4dcbf8f7 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
* | Merge remote-tracking branch 'origin/5.12' into devLiang Qi2019-01-263-4/+6
|\| | | | | | | | | | | | | | | Conflicts: src/android/templates/AndroidManifest.xml tests/auto/widgets/styles/qstylesheetstyle/tst_qstylesheetstyle.cpp Change-Id: I4c9679e3a8ebba118fbf4772301ff8fde60455b9
| * Always unlock graphics buffer after binding texture during composeAndFlushTor Arne Vestbø2019-01-241-0/+1
| | | | | | | | | | | | | | | | | | | | The code path for re-generating the texture already has the unlock, but the non-regenerating code-path was missing an unlock, causing asserts when the graphics buffer was then attempted to be locked (again) at a later point. Change-Id: Ic65add838360079829b7e81d7c1cfe2274959059 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
| * Merge remote-tracking branch 'origin/5.12.1' into 5.12Qt Forward Merge Bot2019-01-231-3/+4
| |\ | | | | | | | | | Change-Id: Icebd151eae0cf9d400319a42573290d1a911ce26
| | * Fix PDF generation for locales using comma as decimal separatorAndre de la Rocha2019-01-081-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A previous change that extended the maximum PDF size has caused the generation of invalid PDF output when the current locale was set to something using commas instead of points when outputting floating point numbers through printf(). This change uses QByteArray::number() instead, which uses points, irrespective of the current locale. Fixes: QTBUG-72868 Fixes: QTBUG-72848 Change-Id: I292eba2d6c89b3e01957bb8c04c04bdca8ada316 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Tobias Koenig <tobias.koenig@kdab.com>
| * | Fix change-of-sign warnings in ICC 19Thiago Macieira2019-01-231-1/+1
| | | | | | | | | | | | | | | | | | | | | error #68: integer conversion resulted in a change of sign Change-Id: I4ac1156702324f0fb814fffd156f80962df6b4a7 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | | Use VPMASKMOV in the epilogue ARGB->ARGB{32,64} AVX2 epiloguesThiago Macieira2019-01-231-97/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of stepping down to 4 pixels, then 2 px, then 1, with essentially the same code, let's use maskload and maskstore to only load and store the effective portions (instructions new in AVX2). The secondary loop gets run at most twice, since there can be at most 7 pixels left. This fixes an off-by-4 bug in the previous implementation (lines 1041 and 1186 should have had 7 instead of 3). Change-Id: I4d4dadb709f1482fa8ccfffd157862e77ac508f6 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | | Merge remote-tracking branch 'origin/5.12' into devQt Forward Merge Bot2019-01-212-5/+5
|\| | | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf Change-Id: Ibfcb30053f3aacb8ec2ec480e146538c9bf440ea
| * | Documentation: Add \nullptr macro and use where applicableFriedemann Kleint2019-01-101-1/+1
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Qt for Python users reading the documentation assume that int(0) can be passed for pointer parameters. Use the newly introduced \nullptr to disambiguate this. In a follow-up step, the \nullptr macro can be defined as None when generating the Qt for Python documentation. Task-number: PYSIDE-903 Change-Id: I3a45f87175a0668ab5f3f95f0aff409f7e3ef027 Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io> Reviewed-by: Christian Tismer <tismer@stackless.com> Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io> Reviewed-by: Paul Wicking <paul.wicking@qt.io>
| * Fix warnings about uninitialized variables - qrgba64_p.hLiang Qi2019-01-071-4/+4
| | | | | | | | | | | | | | | | | | | | In function 'QRgba64 rgbBlend(QRgba64, QRgba64, uint)': error: 'blend.QRgba64::rgba' is used uninitialized in this function [-Werror=uninitialized] qrgba64_p.h:246:13: note: 'blend' was declared here QRgba64 blend; Change-Id: I7b263f863281c51c7d8099704f2cffcc7e1a07df Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Fix the AVX2 ARGB->ARGB64 conversion codeThiago Macieira2019-01-151-5/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit c8c5ff19de1c34a99b8315e59015d115957b3584 introduced the solution as a simple scaling up of the code in qdrawhelper_sse4.cpp, but it's bad due to the way that the 256-bit unpack instructions work: the unpack-low instruction unpacks the lower half of each half of the 256-bit register. So we fix it up by inserting a permute4x64 that swaps the middle two quarters of the 256-bit register (permute8x32 requires a __m256i parameter, instead of an immediate). This introduces an instruction that costs 3 cycles in each loop, but since the AVX2 code has double the throughput compared to SSE4 code, it should still be faster. This problem does not affect the ARGB->ARGB32 code because that repacks at the end. Change-Id: I4d4dadb709f1482fa8ccfffd1578620b45166a4f Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Add AVX2 version of ARGB->ARGB32PMThiago Macieira2019-01-093-2/+157
| | | | | | | | | | | | | | | | Similar to the previous commit. This also removes the SSE4 implementations from Qt builds that use AVX2 throughout. Change-Id: I251f00d706d646ed87b4fffd1577f96ed52a4cf4 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Add AVX2 version of the ARGB32->RGBA64PM codeThiago Macieira2019-01-092-0/+143
| | | | | | | | | | Change-Id: I251f00d706d646ed87b4fffd1577f84854e358a4 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Add clear, reserve and capacity methods to QPainterPathJean-Michaël Celerier2019-01-083-6/+86
| | | | | | | | | | | | | | | | | | | | | | | | | | This allows anticipating and reusing internal allocations of QPainterPathElements instead of using the common `m_myPath = QPainterPath{}` pattern. [ChangeLog][QtGui][QPainterPath] Added clear(), reserve(), capacity(). clear() removes allocated QPainterPath elements but preserves allocated memory, which can be useful for application with complex paths that are often recreated. reserve() and capacity() follow QVector semantics. Change-Id: I763461e2a421feda9053d3eb512af2fcf07ade2b Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Optimize ARGB32->RGBA64PM betterAllan Sandfeld Jensen2019-01-083-20/+199
| | | | | | | | | | | | | | | | This conversion is critical for ARGB32 painting, and no compiler optimized the premultiplication efficiently. Change-Id: Iee137c2f7020246478d09e880a7a1bf2ed3c6fd4 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | QPainter: replace an QVector with QVarLengthArrayMikhail Svetkin2019-01-071-1/+2
| | | | | | | | | | | | | | | | | | We usually do not keep a lot of QPainter states, but we need to call 1 allocation and 1 reallocation for keep 4 states. It will be better to use QVarLengthArray with preallocation for 8 states. Change-Id: Iacb6aa7a73807491534b1a915453f218d6e4305b Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
* | Optimize allocation of QClipData::m_spansMikhail Svetkin2019-01-071-41/+39
| | | | | | | | | | | | | | | | Calculate the size of m_spans before allocate them. Change-Id: Ie572f243d6c167f42e807701bf9bf76a3c6c0c69 Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Merge remote-tracking branch 'origin/5.12' into devLiang Qi2019-01-041-1/+1
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Also blacklist tst_QRawFont::unsupportedWritingSystem() and tst_QGlyphRun::mixedScripts() on windows for now. Conflicts: qmake/generators/makefile.cpp src/corelib/itemmodels/qstringlistmodel.cpp src/platformsupport/fontdatabases/windows/qwindowsfontengine_p.h tests/auto/corelib/itemmodels/qstringlistmodel/tst_qstringlistmodel.cpp tests/auto/gui/text/qglyphrun/BLACKLIST tests/auto/gui/text/qrawfont/BLACKLIST Task-number: QTBUG-72836 Change-Id: I10fea1493f0ae1a5708e1e48d0a4d7d6b76258b9
| * Don't dither antialiasing on glyphs when converting to monoEskil Abrahamsen Blomfeldt2018-12-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When glyphs are converted to monochrome from an alpha map, it does not make sense to apply high quality dithering, because the result will be that some the subpixels along the edges that cover only part of a pixel are filled. This causes the glyphs to look jagged and ugly. Instead, we use ThresholdDither to fill all pixels that are >= 50% opacity. [ChangeLog][QtGui][Text] Improved appearance of monochrome text on some platforms. Fixes: QTBUG-69702 Change-Id: I0f44a8d73f6b9f1eb59f297d66438575f1e9db10 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | QColor: mark light()/dark() as deprecatedChristian Ehrlicher2018-12-242-25/+35
| | | | | | | | | | | | | | | | | | QColor::light()/dark() are deprecated since Qt4 times. Therefore annotate them with Q_DEPRECATED so they can be removed in Qt6. Change-Id: Ifbfc59d6a070670a43c9b60a23f83cc4ba59bf07 Reviewed-by: André Hartmann <aha_1980@gmx.de> Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
* | Merge "Merge remote-tracking branch 'origin/5.12' into dev" into ↵Qt Forward Merge Bot2018-12-131-0/+8
|\ \ | | | | | | | | | refs/staging/dev
| * | Merge remote-tracking branch 'origin/5.12' into devQt Forward Merge Bot2018-12-131-0/+8
| |\| | | | | | | | | | Change-Id: I0fe623517af28e408b642c879efd59f633ab63ac
| | * Avoid crash in blitting or fast draw when QPointF is too bigAllan Sandfeld Jensen2018-12-111-0/+8
| | | | | | | | | | | | | | | | | | | | | Change-Id: I88182d5d95fda15d33836f16dee78167685b3765 Fixes: QTBUG-72392 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
* | | Add Grayscale16 Image FormatAllan Sandfeld Jensen2018-12-122-3/+88
|/ / | | | | | | | | | | | | | | | | | | [ChangeLog][QtGui][QImage] Added support for 16-bit grayscale format. Together-with: Aaron Linville<aaron@linville.org> Task-number: QTBUG-41176 Change-Id: I5fe4f54a55ebe1413aa71b882c19627fe22362ac Reviewed-by: Nick D'Ademo <nickdademo@gmail.com> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | Use Q_DISABLE_COPY_MOVE for private classesFriedemann Kleint2018-12-124-4/+4
| | | | | | | | | | Change-Id: I3cfcfba892ff4a0ab4e31f308620b445162bb17b Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>