commit 219b0d217 fixed forwarding of stdio to a console. unfortunately,
it also forced the creation of a console in the first place if there was
none, which is not part of the contract.
instead, give the child process a window (== console) only we we already
have one. this can be done irrespective of our channel mode, which has
the nice side effect that an explicit redirection to a console would now
also work.
Change-Id: Id25cab5da1ac1cc8ce452127ff95bac8d0a0fea8
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@digia.com>
The declaration for addToQmlModule() in class Tree
is removed.
Task-number: QTBUG-33350
Change-Id: I2278a67cd6daf0e7723b4bf6d33ff9ed33cf9266
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
it contains #ifdefs for that, no need to disable it completely.
Change-Id: I4a7d03e09fefded966e2c3fec58a470b4f1d3300
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
The destructor of the ConverterFunctor calls unregisterConverter. If
the instance is static (as it is in qmetatype.h), then this method
can be called after the QGlobalStatic has already been destroyed.
Change-Id: I33b70734cbe09dfa888e887280c349e43ad1b855
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Don't use ## concatenation to create an identifier. That won't
work for types in namespaces:
Q_DECLARE_SMART_POINTER_METATYPE(QtPrivate::FutureSmartPointer)
Change-Id: I876ea93d817724005efc28413f09c01623c2a7a1
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
forwardedChannelsOutput() actually tests forwarding. also having the
older test only eats CPU cycles.
rename the new test to the old name for clarity.
Change-Id: I16a326c8692bb594d7df7897bc53d31b23c66d90
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
close stdin and let the process finish right away instead of first
waiting for a reaction (which is not supposed to come) and then
finishing.
Change-Id: Ifcf200eead5ed95217843e105f9d2dbb5398d646
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
ForwardedChannels implies that both stdoutReader and stderrReader are null.
Change-Id: I9d5f02d3a1eac62316a6016b90c612d716ecaafc
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
The excessive padding has serious performance implications throughout
Qt and need to go. The original reason for having them was to fix
issues with GL text rendering and issues with unspecified OpenType
fonts. There have been several other changes to the glyph cache
since then and neither of the issues can be reproduced today.
Change-Id: I6de67598a079c296daf48be07cc5c2d67768c384
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
We're currently adding a lot of transparent pixels to the cache,
wasting both memory and cpu cycles while drawing. AlphaMapBoundingBox
was introduced to return the exact same bounds as the alphaMapForGlyph
function so we should only rely on this instead of adding arbitrary
padding and margins all over the place.
Windows still has an arbitrary +4 in the its drawGDIGlyph() which
means batching will not work on windows, but at least now
other platforms do not need to suffer.
Change-Id: I714903fa195004400c09c3bf6570e46179775f09
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
Since the function locatePlugin is unused when
building Qt statically, the build fails on
iOS. This patch will ensure that we only define it
for shared builds.
Change-Id: Idf3c3246d3cac94a3c001cc261f326e9a396aa31
Reviewed-by: David Faure <david.faure@kdab.com>
§24.4.1 [iterator.traits] of N3337 makes it *mandatory* to define the
various types
std::iterator_traits<Iterator>::{value,pointer,...}
for any given iterator.
§24.4.1.2 makes it enough to define them within our iterator class.
Change-Id: I1305c8392d224889b09395e30ecc77b194020a15
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
There was a error: narrowing conversion of 'Myns::XEMBED_VERSION'
from 'unsigned int' to 'long int' inside { } [-Werror=narrowing]
Change-Id: I1e155870b0b632bfe5ffa9deac69c4f151f5aa23
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Clang doesn't like forward-declared inline functions.
qmetatype.h:70:29: error: inline function
'qMetaTypeId<QtMetaTypePrivate::QPairVariantInterfaceImpl>' is not defined [-Werror,-Wundefined-inline]
inline Q_DECL_CONSTEXPR int qMetaTypeId();
^
qmetatype.h:1463:30: note: used here
const int toId = qMetaTypeId<QtMetaTypePrivate::QPairVariantInterfaceImpl>();
^
Change-Id: I1454af5cce56512f0b3d63cfaf51a536207fc511
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
This reverts commit 5b9006bbdb.
Also revert "Doc: Enable documentation for QScopedPointer's rvalue ref functions"
This reverts commit 5f8416ec65.
Adding a move contructor to QScopedPointer makes no sense, because moving
means 'escaping the scope', which breaks the fundamental point of
QScopedPointer.
Change-Id: I4ac1b108bf199af6e436fa1629aa2d3b93c27724
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
To ease interruption of long running tasks, a new method
QThread::setInterruptionRequested() can be called.
The task can check QThread::isInterruptionRequested()
and act upon it by stopping itself.
These methods are designed to replace the use of a global variable
and other hacky ways to stop a task running in another thread.
Change-Id: I17622dd60d2262078210e7e4294ad6c53a6dc179
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
__assume(0) is not strong enough in some cases.
Change-Id: Ifac42a58af891d636e3e0b2fa476da787bd0d1ce
Reviewed-by: Alan Alpert (Personal) <416365416c@gmail.com>
The WaitForMoreEvents flag only guarantees that we will process _some_
events -- either if they are in the event queue already, or by sleeping
and then waking up to process an event. This event might be a system
event, not the timer firing, so a single call to processEvents() is
not enough to guarantee that the timer has fired. Instead we do a
Q_COMPARE with a timeout, where we continiously process events until
we see that the timer fired.
Change-Id: I5dc04377f04190f3505be22e877af73d11b7547d
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
KWin supports the XSync extension. Since the check got added the XSync
implementation in KWin got reworked (release KDE SC 4.8).
Change-Id: I15c37fe4dd5501ca107b90a07ae8d70295ffaeda
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
Required for QQuickText & friends to implement image resource handling
in a clean way - to get rid of QQuickTextDocumentWithImageResources and
eventually make QQuickTextEdit's document interchangeable.
Change-Id: I12305b68065a5990997ca4a47821fd29e0e17476
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
-The qdb->findModule() call creates a module node even if the module
name is empty. This creates the extra module.html pages in some
doc projects.
-The fix is to create a condition for calling findModule()
Task-number: QTBUG-32990
Change-Id: I6c1d1c53f3814ea483df2cd05b8d39dc14b0fb7b
Reviewed-by: Martin Smith <martin.smith@digia.com>
-Qt GUI and Qt Core are included by default
-Added entry about disabling "gui" in the .pro file
-Information placed in snippet files
Change-Id: I1c70dcac9ca2d443e9f658e2a27727d24a25cae1
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Both overwrite QAbstractItemModel's parent taking a QModelIndex which
hides the QObject::parent() method. This must be explicitly forwarded
like e.g. QAbstractItemModel is doing.
Change-Id: I6149ae365cd8467248f4ca79a3cb898e62068b10
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Those should be in window coordinates (or rather, its content view)
not view coordinates.
Task-number: QTBUG-32826
Change-Id: I52dddeccf17b359163ad477ce4299b934633b4fa
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
Otherwise the view will miss its own frame change notifications.
And we must unregister from all the notifications during dealloc.
This would also reveal a bug where we would expose an NSView before
its super view is visible, leading to those "invalid drawable" warnings
when using QQuickViews. Therefore, we add this extra check in
QCocoaWindow::exposeWindow().
Task-number: QTBUG-32826
Change-Id: I69018cb6f199b242768d114b2aa34c7f2d243196
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
Native widgets, which have a NSView but not a
NSWindow, must be created in the hidden state to
prevent Cocoa from selecting them for event delivery.
Change-Id: I741e52729047ad4e03959f2244abe5b14b5df46b
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
Layout items with a Preferred size policy would be treated as fixed
size if they were in the same layout as an Expanding item (or one with
a stretch factor).
This occurred e.g. if a layout was configured similar to this:
1. One item with ExpandFlag/stretch but with a maximumSize set,
e.g. (100x100).
2. Another item with 'just' GrowFlag, and a maximum size bigger than
its size hint.
If the above layout was resized to e.g. (200x50) it would cause the
expanding item to correctly get the size (100x50), but the 'growing'
item would not stretch beyond its size hint.
Instead, it would distribute space around both items, behaving as if
the 'growing' item was fixed'.
The expected behavior is to continue to grow the 'growing' item after
the expanding item has reached its size limit.
Task-number: QTBUG-33104
Change-Id: Ie410653d905f7ca4d702528dafb269f30a0e4f61
Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
Currently there is no API to extract the meta data
from static plugins. This is needed in e.g QtDeclarative
for loading static module plugins.
This patch moves the 'staticPlugins' function from
QLibraryPrivate into QPluginLoader, and makes it public.
As such, we now also export QStaticPlugin.
Since an application developer cannot do much with raw
metadata, we add a new function
QStaticPlugin::metaData() that returns the QJsonObject
for the plugin. The old metaData function is
renamed 'rawMetaData'.
Change-Id: Idb0bf9ad8ebb13340565512e1998b26e762a357e
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>