By construction of the _qt_BuiltInFormatType enum, the .type in
_qt_BuiltInFormats exactly equals its position. So there's no
need to store it explicitly.
Effects on Linux AMD64 GCC 4.9-trunk release stripped:
text: -16B
data: -64B
relocs: +-0 (of course)
Change-Id: Ib68c32de42d264f27bbd8a863538dd78b1ba4507
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Adds the QPA side of the support for text highlighting during text
entry and for spell checking. The changes are compatible with
existing Qt text controls though require more advanced ones to have
any effect.
QQnxInputContext has three colors it can now use for highlighting
text during composition to represent the active region, auto
corrected text and reverted text. If any of these colors is invalid,
that form of highlighting is not used. By default, only the active
region color has a valid default which corresponds to the highlighting
capabilities of classes such as QQuickTextInput. The QNX QPA native
interface has been augmented with the ability to get a function
pointer that can be used to set any or all of the three colors. The
set of colors is reset to the default at any time that focus changes
to ensure appropriate behavior if there is a mix of controls.
It's worth noting that while the colors can be changed even when
used with one of the standard Qt text controls, the auto-correct
color will not show up since it is applied immediately before
committing the text. Appropriate display of this highlighting
requires that the control maintain the highlighting for a period
after committing the text.
Spell checking is provided via another function accessible through
the QNX QPA native interface. This takes a string and a callback
function to be called once spell checking is complete.
As a slightly unrelated change, toSpannableString now uses
toWCharArray to convert the QString to UTF-32 as required by IMF,
the previous code was invalid in the case of strings containing
UTF-16 surrogate pairs.
Removed some extraneous includes.
Change-Id: Ifdf3744d1990e0560d1923bca5db30953dea0192
Reviewed-by: Roger Maclean <rmaclean@qnx.com>
Reviewed-by: Fabian Bumberger <fbumberger@rim.com>
Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
Reviewed-by: Kevin Krammer <kevin.krammer@kdab.com>
Like in I53284066, the result of the SIGNALS() macro is handled in a switch
statement, while the other two character pointers in the struct are replaced
by character arrays of 'maximum occurring size'. If this looks wasteful, it
really isn't:
Linux AMD64 GCC 4.9-pre stripped -O2 effects:
text size: -280B
data size: -160B
relocs: -21
When adding longer strings, compilers will warn, so this doesn't hurt
maintainability, either.
Change-Id: I5ac1cdffd8ac0ea0a1ede1ea4edcc6d3e22dcaa2
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
The usual way of concatenating the strings with NUL bytes and
recording the relative offset of each in a separate offset
table doesn't work here, because the entries are the results
of SLOT() and SIGNAL() macros, which might, in debug mode,
inject a runtime function call (to qFlagLocation()).
Linux AMD64 GCC 4.9-pre stripped -O2 effects:
text size: +16B
data size: -64B
relocs: -6
Change-Id: I532840668bb57ab72ef3fecb01a450c4c46516e9
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
When declaring a Q_PROPERTY(SomeType::SomeEnum foo ...) and SomeType is not a
QObject but a gadget, then we must still include SomeType's meta object in the
list of related meta objects.
Task-number: QTBUG-35657
Change-Id: I46195140cb5d180c4f03bb1fe06a876e3fe11267
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
QtWayland uses QtWaylandScanner to generate c++ files which will be
subclassed. This works ok in QtCompositor as it implements the pimple
pattern. However, QtWayland has to expose a library called
QtWaylandClient as a way to create specialized wayland plugins. These
classes don't promise an ABI, and has limited API guarantees, so they
subclass the classes generated by the QtWaylandScanner directly. For
this library to be possible, we have to install the generated files.
Also, it should be possible to use the private API, and that's not
possible without the generated files.
Change-Id: Id55200fe23652587390dabf84ca846e4f39cf70e
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Reviewed-by: Andy Nichols <andy.nichols@digia.com>
Hand-roll a string table here, since there's opportunity for
sharing string data between string entries.
Effects on Linux AMD64 GCC 4.9-trunk release stripped:
text: -88B
data: -64B
relocs: -5
Maintainability is hurt somewhat, but it is expected that the
contents of this string table do not change much, so the
overall effect is still very low.
Change-Id: I2a22da4c8548c53ef31c33319b4652f3cb6f62f5
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
QAtomic will now depend on QTypeInfo, so shuffle the order to make
sure the includes are right.
The first set do not require anything but the macros from qglobal.h,
then qflags.h requires qtypeinfo.h and qtypetraits.h, qatomic.h
requires qtypeinfo.h and qglobalstatic.h requires qatomic.h.
Of those, only qatomic.h isn't in global/, so we could even consider
using "" includes, but I recall MSVC not honoring them correctly.
Change-Id: I76c150254a99cdea8857445bdebf2e724eaa76bd
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
Right now, the sublib targets, if any, show up between clean and
distclean targets. That's silly.
I doubt anyone is using sublib targets anyway, but...
Change-Id: I2beffc69f68fa7626ff4aa4a7cc1169b2c6c69a7
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Then it's possible to embed native cocoa widgets without crashing.
Task-number: QTBUG-35629
Change-Id: Ic212c36178282b4d090c6ce0470012adc8e0c2bb
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
- thread was duplicated
- x86 & ppc are obsolete and don't actually do anything
- incremental was just plain nonsense (it does something entirely
different, and it's better to hide this "feature" from public view)
- resources is basically an implementation detail (it's on by default if
qtcore is used)
Change-Id: I9163af6e8db7988382ccf993d4be280f7faec1f2
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
while the dependencies in the manual projects are crappy anyway, it is
still worth to cover the case of the user changing the install paths.
Change-Id: I0a7ca5c8ba660c689d6d7af6b65d878390d6456f
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Done-with: Leena Miettinen <riitta-leena.miettinen@digia.com>
Change-Id: I1e031402bc3d857cf29782957e5340e3c82f1ed2
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@digia.com>
Some database systems (like PostgreSQL) use alphanumeric error codes.
Introduce a new method nativeErrorCode() which replaces number().
If the error code cannot be converted to int, number() will return 0.
Task-number: QTBUG-142
Change-Id: Ic7fba841737674b75c0c01c2263f51d2041da497
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
Those flags are required to pass the Windows Store App Certification
process. Otherwise apps are not allowed to be published.
The SAFESEH option is only required for x86.
According to documentation APPCONTAINER only talks about the
executable, but when running through the certification, the Qt modules
are reported to be errornous as well.
Change-Id: I5450687dcd5bc537149e331332e253c4617df55d
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
Reviewed-by: Andrew Knight <andrew.knight@digia.com>
When we get a WM_CHAR message we do not need to add anything to the key
map as these messages already contain the character code in question.
Task-number: QTBUG-35532
Change-Id: If73993cd873b7c616876b9ba52ceba6b27a6a7b1
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
This allows us to add new members without breaking BC.
Change-Id: I59236cd5eeacdcfc490849a18b3bdf70d7a501bf
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
Task-number: QTBUG-34749
Corrected link to drag and drop example.
Corrected link to {mandatory fields}
Created target referring to macros for defining plugins
Change-Id: I387a2d9bab428b2eacd8d371f08c72f42f7e2be2
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
Querying the "extra" fallback fonts (which are hard-coded names, actually)
for family only makes sense for scripts that cover more than just a single WS;
these currently are Common (<-Inherited) and Han.
Change-Id: I37682f1ae51a476a21b933607de48b01255cf1c3
Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com>
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
In a slot connected to readyRead, if the app detects that the
buffer size is too small and increases it, it expects that
readyRead() will be emitted again.
setReadBufferSize() doesn't re-enable the socket notifier when
calling from within readyRead, and readyRead itself was missing
the code to do it.
Change-Id: Ia00a3066ad3ba09d5cfae0716adc5691ae96c3fa
Done-with: Thiago
Reviewed-by: Peter Hartmann <phartmann@blackberry.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Use of mkpath/mkdir is removed in order to make the proxy less
invasive when there is no compiler service running. Creation of the
directory structure is fully the service's responsibility.
Service availability is now only checked once, at the first invocation of
D3DCompile, as it is expected to be started before the application.
Change-Id: Ib8c4f062c418497c2253daf524654e1db30dae47
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
MSVC warns about multiple symbols when using extern "C", but MinGW
requires it. #ifdef it for MinGW.
Change-Id: I8b16ab4ea129312787090e042115d8f709fdd814
Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
Do exactly what windows font database does to determine
writingSystems in case of non-truetype fonts.
Task-number: QTBUG-13585
Change-Id: I4a1a48d74c36e403c31f20847cf80295d89a34bc
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Most devices that use tslib have the device path defined by
the TSLIB_TSDEVICE env. variable.
Change-Id: I89fc17cb2c7fba7741de2fd348aacd608cb21a2a
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
For the linuxfb platform the screen was registered
before its geometry was calculated resulting that
the qpa controller will deal with a screen instance
that has geometry of QRect(0,0,1,1) .
This masks pretty much all the painting and the input.
The fix is to call screen init before registering
the screen instance to the qpa controller.
Change-Id: If84daca6587dc368301b578cdbf7b2a65a56a5b5
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
QMacPasteboardMime is a public class in Qt 4. Qt 5 has
two copies, one public QtMacExtras and an internal
one in the cocoa plugin. This causes a symbol collision
when building statically.
Rename the internal copy to QMacInternalPasteboardMime.
Task-number: QTBUG-35310
Change-Id: I891787b451a0b342ed85aa7196e606bc11623e21
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
The QVarLengthArray inside qlocale_blackberry.cpp was being preallocated with
512 bytes, that means internally it could grow up to 512 bytes using the
stack before switching to the heap, but its actual semantic size was still 0.
After qt_safe_read(... buffer.data() ...) was being called, data was written
to the QVarLengthArray buffer, but its semantic size was still 0, since it was
not resized or anything. This triggered an assertion when buffer[bytes] = '\0'
was assigned, since 'bytes' > buffer.size() ( == 0) despite buffer.capacity()
== 512.
Change-Id: I5503ee9b02413794f67730700fba05a4c194d465
Reviewed-by: Mehdi Fekari <mfekari@blackberry.com>
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
- Explain that values() is unnecessary and causes an extra copy.
- Replace "are fastest" with "are faster".
- Briefly explain the snippet.
Change-Id: Iff1d3a0b6140fca1d78157aeeca3d538c4d78b84
Reviewed-by: Albert Astals Cid <albert.astals@canonical.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The "Fixed CE build of sqlite3" patch is preserved in this change.
(ea70ec8711)
Change-Id: I41a268bd077e396810965ca27cd572cef7259d58
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Mark Brand <mabrand@mabrand.nl>