While compiling with clang, everything has to be valid code. So the types
have to be correct
Change-Id: I73f5e493a19e27b1a459f92ea37480f3329a1c0a
Reviewed-by: Martin Smith <martin.smith@theqtcompany.com>
One day we might add that information to the documentation itself.
But it is important to declare them as constexpr otherwise this causes
error while parsing code that wants it to be constexpr when generating the
documentation of other constexpr function
Change-Id: I28120fea90b29fe1e87af0d8cded0f2430e35443
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Martin Smith <martin.smith@theqtcompany.com>
In functions such as QObject::connect and similar which are using pointer
to member function or functor, we have a different declaration for qdoc
because we don't want to show the QEnableIf and other type traits in the
doc.
However, The code still needs to be valid, as we will use clang to parse
the documentation.
Fix it by making 'PointerToMemberFunction' and 'Functor' template
parameters (which they actually are).
Change-Id: Ie2648407bae21ba6d1677f6de2d6f597486b5c98
Reviewed-by: Edward Welbourne <edward.welbourne@theqtcompany.com>
Reviewed-by: Martin Smith <martin.smith@theqtcompany.com>
All symbols are available through eglGetProcAddress().
Change-Id: I636f9555f578dc5cf517995a4fcb01b0cd7f7698
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
Qt crashes when opening a native file dialog. Disable this feature to
fix this issue.
Change-Id: I1ee17d858238c2531964a63ddbe3e11c5a85483c
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Determine offset point to similar to QTextEdit::inputMethodQuery()
and add an autotest.
Task-number: QTBUG-51923
Change-Id: I8232eb348063e2cd95d0632fe74a6eb30c897eda
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Update files using old header.LGPL3 to header.LGPL
Update files using old FDL template to use new one
Update files using old BSD template to use new one
Change-Id: I36a78272516f9953d02956522f285b40adfc8915
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
Subjects each *.png file that matched grep -law "sRGB" to:
pngcrush -ow -brute -rem allb -reduce
(Two needed -force but did get smaller.)
Change-Id: Ia030f0bc1d3617ba716bcc26677ff919ef58423c
Reviewed-by: Topi Reiniö <topi.reinio@theqtcompany.com>
Moving tabs of a QTabBar goes through a temporary QWidget that
captures a "screenshot" of the tab, and then gets moved around.
Unfortunately, that screenshot was not using the devicePixelRatio,
resulting in blurry text and icons. For some reason, setting
the DPR on the pixmap isn't enough -- that causes it to be
drawn twice as big (bug somewhere in Qt styles?).
Work around that by not using the palette, but a simple widget
which draws the pixmap (which also leads to somehow clean code).
Change-Id: Id12f9251625693d108031488ddfab86277128705
Task-number: QTBUG-50898
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Its currently not possible to style the arrows with QCommonStyle because
drawPrimitive from QCommonStyle is called instead from the proxy.
Change-Id: I910b13df110601cb18578bc16edfa5ddaa17bbd2
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
The previous implementation overwrote multiple 'time' parts in the
qSetMessagePattern with the last setting in the pattern line.
%{time}%{time process}%{time boot} ended up to be output as if
%{time boot}%{time boot}%{time boot} was set.
This fix keeps the arguments of each individual 'time' part.
The same holds for multiple 'backtrace' parts. The previouse
implementation overwrote multiple 'backtrace' arguments with the
arguments of the last occurrence.
This fix keeps the individual arguments for the 'process' parts.
The individual arguments are applied in qFormatLogMessage.
A new test to verify the individual 'time' arguments application
is added, too.
Task-number: QTBUG-51944
Change-Id: Ib757614a482c5f31ed0a61b550daa2eea4b907b4
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Match correct number of digits and entire string, amending
change 4347e81161.
Task-number: QTBUG-33962
Task-number: QTBUG-51373
Change-Id: I56de00bd5ffb3a3a700efbb20970154faf86f923
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
QWindowsPipeWriter doesn't write in a separate thread
anymore.
Change-Id: Id978bfdfa2531be91cce94476ab9b0dff237bd61
Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
Show and Hide events were not propagated before this change.
Add Timer, DynamicPropertyChange, ChildAdded, and ChildRemoved,
because they are supposed to be delivered to one QObject.
Also don't propagate these events if WA_DontShowOnScreen is set.
Change-Id: I134bf3909d46141e4d3e39f41983f493a4f35478
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Drop addSub() test. It executes exactly the union of fetchAndAdd()
and fetchAndSub(), which have already had their UBs fixed.
No need to do fixes in duplicated code.
Change-Id: Ib72caab0310fce3ff9a40c261d8a38518f91ecaf
Reviewed-by: David Faure <david.faure@kdab.com>
Commit 0307c008 removed the buffering of data-to-be-written from
QWindowsPipeWriter, because it was assumed that users of this class
(QProcess and QLocalSocket) already buffer data internally.
This assumption was wrong for QLocalSocket. The following sequence
localSocket->write(someData);
localSocket->write(someMoreData);
would not write anything on the second write.
Add a write buffer to the Windows implementation of QLocalSocket.
Task-number: QTBUG-52073
Change-Id: I6d0f03a722ec48138cbde3e2f69aae7dafe790d3
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Add an example showing the types in QMimeDatabase in
a QTreeView with detailed information on click.
The example has menu options to detect a file type
and search by name.
Change-Id: If6f1a6661edd100a54460a49562a8a8667245ddb
Reviewed-by: David Faure <david.faure@kdab.com>
This makes minimal a bit more useful for apps needing to access
QFonts from non-UI environments.
Change-Id: Idc5ca13f0c385ab9b4258e11fea7ec886515eea4
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Louai Al-Khanji <louai.al-khanji@theqtcompany.com>
In user code it is not uncommon to have QActions as proper members
in structures. Being forced to pass a null parent in their
constructors is uncomfortable.
Change-Id: I10d0b0b39d7f8c2b158af1136367b44f1150d4df
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
This brings the feature name in line with the name
of the define.
Change-Id: Ib56c9c25ce83c396e5085d69efd3fe953c1aadd0
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
The platform header defines geteuid(), which is necessary for the SQLite
library. The common platform header is also modified to handle being
included from C, and resolves a typo on the way.
Change-Id: I8ace8a11ceac0f541b9c9b0d8112609579224884
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The most visible problem is that changing selection model didn't update()
the view, resulting in the old selection/current item still being drawn.
In general trigger the handlers for when the selection/current item
changes.
Change-Id: Ib3b2ad70412e6a21a182d4c173e617710bcc630d
Task-number: QTBUG-50535
Reviewed-by: Stephen Kelly <ske@ableton.com>
Found by UBSan:
src/gui/text/qrawfont.cpp:647:55: runtime error: load of misaligned address 0x000001eeed26 for type 'quint32', which requires 4 byte alignment
src/gui/text/qrawfont.cpp:648:50: runtime error: load of misaligned address 0x000001eeed02 for type 'quint32', which requires 4 byte alignment
Fix by using the qFromBigEndian() overload that can read from
unaligned memory.
While touching the code, also disentangle the two loops so that
operations are now performed in memory order instead of inter-
leaved, use less magic numbers, and avoid a QByteArray detach.
Change-Id: I26fa39726f6fa2e957b60863fa160280cf1dc9ac
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
While the implementation of the QByteArray::operatorX(const QString &s2)
for X \in { ==, !=, <, <=, >, >=} was already inavailable when
QT_RESTRICTED_CAST_FROM_ASCII was defined, the declaration was
still visible, leading effectively to a linking error.
This change hides the declaration, too, creating a compiler error as
intended, and as present with the QString::operatorX(const QByteArray &s2)
functions.
Change-Id: Ifdb0b85b7423b3b9c69212639b1512b0808a7983
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
...instead of overwriting when building qmake for windows.
Change-Id: I89eb33439b03a0ad33d006d12c9896c87d271c4f
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Using Visual Studio a user very seldom wants to disable the automatic
invocation of windeployqt. Hence switch from opt-in behavior to opt-out.
This also fixes first user experience to invoke qmake –tp vc and then
hit run on examples.
[ChangeLog][Platform Specific Changes][qmake] qmake-generated Visual
Studio projects now automatically invoke windeployqt by default.
Task-number: QTBUG-52008
Change-Id: Iee1607269c38c7f6c726f554978ac05477bebe5e
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Set input method attribute to be aligned with read-only
value in QTextBrowser initialization
Task-number: QTBUG-52071
Change-Id: If0e64bf09e2a2d505ed66fcbfb8cd12ae39844d3
Reviewed-by: Andy Shaw <andy.shaw@theqtcompany.com>
Clang expects valid expressions. (Code that actually compiles.)
Now this is a valid expression ('or' is a C++ keyword meaning '||').
And it still has the meaning we want to convey in the documentation.
Change-Id: If217e9e448eabe2a64df81cf5cd25f8c17e22109
Reviewed-by: Edward Welbourne <edward.welbourne@theqtcompany.com>
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@theqtcompany.com>
Reviewed-by: Martin Smith <martin.smith@theqtcompany.com>
QListSpecialMethod is an internal class. Everything needs to be hidden
from Q_QDOC otherwise while parsing with clang, we get errors.
Importantly, hides it while inheriting from QList so it does not
appear in the documentation
Change-Id: If2ac158f35d6a367aa033cfc7e6a054c912359b9
Reviewed-by: Martin Smith <martin.smith@theqtcompany.com>
This patch adds a new option, QCommandLineOption::ShortOptionStyle, which helps
applications (such as compilers, so moc and now qdoc) which need to mix long-style
and short flags.
[ChangeLog][QtCore][QCommandLineOption] Added flags() and setFlags() methods.
Added ShortOptionStyle and HiddenFromHelp flags.
Change-Id: I944ce56aff2b28ecd6bb9d2d23c4e726e9d06647
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Some Qt users include non-system OpenGL headers, resulting
in a possible mismatched redefinition of GLhandleARB.
Ideally, we'd like to skip the whole glext.h inlined portion
and rely on qopenglext.h. However, some issues remain such
as GLDEBUGPROC not being defined on OS X.
Change-Id: Ie551cf0be309234b22cd615cc3703980f48298b9
Task-number: QTBUG-46149
Reviewed-by: Jake Petroules <jake.petroules@theqtcompany.com>
The spawn code was only used to make QProcess work on QNX 6.5.0. Fork
works on QNX 6.6.0. The QNX spawn implementation has a flaw that causes
a deadlock in certain situations. When a working directory is specified
for the process, the QNX spawn implementation stops all threads except
the one doing the spawn so that it can temporarily change the process'
working directory. This can lead to a deadlock if the thread does
anything that conficts with something being done in a stopped thread.
QNX 6.5.0 is no longer supported in Qt 5.6.0 so we can just switch QNX
to the fork implementation and get rid of the spawn implementation.
Made a QNX specific adjustment to the hardExit test. There's a bug
in the OS that the test can run into because it does something that
normal applications wouldn't.
Task-number: QTBUG-47250
Change-Id: Ib32567d2c15ce651815858000035ac5aa6f35224
Reviewed-by: Dan Cape <dcape@qnx.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
There is only one place in Qt Widgets where they are still present -
QProgressDialogPrivate::layout().
Change-Id: I53742dd6d5a61e468a90c6a487cf2a67f89b244c
Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
Remove parameter from QWidgetPrivate::createWinId(), add a warning and fixme
comments. Update the documentation to point the users to QWindow::fromWinId()
and QWidget::createWindowContainer().
Task-number: QTBUG-33079
Task-number: QTBUG-51853
Change-Id: I03ae922b31bb46a411889cc0260ea14a4d933492
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
This fix repairs the mechanism to deploy Qt dlls as well as C++ runtime
to a wince target in Visual Studio.
Do this by adding a deploy section in the Visual Studio solution and
adding the C++ runtime from the mkspec to the files deployed to the target.
Deploy target path is set to what the wizard of Visual Studio defaults to.
Before, the c++ runtime was only deployed for executables which were built
as part of Qt.
Task-number: QTBUG-50924
Change-Id: I478010dc16e35c68578281895aa3ae14b5c96bb4
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@theqtcompany.com>