This property is used to automatically hide tab bar if it has only one
tab.
Originally-by: Denis Kovalskiy <denimnumber1@gmail.com>
Change-Id: I6967f760010fa55bad6a5986c29abe7ccf625cf8
Reviewed-by: David Faure <david.faure@kdab.com>
The check has to detect if boost header is present in the system we are
building for.
Change-Id: I700a11df208c8852ba094d8bff387ad21fa309b2
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
This is useful to detect confusions between local paths and URLs.
Change-Id: I1aa72ae10186984812691c8a1a4e843db3c85246
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Q_WS_WIN is never defined, and the qt_win_get_* functions don't exist
anymore. The QPA plugin takes care of doing the Windows-specific handling
for the file dialog.
Change-Id: Icdf9aed7da3db8ed2bd71d60f821869340ec1041
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
To prevent profiling and debugging tools from generating misleading
"errors", call glGetString only for ES and GL < 3.0.
Task-number: QTBUG-35173
Change-Id: I4fe3b048fff4cda948152e2ceeb1347f2b0e4ca5
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Do not try to be clever, this format works always.
Using RGBX8888 for windows without alpha buffer was a bad idea because
it broke renderToTexture widgets (QQuickWidget, QOpenGLWidget) which
failed to properly draw the transparent rect with this format.
Change-Id: I295d2f8c17490b59cc5e6b9d81035360da28ab3d
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
This will simplify future maintenance of qdoc, adding options being
much easier with QCommandLineParser.
As always, this revealed a number of undocumented options:
-log-progress, debug, -autolink-errors.
Compared generated docs with and without the patch, looked fine,
except that order differs (the qt_qhash_seed thing doesn't work)
Based on initial patch by Laszlo Papp.
Change-Id: I3c851135f2fd573d622d2ed456a11cee34e06054
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Martin Smith <martin.smith@digia.com>
Improve the existing docu for Qt::ToolButtonFollowStyle in QToolButton
and show the same text in all other widgets that have toolButtonStyle property
(QToolBar and QMainWindow).
Change-Id: I26ff0ed332f8bd10b542a4111c6ae48a963d5667
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
With "QExplicitlySharedDataPointer::QExplicitlySharedDataPointer( const
QExplicitlySharedDataPointer<X> & other)" implicitly doing an
static_cast<T *>(...) on other.data(), this could lead to dangerous use
of this copy constructor.
Example code:
QExplicitlySharedDataPointer<Base> base(new Base);
QExplicitlySharedDataPointer<Derived> derived(base); // that works!
This patchs disables the use of the static_cast, and adds a new define called
QT_ENABLE_QEXPLICITLYSHAREDDATAPOINTER_STATICCAST to re-enable
that code path.
Note, that the other way-around (assigning 'derived' to 'base') still
works as intended.
Other side note: QtXmlPatterns is relying heavily on the hidden
static_cast "feature". The other default Qt modules compile fine with
the static_cast removed.
[ChangeLog][Important Behavior Changes] QExplicitelySharedDataPointer's
copy constructor which performs a static_cast from "X *" to "T *"
(when constructing a QExplicitlySharedDataPointer<T> from
a QExplicitlySharedDataPointer<X>) doesn't perform a static_cast
from "X *" to "T *" any more. Instead, an implicit cast is now
performed. This change will break compilation of code that
relied on the downcast (i.e. cast towards a more derived type) of the
templated type when copy costructing a QExplicitelySharedDataPointer
object. Please refer to the class documentation for more information
about this issue and a workaround to keep old code compiling.
Change-Id: Id32aba6cda4e6d44728d7bc3a5c0c7a20f19adc6
Reviewed-by: Kevin Funk <kevin.funk@kdab.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Remove the "As of Qt 5.4" to avoid misunderstandings.
Also add the note for the classes that miss it.
Change-Id: Id7f437954bb3ec12c0fc944c18e58e6e977863f1
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
A lot of code in QHash is doing casting to QHashNode while the pointer
may be of type QHashDummyNode. This is a lot of undefined behavior.
Remove QHashDummyNode and specialize QHashNode for QHashDummyValue instead.
QHashDummyValue is the only type for which QTypeInfo::isDummy is true.
Q_DUMMY and QTypeInfo::isDummy are internal API, so is QHashDummyNode, so
we can remove them.
Task-number: QTBUG-40029
Change-Id: I60c2ff0933075b9202bde89a9992746052f75133
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Example with this code:
"template <class Key> struct QHashNode<Key, QHashDummyValue> {"
The previous regexp would take "QHashNode<Key," as some keyword,
and "QHashDummyValue>" as the class name. By forbidding '<' in the
keyword, we avoid such mistake
Change-Id: I5d5077b9e5e764e91899bcaef137d99214ea5d63
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Introduce an enumeration for the rows/columns and
use std::find() to find the matching colors.
Change-Id: If8b7f76d48beab470f6cac0bfdeaf56058237e94
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
Use the findItem()'s optimized binary search impl instead of a generic one.
Also drop the "already shaped item" case since setBoundary() is only
called from itemize(), where the items are not shaped yet.
Change-Id: Ifbecdc41b2e3cb7791a7896fbb0cbea439ca0706
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Fix updating of the drop cursor when the user presses/releases the
shift key while dragging.
Task-number: QTBUG-39822
Change-Id: I1d9d3a80d349f7e405db24f8f7dc372428c34f52
Reviewed-by: David Faure <david.faure@kdab.com>
the windows version is already sane in this regard
Change-Id: Ib9c6fa35ede0e5e98b38b7b97086b9245c79d48f
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
[ChangeLog][configure] The -process/-fully-process/-dont-process options
have been removed due to being unnecessary and counterproductive.
-fully-process has always been broken to a degree under unix (and since
5.0 under windows) - rcc isn't built before running qmake -r, so the
dependencies are unreliable (and there are many warning messages from
qmake).
also, it is a lot slower nowadays, as qmake -r is not parallelized.
-dont-process doesn't make any sense any more - even if you don't need
the Makefile for some obscure reason, the time spent on creating it is
not relevant without the recursion.
this leaves -process as the only option.
Task-number: QTBUG-36955
Change-Id: Ifd3949d9ff773780646c6f65db1629e1c19e53d2
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
the generated projects aren't optimal for building qt anyway (as rcc is
not built yet, dependencies are missing), and the added value isn't all
that great to start with (Qt devs typically use Qt Creator nowadays).
the -no-qmake-deps option was also removed, as it affected only -vcproj.
[ChangeLog][configure] The -vcproj option was removed. Use "qmake -r
-tp vc" _after_ building Qt in case you want to use VS to work on Qt.
Change-Id: I0207d1a89a83b70991a63a7d121a9de4cb685ca5
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Add function returning the screen for a new geometry for geometry
change events. This ensures that the checking is done in platform
screen coordinates (which might differ from QScreen coordinates
due to high-DPI changes) and also that no screen changes are
emitted for child windows.
Change-Id: I406750f59f006f834c386d09c0c85a804014924a
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
This makes it possible to retrieve the GLXFBConfig used by Qt to
create the GLXContext. QtWebEngine on desktop needs this so that
Chromium can use the same config as Qt to eliminate BadMatch errors.
Change-Id: If18c0937b5af3e457ddbfda035e5d652230211c6
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
This allows QtWebEngine to use the class API on top of the
Chromium network stack.
Change-Id: If595e30cfa6ecdc62cba8453d8f57ddccc1793d9
Reviewed-by: Peter Hartmann <phartmann@blackberry.com>
Value interfaces on OS X and iOS can be strings, so can the value
property of MSAA. Before we'd always only send doubles, instead
change it to use strings as well.
Change-Id: I1b4410c68238ba7a69a5507d87c251f2ac61c568
Reviewed-by: Caroline Chao <caroline.chao@digia.com>
This only ocurred in -opengl dynamic builds on Windows, when using
ANGLE. The !QT_OPENGL_ES_2 code path did not correctly check for ES.
We also need to avoid using REPEAT, just to be safe on ES2 implementations
(embedded devices typically) that will not do repeat on non-power-of-two textures.
Task-number: QTBUG-39638
Change-Id: I2eeab6627c17255373193c0a0fec8923f711e28c
Reviewed-by: Andrew Knight <andrew.knight@digia.com>
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
This is trickier than the GLX and EGL implementations due to the
way pixel formats, windows and contexts work. Apart from some
restrictions, it should be fully functional nonetheless.
Add also some proper documentation.
Change-Id: Ia6e3eb1ab2701e439b8621b9092c2b0934ff2151
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
The grabWindow API basically should return a screenshot at the window
location. On QNX only the SCREEN_DISPLAY_MANAGER_CONTEXT can read from
the screen which will require root privileges.
At least this will fix some QWidget auto tests that rely on this API.
Change-Id: I350233173d3aecd376f48af9f650606a5cce6205
Reviewed-by: Fabian Bumberger <fbumberger@rim.com>
QMetaType::create can call user code and we should not keep mutex held as
this may cause dead lock.
Make sure the tst_qobjectrace actually emit some signal so the test check
there is no race if the receiver object is destroyed while
the mutex is unlocked.
Task-number: QTBUG-39990
Change-Id: I56ca1ae7a11cd7b33c1a68727370972862e11c2f
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
It isn't a particularly complex operation, but why waste CPU cycles?
This is the kind of function that should be declared pure/const.
Change-Id: I13f03ef0f87607f7649c66beeb37614a31ef2a10
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
MSVC 2013 implements the behavior mandated by C++11 that removes the
ability to downconvert a string literal to a modifiable char*, but it's
not enabled by default. This option turns it on.
It's only enabled for release builds because the compiler page has a note
saying the Standard Library has bugs that prevent it from working in
debug mode. See http://msdn.microsoft.com/en-us/library/dn449508.aspx
Visual Studio "14" has this fixed.
[ChangeLog][Compiler Specific Changes] Release builds with Microsoft
Visual Studio 2013 now enable the standard-conforming C and C++ strict
string behavior. This option will be enabled in all builds with future
Visual Studio versions. Non-conforming code should be fixed for maximum
portability and correctness. See
http://msdn.microsoft.com/en-us/library/dn449508.aspx for more
information.
Change-Id: If5ba6cc8456209b268e047d1010710fe332b8312
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Architectures missing were arm64, mips64, power64, s390x and sparcv9
(sparc64, but we're using the name that matches the Q_PROCESSOR_xxx
define, which in turn matches Solaris's psrinfo output).
Change-Id: I50b8152b3c42589b98db157b9efeae2be6a90414
Reviewed-by: Kai Koehne <kai.koehne@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The GCC documentation says that a const function is not allowed to read
global memory. This needs to be clarified: it's not allowed to read RW
global memory. It's fine to read read-only memory, as that is equivalent
to just pure code.
The QChar static out-of-line functions only lookup a property of the
given Unicode character and always return the same value.
The only exception is the decomposition() function, which returns a
QString and is therefore not allowed to be marked const.
Change-Id: Id36b2f84a1b8ff9db5acf1d4e59e8b3811068cff
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
This macro is no longer used. It was introduced probably by mistake,
due to MSVC not following the strict string requirement of the C and
C++ standards by default (you can assign a string literal to a
non-const char*).
Change-Id: I4b221dd435191b0eea689dbed35915cf3206648b
Reviewed-by: Martin Smith <martin.smith@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Like for integers, this is activated only on QLocales other than C.
[ChangeLog][QtCore][QTextStream] QTextStream now uses group separators
when writing floating-point numbers when the locale is not the C locale.
The old behavior can be restored by setting QLocale::OmitGroupSeparator
on the locale.
Change-Id: Ie451b91017746c3a9b11b6211b2ddd09cd295cd2
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
Currently QOpenGLTextureCache::bindTexture always convert any uploaded
image to RGBA8888 before uploading. This is quite inefficient when
OpenGL natively supports uploading formats in the original format.
This patch adds support for uploading a few native QImage formats. This
also get the performance of QOpenGLTextureCache::bindTexture on par with
QGLContext::bindTexture.
The texture brush used by QOpenGLPaintEngine is also converted to QImage,
since bindTexture will convert it to QImage anyway, and going over QPixmap
may cause an unnecessary conversion.
[ChangeLog][QtGui][QOpenGLTextureCache] Support uploading common QImage
formats directly to OpenGL when supported.
Change-Id: I828a763126441a98e4547c32ef52dddf7c129a32
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
This ports the Qt4 method of supporting the system tray
window visual that has an alpha channel as well as ones
that do not. We detect whether or not we have a 32-bit
format and either use a Qt::transparent background, or
call xcb_clear_region before painting the icon.
[ChangeLog][Linux/XCB] Fix transparency of tray icons in cases where
there is no alpha channel or system tray visual.
Task-number: QTBUG-35832
Change-Id: I43d500c39846d2916dd39f8c47c8d85e59b49cae
Reviewed-by: Uli Schlachter <psychon@znc.in>
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@digia.com>
QWindowsDrag::defaultCursor() used xpm-based cursors which are aliased,
dark and not available in different sizes.
This patch uses the new cursors from QWindowsCursor::customCursor for
the drag cursors and gets the ignoreDragCursor from the system. If
fetching the ignoreDragCursor cursor fails, we still fall back to the
ignoreDragCursor.xpm.
The other xpms were moved to QWindowsDrag::defaultCursor() for the WinCE
or non-png case.
Change-Id: If216ffc8c9cc134529b7addd0121857d41805eac
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Adds basic support for 10-bit per color channel formats to QImage
and the XCB plugin. This will make it possible to paint to and from
these formats, but only at 8-bit per color channel accuracy.
This also fixes Qt5 applications on X11 with native 30bit depth.
[ChangeLog][QtGui][QImage] Added support for 10-bit per color channel image formats.
Task-number: QTBUG-25998
Change-Id: I93ccd3c74bfbb0bd94b352476e5fe58a94119e1f
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
url is set in qtbase/doc/global which is inherited by the
Qt 5 module qdocconf files.
Change-Id: Ieffa174f598f4a3b8ce8be9bfae7ca9b6981f12b
Reviewed-by: Martin Smith <martin.smith@digia.com>