Implement INCR property mechanism according to the icccm specification.
Change-Id: Ic8f85b71cab825d70ee1b61f29acd09fa4c3e642
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
The rotation matrix is different according to the order of scale and rotate operations. The fix takes into account this.
Task-number: QTBUG-31822
Change-Id: Ia1c9068e54966ec083af9c165af29caa87c510f6
Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com>
On linux using QFileSystemWatcher with inotify backend when a watched
file is moved and added again to the watched files its path is not
replaced with the new one. This behavior prevents the emission of
the fileChanged signal with the wrong file path.
Task-number: QTBUG-33211
Change-Id: Ib45d8efdf5afbf8b8f6b4b26e43f3d6ee740aca6
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
PNG allows 1bpp greyscale images (PNG_COLOR_TYPE_GRAY) to have
an alpha key; so even in this case we need to inquiry if
the image has a transparency, and if so modify the color table
of the monochrome image accordingly.
Task-number: QTBUG-33503
Change-Id: Iab07c8f95ac8865269c48816e222645cdcb6bbc1
Reviewed-by: Nicolas Arnaud-Cormos <nicolas@kdab.com>
Reviewed-by: aavit <eirik.aavitsland@digia.com>
Initialize all values read to sensible default in case reading them
fails in read_image_scaled. It has already been done for a normal
image read
Task-number: QTBUG-32674
Change-Id: I19dccad7ef342f1b1bba6b513c04d3661d128a54
Reviewed-by: aavit <eirik.aavitsland@digia.com>
Changed the sigchld-Handler such that the SA_SIGINFO flag is handeled
correctly. Furthermore the signal mask is preserved such that the original
signal handler is not interrupted when not allowed.
Task-number: QTBUG-32979
Change-Id: Iec7663e7289ea5d95155f52cf8788ebf646cfabd
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Since the Cocoa Print Panel was not initialized with the NSPrintInfo we
had created, it meant that it did get any of the settings from the print
dialog as it was trying to access an invalid NSPrintInfo.
Task-number: QTBUG-32734
Change-Id: I23c766eb13281f4c494656a54d37c5bf28fb68fd
Reviewed-by: John Layt <jlayt@kde.org>
The backtrace in QTBUG-33012 indicates that the
screen list is getting out of sync on plugging/unplugging
an external monitor. This happens on 10.9 only.
Check if we are about to out of bounds access the
screen list; call updateScreens() which will add the
new screen.
Task-number: QTBUG-33012
Change-Id: Id1acc3baca9e60e7f2a83188d66cdf9d322a582c
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
Add examples that do not have any images in their documentation
into manifest-meta qdocconf file, and define a generic image to
use as a thumbnail in Qt Creator Welcome mode.
Task-number: QTBUG-31314
Change-Id: I1625bf15cbaa53e940a07b1828dc77ca5ba45ccc
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
Default for QUrl::password() and QUrl::userName() is in Qt 5.1 QUrl::PrettyDecoded
which means the return value may contain percent-encodings. For authentication
we need the real decoded result, and should instead use QUrl::FullyDecoded.
Note this bug has already been fixed indirectly in Qt 5.2 since the default for the
two methods was changed to QUrl::FullyDecoded.
Change-Id: Ia0f38c073cb001e37ad8b3eda40b3db756bec3dc
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
QVariant::typeName() returns a const char *, so one can't use ==
to compare it against another string.
Change-Id: Id7a4c06a9e4874459609b3749f87d39ed73e8405
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
- The "Concurrent Programming" page is an exact duplicate of the Qt Concurrent module landing
page.
- The "qtconcurrent intro" target is not referenced anywhere.
Change-Id: Ice9b4360783013fe972258ca54a0004be43b8766
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
Previously, the generated documentation contained
"QFutureWatcher:: progressValueChanged()". While it is legal C++, it
prevented QDoc from auto-linking to the QFutureWatcher class reference.
Change-Id: I2cace763f1825b0b4478b2bde95679d25df8bb5e
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
Center gravity doesn't mean center the window, it only affects the
method of converting between internal window bounds and decorated bounds.
So wanting to have each dialog centered w.r.t. its transient parent
is not a reason for using center gravity. Instead it caused the
bug that when you resize a QMessageBox by clicking the Show Details
button, it jumps downwards on the screen.
Task-number: QTBUG-32473
Change-Id: I3fabf3caa1e4d10fd4f7508e297f73efe5cc51b6
Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com>
Normally, searching for a V in a container of T using std::lower_bound
only needs an operator<(T,V). But in MSVC2008 debug mode, STL algorithms
perform some extra checks, such as ensuring the range passed to
std::lower_bound is sorted. This adds a requirement for operator<(T,T)
and operator<(V,T).
QtDBus didn't compile on MSVC2008+Debug since 1e37d854 (Sept 2012!)
because it missed those operator overloads for some private types.
Task-number: QTBUG-33473
Change-Id: I18902d86e6c58349eb7ba3601dc383ad5431c460
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The old code smply copied 100 shorts from the pointer passed into the
ushortarray ctor, regardless of the actual bounds of the original array.
Fix by making the ctor take the array by deference, deducing the size
as a template parameter, and only copying that much.
Fixes asan trace:
==18660==ERROR: AddressSanitizer: memcpy-param-overlap: memory ranges [0x7fff3c56de00,0x7fff3c56dec8) and [0x7fff3c56dd60, 0x7fff3c56de28) overlap
#0 0x457161 in memcpy asan_interceptors.cc:330
#1 0x4c40fe in ushortarray::ushortarray(unsigned short*) qtbase/tests/auto/corelib/io/qurlinternal/tst_qurlinternal.cpp:62
#2 0x4b0437 in ushortarray::ushortarray(unsigned short*) qtbase/tests/auto/corelib/io/qurlinternal/tst_qurlinternal.cpp:63
#3 0x47b643 in tst_QUrlInternal::idna_testsuite_data() qtbase/tests/auto/corelib/io/qurlinternal/tst_qurlinternal.cpp:119
...
Change-Id: Ie497bc8d337bc680a562482ca71ace535797ffb3
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
'val' was set to
QList<...>() << ... << ...
further down.
Fixes a Clang warning.
Change-Id: I5fe80d87dbe2c1d50652dfd7b6c5f4a9198cd467
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Partial revert of 3c6bb0ed8b and
57aed703d2.
When registering an object that was previously unregistered but not yet
garbage collected, the activeChildren count on the parent node was not
incremented, which could result in other registered objects disappearing
after a later unregisterObject.
Copying objects in the tree is not free, but it's not expensive enough
or used frequently enough to justify that error-prone logic. It's much
safer to simply remove objects immediately.
Change-Id: I3dc59c2ebd07b237518424fcd8ea7371a22d6d15
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
- Incomplete: It doesn't talk about how to use a raw QThread, or
QRunnable, or Qt Concurrent.
- Redundant: Its contents are already presented in QThread's class ref,
and the line before this section links to the "Multithreading
Technologies in Qt" overview page which provides a more complete intro
Also remove snippet markers that are no longer used.
Change-Id: I89b7bd72f10c8ffdfd9b7772e2493050aafc9c88
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Multiple issues:
- Incomplete: It doesn't talk about instantiating a raw QThread
- Redundant: Its contents are already presented in QThread's class ref
- Incorrect: It is legal to create a QThread before a QCoreApplication
- Irrelevant: The bit about QCoreApplication::exec() and the etymology
of "GUI thread" is unrelated to the topic of starting threads
Also remove snippets that are no longer used
Change-Id: Ice1819845b5b2cf843719edaa7b0f4bbb1e8bd97
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
It's helpful to see how to choose among different solutions, right
after seeing short descriptions of all the solutions.
- Some minor rewording was done during the move
- The example about polling ports in a new thread was removed because
there are better ways to do that without threads.
Change-Id: I2cb571a4dbf9be93fb0ec88c60fb7406996c345b
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Also bring text closer to the style guide at
http://qt-project.org/wiki/CppDocumentationStyle
Change-Id: I30b1c36ac125a10c002efeb36978ced0d7a8f8bf
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
The Xcode generator relies on the generic makefile generator for extra
compilers such as qrc and moc, by generating makefiles that are then
executed as separate build steps in the Xcode build.
These makefiles are generated by entering a special mode in the Xcode
generator, in which case we _do_ want to resolve dependencies, so that
e.g. the files referenced inside a qrc file are added as dependencies
to the makefile rule that generates the qrc-cpp file.
Change-Id: I96bdcb165e9774a6328ae1980986fa2c6b00c6d9
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
This reverts commit 59fd36bb914cae248d3c5100dd734d6d90a58dca,
which caused other drawing problems.
Change-Id: I3bb75fd3ca1cd21ffbb9ef5474266f4cd615a64a
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
Make sure enough pixels is sourced by multiplying
the layout rect size with the pixmaps devicePixelRatio.
Task-number: QTBUG-31477
Change-Id: I742603c09a65a520587da3eef9479ef7f0c87022
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
Implement the foreignWindowCreated and foreignWindow closed signals, emitted when foreign windows are created and closed, respectively.
Change-Id: I72dd5380e6061f191eb8362fda5dd8fb8e9ed06b
Reviewed-by: Thomas McGuire <thomas.mcguire@kdab.com>
Reviewed-by: Kevin Krammer <kevin.krammer@kdab.com>
Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
Implemented nativeResourceForScreen api to return QObject* which can be used to connect foreignWindowCreated, foreignWindowClosed signal in QQnxScreen.
Usecase is to connect signal in custom QML component as below
QObject * obs = interface->nativeResourceForScreen("QObject*", screen);
connect(obs, SIGNAL(foreignWindowCreated(void*)), d, SLOT(newForeignWindowCreated(void*)));
Change-Id: I512c3b6d188a2e90ef7b8e89c413ca420a29dd9b
Reviewed-by: Kevin Krammer <kevin.krammer@kdab.com>
Reviewed-by: Fabian Bumberger <fbumberger@rim.com>
Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
The median, for arrays of odd size, is found in [size/2], not [size/2+1].
For arrays of even size, the code doesn't work anyway, so nothing to do there.
Change-Id: Id23ff3fe9538c2d8ef8f88e23127cb92af08b444
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Demonstrates that you can have mnemonic buttons which don't
conflict with the Ctrl-A and Ctrl-C shortcuts.
Task-number: QTBUG-6731
Change-Id: I41ce64e6f3bd0cf387af13c5c37894b721b5a3bb
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
The context menu all along has indicated that Ctrl-A selects all the
text, so now that is actually implemented.
Task-number: QTBUG-6731
Change-Id: I82dac3aea530e5a3fcd59217c4c0118025061c7d
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
You can hit a key with no modifier to select a dialog button that has
the corresponding mnemonic, but it doesn't make sense to do that if
the Control or Meta key is being held. Now you can hit Ctrl-A, Ctrl-C
to select all the message detail text and copy it to the clipboard,
even if the dialog has buttons with mnemonics like &Continue and
Save &Again. But as before, Alt-C, plain C, Alt-A and plain A select
the mnemonic buttons on the dialog.
Change-Id: I40c052dbb7730bde444ac2de405724a3203d1472
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Use the UpdateLayeredWindow() functions only for windows with alpha.
Task-number: QTBUG-33025
Change-Id: I64b0c28ee0997cd3d09dc76babe105ed474c6835
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
In the latest libjpeg version, the "boolean" type is changed so that
true and false no longer can be used instead of TRUE and FALSE.
Also, purge some ancient code remains meant to support a now defunct
OS´s idea about the boolean type.
Task-number: QTBUG-33166
Change-Id: Iebbdf300cfdc22775954de65f985358424ed2b49
Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com>
If two items are equal according to the current sorting criterion,
the sorting predicate uses the address of the items to break the tie.
The problem is that the items themselves are being moved during
the sort; therefore, this will break the Strict Weak Ordering
that std::sort requires.
For instance, suppose to be sorting case-insensitively the following array:
("b", "a", "A")
Simulating a swapped-based sorting can lead to:
Array before Evaluated predicate Array after
("b", "a", "A") "a" < "A" (1) ("b", "a", "A")
^ ^
("b", "a", "A") "b" < "A" (2) ("A", "a", "b")
^ ^
("A", "a", "b") "A" < "a" (3) (XXXXXXXXXXXXX)
^ ^
(1) True, because of the array ordering (they're equal otherwise)
(2) False: swap them
(3) True, because of the array ordering (they're equal otherwise)
(1) and (3) say that "a" < "A" and "A" < "a", SWO gets violated,
leading to undefined behavior.
This problem was causing QFileSystemModel autotests failures (cf. [1])
after switching to STL algorithms instead of using qSort.
The array to be ordered in that case is ("a", "c", "C"),
cf. tst_QFileSystemModel::caseSensitivity.
(STL algorithms are much smarter than good ol' quicksort in qSort;
if we're ordering on an array which fits in a cache line, they
turn to the much faster (~1 robe) insertion sort. Violating SWO with
a quick sort usually just gets to a non-sorted container; insertion
sort is implementable in ways that rely on SWO, otherwise they
will overflow the iterator; cf. Cormen/Leiserson/Rivest and the other
literature on the topic.)
This commit reverts commit fa5f3a44 (in Qt 4).
[1] http://testresults.qt-project.org/ci/QtBase_dev_Integration/build_01749/linux-g++_shadow-build_Ubuntu_11.10_x86/log.txt.gz
Change-Id: I5d8ac0d0907675c501717969abee2816b41eca18
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
You are not supposed to call NSOpenGLContext -setView: for a view that
has not yet called drawRect. Doing this would result in a invalid
drawable error.
Similar to 4.8 commit cd2a51a66f
Change-Id: Ibb2300a8c6fe52f786f813987e93d4a3dc145366
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
qdoc-manual.qdoc is now an overview document
Each section is a separate qdoc file
Title modification in minimal qdocconf qdoc file
Task-number: QTBUG-31801
Change-Id: I9e50eb8c4f1f501e9c0bc768372d4393b73053ed
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
Reviewed-by: Martin Smith <martin.smith@digia.com>
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
These macros were previously defined for QDoc manual.
This change adds them to global macros.qdocconf so
they can be used everywhere.
Change-Id: I4fdf5a103ecfb356719951a7d0c6fbd35c887744
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
When creating a fontengine in QFontconfigDatabase::fontEngine we
solely base the antialias setting on the QFont StyleStrategy and forget
to ask fontconfig it has an overriding definition for this font match.
This patch will now let fontconfig decide the antialias setting unless the
NoAntialias stylestrategy has been set.
Change-Id: I67981582a37cfd3c59aa1db929095585af554088
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com>