Commit Graph

7053 Commits

Author SHA1 Message Date
Konstantin Ritt
cbfdec6603 move the default text breaking algorithm impl from HarfBuzz to Qt
there are several reasons to do this:
* text breaking is not a shaper's job;
* since the text breaking rules are bound to a specific Unicode version,
  updating Qt's internal unicode data would require updating the data in HB as well;
* makes porting to HurfBuzz-NG some easier

Change-Id: I0bbf8e8a343bc074696f4ddf2ae4e7fa32a61629
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-05-10 11:34:25 +02:00
Konstantin Ritt
8c0048a377 add some useful methods to QUnicodeTables::
in order to reduce code duplication and prepare the ground for upcoming changes

Change-Id: I980244149f65384c9484bbec4682de8b7b848b08
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-05-10 11:34:25 +02:00
Marius Storm-Olsen
2d23374a6f Merge "Merge branch 'docs-refactoring' into master" into refs/staging/master 2012-05-10 11:34:25 +02:00
hjk
7f2c22e891 gettingStarted, part 3-5: sanitize parameter names and compile fix
Change-Id: I12795439de71a41728f98b3d3438324664b27a0f
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-05-10 09:16:35 +02:00
Marius Storm-Olsen
9456528aac Merge branch 'docs-refactoring' into master
Change-Id: Iebd1966abace3cdf7f9428dcfc1ded5b124ab113
2012-05-10 09:11:23 +02:00
Marius Storm-Olsen
ee38dec6f3 Don't add C-style copyright headers to qmake project files
Leads to parse errors, and we don't really put copyrights into these
files anyways.

Change-Id: I4b423b3f4f5c4f1f5051d8e3613133c4f1df342a
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2012-05-10 09:07:14 +02:00
Bradley T. Hughes
5f43422ddf qpa: Remove QPlatformDialogHelper::deleteNativeDialog()
This function isn't really needed. The QDialogPrivate destructor deletes
the platform helper, so the QDialog destructor does not need to do it.
Subclasses of QPlatformDialogHelper are now responsible for deleting any
native resources they create.

The one place in QFileDialog that needs to recreate the native dialog
can simply recreate the helper. QDialogPrivate::deleteNativeDialog() now
becomes QDialogPrivate::deletePlatformHelper(), which resets all state
to allow the platform helper to be recreated.

Change-Id: I58adfe8801e02e63b3cb4a9a3a0b8cb5b3c7b161
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-05-10 06:56:20 +02:00
Bradley T. Hughes
d223b30c42 qpa: Clean up QPlatformDialogHelper API
Remove the _sys suffix from all members of QPlatformDialogHelper and its
subclasses. The QPlatform* class prefix already implies that these
methods are system specific, we don't need the method suffix as well.

Change-Id: I5ad1f928fab3a989992951acc244915e7fa48d32
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-05-10 06:56:04 +02:00
Thiago Macieira
75552c8f62 Fix a crash when parsing a URL with username and port, but no password
This was crashing because the ':' was found past the end of the
username, causing the recoder to run from position 22 to 11, via the
long way around the memory.

Change-Id: Ic1ae596f34f7db857fb4210294974fb5a6adf691
Reviewed-by: Alexis Menard <alexis.menard@openbossa.org>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-05-10 02:39:30 +02:00
Jędrzej Nowacki
ff3a2ab242 Fix test case dependency in tst_exceptionsafety.
Change-Id: Icb3887e8bca55a7e76b264b0a5ce8aa2dd118275
Reviewed-by: Harald Fernengel <harald.fernengel@nokia.com>
2012-05-10 02:39:30 +02:00
Eskil Abrahamsen Blomfeldt
602203cf06 Don't ignore default font's font capitalization in QTextDocument
The consequence of this was e.g. that it would be impossible to
set the capitalization of TextEdit elements (or Text elements
with RichText format) in QML.

Change-Id: Ie219fac7e4305efc59a4ac9da5b06c25ff3ac9ac
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
2012-05-10 02:39:30 +02:00
Shane Kearns
7578a9f69d Fix a QSslSocket test expectation on ubuntu 11.10
Because SSL2 is disabled in ubuntu's openssl binaries, the SSL
connection is expected to succeed rather than fail when the server
side is using SSL3/TLS1.0.
Used the OPENSSL_NO_SSL2 macro to decide this.

