Conflicts:
src/corelib/tools/qvarlengtharray.qdoc
src/corelib/tools/qvector.qdoc
Resolved documentation changes in favor of 017569f702,
which keeps the move overloads along with its const-ref sibling.
Change-Id: I0835b0b3211a418e5e50defc4cf315f0964fab79
Some compilers will assume src and buffer are different and only
vectorize the unaliased case and take a slow path when they are equal.
In our case they are as often equal, so we need to manually unalias the
variables to make sure both cases are fully optimized.
Change-Id: I6ec86171dd179844facdf45376253c55980d9e36
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
All of these had already no effect.
Cleaned up a bit of code around old Qt 4 #ifdefs and
documentation mentioning Carbon.
Change-Id: Id2858c56a5785f82c47e20e1e760743fb4d08189
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
It looked inverted for some reason. A single line looks
better than before.
Change-Id: Icb214b44ddcc6e9e57fe12e7b4c3f512a5f66452
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
While the QPA theme provides support for dock widgets
title font we never use it.
This is a very similar solution to what we do in
QMdiSubWindow, setting the platform theme font at
few specific points.
This patch also fixes the dock window title font on
macOS, as queried in QCoreTextFontDatabase.
Change-Id: Ie264e4e83e0d3d1e8f78bd378359f3063cc1d525
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
Not only they should not appear (icons in menus is a special
thing on macOS), they don't match the look on the window frame
buttons. So, it's better to hide them completely.
Change-Id: I8814ed3e128480abff4f53fdd40a0bb13f1796ef
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
There are a couple issues. Because the actual class for
the buttons returned by +[NSWindow standardWindowButton:
forStyleMask:] is private, we can't fully configure them
as we could with HITheme. Therefore, we don't get the
mouse hovered state and the zoom button will show the
fullscreen arrow instead of the '+' icon.
Hopefully, QMdiArea will go the way of the dodo soon
enough. It is not a thing on macOS and it has been
replaced by tabbed windows UI on most desktop apps.
Change-Id: Ia581f72611ad0224f42657afbc4d9f94bf5e5a3a
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
This is currently only used in QMacStyle since,
on macOS, the spin-box buttons are always beside
the line-edit. Hence, there is no need to tamper
with the line-edit frame.
Change-Id: I8ccfbab547fccae89a8ddeaeb7005cb17d5951e6
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
Bonus changes in this edition:
* The focus frame shows only around the spin-box's
line-edit, as it should. This requires getting
access to the spin-box's line-edit, which we do
by setting a property on the former. Notice that
the stepper doesn't get focus. On this point,
macOS is inconsistent (partly because there's no
such thing as an NSSpinBox, and partly because
spin-box buttons are a separate control), so we
copy the same focus behavior as NSDatePicker.
* We clean some QFocusFrame related dead code in
QMacStyle::event().
Change-Id: I204ca2093d9db343c78f0420811dda35c463bbcd
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
Regression after 114f795221, which incorrectly assumed that checking
qt_logging_to_console() was a safe behavior change to include.
Unfortunately that broke debug output in Qt Creator, as Creator doesn't
seem to run applications with a controlling TTY unless it itself was
started with one, and doesn't set QT_LOGGING_TO_CONSOLE to force log
console output either.
Task-number: QTBUG-66153
Change-Id: I775cb06953122a3f20c16bfe21e19de2d1aa5b52
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
This way, it's lossless.
This commit is a cherry-pick of ab1e507574,
which was reverted.
[ChangeLog][QtCore][QVariant] Conversions of QDateTime to strings now
contain the millisecond components.
Change-Id: I5e421e32396d44e4b39efffd150b744e40fff3a1
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
AtSpiAdaptor::componentInterface was not checking the coordinate type in
GetAccessibleAtPoint.
Now, if the coordinate type is ATSPI_COORD_TYPE_WINDOW the coordinates of the
window will be added to the specified coordinates.
Change-Id: Iba571109a8da300f4141d616a94ef4ac87918f98
Reviewed-by: Jesus Fernandez <Jesus.Fernandez@qt.io>
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
If the accessible description of a QLineEdit is requested and none has been
set, the placeholder text will be provided if one is available.
Change-Id: I4c0dad1d06fd3d8a6e00c963402d380c59bd7f05
Reviewed-by: Jesus Fernandez <Jesus.Fernandez@qt.io>
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
Passing on the thread ID is confusing, as it's not really what the
function does. The QNX code path can resolve the thread ID by itself.
Change-Id: I5f0d54621058576cdcf3707d36a11762fe2383c8
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The include is not needed and breaks build that do not have process
support.
Change-Id: I3951c24c950dd556a3b26744d8994709e294d397
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
The actual implementation for Android will come later.
Change-Id: Ia68fcb03ea5d769d302ec6f77e5666292b567ffa
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
It can be used by custom widgets or for example by
the Breeze style from KDE, which allows to drag windows
by some widgets.
It's important on X11 because _NET_WM_MOVERESIZE requests
induced by touch sequences require support from Qt.
Task-number: QTBUG-58044
Change-Id: I31c37534555a9050cf361cad85bdef13c2808572
Reviewed-by: Johan Helsing <johan.helsing@qt.io>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
The first, isValidUtf8(), as the name says, returns true if the string
is valid UTF-8. As a bonus, it also returns whether it's valid US-ASCII.
The other two are meant to compare an UTF-8 string to either a Latin1
one or an UTF-8 one, without memory allocation.
Change-Id: Ic38ec929fc3f4bb795dafffd150ad0d63e28cd32
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
While we're at it, add a way to get it without the dashes too. I'm
calling it "id128", as in "128-bit ID", as seen in journald's sd_id128_t
type and the sd_id128_xxx() API.
[ChangeLog][QtCore][QUuid] Added a parameter to both toString() and
toByteArray() to allow controlling the use or not of the braces and
dashes in the string form.
Change-Id: I56b444f9d6274221a3b7fffd150cde706cfc5098
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
New members were added to QVarLengthArray and QVector,
but the engineer didn't document them. Since they are
only slightly different versions of existing functions,
their \fn commands were added to the eisting qdoc comments.
Some defined(Q_CLANG_QDOC) uses were also added.
Change-Id: I8a5505ca27efc9205b1387ed0be310e4b74ec490
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
QtWidgets has one link to the linguist manual, so it needs
to see the3 index file for qtlinguist.
Change-Id: I2bbbc4cc9e6d43fed1b6cdee556bc9c4d5f01299
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
A \l was changed to \c to be consistent with all the other references
to the class name..
Change-Id: Ic7449a06e0a1f1d6d7087e11cc85258e81a0dfab
Reviewed-by: Martin Smith <martin.smith@qt.io>
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
Return types were missing from two \fn commands, but clang-qdoc
did not detect they were missing on macOS. clang-qdoc on linux
did detect them. This could mean there is a problem with the
function that matches a \fn signature with its declaration in
the database. It might be too forgiving.
Change-Id: I01f107a6162e2f36b594b5d3dd4029b8ef2db678
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This is a standard feature in GtkEntry widgets or HTML
<input type="text"> elements. During a normal text selection by mouse
(LeftButton press + mouse move event), it's now possible to quickly
select all the text from the start of the selection to the end
of the line edit by moving the mouse cursor down.
By moving it up instead, all the text up to the start of the line edit
gets selected. If the layout direction is right-to-left, the semantic of
the mouse movement is inverted.
This feature is only enabled if the y() of the mouse move event is
bigger than a fixed threshold, to avoid unexpected selections in the
normal case. This threshold is set by the QPlatformTheme and a value
smaller than zero disables this feature.
The threshold is updated whenever the style or the screen changes.
[ChangeLog][QtWidgets][QLineEdit] Implemented quick text selection by
mouse in QLineEdit.
Change-Id: I4de33c2d11c033ec295de2b2ea81adf786324f4b
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
__cplusplus was removed from the list of defines passed to
qdoc because it should not be there for clang-qdoc.
Change-Id: I32802e68d915f7a5b717f16ba26a1cd57d7ff645
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
Properly set QStyleOptionViewItem::viewItemPosition to honor the css
Pseudo-States.
Task-number: QTBUG-27110
Change-Id: I9b9bb4913210feb665fd9d00a71dc4a953a93606
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
Replace '2' with the correct margin retrieved from PM_HeaderMargin during
paniting of CE_HeaderLabel within QCommonStyle::drawControl().
Change-Id: I5a50e02f107a00f382a38e14c4d3fa8dcb97ad12
Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
When an icon was given through Qt::DecorationRole, the available space
for the text was not adjusted which created a graphical glitch.
Task-number: QTBUG-62091
Change-Id: I0f20b6de95deed14fb882efde5c81b83ab3e9a7e
Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
Fixing miscellaneous rendering issues to make the WindowsVista
style look good on High DPI displays:
- Fixed size/resolution of combo box arrows, and changed to native look.
- Fixed vanishing horizontal line in the frame of line edit widgets.
- Fixed gaps in combo box popup.
- Fixed size/resolution of arrow in push button menu.
Task-number: QTBUG-49374
Task-number: QTBUG-65237
Task-number: QTBUG-65238
Change-Id: If68c2fae7472def3c19636483af741ca8ed2c490
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Fixing miscellaneous rendering issues to make the Windows
style look good on High DPI displays:
- Fixed size/resolution of combo box arrows.
- Fixed size/resolution of scroll bar arrows.
- Fixed size/resolution of check boxes.
- Fixed size/resolution of radio buttons.
- Fixed the frame of default buttons.
Task-number: QTBUG-49374
Task-number: QTBUG-65237
Change-Id: Ib7e2ef2ed027c50dbac23b16a73f7033000552f1
Reviewed-by: Andre de la Rocha <andre.rocha@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
In remove(const QString &str, Qt::CaseSensitivity cs)
call remove(QChar c, Qt::CaseSensitivity cs)
if str.size() is equal 1. It prevents quadratic behavior
for that case.
Change-Id: I9a7ab3019c580343533c8c6c6a04b6b0c8c1fb55
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Fix warnings:
QtEdidSupport: WARNING: qtbase/src/platformsupport/edid/qedidparser_p.h does not have the "We mean it." warning
QtEdidSupport: WARNING: qtbase/src/platformsupport/edid/qedidvendortable_p.h does not have the "We mean it." warning
Amends 5f7ab88055.
Change-Id: I3868096344480d509d7b7c1833389adaa67623a0
Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@liri.io>
WindowScreenChanged events might be reported repeatedly from the QPA backends
until the event has reached GuiApplicationPrivate::processWindowScreenChangedEvent()
which sets the screen. Ignore events in case the screen is already correct.
Task-number: QTBUG-65580
Task-number: QTBUG-62971
Change-Id: Ie5fc9830771e816db942355efbe5a48e829914cb
Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
Add information about mouse tracking/grabbing for widgets
and window where applicable.
Change-Id: Idfe8bef6d146ff06dfe95c0bad5e29e7a4ea7adc
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
My assumption before was that show() method calls exec(), but it seems
to be vice-versa and so QML applications using QFileDialog were not able
to open dialogs as they use visible property, which in turn calls show()
method. I made the show() method to call new openPortal() method where
I moved the actuall DBus call from exec() method. The exec() method now
internally calls show(), at least this is my assumption and it seems to
behave like that from my testing.
Change-Id: I27a5b0198e9ff1a9ea031f9ae45b57ceae99c6ae
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
- Allocate widgets on stack. The previous version was inconsistent (some
widets were managed by QScopedPointer and some were simply leaking).
- Use QTest::mouseMove(QWindow *)
- "This test fails on OS X on CI" was a clear indication that test is
flaky, the new implementation can reliably reproduce issue which is
now tracked in QTBUG-63031.
Task-number: QTBUG-63031
Change-Id: I59965ef8fa8edca17c8a73901d81e9efc7da3c5b
Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>