This allows all compilers to inline the function call into the
std::sort instantiation.
Change-Id: I3d831ee9160dd89208f42b258ff2463f942a7630
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
- Introduce Qt 5 signals & slot syntax
- Use QCommandLineParser to obtain file arguments
- Merge MainWindow::createMenus()/createQToolBars()
into MainWindow::createActions(), removing the need
to store the actions as member variables.
Use QMenu::addAction() for brevity.
- Use QIcon::fromTheme() to obtain system icons and use
resource icons as fallback.
- Rewrite settings code to use
QWidget::saveGeometry(), Widget::restoreGeometry() since
saving size and position does not work well with multiple
screens. Query the available size when determining
the initial size instead of using hard-coded values
for High-DPI screens.
- Fix minor issues in code, use multi-argument version
of QString::arg(), QDir::toNativeSeparators() to
present file paths to the user.
- Fix snippet references accordingly.
Change-Id: I1bc49a8913aa6d669e0e666f04be3f1f42eaba10
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com>
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
Make the name of the signal and the name of the getter unambiguous,
which in turn allows the easy use of Qt 5-style connects.
[ChangeLog][QtCore] Deprecated QProcess::error() signal in favor
of new QProcess::errorOccurred() one.
Change-Id: Ic5bcf7d6878e6985f1b4fed9dbe247527d13758c
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
This update adds the \noautolist command to qdoc.
This command can be used in the qdoc comment for
a \module or \qmlmodule to tell qdoc not to write
the automatic annotated list of C++ classes or
QML types to the HTML page because the documenter
has listed them manually. The qdoc manual is also
updated to include the \noautolist command.
Change-Id: I2eac5ceebfcd83a41bca7384b3da038fffbe6e66
Task-number: QTBUG-46821
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
This function has been removed. Fixes documentation warning:
qtbase/src/corelib/codecs/qtextcodec.cpp:1160: warning: Cannot find 'setCodecForTr(...)' in '\fn' QTextCodec::setCodecForTr ( QTextCodec * c )
Change-Id: I8d17705291b414d9c27827af4248bbf9e090962e
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The test is crashing regularly (see bugreport).
Currently the test is not run in the regular CI system, that is why
the failures were not noticed.
Task-number: QTBUG-47128
Change-Id: I70d4ada0872316cc63d7629bb9ab2d055d70cf2a
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Fix the corner case when called on empty buffer.
Change-Id: I1316de7fbe69f3db40a7fdde06336e53d82675c9
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Previously, this allocated temporary QByteArrays in the frequent
QVector<Symbols>::indexOf calls (macro.arguments.indexOf(s)).
Now, the we reuse the fast SubArray::operator== implementation.
Change-Id: Idbc6e3cf5fd353e8e36d51ba88d31e4c3bfd121d
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
ParsedParameter is larger than a void*, so holding it in QList
is needlessly inefficient. Worse, the code could come to depend
on the fragile property of (inefficient) QLists that references
to elements therein never are invalidated.
Fix by marking it movable, and holding in a QVector instead.
Change-Id: I5b1bea9ef7b796a790d8e86404531ae19a4aca66
Reviewed-by: Martin Smith <martin.smith@digia.com>
QDBusIntrospection::Argument and the QPair are larger than a void*, so holding
them in QLists is needlessly inefficient. Worse, the code could come to depend
on the fragile property of (inefficient) QLists that references to elements
therein never are invalidated.
Fix by marking the types movable, if not already done, and holding them in
QVector instead.
Change-Id: I1cf88287cc3a1d87e1fcd5061ed8d6d19d2f0722
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
GIMP asks for image data in PNG format when doing a "paste" which
was previously handled only in convertToMime(). Add handling
to convertFromMime() and register format.
Task-number: QTBUG-46848
Change-Id: Ib11de27d301c8632869c7276e421e48e4f34e1d0
Reviewed-by: aavit <eirik.aavitsland@theqtcompany.com>
Previously, 0 was passed which causes QWindowsXPStylePrivate::winId() to
go on a hunt trying to find a window handle needlessly looping over top
levels, slowing down painting.
Task-number: QTBUG-42245
Change-Id: Ic702d9a73c4f749fd5988950280aef632a3308c4
Reviewed-by: Marko Kangas <marko.kangas@theqtcompany.com>
Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
There was an attempt to allow static instances of QIcon in
7727a4355876607a1a022ff54e2570dae883f79c (Qt 4). This patch does only
solve some of the corner cases and broke with
aa5f70c00a. Since the "breakage" has been
there for two years, let's officially declare it unsupported instead of
trying to work around the issue.
Change-Id: I61e12fd03953763ee2e70eae58bcaecabdcb85b8
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
This allows end users to create QSystemTrayIcons that are properly
displayed as monochrome images on OS X, which is especially important
on Yosemite and above when Dark Mode is turned on.
[ChangeLog][QtGui][QIcon] Add ability for QIcons to be marked
as template images. This allows end users to create QSystemTrayIcons
that are properly displayed as monochrome images on OS X, which is
especially important on Yosemite and above when Dark Mode is turned on.
Task-number: QTBUG-42109
Change-Id: I095fb71355ffa572d0abb4769341f68b89b877c4
Reviewed-by: Jake Petroules <jake.petroules@petroules.com>
They are held in QStack, thus QVector.
Change-Id: I0673b68632b384d6428e881e24ff830d12aecfab
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
The latest version of Haiku provides the implementation
for pthread_condattr_setclock, so we can enable the code
in QWaitCondition again to make it use the monotonic clock
correctly.
Change-Id: Ibb9ad33d873c3b34f2c516087c4e0aeac04cc83f
Reviewed-by: Augustin Cavalier <waddlesplash@gmail.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
We have ownership for a reason - and there seems to be
no good reason not to accept it here.
[ChangeLog][QtWidgets][QComboBox] QComboBox::setView no longer
deletes the old view directly. It now checks the ownership first.
Change-Id: Icb5e5c0a6e9dc93c1d1c1a90ff57fbcc0786aa60
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
Previously, directory nodes in the resource tree generated empty
file names in the --list output. They do not add value.
Change-Id: I04ac495ba5f57802de9796ec663c28facfee89f2
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Simon Warta
It might get new features, but it probably won't so don't create
false expectations.
Change-Id: Icbdae9242822798c681f75988c968fc9e6f0d081
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
Some window managers don't reparent the client window into the frame,
so the old method of calculating frame margins by the geometries of the
window and it's frame window is not suitable for them. Use it only as a
fallback.
Change-Id: Ie4d62370425effef4dd91bf27d98e3746e8a375e
Task-number: QTBUG-2280
Reviewed-by: Gatis Paeglis <gatis.paeglis@digia.com>
Reviewed-by: Uli Schlachter <psychon@znc.in>
Its not known if the call to flush() is required in
Qt 5. It has been compiled out until now; remove it.
Change-Id: I7033e02af8ac7ea2a357d1287e368b541d1d6776
Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
This is in preparation of adding -Wzero-as-null-pointer-constant (or similar)
to the headers check.
Task-number: QTBUG-45291
Change-Id: Ie14e5280c430b6a254f8f686534450c1e5995374
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
Saves one full iteration and memory allocation.
Change-Id: Ice527499b5f5f62bd1e47d76fdf40119948ee3a1
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
... by marking the ctors (if any) explicit and the
function-call operator const.
Change-Id: Ia65fbad0dfdccbb31d630a5501c4d6f0f5aa3623
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
They are already held in QVector.
Change-Id: Ib1266956c860ecd4671501ab12ab932a8ce9b7d6
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Nuiouser.h seems to be missing in WEC2013.
But it can be re-enabled according to Gunnar,
thus disable it conditionally.
Change-Id: I01be629fc309f04d2a43a9153c124a4e332b6ed0
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Gunnar Roth
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@theqtcompany.com>
Micro optimization, because it's called a lot.
Change-Id: I50f775b39393f1f450e09ae9dc59a77d584f3c10
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Was placed under an unrelated enum. Move it to the
correct one.
Change-Id: I0cf1ffc678c4cffae16660acde95183d5ebcad03
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
These types are larger than a void*, so holding them in QLists
is needlessly inefficient. Worse, the code could come to depend
on the fragile property of (inefficient) QLists that references
to elements therein never are invalidated.
Fix by marking them movable, and holding in a QVector instead.
Change-Id: I3d5cf78c1597bd1b743ed3692aaa5e2e750a85f9
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
DestFormat is not defined here but should be Format_RGBX8888
Change-Id: Ie33989a6fc31650434281a6b7b0f4806524268af
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Timo Jyrinki <timo.jyrinki@canonical.com>
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Found by ICC:
qtextengine.cpp(1259): error: more than one instance of constructor "QFixed::QFixed" matches the argument list:
function "QFixed::QFixed(int)"
function "QFixed::QFixed(long)"
function "QFixed::QFixed(qreal={double})"
argument types are: (uint)
QFixed stretch = QFixed(actualFontEngine->fontDef.stretch) / QFixed(100);
^
Change-Id: I790fb4cae1abc692705253a7863291bc8743b832
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Jake Petroules <jake.petroules@petroules.com>
The warning is useless, since the application is about to terminate
anyway. The user will be better informed by getting a proper backtrace
of the throw point, instead of the rethrow point inside QObject's
destructor.
The application WILL terminate because C++11 destructors are noexcept
and GCC 6 enforces it:
qobject.cpp:909:13: error: throw will always call terminate() [-
Werror=terminate]
qobject.cpp:909:13: note: in C++11 destructors default to noexcept
QT_RETHROW;
^
Change-Id: Ib056b47dde3341ef9a52ffff13ee8f01d874d224
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
On Windows, t->timeout was updated only once, at creation time, so the
timer would always show as "overdue" after the first activation.
The timer is updated to indicate the full remaining time during the slot
activation, which is the behavior of the Unix and Glib dispatchers.
Task-number: QTBUG-46940
Change-Id: I255870833a024a36adf6ffff13ecadb021c4358c
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>