Change-Id: I2c35aa5aa0c9432ae78000c81f70086bdc31843d
Reviewed-by: Richard J. Moore <rich@kde.org>
2012-05-10 02:39:30 +02:00
Michael Brasser
c47c8ba59e Remove QAbstractDeclarativeData::objectNameChanged.
There is now an actual NOTIFY signal for this property, and the callback
is no longer necessary.

Change-Id: I664714e22e607c747f144250cfb78de8c1d28686
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
2012-05-10 00:20:43 +02:00
Casper van Donderen
47799adc0d Doc: Move some remaining files over for modularization.
The files in this change were still in qtbase/doc/src or required for
it. qtbase/doc/src should now only contain example documentation and
images for the example documentation.

Change-Id: Ia7ca8e7fd2b316e77c706a08df71303bc8294213
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2012-05-09 22:43:31 +02:00
Martin Smith
81c68fe029 qdoc: Fixed three qdoc error problems
1. For QML properties documented in a .qml file,
qdoc no longer prints the error message that it
can't detect whether the property is read-only.

2. For QML properties documented in .cpp files,
qdoc now includes the file path and line number,
when it prints the error that it can't detect
whether the property is read-only.

3. qdoc also includes the completely qualified
property name in the error messages described
in 2.

Change-Id: If88381783fd0f29271f579ae170a0a6f4b1a7344
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2012-05-09 20:10:44 +02:00
Casper van Donderen
66ca9382c9 QDoc: Remove generateQmlDesc and use generateApiDesc instead.
generateQmlDesc was basically a copy of generateApiDesc. Just using
generateApiDesc also fixes a bug with the generation of a <shortDesc>
inside an <apiDesc>

Change-Id: I129a24ab0244283cc394c2afacc0f8227e4e5a88
Reviewed-by: Martin Smith <martin.smith@nokia.com>
2012-05-09 20:10:44 +02:00
Stephen Kelly
bbe9b28c0b Remove garbage.
Change-Id: I0801932ee9ce7002fdf897354f9e6e6d3999c8c2
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
2012-05-09 20:10:44 +02:00
Aron Rosenberg
6ccbfd6ca4 Fix various NTLM/Digest multi-threading and usage issues
- Fix multi-threading bug where NTLM/Digest auth would fail when
concurrent requests were on the wire. The fix for this is too not
internally share QAuthenticationPrivate pointers, since the challange
values would get overridden in different threads. This was failing
because the internal QAuthenticationPrivate members would have been
set with the status/values of the current request which would mess
up the state of the new request. As currently implemented, the helper
functions inside QAuthenticationPrivate can't call detach to implement
proper copy on write symantics.
- Fix issue where if user was set via constructor, the NTLM domain
parsing would not occur. Parsing of DOMAIN\user is now redone if
proxy type is determined to be NTLM.

Task-number: QTBUG-15472
Task-number: QTBUG-17322
Task-number: QTBUG-18794
Task-number: QTBUG-13063
Task-number: QTBUG-16585
Change-Id: I8a898c51fb04fab6fb08d96d88dd73be0c87af5d
Reviewed-by: Aron Rosenberg <aronrosenberg@gmail.com>
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
2012-05-09 20:10:44 +02:00
Alexis Menard
92d4e843bd Fix qDecodeDataUrl for already percentage encoded content.
If the url we pass as parameter already have percentage encoded data,
we don't want to decode it and call fromPercentEncoding. The test
coverage is not complete for qdataurl.cpp file but it is better than
previously and it will also protect us from future regressions.

Change-Id: I79f709f44bed1b7f274a3de639c7e291fa91a193
Reviewed-by: Thiago Macieira
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-05-09 20:10:44 +02:00
Martin Smith
4e9dc8b49d qdoc: Fixed a qdoc error problem
When an example was missing, qdoc printed
an error message without specifying the
location of the error. Now it includes the
file path and line number of the \example
command where the error can be fixed.

