Otherwise build will be broken due to no support for it.
Change-Id: If5ccd7fbcf8340600c5b12081ac4f7e2c6b420fd
Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
It's unexpected that all messages generated by the stream version
of qDebug and friends have a trailing space. It also makes switching
to categorized logging (which only supports the stream version) difficult,
since all autotests checking for debug output would have to be adapted.
Task-number: QTBUG-15256
Change-Id: I8d627a8379dc273d9689f5611184f03607b73823
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The abstractions are needed so that they can work with both
QGraphicsLayouts and QtQuick.Layouts.
Since the plan is to move the engine to QtGui, this means that the
engine cannot have any references to anything in the QtWidgets module.
As a consequence of that several things had to be done:
* The style info object had to be redone with an abstraction layer
to get rid of style and widget dependency. (Abstract class is
called QAbstractLayoutStyleInfo)
* QGridLayoutEngine must be subclassed due to some specializations for
QGraphicsLayoutItem, manifested as QGraphicsGridLayoutEngine.
* QGridLayoutItem must be subclassed due to some specializations for
QGraphicsLayoutItem, manifested as QGraphicsGridLayoutEngineItem.
Did also some minor cleanups, reordered arguments so that all styleInfo
arguments are last in all function calls
This also fixes QTBUG-35099 (bug was spotted during this refactoring)
Task-number: QTBUG-35099
Change-Id: If49d40f71870dc8d99d2e145be158e3080b595fa
Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
When the window is requested to be made active then it should check if
the window accepts focus or not. If it does not then it should ensure
it informs the underlying system that it does not accept the activate
event.
Change-Id: I3e6533be792d8bdbb2bfcdf3b9c1a93e2c67c75a
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
As stated in commit 46106c4, placeholder text should not be shown
when an empty QLineEdit has visual preedit text fed by a composing
input method. The same condition applies to setPlaceholderText() in
the sense that there is no need to call update() when the placeholder
text is not even shown.
Change-Id: I2521a119b160e16ae0738d3575fea6d9939d6d2a
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Tasuku Suzuki <stasuku@gmail.com>
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Take longer search strings into account instead of just using the first
character of the search string.
Touches up https://qt.gitorious.org/qt/qt/merge_requests/1418 for
resubmission.
Task-number: QTBUG-3032
[ChangeLog][QtWidgets][QSpinBox] Fixed keyboard selection with
multiple-character strings.
Change-Id: I2f68c8b97b1a1884659dcb19f52b1efeace9b88b
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
When comparing expected with actual debug messages, allow the expected
ones to contain a trailing space. This is needed to not break all
autotests in a follow up patch, which will prevent ~QDebug() from
generating a trailing space by default.
Task-number: QTBUG-15256
Change-Id: I7f67393ddfbfe37fde1ca5ef45e4ad7f4b5324b4
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
Reviewed-by: Jason McDonald <macadder1@gmail.com>
Before, we'd get just an error message that the size of the array was
negative. Now, for C++11 compilers, we get a better error message:
qbasicatomic.h:117:5: error: static assertion failed: Template parameter is not a supported integer on this platform
qbasicatomic.h:119:24: error: invalid use of incomplete type ‘struct QAtomicOps<long long unsigned int>’
Change-Id: I6b0792254c0dc6103a4a7608f2942d59cda07c00
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
This is a prerequisite of sharing the layout engine of QGraphicsLayout
with the engine of QtQuick.Layouts.
Change-Id: Iae566c0e51d234b836cf818b541d4284bd78bbee
Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
ASSERT removes the condition when building for release mode. However,
QueryInterface must be called in any case. Adopt to using ASSERT(false)
like in other occurrences in angle.
This is a follow-up patch to 331bc16afd
Change-Id: I4413bab06b5a529fcbd09bbc20828fcdcf4e4fc6
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Andrew Knight <andrew.knight@digia.com>
The T was missing in QT_BASIC_ATOMIC_HAS_CONSTRUCTORS. This makes
QAtomicInt's constructor become constexpr.
Change-Id: Ibe58ff36517c5d05ce8af9c0f28169fa63521632
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Since we already have the section there is no need to have an
extra structure. It simplifies the code itself and the code
is overall more efficient.
The benchmark seems to show overall performance increasement
various places (e.g insert, swapSection).
Change-Id: I623453b69a9a830908e8d9d5f3816ccebe073c9f
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Introduce isNull overload to take field name as a parameter.
This is corresponding to the commit
7e6e141234
Change-Id: I122f79707d26eaa09c2f38dc31aeee1dac7de33b
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
xcb and windows already do this. The default value is 1 so the
behavior on cocoa does not change when setSwapInterval() is not
called.
Task-number: QTBUG-31939
Change-Id: Id9d9204c9324f1cc187c6aee4286e7da42583759
Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com>
glViewport expects device pixels, but the various
geometry accessors returns values in device-independent
pixels.
Change-Id: I8004692de82251e4f1f25bf8f2698895f222ede3
Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com>
NSEvent needs to be copied.
Reference:
http://lists.apple.com/archives/cocoa-dev/2007/Dec/msg00678.html
Task-number: QTBUG-33533
Change-Id: I73709545573e59aab6875a8c3dd903cb171e858f
Reviewed-by: Jake Petroules <jake.petroules@petroules.com>
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
This class is never inherited from, so save the vtable, and
everything that goes with it (typeinfo, ...).
Effects on Linux AMD64 GCC 4.9-trunk release stripped:
text: -248B
data: -64B
relocs: -5
Change-Id: I12eec1115529eb3fc873fb9a9aacc150d9937fb9
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
The functions valueAt() and setValueAdd() were defined inline out-of-body,
but not declared inline. Fix by adding inline to the declarations, too.
This has in the past caused warnings on exported classes on MinGW, and it's
simply wrong, too.
Change-Id: I5922cb9ca0c5ee37408f553f0aad0e3264853827
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
QSimplex is not designed to be copied, so disable explicitly.
Change-Id: Ia1ddcfe905380e594930717c7c55bb38a7dd4059
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
Determine writing system before executing the loop.
Change-Id: I6c462bdef4d70860e76c7cc9d939e3e92983b173
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
We require glx version 1.3 which is where fbconfig is first defined.
Also make use of the configure test and report the glx status.
GLX support should always take precedence when compiling the
xcb backend
Change-Id: Ie46834210bf5cd2ac4006ff08379e0d3434ffa2b
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
This adds a new configuration parameter, xcb-xlib, which allows
overriding the configure test for that existing configuration option.
The use of xcb-xlib in the xcb platform plugin becomes the preferred path
for non-OpenGL ES 2 builds, while the EGL codepath is used otherwise.
This has the advantage that EGL can be used with Desktop OpenGL if Qt is
configured with -no-xcb-xlib.
Change-Id: I5018e31fe0399b94f020c671eff9414d00431c44
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
The condition under which the placeholder text should be shown changed recently,
so refactor the code to centralize the condition.
It turns out that setPlaceholderText() and paintEvent() disagree on the condition
already.
Change-Id: Id193a9a138042ab0690082dcf634cf7487a5276e
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Change match() to return an index and use that to reintroduce
the blacklist bookkeeping for fonts for which font engine
creation fails (for example, due to missing open type support).
Change the algorithm to retry search if that happens.
Add empty string as fallback for non-common scripts indicating
'try to find any font matching the script' as is done in Qt 4.
Task-number: QTBUG-34908
Change-Id: I9ac81ff1c275ebb635675dc26b52394789fca60c
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
This patch adds more char tests for the plus and minus signs to
ensure that e.g. number input widgets can be used with the locale
and the known sign chars.
[ChangeLog][QtCore] Fixed a bug that caused negative number input
using '-' to be rejected because the current locale uses e.g. 0x2212.
QIntValidator and QDoubleValidator now accepts both signs as well as
the locale minus sign.
Task-number: QTBUG-35069
Change-Id: I857105ca38b1d3826e27eb64645fef07149d74bc
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Use explicit format string, that contains milliseconds, when
converting an QDateTime/QTime to a SQLite field content.
Task-number: QTBUG-24200
[ChangeLog][QtSql][QSQLITE] Fix sub-second handling
Change-Id: Ib89152b7c3dd780b57a8826beff8b6b118e9d3d6
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
As stated in http://dev.mysql.com/doc/refman/5.7/en/c-api-prepared-statement-data-structures.html
the content of MYSQL_TIME.second_part field is supposed to be
in microseconds not milliseconds.
Task-number: QTBUG-31124
[ChangeLog][QtSql][QMYSQL] Fix sub-second handling
Change-Id: I5718868029bdedab9508213e800d2dcf3da9be9a
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
The ip address should be set before the netmask. The reason for this is
that QNetworkAddressEntry::setNetmask() compares the protocol of the
netmask and the ip, if they don't match the netmask won't be set.
Task-number: QTBUG-33911
Change-Id: Ic344b3653c5dfdc5df912dee16e4dbe069d57d24
Reviewed-by: Peter Hartmann <phartmann@blackberry.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Add a check for the case sensitivity of the file system, so that
unit tests can determine whether names of preference files with
different case should generate an error or not.
* Add check for OS X native file format in rainersSyncBugOnMac().
Task-number: QTBUG-32655
Done-with: Liang Qi <liang.qi@digia.com>
Change-Id: I76821653dd4ebc00e20abdbb5b79c1a80290dece
Reviewed-by: Liang Qi <liang.qi@digia.com>
Most of QPrinter assumes that QPdf is available as the fall back engine
in case either the plugin fails to load or there are no real printers
configured. Make this assumption explicit in the feature configure and
remove the two places where QT_NO_PDF is actually checked.
Change-Id: Ibb1bdf3bafa5809fbc844c84d7127911a1685506
Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com>
from QXcbNativeInterface. The QPlatformScreen is available from
QScreen::handle()
Change-Id: If81daf34c07f4a49c85c43d3755d1a9167626d6d
Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com>
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Currently Qt::WindowFulscreenButtonHint is only
respected on window creation. But flags
can also be adjusted later on.
Further setWindowShadow can be removed from
within createNSWindow, as it operates on a Nil
object in that case. It is however called by
recreateWindow / setWindowFlags subsequently.
Change-Id: I507d6fde5ad2f0ee5b9db322325ede99b70e151e
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
As of CMake 3.0, the output of `cmake --version` now has a second line
showing that it is maintained by Kitware. Change the version parsing to
look only at the first line of output.
Change-Id: I347de4c376e0bde25a43a38d59587d9b63f6b43a
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
desktop opengl and egl are not incompatible with eachother, so there
is no need to disable egl when on desktop opengl
Task-number: QTBUG-34949
Change-Id: I757c38674a480910d1cb23853c255eb993e107ff
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Andrew Knight <andrew.knight@digia.com>
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>