Analogous to QWidget::setAttribute(), introduce an API to easily
enable/disable a single window flag without having to resort to
w.setFlags(w.flags() | Qt::NewFlag).
Change-Id: Ib0f7254a34c8d884cdec181c41b99e5ef035d954
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Sérgio Martins <sergio.martins@kdab.com>
clangqdoc must parse the declarations for QSctpServer and
QSctpSocket, not just for Q_OS_WIN, so Q_CLANG_QDOC must be
tested as well.
Change-Id: I70f5a0542b654826d9d36fe68930752e68caf6b6
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
clangqdoc must parse the declaration for QWinEventNotifier
for all platforms, not just for Q_OS_WIN, so Q_CLANG_QDOC
must be tested as well.
Plus the qdoc comment for an invisible static function is
converted to a non-qdoc comment in qvariant.cpp
Change-Id: Ic41731decca55b3be837f9c5f832310513773e60
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
Giving the URL of unicode.org isn't much use; the standard is enormous
and the reader shall have trouble finding the specific table that
enumerates the direction types. Found a more specific URL (that looks
like it should be stable) for this one link.
Change-Id: I8abcedf530baf692d7e0c7f146f3066df223951f
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Instead of relying on AdjustWindowRectEx() and dirty-handling,
capture the rectangles before and after the processing of
WM_NCCALCSIZE and calculate the frame from that. This allows
for changing window frames by handling WM_NCCALCSIZE and
monitor-dependent window frames when using High DPI scaling.
Task-number: QTBUG-53255
Task-number: QTBUG-40578
Task-number: QTBUG-56591
Change-Id: If8364a5440a6324ea5d470bf5b74e68942285abe
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
This commit re-enables support for OpenVG in Qt, but not in the
same way as in Qt 4.8. The first part is about adding a test
and using the new configure system to enable OpenVG.
There is still support code in Qt for setting up EGL to provide a
surface and context for rendering with the OpenVG API, this commit
enables a path to do so.
Normally to get access to an EGLContext from a QWindow you do so via
QOpenGLContext, but in setups without OpenGL but with EGL and OpenVG
this doesn't make sense (there would be no QOpenGLContext). So the
intended way is to use a QWindow to get an EGLSurface, then create
an EGLContext directly (without going through QPA).
Change-Id: I0f75aadbaa3cd006deb7e6fd12cfbb574870fba4
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
It is possible to have support for EGL without having support for OpenGL
for example with OpenVG. Unfortanately many features of EGLFS require
OpenGL (Cursor, MultiWindow, QEGLPlatformContext, QBackingStore), so the
plugins become pretty useless on their own. This is necessary if you
still want to use Qt as a method to provide an EGL surface to render to
via QWindow. This is the method by which Qt Quick uses OpenVG to render
its content when available.
Change-Id: I34973b21bf1932865950ce6a78b71b3a29360d65
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
No need for the templates to just forward. Reduces the call stack during
event delivery.
Change-Id: I93f7eb5fa331cc7e86e5bdb5985bcad1eb8b2a4a
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
No change to implementation.
Change-Id: I2a3e02ea52012f8424ef05b7b6e84897182d133e
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
This will be used in QtQuick to avoid costly string manipulation (which in turn
involves memory allocations).
Change-Id: I51a67a4cd97cc576f399483c9c0c13da1e1c6e72
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
When a menu item's enabled state changes after
-[QCocoaMenuDelegate menuWillOpen:] is invoked, i.e.,
during or after QMenu::aboutToShow() is emitted, that
state change may not be taken into account. This is
because the automatic menu validation, upon which Qt
relies, is not made aware of any such change.
By calling -[NSMenu update] when syncing the QPA menu
item, we induce Cocoa to invoke -[QCocoaMenuDelegate
validateMenuItem:] and ensure that previously synced
items, whose state may have changed, will be properly
updated. This, however, has a small side effect, namely
that menu-holding items will also go through the automatic
menu enabling path and may appear disabled since, until
now, they were not properly configured. In order to solve
this, we set the action on those items as well, and make
sure that both of QCocoaMenuDelegate's relevant methods,
validateMenuItem: and itemFired:, properly process
menu-holding items.
Menurama manual test updated accordingly.
Change-Id: I62f955538b8be09b8494ea0ce87fca7910148d38
Task-number: QTBUG-56850
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
That loop could never have worked properly.
Identified by analyze compile switch.
Change-Id: I5e987dc9f5c57d3ffbcf054b7b417b506c02e7e1
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
this is complementary to configure's makeSpec library source type.
this should be sufficient to make QMAKE_USE += {egl,opengl,opengl_es2}
actually work, obsoleting the need for opengl.prf and egl.prf (and the
currently dysfunct openvg.prf).
Change-Id: I2f7595ac89afa087ea7f0f25060e8e47e6148be9
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
The documentation for the qtmain license is right now pretty hidden.
The library is added by qmake independent of the Qt module that are
linked to, but it seems safe to assume people at least link against
Qt Core.
Change-Id: Id474990edde45feab6727bada2bc6a28946216cd
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
Usage of custom OpenGL functions is allowed in OpenGL ES 2. It allows
custom platform plugins to define their OpenGL functions.
Change-Id: I611b6987dc35deb4cf147684456f25b29f136560
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
Pretty useful when working on Qt itself or just having to deploy
a proper hand-crafted latest greatest to the Yocto-built image.
[ChangeLog][Platform Specific Changes] Added support for
cross-compilation targeting Renesas R-Car H2 (Lager) systems.
Change-Id: Ie359956046b0752a6053f85b81d32550b91ce453
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
The "rect cache" has been #if 0'd out for ever. Do not waste time on
maintaining a vector for nothing.
Change the screen image to be a normal member variable. There is no need
for extra heap allocations.
Task-number: QTBUG-56306
Change-Id: Ib88aa57896bf1a616b8cedbec7490f0a4bf0ba5f
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
The generic DRM code, not involving any GBM or EGLDevice stuff, can
now be reused in components outside eglfs, for example linuxfb in
order to get support for DRM dumb buffers.
Task-number: QTBUG-56306
Change-Id: If7dffdb2415489dbc6470782fa76efcaeccf01c7
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
Since virtually all the logic is shared between QNSColorPanelDelegate
and QNSFontPanelDelegate, we extract the added buttons and
layouting logic and move it into its own class. This requires
the two afore mentioned Objective C classes to satisfy the
QNSPanelDelegate protocol.
Change-Id: Ie26e758f5db71920896d930a4f3644b51a1ce3fa
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
now the callbacks don't need to re-export the designated file contents,
which improves the abstraction and removes some boilerplate.
Change-Id: Ifa50313155fc96762025e2610b810ebb71daa373
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
swap the branches for (not) reading from qt.conf, and use a state
variable instead of an 'else' for mutual exclusion. this is somewhat
more self-documenting, and allows for a saner handling of the mkspec
fallbacks (which really should have been in a separate [QMake] section
along with Host* and Sysroot, but changing that now is way too much
hassle downstream).
Change-Id: I80a73294022fd1e8d84fe501b737c4fc7758662f
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
so far, qmake.exe was built in qmake/ and then copied to bin/, with
possible errors in the second step ignored. this made no sense.
this unifies the nmake makefile with the unix one; compare 46e51ce1d.
Change-Id: Ieb9c7cd46f0be0501d17e297808ac1cdad1b3c4a
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
when the file's effects are discarded, the mention of the file should be
as well.
Change-Id: I894b7e2b887dd34d18533b197bfa9d0d84d647e7
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
the normal mode forces the prompt into a pattern which may be
undesirable.
Change-Id: I01689c7a6573415801862348b32bafc6a609ed4a
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
that is, adjust path separators and don't quote them. we already did
that to some degree, but totally inconsistently, so it just didn't work
for any targets with "fancy" file names.
note that we don't bother doing that for recursive targets, as these are
assumed to be identifiers.
Change-Id: Ic75f003b71abc6fed03a4121b903ad5ee8253ed2
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
if the externally provided qmake had a different on-device install tree
layout, things would go wrong. of course, that's a rather unlikely case,
so nobody noticed ...
Change-Id: I59f9976a769ccb6099b7237ef42555f0549615aa
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
there are plenty new functions, let's do this symbolic act.
Change-Id: Iaeb88afa5e33cacd81dc0ea26e380a16af06a739
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
otherwise it's sometimes quite hard to tell it apart from configure's
own messages.
Change-Id: I2f4908344367a9a3ce38e032bf76486fc4552ffd
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
this got broken in 2ad4d75754.
however, the new configure system operates from the top-level build dir
anyway, so there is no point in messing with the cache as a reference
point to start with - just use OUT_PWD.
Task-number: QTBUG-57120
Change-Id: I69629bf497931574bff8452939170abb1776ab60
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
60985aa42 converted the QT_CONFIG use, not taking into account that the
feature isn't actually known to the configure system - it's coming
directly from the makespec. so revert that hunk (until we have a better
integration between makespecs and configure).
Task-number: QTBUG-57039
Change-Id: Iaf57b5f5339250055f1c378e091da3ab3fcd4292
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
Cocoa is known for not sending key up events for key equivalents,
regardless of whether it's an actual recognized key equivalent.
Notice that only Cmd-based shortcuts suffer from this feature.
We decide to force fate and forward the key event to the key
(focus) window. However, non-Qt windows will not (and should not)
get any special treatment, only QWindow-owned NSWindows. Since we
know that Cocoa will not send it to the key window, we can safely
forward it and ensure no duplicated key events.
Change-Id: I0449f7f5195a327eef6d792bd441fc3fd0882db1
Task-number: QTBUG-36839
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
We can not improve the result from JSON parsing without changing API,
so instead recalculate the line and column based on input and offset.
Change-Id: I54149233f71023aa5d30deff854d6f3406c5c48c
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>