Change-Id: Ib75ffc467c0f266ed3939b8aa4b24800ec5eb92e
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2012-05-09 17:52:48 +02:00
Samuel Rødal
4ab7d53431 Compile fix for kms plugin.
Change-Id: I0ad9716273a7beb643fab5fafc7fcf4884c8a364
Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
2012-05-09 17:51:53 +02:00
Laszlo Agocs
52bc65dc8a Enable float coords in evdevtouch
There is no reason to truncate the touch position.

Change-Id: I2bdcd43d3bb06a664e909d92704a701ece603847
Reviewed-by: Paul Olav Tvete <paul.tvete@nokia.com>
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
2012-05-09 17:51:18 +02:00
Casper van Donderen
4f6b1cad56 QDoc: Use node name for page DITA title when name argument is empty.
When QML documentation is being generated from .qdoc files the 'name'
argument of the generateHeader() function is always empty, since the
plaincodemarker sets the plainFullTitle to "".

In that case the Node->name() should be used to specify the title of the
page, this will always be the first argument given to the \qmlclass qdoc
command.

Change-Id: If3e86ce59be1fdad608fab9f32fbe7bbca97aa93
Reviewed-by: Venugopal Shivashankar <venugopal.shivashankar@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-05-09 17:30:14 +02:00
hjk
cc8d9fb85e gettingStarted: sanitize parameter names and compile fix for Qt 5
Change-Id: I3f30ccee89b8add8718a9a36f0f16fa7b2e9bad1
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-05-09 17:16:55 +02:00
Friedemann Kleint
014ad6bf1b Windows: Disable Non-modal native file dialogs.
Disable dialogs, add explanatory comment. This is now
equivalent to Qt 4.

Change-Id: Ib6f4853d6f7ef1812bd5887d3ced8d7c8d1db5c8
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-05-09 16:46:11 +02:00
Bradley T. Hughes
ab947649eb QPA: Cleanup native dialog modal execution
Remove the _q_platformRunNativeAppModalPanel() function, together with
the launchNativeAppModalPanel() signal and
emitLaunchNativeAppModalPanel() slot, which were previously used to run
the modal loop inside the QDialog::exec() loop. This trick isn't
necessary anymore, so remove the mechanism and code related to it.

Rename QPlatformDialogHelper::platformNativeDialogModalHelp() to
exec_sys(). This function is now responsible for both showing the native
dialog and running the modal loop. QDialog:exec() now calls this
function if a native dialog is in use (it does not call
QEventLoop::exec() anymore).

The dialogResultCode_sys() function was unused, so it has also been
removed.

This commit also removes some unused private slots that were left over
from the port to QPA.

Note that the comments in the Cocoa plugin are still valid and relevant,
but this commit does not fix the scenarios mentioned. This will be done
in a future commit.

The Windows plugin needs minor changes. The QueuedConnections to
accept() and reject() cause the deliver to come too late, resulting in
crashes, hence the change to AutoConnection (which ends up being a
DirectConnection).

Change-Id: Ifc90325c945ca78737e60bf331929f03ecc52e0a
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
2012-05-09 13:42:03 +02:00
Bradley T. Hughes
9f2f7a8f72 Make sure QWidgetPrivate::hide_sys() really hides
When commit 55fa3c189f was merged from
api_changes, the conflict resolution left it possible for hide_sys() to
leave a visible window on screen. This happens when
Qt::WA_DontShowOnScreen is set on a visible widget. hide_sys() needs to
always hide the platform window if it is non-zero.

Change-Id: I3a1a882b66954e90d6ba80c657de69cae32e75a7
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-05-09 13:41:54 +02:00
Bradley T. Hughes
cebfd69ade Don't handle window events after Qt::WA_DontShowOnScreen is set
QWidget can set WA_DontShowOnScreen while visible, which generates
events when the QWidgetWindow is hidden. This causes
QWidgetWindow::handleExposeEvent() to clear the WA_Mapped flag which was
set by QWidgetPrivate::show_sys(). Once WA_Mapped is cleared, the
QWidget becomes non-functional, causing failures in at least
tst_QGraphicsProxyWidget::paintEvent(), since paint events are not sent
to widgets that don't have WA_Mapped set.

