summaryrefslogtreecommitdiffstats
path: root/src/platformsupport
Commit message (Collapse)AuthorAgeFilesLines
* Remove unused file.Frederik Gladhorn2012-09-111-94/+0
| | | | | Change-Id: I402f1d3216129d693a4b0d33e015fd047c7d2298 Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
* Fix printing with OS X platform pluginEskil Abrahamsen Blomfeldt2012-09-101-1/+13
| | | | | | | | | | | | | | | | | | | | | | | | | Since we do not pass in the destination dpi to CoreText when making the font, we need to pass in a point size which is scaled to include the dpi change. The default dpi for the screen is 72, thus the scale factor is destinationDpi/72. Since pixelSize = pointSize / 72 * dpi, the pixelSize is actually the scaled point size for the destination dpi, thus we pass in that instead. Note that this only works because the default screen dpi on Mac is 72. You can look at the CoreText font database in Qt 4.8 to verify that the same trick is used there. When 96 dpi is explicitly set (specifically for autotests), we need to fall back to the old behavior, since the OSX platform plugin will then use 72 for some fonts and 96 for others making it impossible to detect the DPI in a consistent way. The correct fix would be to pass in the dpi to the function, but until that fix can be made, we just use the old code to keep the autotests passing. Task-number: QTBUG-25555 Change-Id: Id20a273549c3abf3db56ef1c48553c0958c48d61 Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org> Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
* Fix rounding error when drawing scaled text on OS XEskil Abrahamsen Blomfeldt2012-09-101-6/+6
| | | | | | | | | This especially affected the print preview dialog, where certain characters would be grossly mispositioned. Task-number: QTBUG-27131 Change-Id: I385474a6f609a8f4291988206c7e63a0747673dd Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
* Removing duplicate includesSergio Ahumada2012-09-091-1/+0
| | | | | | | Do not include a header more than once Change-Id: Ia2e5d66e72988ad833cf5177a3f8aa988bf510e9 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Use QStringList::join(QChar) overload where applicable [QtWidgets]Marc Mutz2012-09-072-2/+2
| | | | | | | | | | | This is an automated change performing the following replacements: join\("(.)"\) -> join('\1') join\(QLatin1String\("(.)"\)\) -> join(QLatin1Char('\1')) join\(QStringLiteral\("(.)"\)\) -> join(QLatin1Char('\1')) Change-Id: Ia30048e0c40967dc86a4e4ad26ac02ab67519096 Reviewed-by: João Abecasis <joao.abecasis@nokia.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* Use QStringList::join(QChar) overload where applicable [QtGui]Marc Mutz2012-09-072-2/+2
| | | | | | | | | | This is an automated change performing the following replacements: join\("(.)"\) -> join('\1') join\(QLatin1String\("(.)"\)\) -> join(QLatin1Char('\1')) join\(QStringLiteral\("(.)"\)\) -> join(QLatin1Char('\1')) Change-Id: Id8d43c1b1ca9cd3aa0b4eedca6709b6287a9bc98 Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
* Enable autodetecting of EGL event for desktop GLJorgen Lind2012-09-071-9/+8
| | | | | | | | And only use the QT_CONFIG,egl syntax in eglconvenience Change-Id: I81c0602334714f4b27a7e90e7b5859c989e6bd63 Reviewed-by: Paul Olav Tvete <paul.tvete@nokia.com> Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
* Mark plugin class docs as internal.Frederik Gladhorn2012-09-075-15/+8
| | | | | | Change-Id: I2eb0a6ce4108774377df1296de4152715b65de6e Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com> Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
* Use true and false in preference to TRUE and FALSESergio Ahumada2012-09-051-1/+1
| | | | | | | | The TRUE and FALSE macros are obsolete and should be replaced with true and false (all lower case) respectively. Change-Id: Iee352e8173500683e6319be0abbf5bacf29016e0 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* fbbackingstore: Don't overload inherited virtual functionKent Hansen2012-08-242-3/+2
| | | | | | | | The QPlatformBackingStore::endPaint function does not take any parameters. Change-Id: If15d7824d65a52c38332c6676c12a954469a58ab Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Replace deprecated ATS calls with CTFontManager calls in 10.8Jiang Jiang2012-08-211-1/+48
| | | | | Change-Id: I81c0361059319575e55621123d40b7c6f3c6b699 Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
* Fix freetype font rendering for Windows CEAndreas Holzammer2012-08-202-0/+121
| | | | | | | | | | Windows CE does not have support for GetGlyphOutline. So addGlyphToPath will not work. QML uses it for their distance field rendering. One option to bypass this issue is to use freetype as rendering backend. Change-Id: I965254344945cbdad771a5d505fb61c1cc2087df Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Doc: Fix spelling errorsSergio Ahumada2012-08-171-1/+1
| | | | | Change-Id: Ibae8d10183f6b15a16b1499daa2df8802dbb014e Reviewed-by: Geir Vattekar <geir.vattekar@nokia.com>
* QtGui: use new qEnvironmentVariableIsEmpty()Marc Mutz2012-08-141-2/+2
| | | | | | | | In particular, static bool showRasterOverlay is safer. Change-Id: I9df6c9a9a56d2e61b13391b6889c0ac6e259e801 Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QtCore: use new qEnvironmentVariableIs{Set,Empty}()Marc Mutz2012-08-141-1/+1
| | | | | | | | | | | | In particular, qEmergencyOut() is now completely exception-free. Incidentally, this patch shows that Qt isn't consistent in how it treats empty environment variables used as flags, but that is something for a separate commit. This patch aims to be behaviour-preserving, except in exceptional circumstances, of course. Change-Id: Ie106e7b430e1ab086c40c81cc1e56cd0e5400cb4 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Add Linux Accessibility BridgeFrederik Gladhorn2012-08-1417-0/+4296
| | | | | | | | This is a plugin that bridges the QAccessible world to AT-SPI 2 on Linux. Change-Id: I7af22621ee6a3cefc723b137b7f227a611cf6641 Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
* rename qt_module_config.prf => qt_module.prfOswald Buddenhagen2012-08-081-1/+1
| | | | | | | this is more logical, following the qt_plugin and qt_tool scheme. Change-Id: Ib3b2abec6728cdab260e15128b1cd78e8e6f5d6a Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
* Revert "Move QWindowSystemInterface out of qpa."Paul Olav Tvete2012-08-036-6/+6
| | | | | | | | | | | | | | This reverts commit 784a877d3cd9a1a75aca9c83146389503a966071. Conflicts: src/plugins/platforms/cocoa/qcocoawindow.mm src/testlib/qtestkeyboard.h src/testlib/qtestmouse.h src/testlib/qtesttouch.h Change-Id: Iebfed179b3eb7f30e4c95edcae5a8ad6fd50330e Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Fix default font for X11.Friedemann Kleint2012-08-022-3/+43
| | | | | | | | | | | Qt 5 X11 applications currently have differing fonts since they no longer read ~/.config/Trolltech.conf. Set the default font value 4.8 would return for XRender/FontConfig in the theme classes. Change-Id: Ie0a77e6781a47a68fd67895821ab1773c25e0470 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com> Reviewed-by: hjk <qthjk@ovi.com>
* Send the native scancode in evdevkeyboardLaszlo Agocs2012-07-282-4/+8
| | | | | | | | | | | | | | Until now the native scancode was not specified which meant when qwindow-compositor (or any other Qt-based compositor using the standard Wayland protocol, i.e. sendKeyPress() and such) tried to send the native scancode over to the clients, all it got was a code of 0. This fixes keyboard input when running qwindow-compositor on top of kms and EvdevKeyboard. Change-Id: I5d9a882f249634fb7584900b5f298f794befee3b Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* WindowSystemInterface::sendWindowSystemEvents(): Remove unused parameter.Friedemann Kleint2012-07-232-4/+3
| | | | | | | | No need to pass the dispatcher. Get rid of Windows logic to maintain a stack of dispatcher associated with flags. Change-Id: Ic2daad4b6762a46fac3274937effc188af436c9a Reviewed-by: David Faure <faure@kde.org>
* Create CMake files conditionally on the internal_module CONFIG option.Stephen Kelly2012-07-231-7/+1
| | | | | | | | | This includes a revert of 195df6e8e0ffb2636cfe395f560eb73c05a54b61 so that the solution scales better to other Qt modules, and other logic related to 'internal' modules. Change-Id: Ie4c1f10d20953aeb15438273081a810ab8bc9ec9 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Don't create cmake files for QtPlatformSupport.Stephen Kelly2012-07-201-0/+6
| | | | | | | It is for internal use only, not third party use. Change-Id: I7a8dbc930e794ccdad4cc5591b454a640b921bb0 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Move QWindowSystemInterface out of qpa.Stephen Kelly2012-07-196-6/+6
| | | | | | | | Public QtTest headers require it, so all unit tests would have to use private Qt headers otherwise, which is not practical. Change-Id: I5d4466ec30b6a57ebdfc34413e716e657eb51368 Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
* input/evdevmouse: normalize signals/slotsMarc Mutz2012-07-131-2/+2
| | | | | | | | | This is the result of running util/normalize --modify from Qt 4.7 with manual review. Change-Id: I4afac23e897404ac7efb5b4a89493a2c15e3c670 Reviewed-by: Laszlo Papp <lpapp@kde.org> Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* linuxfb: fix style in QFbCursorGirish Ramakrishnan2012-07-132-45/+46
| | | | | | | Fix coding style, constness, m-prefix for member variables. Change-Id: I9d75b410b398e5c3084b086b41884f2a0ddd6e5e Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
* linuxfb: Remove QFbWindow::setVisibleGirish Ramakrishnan2012-07-113-13/+2
| | | | | | | | | | | | | | QFbWindow::setVisible doesn't call into the base class implementation and thus suppresses the delivery of the expose event. It turns out we don't need to track the visiblity at all since the base QPA code tracks this already. After this change, windows are now render on the framebuffer. Change-Id: Ifcfc730456883eb423d79479bd0b04330b8c2d72 Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com> Reviewed-by: Thomas Senyk <thomas.senyk@nokia.com> Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
* linuxfb: Add m prefix to all member variablesGirish Ramakrishnan2012-07-114-69/+69
| | | | | | | | Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com> Reviewed-by: Thomas Senyk <thomas.senyk@nokia.com> Change-Id: Id1eb31ff15713c4ce3659f71d23a18ecf42f6bd3 Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
* linuxfb: raise and lower should take QFbWindow as argsGirish Ramakrishnan2012-07-113-25/+23
| | | | | | | | Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com> Reviewed-by: Thomas Senyk <thomas.senyk@nokia.com> Change-Id: I856ea141a39f23968169ba29be1445fa089f7f02 Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
* linuxfb: let the window register itself with the screenGirish Ramakrishnan2012-07-111-0/+2
| | | | | | | | | This moves the addWindow call to the platformsupport code. Change-Id: Icf9175ae86ad880248036362e9c5f40124744272 Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com> Reviewed-by: Thomas Senyk <thomas.senyk@nokia.com> Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
* linuxfb: Rework screen codeGirish Ramakrishnan2012-07-112-67/+35
| | | | | | | | | | Move the screen code from integration. The design philosophy is that QFbScreen takes care of generic framebuffer composition. QLinuxFbScreen is just an linux framebuffer adaptation layer. Change-Id: I8456c13826f06621037dd77fe0d0bd8873806c96 Reviewed-by: Thomas Senyk <thomas.senyk@nokia.com> Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
* linuxfb: remove mScreens from QFbWindowGirish Ramakrishnan2012-07-113-65/+33
| | | | | | | | | | A QWindow can only be in one QScreen, so it makes no sense to track a list of screens. Change-Id: I341a67afa90c7fbbbd95786b43d0a322fc1ddba2 Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com> Reviewed-by: Thomas Senyk <thomas.senyk@nokia.com> Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
* linuxfb: create image only on resizeGirish Ramakrishnan2012-07-112-11/+3
| | | | | | | | Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com> Reviewed-by: Thomas Senyk <thomas.senyk@nokia.com> Change-Id: I04cd75f96cf755ef0c12fad70e3bbd96fbbed9a1 Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
* linuxfb: don't store window in backingstoreGirish Ramakrishnan2012-07-115-17/+16
| | | | | | | | | | | The backing store already knows about the window. Also, rename surface to backing store in QFbWindow. Change-Id: I3701b3cdbdc228200da9b93b13037655dc436f53 Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com> Reviewed-by: Thomas Senyk <thomas.senyk@nokia.com> Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
* linuxfb: make platformsupport convenience compileGirish Ramakrishnan2012-07-1113-722/+1037
| | | | | | | | | | | Rename fb_base to fbconvenience in-line with the other convenience classes. The code only compiles, it is not known to work. Change-Id: If51700ddf0a11ace5129af6f00f34fd895a6a4df Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com> Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
* Fix the UCS-2 surrogates handling in Q*FontEndine*::stringToCmap()Konstantin Ritt2012-07-101-0/+2
| | | | | | | | | by making sure QGlyphLayout's numGlyphs member is properly initialized if the string-to-glyphs lookup was successful (tip: a surrogate pair produces a single glyph index). Change-Id: I01953f3b6281d79e1a214bfab0424e796d94769a Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
* Move ShaperFlags enum from QTextEngine to QFontEngineKonstantin Ritt2012-07-102-6/+6
| | | | | | | | These flags are specific to font engine(s) and has nothing to do with the text engine or the text layout. Change-Id: I4bb793c3c634b3cf0ae0a8a8c23b946fad5874b6 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
* Remove Library dependency on SettingsTasuku Suzuki2012-07-092-0/+10
| | | | | | | | made QLibraryInfo available with QT_NO_SETTINGS. QKdeTheme is removed when QT_NO_SETTINGS is defined. Change-Id: I63d619bb305e6c23985d9ea50c72d39a697b7a4b Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* android: work around android's linux/input.h being retarded.Robin Burchell2012-07-062-0/+35
| | | | | | | | It seemingly doesn't include many of the required defines for evdev, so do what everyone else seems to do, and work around it. Change-Id: I4a6ffb548c7370f675c736177b63220f034d06b8 Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
* Suppress QWindowSystemInterface inclusion warnings.Girish Ramakrishnan2012-07-037-7/+7
| | | | | | | | | | | | | Since QWindowSystemInterface is now part of QPA API. The correct inclusion is: #include <qpa/qwindowsysteminterface.h> #include <qpa/qwindowsysteminterface_p.h> Bulk of the work was done by: find . -type f | xargs sed -i -e 's,#include <\(QtGui/\)\?QWindowSystemInterface>,#include <qpa/qwindowsysteminterface.h>,g' Change-Id: If75fc32611e72ef1cf58505794def375b1acf74a Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Remove _qpa from cpp filenamesGirish Ramakrishnan2012-07-032-1/+1
| | | | | | | | 36547f4eff44361f7a6acd0cff107c0e47561f93 removed the _qpa from .h files and promised to remove it from .cpp files at a later date. Change-Id: I24a5c3796f6b07dd9a1931b699f3212d315edb12 Reviewed-by: Andrew Stanley-Jones <andrew.stanley-jones@nokia.com>
* Clean up the EXPORT macros in qglobal.h.Thiago Macieira2012-06-291-1/+1
| | | | | | | | | | | | | | | | | | | | QtPlatformSupport is a static library. It should never export anything, so Q_PLATFORMSUPPORT_EXPORT is unnecessary. QtSql, QtXml, QtDBus, QtOpenGL and QtPrintSupport now have the macros on their own source trees. It's possible these modules might be separated out from qtbase in the future. For QtDBus, the macros are moving back to where they used to be. This also leaves qglobal.h only creating the macros for QtCore, QtGui, QtWidgets and QtNetwork, the core libraries. Q_CANVAS_EXPORT, Q_OPENVG_EXPORT and Q_COMPAT_EXPORT aren't used anywhere in the Qt sources, so simply delete them. And the Q_QUICK1_EXPORT macro in the static section was wrong, so remove it too. Change-Id: I50bdf86e783338f814903b25979721f788a7becf Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Change CONFIG += staticlib to CONFIG += staticThiago Macieira2012-06-281-1/+1
| | | | | | | That's the targetted, correct way of defining a static library. Change-Id: I43c23bf7e1bc5fb07bbb55720a320eaca680b038 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Move QPlatformInputContextPlugin/Factory to QtGuiWeng Xuetian2012-06-286-333/+0
| | | | | | | | | | | | | PlatformSupport is no longer shared and there should be no plugin factory in it otherwise it will break plugin loading. Since PlatformInputContext is already in QtGui, so move QPlatformInput- ContextPlugin/Factory to resolve the platforminputcontexts plugin loading problem. And remove platformsupport-private dependency from existing inputcontexts plugin. Change-Id: If4cb766470b8f9c8b72157da86cb33b4e1ff09e3 Reviewed-by: Pekka Vuorela <pekka.ta.vuorela@nokia.com>
* Set window's surface format to support alpha channel.Gatis Paeglis2012-06-281-0/+4
| | | | | | Task-number: QTBUG-26114 Change-Id: I33f191373327832fb9d3054366412ec5be855cff Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Add const & to foreach 'iterators'Albert Astals Cid2012-06-272-2/+2
| | | | | | | Change-Id: I8c0600dfd919f45d14a0011f2da9b9fe0b9a0df3 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com> Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
* Fixed missing way of choosing EGL renderable type with QSurfaceFormat.Samuel Rødal2012-06-273-8/+41
| | | | | | | | | | | This has been long overdue, since EGL now lets you choose between desktop and ES based OpenGL. We also add OpenVG for those who want to use raw OpenVG with a QOpenGLContext. The underlying EGL API for using OpenGL / OpenVG is the same, with eglMakeCurrent() and eglSwapBuffers(). Change-Id: Ib0146b3fde5fe632069ebf99e7712f496ee7ea4d Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Don't try build devicediscovery if evdev is not available.Robin Burchell2012-06-261-1/+1
| | | | | | | Fixes build on Android. Change-Id: I1e6af972e8c29dd4c38773985e8f201064c2164f Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
* fix misnomer: qt_module.prf => qt_build_config.prfOswald Buddenhagen2012-06-191-1/+1
| | | | | | qt_module suggests to be congruent to qt_plugin. Change-Id: I629530bcbe2ba6c0adbdc11a275119c8aff0c953
* automatically add QT_BUILD_FOO_LIB to DEFINESOswald Buddenhagen2012-06-191-2/+0
| | | | | Change-Id: I35d9861e48469eb5cc8824e361450684047e6559 Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>