summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* Add Grayscale8 and Alpha8 formats to QImage and drawingAllan Sandfeld Jensen2014-09-1725-268/+1040
| | | | | | | | | | | | Extend the QImage format with two 8-bit grayscale and alpha formats. These formats have the advantage over Indexed8 that they have simpler conversion and can be rendered to by the raster engine. [ChangeLog][QtGui][QImage] Added support grayscale and alpha 8-bit formats which can also be rendered to. Change-Id: I4343c80a92a3dda196aa38d0c3ea251b094fc274 Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* Fusion Style: Workaround to get combo box item style from QtQuick CtrlsJan Arve Saether2014-09-171-1/+2
| | | | | | | This is to align the behaviour with how QGtkStyles behavior is. Change-Id: Ic85d96cf4a4ab30974b25936de6d5b98e65dd2f3 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* EGLFS KMS Hooks: Get rid of flashingLouai Al-Khanji2014-09-161-46/+60
| | | | | Change-Id: I590572ceb0f64d3e6a1d687874d549e84f20f60a Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* EGLFS KMS Hooks: Add HW cursor supportLouai Al-Khanji2014-09-161-0/+189
| | | | | Change-Id: I9cd62f3cbcc4ab844f05c43e775512b72d4ff159 Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* Add some minimal size checking for dynamically loaded resourceshjk2014-09-161-3/+13
| | | | | | | | This covers the case in the bug report, but not much more. Task-number: QTBUG-21254 Change-Id: Ie191a39ceddd7e58a0d8baf7d01f2a08c70162e5 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
* QDateTimePrivate: Add a note about wasted spaceRobin Burchell2014-09-161-0/+3
| | | | | | | And a comment to fix it when the tooling situation improves. Change-Id: I79781da18a36d4e11cede8477f90f216e08bffe2 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Refactor the sloppy submenu logicJørgen Lind2014-09-168-106/+519
| | | | | | | | | | | | And enable the style to control the behavior of the sloppy submenus [ChangeLog][QtWidgets][QMenu] QMenu now pick up how "sloppy" submenus behave from the style Task-number: QTBUG-20094 Change-Id: Ib1a9770d9b63028033cc360ae236471449d00267 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* EGLFS: Do not assume all hooks will want to create a QEGLPlatformCursorLouai Al-Khanji2014-09-167-8/+7
| | | | | Change-Id: I05502c27d697524fb4c4d4ccc3aec0e59589fe24 Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* Add presentBuffer method to EGLFS KMS hooks.Louai Al-Khanji2014-09-161-8/+2
| | | | | Change-Id: Ia7e4aec30ced249ab8a9feb59401d02f250193a0 Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* Add presentBuffer method to EGLFS hooks.Louai Al-Khanji2014-09-163-0/+6
| | | | | Change-Id: Iab5674fe9407d3ab447ef6c16577b24fa60d42aa Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* QFontDatabase: Micro-optimize getFontWeight.Robin Burchell2014-09-151-22/+49
| | | | | | | | | | | | | | | | | | | | Translation is an expensive thing, and probably quite uncommon - so don't penalise any common cases by checking for it until we're quite sure they have failed. In addition, we avoid repeated string construction when translating (caching the result) and avoid repeated case-insensitive comparison by toLowering the string data. This change either speeds up most runtime cases that were unfairly penalised (such as "light") by 50-70% or doesn't impact the runtime speed at all (or, results were within the margin-of-error). Of course, calling with translated content will be a bit slower now, but the slowness of the translations should more than dwarf the real change there. Change-Id: If24685dfd553e4aed07fbf07678b2585e22b0a3a Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
* QDateTime: Micro-optimize by using QString::fromLatin1 instead of ↵Robin Burchell2014-09-151-16/+16
| | | | | | | | | | | | | QString::fromUtf8. This data is clearly not (and will never be) utf8 data, so using fromLatin1 avoids the (slightly more expensive) utf8 mangling. I didn't see any significant impact on benchmarks, but I also wasn't specifically collecting data when making this change. Change-Id: I45190d40b2caccf15b1f9a1ae5b7dcd08cbd541f Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* QDate: Micro-optimize for fromStringIso benchmark.Robin Burchell2014-09-151-2/+2
| | | | | | | | By using QStringRef instead of QString, we avoid a data copy. This takes the QDateTime::fromStringIso benchmark from 0.79ms to 0.53ms for me. Change-Id: Ibb36067491ffc275ce3b667cb0e04941aa9457f0 Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* QTextDocument: code cleanupSamuel Gaist2014-09-151-5/+5
| | | | | | | | | Improve code readability using by-pointer rather than by reference out argument. Change-Id: Icf2d609f1b63feac7b1674b357fe64473bfa8f3f Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* QTextDocument: Correct parameter documentationSamuel Gaist2014-09-151-7/+5
| | | | | | Change-Id: Ie91aa2731732e4a6a1abdc2fc7ae00876c5d76e2 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* QTextDocument: doc and function parameter name cleanupSamuel Gaist2014-09-152-19/+17
| | | | | Change-Id: Idecdf66da0d00cbede6ca5b742d10cf536f366d2 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
* Add QRegularExpression support to QTextDocumentSamuel Gaist2014-09-152-1/+131
| | | | | | | | | | | Currently QTextDocuement only provides find using QRegExp. This patch aims to add support for QRegularExpression. [ChangeLog][QtGui][QTextDocument] Support for searching with a QRegularExpression in a document has been added. Change-Id: I6dba10545b83995d093407038a821fe54db3d261 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Use new, supported APIs in OS X 10.10 and iOS 8.0 to get the OS version.Jake Petroules2014-09-126-66/+80
| | | | | | | | | Gestalt is deprecated so we can't use it long term. At the same time, the new API is cross platform, so we'll no longer have to parse strings in -[UIDevice systemVersion] either. Change-Id: Ic81797174c1a3d50b47b9b209205a6a506cc75ef Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
* Read and use WheelScrollLines configuration on KDEAllan Sandfeld Jensen2014-09-124-2/+17
| | | | | | | | | | Qt supports changing the default lines a scroll wheel click scroll, but wasn't trying to read the system settings. The patch adds support for platform themes to set the default. Change-Id: I53fdcec7984941d1d1285d927d70460356613f81 Reviewed-by: Kevin Ottens <kevin.ottens@kdab.com> Reviewed-by: David Faure <david.faure@kdab.com>
* Micro-optimize qt_section_chunk ctorMarc Mutz2014-09-121-1/+1
| | | | | | | Use C++11 move semantics, and the ctor-init-list. Change-Id: I1a5faa83ef552e8d98ce994edf967770a73cab0e Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QPainter: use qEnvironmentVariableIsEmpty()Marc Mutz2014-09-121-1/+1
| | | | | | | | It doesn't allocate memory, so cannot throw and is a lot faster than qgetenv(). Change-Id: I1ac14bb3d262201071025a885633886934f2d74c Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* QImageReader: use qEnvironmentVariableIsEmpty()Marc Mutz2014-09-121-1/+1
| | | | | | | | | It doesn't allocate memory, so cannot throw and is a lot faster than qgetenv(). Change-Id: I92805767b55adce478a4bf8eb1cbafaa544f96aa Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com> Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* QIcon: use qEnvironmentVariableIsEmpty()Marc Mutz2014-09-121-1/+1
| | | | | | | | | It doesn't allocate memory, so cannot throw and is a lot faster than qgetenv(). Change-Id: I427aa5bf5b8d76aabdd5ce5950e9e6762f79b8d8 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com> Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* QFileSelector: use qEnvironmentVariableIsEmpty()Marc Mutz2014-09-121-1/+1
| | | | | | | | It doesn't allocate memory, so cannot throw and is a lot faster than qgetenv(). Change-Id: Ib303f00ce45816677ffca0580cc6b91a14a0e5be Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
* QWheelEvent: make magic number 120 a symbolic constantMarc Mutz2014-09-121-0/+2
| | | | | | | | | The documentation states that 120 is the value users of the event should use to determine one full step of the wheel. Provide that number as a symbolic constant. Change-Id: I0da0cdd8328a476538080b7276d02863906ea53f Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* QGraphicsView: use qEnvironmentVariableIntValue()Marc Mutz2014-09-122-2/+2
| | | | | | | | It doesn't allocate memory, so cannot throw and is a lot faster than qgetenv(). Change-Id: I774ae9011b855f746b5e3fdf25995d81ec60b82a Reviewed-by: Andreas Aardal Hanssen <andreas@hanssen.name>
* xcb: use qEnvironmentVariableIntValue()Marc Mutz2014-09-121-1/+1
| | | | | | | | It doesn't allocate memory, so cannot throw and is a lot faster than qgetenv(). Change-Id: Ie625d79352fa166e45939ef8f0a5e0cc32f8e801 Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* WinRT: use qEnvironmentVariableIntValue()Marc Mutz2014-09-121-1/+1
| | | | | | | | | It doesn't allocate memory, so cannot throw and is a lot faster than qgetenv(). Change-Id: I73d548ad4e25424fc41722961f527e63632a7b56 Reviewed-by: Andrew Knight <andrew.knight@digia.com> Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
* QNX: use qEnvironmentVariableIntValue()Marc Mutz2014-09-121-3/+3
| | | | | | | | It doesn't allocate memory, so cannot throw and is a lot faster than qgetenv(). Change-Id: I211d6de32da06bf465c4f721f39d73289206745f Reviewed-by: Alan Alpert <aalpert@blackberry.com>
* QMinimalIntegration: use qEnvironmentVariableIntValue()Marc Mutz2014-09-121-1/+1
| | | | | | | | It doesn't allocate memory, so cannot throw and is a lot faster than qgetenv(). Change-Id: Idaad6ec1d92d9aa58d61e2d98e136f108be2bb4c Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* QKmsScreen: use qEnvironmentVariableIntValue()Marc Mutz2014-09-121-1/+1
| | | | | | | | It doesn't allocate memory, so cannot throw and is a lot faster than qgetenv(). Change-Id: Iaaba62396de2d70f611bfa2ba5badb070087fa24 Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* eglfs: use qEnvironmentVariableIntValue()Marc Mutz2014-09-123-4/+4
| | | | | | | | It doesn't allocate memory, so cannot throw and is a lot faster than qgetenv(). Change-Id: I4c43809954ed720de95b3056c13bf520577e3280 Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* Android: use qEnvironmentVariableIntValue()Marc Mutz2014-09-126-8/+8
| | | | | | | | It doesn't allocate memory, so cannot throw and is a lot faster than qgetenv(). Change-Id: I6d79852613228658f9093a272edf9b434e60286c Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
* QEvDevTouch: use qEnvironmentVariableIntValue()Marc Mutz2014-09-121-1/+1
| | | | | | | | It doesn't allocate memory, so cannot throw and is a lot faster than qgetenv(). Change-Id: I64de0b2644c50469a35fdba9ecde167862975b79 Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* QFbVtHandler: use qEnvironmentVariableIntValue()Marc Mutz2014-09-121-1/+1
| | | | | | | | It doesn't allocate memory, so cannot throw and is a lot faster than qgetenv(). Change-Id: I18c00da9504dd3744e6fbb23ea9b9fb7c6d669c9 Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* eglconvenience: use qEnvironmentVariableIntValue()Marc Mutz2014-09-122-6/+6
| | | | | | | | It doesn't allocate memory, so cannot throw and is a lot faster than qgetenv(). Change-Id: Id50609c1f3511287d99e24b03e48c0a254893194 Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* QPainter: use qEnvironmentVariableIntValue()Marc Mutz2014-09-121-1/+1
| | | | | | | | It doesn't allocate memory, so cannot throw and is a lot faster than qgetenv(). Change-Id: Ie41b95c09f2c6106a6683ba4637513c974555840 Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* QHash: remove unnecessary #ifdefMarc Mutz2014-09-121-3/+1
| | | | | | | | | | There's no need to use a macro here, since we can just store the pointer value in a qulonglong and have the second shift operation be done unconditionally. For 32-bit platforms, it will yield 0, and xor'ing it into 'seed' will have no effect. Change-Id: I3e63bd504e81c84d13935d5503c3707d40d74d6f Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QPainter: drop a pointless checkMarc Mutz2014-09-121-3/+1
| | | | | | | There's no need to check for nullptr before invoking delete. Change-Id: Ied751f76f15f390bf86bbba53c14a3e450aa81e8 Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* QPainter: use qDeleteAll()Marc Mutz2014-09-121-2/+1
| | | | | Change-Id: I167e4d7a57e92eb5ea7c39b04246ac2f44c91de0 Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* QLibrary: simplify qt_debug_component()Marc Mutz2014-09-121-4/+1
| | | | | | | | | | | | | | | Instead of initializing debug_env to -1 (thus forcing the variable into the data segment), and then overwriting the -1 with a read from the env-var, dynamically initialize the variable from the env-var directly, thus allowing the variable back into the bss segment (which doesn't occupy storage in the executable). There may have been a reason to do it this way when the old code could fail due to the memory allocation involved, but now with qEnvironmentVariableIntValue(), that is no longer a reason. Change-Id: I9f21b0783ff348f50b574395fc07f2869a14102e Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QLibrary: use qEnvironmentVariableIntValue()Marc Mutz2014-09-121-1/+1
| | | | | | | | It doesn't allocate memory, so cannot throw and is a lot faster than qgetenv(). Change-Id: I8d440619edfbd90045564e1f92676f1e1f87e136 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Add qEnvironmentVariableIntValue()Marc Mutz2014-09-122-0/+49
| | | | | | | | | | | | | | A lot of code in Qt uses VAR=1 for enabling or disabling some feature or other, ignoring qEnvironmentVariableIsSet(), which was added for that purpose. Other code actually reads numerical values from environment variables. For both use-cases, provide a non-throwing, non-memory-allocating way to get the numerical (int) value of an environment variable, complementing qEnvironmentVariableIs{Set,Empty}(). [ChangeLog][QtCore] Added qEnvironmentVariableIntValue(). Change-Id: I81c85287ea10d355c1bbf8d7807ec9a0e477bce0 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QAbstractItemView: add iconSizeChanged signal.David Faure2014-09-122-1/+4
| | | | | | | | | | | This is useful when writing a generic preview-icon-generator which should work with different type of views, itemviews and QML views. A way to be notified of a change of icon size was missing on the itemview side. [ChangeLog][QtWidgets][QAbstractItemView] Added iconSizeChanged signal. Change-Id: I19b3049961002ca27d71aefbb6980d1e6f225c79 Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* QTextStream: add fast path for writing char and QChar.David Faure2014-09-122-2/+30
| | | | | | | | | | | | Avoids allocating a QString for every char being written out. The benchmark went from 5.5 ms per iteration to 0.8 ms, and from 40 million instructions to 6 million. Found using Milian Wolff's heaptrack tool. Change-Id: I1784c47b944454bc947a607a22c39d249372ed55 Reviewed-by: Adam Majer <adamm@zombino.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* Remove incorrect read from QSslSocket::readData()Alex Trotsenko2014-09-111-10/+6
| | | | | | | | | QIODevice makes readData() call only when its read buffer is empty. Also data argument points to the user or reserved read buffer area. So, no need in data transfer from read buffer at this point at all. Change-Id: Ieb4afdf7eec37fdf288073e4a060e64424f22b9c Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Merge remote-tracking branch 'origin/5.4' into devOswald Buddenhagen2014-09-10126-1161/+2893
|\ | | | | | | Change-Id: Id4997327cc01bd4bb397a463bdffbd15e80398ef
| * Fix garbled resize with QOpenGLWidget when using multi-sampling.Dyami Caliri2014-09-101-0/+1
| | | | | | | | | | | | | | | | If you configure QOpenGLWidget to use sampling, the 'resolvedFbo' isn't updated during resizing. This leads to garbled views. Change-Id: I9f9265520134bcf12436778773507df936c5fbb6 Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
| * xcb: fix getting a XdndAware property if a proxy window existsAlexander Volkov2014-09-091-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | According to the XDND standard (http://www.newplanetsoftware.com/xdnd/) if the proxy window exists then it should be checked for the XdndAware property rather than the target window directly. c3f9de62966d32d8e33d62eb374fe2657a4cfebe introduced the mistake. In the old code the proxy window was used. Change-Id: I83b66d4b1f08a1f44d5c1451d0f1735c084bcf09 Spotted-by: Alexander Smirnov Reviewed-by: Lars Knoll <lars.knoll@digia.com>
| * QNetworkReply: move "State" enum declaration into QNetworkReplyPrivateMaks Naumov2014-09-095-45/+35
| | | | | | | | | | Change-Id: If63a029a7a7ef84fc1b4b73f5bab495992ea7e02 Reviewed-by: Peter Hartmann <phartmann@blackberry.com>