Change-Id: I2d3e5b3baffb07ab73f41520771866f181260bd2
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-05-09 13:41:49 +02:00
Friedemann Kleint
4e4403d69c No longer use deprecated methods for plugin loading.
Change-Id: I19c66b1c41ea4dd236726c86d7d071b210ec9244
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-05-09 13:40:23 +02:00
Friedemann Kleint
b316c3ac5e Improve widget geometry.
- Rename posFromMove to posIncludesFrame in Widgets and
  make the handling more fine-grained; try to clean it up
  as soon as the frame margins are known
  in QWidgetPrivate::fixPosIncludesFrame().
- Implement QWidgetPrivate::updateFrameStrut().
- Windows: Handle posIncludesFrame in window creation,
  notify changed geometry after setting window flags.
- XCB: Do not change the window gravity in propagateSizeHint()
  as this causes the window to jump around. Determine
  the gravity in window creation, leave it constant and
  fix the geometry when setting instead.
- Store the normal geometry when maximize/fullscreen
  state change events are received.
- Remove xfails from fixed tests

Task-number: QTBUG-25331
Task-number: QTBUG-24905
Task-number: QTBUG-24294

Change-Id: I89c7229d86aaf88f02247d63915da7905e4a27ea
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-05-09 13:40:16 +02:00
Stephen Kelly
465c9f4a7e Use bool for the template argument.
It is only ever called with 'true' or 'false'.

Change-Id: Ibaba1c964cebb3ac75a230471a7a6547c2245039
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
2012-05-09 12:54:08 +02:00
Eskil Abrahamsen Blomfeldt
4b09230d97 Avoid assert in QTextLayout for certain strings
As in other shapers, we need to make sure that the default
attributes of the first character is set before doing the
greek-specific composition (which will set the attributes
for characters > 0). The effect of this would be that
the clusterStart did not default to true in the start of
the string, and we would get an unexpected situation
in addNextCluster() in QTextLayout which would cause an assert.

The example in the task, which combines a greek polytonic
(dasia-oxia: u1FDE) with a regular combining diacritic
(asterisk under: u0359), is not a correct string, but should
not cause an assert.

Task-number: QTBUG-22864
Change-Id: Ieaff3cccbd10abc634e95e9a79dcde4c48504a3c
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-05-09 12:07:58 +02:00
David Faure
5ea4c3f148 Ensure qstring.h compiles with QT_NO_CAST_FROM_BYTEARRAY
19d160b72b broke it temporarily, and this wasn't detected by
tst_headersclean, because it sets QT_NO_CAST_FROM_ASCII too,
which disabled the faulty code.
So this adds a new unittest for QT_NO_CAST_FROM_BYTEARRAY alone.

Change-Id: Iaf7a36a1378e77188bcc636e5dc9a1f9b84f70a7
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2012-05-09 12:07:47 +02:00
David Faure
677858ad9e Fix QUrl::StripTrailingSlash for the case of no path at all.
Change-Id: I1fd0fe4b9b67996732c85c1792415e371e865595
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-05-09 12:07:33 +02:00
Casper van Donderen
a4d07f6c0b Doc: Add "make docs" targets for libraries.
Change-Id: I249c238f4986f443f84aaa6a3ac4ce102abff4db
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2012-05-09 08:37:35 +02:00
Casper van Donderen
6d4f2486d5 Doc: Modularize QtTest documentation.
This change moves the snippets to the modularized directories.

Change-Id: I917dd1dae5ee5d4b6bd5a0390783a8b9a99edc06
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2012-05-09 08:37:21 +02:00
Casper van Donderen
1794c3b7a1 Doc: Modularize QtPrintSupport documentation.
This change moves the snippets and images to the modularized
directories.

Change-Id: Ib8f8556bcef13593ee40ac1122d765ed307ecb93
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2012-05-09 08:37:10 +02:00
Casper van Donderen
03d81b0100 Doc: Modularize QtOpenGL documentation.
This change moves the snippets to the modularized directories.

Change-Id: Ifcf22fa3f234681f851d1e7eed5fe44e2e223ffd
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2012-05-09 08:36:59 +02:00
Casper van Donderen
97b5b80092 Doc: Modularize QtWidgets documentation.
This change moves the snippets and images to the modularized
directories.

Change-Id: Idec1afb9db7ea6add1ca4cf25ec4019d8bce0c4d
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2012-05-09 08:36:46 +02:00
Casper van Donderen
cfdc5628b1 Doc: Modularize QtGui documentation.
This change moves the snippets and images to the modularized
directories.

Change-Id: I5f86f598fbe7c47d632c613b85d94ced89ba2c29
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2012-05-09 08:36:34 +02:00
Casper van Donderen
3b8e6027c2 Doc: Modularize QtDBus documentation and add missing file to QtNetwork.
This change moves the snippets and images to the modularized
directories.

Change-Id: Idacff866735d00b048d65318bc4c3ee1dfa16310
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2012-05-09 08:36:17 +02:00
Casper van Donderen
4548022ee2 Doc: Modularize QtConcurrent documentation.
This change moves the snippets and images to the modularized directories.

Change-Id: If52f69c0f8bb4d2df4ee46f5524a82047ec214de
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2012-05-09 08:36:06 +02:00
Casper van Donderen
a409cebe3d Doc: Fix typo in QtNetwork qdocconf.
Change-Id: I759e8a77b0471d380ffd9f893ae5bb5ed0c5c992
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2012-05-09 08:35:55 +02:00
Casper van Donderen
7eca53b51a Doc: Modularize QtNetwork documentation.
This change moves the snippets and imagesto the modularized directories.

Change-Id: If14912692a7f72d7de345eaf88d9ec9752310fca
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2012-05-09 08:35:43 +02:00
Marius Storm-Olsen
9fde9ab167 Properly implement a 'make docs' target for subdirs and apps/libs
Only call qdoc for projects which sets the QMAKE_DOCS variable to
point to a qdocconf file.

Exclude examples/ and tests/ from the qdoc run, by adding
    no_docs_target
to CONFIG for those projects.

Change-Id: Ic856c8f19db59309302d0602b3e99735609e525a
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2012-05-09 08:34:42 +02:00
Girish Ramakrishnan
33edd606ae Fix qpa legacy headers installation
syncqt is run twice when using the top level configure (as in
the CI system). The pri_install_files and pri_install_pfiles
variables are not populated if the file already exists when
generating the compatibility headers.

Therefore, headers.pri ends up with different content in
each syncqt run. In the first run, the compatibility headers
are part of SYNCQT.HEADER_FILES. In the second run, they
are not part of it since the header files already exist.

Change-Id: I4908fb934a639a3c9f6af1796d56a40fd4df2d50
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com>
2012-05-09 06:42:25 +02:00
Marc Mutz
b58b777cb3 QtDBus: add member-swap to shared classes
Implemented as in other shared classes (e.g. QPen).

Change-Id: Ic827540b535fc5506165b5395b796a53a00bb096
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-05-09 02:39:08 +02:00
Konstantin Ritt
7fbc80f0eb QTextEngine: simplify the code a bit
by using QVarLengthArray so we can avoid the manual clean-up code.

Change-Id: I35e2f7150d777c1760f722553e6fe7a20f6ecc46
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
2012-05-09 02:28:49 +02:00
Martin Smith
025d544caa qdoc: Fixed qdoc error messages
qdoc prints many error messages without including the
source file path and the line number for where the error
occurs. This makes it difficult to find the place to
fix the error. This update corrects some of those error
messages. Further updates will fix the others.

Change-Id: I9c0eed96482c61643a2d83c5135368413e63ae52
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2012-05-09 02:28:44 +02:00
Lars Knoll
3db8f5fbb3 Remove qplatformdrag.h dependency in qguiapplication_p.h
Including a qpa/ header here doesn't really work very well
for other modules using qguiapplication_p.h.

Change-Id: I7620b40bc4731d5a74fe11537637f376c578a786
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
2012-05-09 02:28:39 +02:00