summaryrefslogtreecommitdiffstats
path: root/src/platformsupport/fontdatabases
Commit message (Collapse)AuthorAgeFilesLines
* [QBasicFontDatabase] Minor code clean-upKonstantin Ritt2015-07-312-7/+3
| | | | | | | We do not use supportedWritingSystems anymore -> simply remove. Change-Id: I8c8b4b0614bf396c943d810c396d18e2d0201eff Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
* Micro optimization to Basic/Android FDB::populateFontDatabase()Konstantin Ritt2015-07-311-11/+12
| | | | | | | | | Re-use QDir to check if dir exists (QDir::exists() also returns false if path specifies a file), and use somewhat faster QDir::entryInfoList() to iterate the font files. Change-Id: Iea3a6e5548928a01db71037425adf170cb722151 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
* Default implementation for QPlatformFontDatabase::fallbacksForFamily()Konstantin Ritt2015-07-312-10/+0
| | | | | | | | | ...mainly for platforms that do not provide a native/unified way to obtain system-defined font fallbacks list (ie !CoreText && !FontConfig). Change-Id: I23c5589d79ddecb6311ccc52ec8b29977f06d408 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
* Add missing Q_DECL_OVERRIDE in Cocoa specific header filesGabriel de Dietrich2015-06-242-40/+40
| | | | | | Change-Id: I91831390e9e0d97ab28f0e34ca0573fb2c84e954 Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Avoid signed-unsigned warning on OS XLaszlo Agocs2015-04-161-1/+1
| | | | | Change-Id: I61db35a367b1a96b13af08a5102d6b2a55c68517 Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
* Build bundled freetype as qt_helper_libKonstantin Ritt2015-03-271-6/+1
| | | | | | | | And thus do not disable warnings for the whole module when configured with -qt-freetype. Change-Id: I601a7c2990c8e3377531a28078db73800c138ec1 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
* Update Unicode data up to v7.0Konstantin Ritt2015-03-271-1/+24
| | | | | | | | | | | | | | | | | | | | | | * Two newly adopted currency symbols: the Azerbaijan manat and the Russia ruble * Pictographic symbols (including many emoji), geometric symbols, arrows, and ornaments originating from the Wingdings and Webdings sets * Twenty-three new lesser-used and historic scripts extending support for written languages of North America, China, India, other Asian countries, and Africa * Letters used in Teuthonista and other transcriptional systems, and a new notational set, Duployan For more details, see http://www.unicode.org/versions/Unicode7.0.0/ The Properties struct's .*Diff members were narrowed down to signed 15 bits and the unicodeVersion has been expanded to 8 bits. [ChangeLog][QtCore] Unicode data updated to v.7.0 Change-Id: I93ab6f79fa3b05f61abc7279f1d046834c1c1a0b Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Introduce src/3rdparty/freetype.pri for better maintenanceKonstantin Ritt2015-03-141-72/+1
| | | | | | | | This deduplicates qmake rules in platformsupport and platform plugins. Change-Id: Ie9c7d933c4433b96bf502e9753a12faa238b4569 Reviewed-by: Lars Knoll <lars.knoll@digia.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
* [QCoreTextFontDatabase] Minor clean-upKonstantin Ritt2015-03-072-7/+0
| | | | | Change-Id: I4579d4c4a516cc458aa7ddd8aca385b4ae21879b Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* [QCoreTextFontDatabase] Micro optimizationKonstantin Ritt2015-03-071-13/+19
| | | | | | | | With use of pre-allocated buffer, there is always a good chance to get the requested data with a single call. Change-Id: I8fed718e15970ab345ce96a9405578947b59f311 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* OS X: Fix mixing writing systems, ligatures and text formattingEskil Abrahamsen Blomfeldt2015-03-051-5/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | In QFontEngineMulti::stringToCMap() we call the primary engine's implementation of the same function. If this engine does not support the character in question, then it's supposed to clear the glyph array, otherwise there may be left-over junk in the glyph array from previous script items and the font selection algorithm will think it has already found a match for the character corresponding to the glyph position. The freetype engine, for instance, clears the respective entries in the array when it gets a 0 glyph from the font engine. In particular, this would happen when you had a ligature preceding an item that was shaped separately. The ligature (e.g. "fi") would set the first two slots of the glyph array, but later replace them with a single glyph. The next item would then get an offset of 1, i.e. pointing to the position in the glyph array where the glyph for i was originally contained. If this was not cleared, it would assume the primary engine supported the character. If the character was of an unsupported writing system, then you would get a box in place of it instead. [ChangeLog][OS X][Text] Fixed appending text with a different writing system and formatting to a latin ligature. Change-Id: Id8c81cdc8e2d8994cc1a999769fcae452c4f52ae Task-number: QTBUG-44708 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
* OSX: fix leaks due to missing NSAutoreleasePoolErik Verbruggen2015-02-261-0/+14
| | | | | | | env OBJC_DEBUG_MISSING_POOLS=YES qtcreator Change-Id: Ibbe5f42af5b94a439be3f0dd0f2b6e34bb1afd3f Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
* Correct typo in the Gujarati openType identififer.Michael Brüning2015-02-251-1/+1
| | | | | | | | Based on testing by Paresh Adhia. Task-number: QTBUG-44568 Change-Id: I0a84710bcda40f65b38c3b18f4d9b34f654e4c22 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
* QCoreTextFontEngine: Cache face_id.Robin Burchell2015-02-222-7/+6
| | | | | | | | | | | | This involves a significant amount of memory allocation, which made it rather more expensive than one would expect. The FT engine also caches face id, so this seems like a reasonable prospect. Increases delegates_text by another few ops/frame. Change-Id: If31e6b54478e4caf46a3a12a9ac45254a1f01525 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
* Fixed license headersJani Heikkinen2015-02-172-2/+2
| | | | | Change-Id: Ibebe1318d1c2de97601aa07269705c87737083ee Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
* Use C++ <cmath> instead of <math.h>Allan Sandfeld Jensen2015-02-161-1/+3
| | | | | | | | | | | | | | Including math.h can pollute the default namespace, and break some compilers if cmath versions of the method are declared as using. Switching to C++ math functions also greatly simplifies handling of float qreal as C++ automatically chooses the right method. [ChangeLog][QtCore][QtMath] qmath.h no longer includes math.h, so any sources depending on that indirect inclusion may fail to build. Change-Id: I4d0e331dafba354ec05dc5052e61ef4ff8d387fe Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
* FreeType: Support RGB rendering when not using FontConfigSérgio Martins2015-02-141-2/+12
| | | | | | | | | | | | | | | | | Windows+FreeType, Linux with -no-fontconfig and the forthcoming OSX FreeType engine can now use sub pixel rendering. The function to get the subpixel type is in QPlatformScreen because we're moving to per screen font settings in the future. This patch is safe, as no functionality is changed for existing users, if one wants sub pixel rendering they'll still have to pass -DFT_CONFIG_OPTION_SUBPIXEL_RENDERING to configure. Task-number: QTBUG-44269 Change-Id: Ib6c22d48a1b7c7b85ee316d5d9e3b6eae0c1ecc0 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
* Update copyright headersJani Heikkinen2015-02-1111-107/+91
| | | | | | | | | | | | | | | | | | Qt copyrights are now in The Qt Company, so we could update the source code headers accordingly. In the same go we should also fix the links to point to qt.io. Outdated header.LGPL removed (use header.LGPL21 instead) Old header.LGPL3 renamed to header.LGPL3-COMM to match actual licensing combination. New header.LGPL-COMM taken in the use file which were using old header.LGPL3 (src/plugins/platforms/android/extract.cpp) Added new header.LGPL3 containing Commercial + LGPLv3 + GPLv2 license combination Change-Id: I6f49b819a8a20cc4f88b794a8f6726d975e8ffbe Reviewed-by: Matti Paaso <matti.paaso@theqtcompany.com>
* Merge remote-tracking branch 'origin/5.4' into devFrederik Gladhorn2015-02-102-39/+42
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/3rdparty/harfbuzz-ng/harfbuzz-ng.pro src/gui/image/qimage_conversions.cpp src/gui/opengl/qopenglextensions_p.h src/gui/text/qtextengine.cpp src/network/ssl/qsslsocket_openssl.cpp src/plugins/platforms/eglfs/qeglfshooks_stub.cpp src/plugins/platforms/eglfs/qeglfsscreen.cpp src/plugins/platforms/eglfs/qeglfswindow.cpp src/plugins/platforms/windows/qwindowsfontdatabase.cpp src/plugins/platforms/windows/qwindowsfontdatabase_ft.cpp src/plugins/platforms/windows/qwindowsnativeinterface.cpp src/plugins/platforms/windows/qwindowsscreen.cpp src/plugins/platforms/windows/qwindowswindow.cpp src/plugins/platforms/windows/qwindowswindow.h src/plugins/platforms/xcb/qxcbdrag.h src/widgets/itemviews/qabstractitemview.cpp src/widgets/kernel/qwidget.cpp src/widgets/util/qsystemtrayicon_p.h tests/auto/corelib/itemmodels/qsortfilterproxymodel/tst_qsortfilterproxymodel.cpp Thanks to Friedemann Kleint for resolving the qwindowsfontdatabase.cpp conflicts. Change-Id: I937232c30523d5121c195d947d92aec6f129b03e
| * Only use Xft font settings as defaults, and let fontconfig overrideAllan Sandfeld Jensen2015-02-021-38/+38
| | | | | | | | | | | | | | | | | | | | | | | | On a GNOME or UNITY desktop, Qt will currently read font-settings from Xft and use those ignoring any fontconfig instructions. This patch changes the behavior so the Xft settings are only used as default, but any explicit overrides by fontconfig will take precedence. Task-number: QTBUG-43660 Change-Id: Ie10d5828cbfdd95fe5364c63a625d455d9213936 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
| * OS X/iOS: Fix stretched font renderingEskil Abrahamsen Blomfeldt2015-01-221-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Setting the stretch of a QFont did not work correctly on OS X or iOS. Two things are needed to make it work: First of all, we need to properly set the transform when creating the CTFont. In addition, we need to manually scale the advances, as CTRunGetPositions() does not do this for us. On OS X 10.6, however, there was a regression and CTRunGetPositions() would return scaled positions, so we exclude the step to scale the advances on this particular version. This is an adaptation of bc25cfdd65452efa226cbd544c9ae9803eb6748a in Qt 4. [ChangeLog][QtGui][OS X/iOS] Fixed a bug when rendering fonts that were set to be stretched. Task-number: QTBUG-43801 Change-Id: I4902a9f5e29299761e3c2c5c6d6d80ee1dea1a25 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
* | Don't build WinCE specific code on other platformsKonstantin Ritt2015-01-232-120/+0
| | | | | | | | | | | | | | Change-Id: I7ade08e57ea0c9c496e316ff0f856b8951eab61e Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: Björn Breitmeyer <bjoern.breitmeyer@kdab.com> Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* | Merge "Merge remote-tracking branch 'origin/5.4' into dev" into refs/staging/devSimon Hausmann2015-01-212-1/+12
|\ \
| * | Merge remote-tracking branch 'origin/5.4' into devFrederik Gladhorn2015-01-212-1/+12
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/global/global.pri src/corelib/global/qcompilerdetection.h src/corelib/global/qglobal.h src/corelib/tools/qdatetime.cpp src/plugins/platforms/xcb/qxcbscreen.h src/plugins/platforms/xcb/qxcbwindow.h src/widgets/dialogs/qcolordialog.cpp src/widgets/dialogs/qcolordialog_p.h tools/configure/configureapp.cpp Change-Id: Ie9d6e9df13e570da0a90a67745a0d05f46c532af
| | * Turn off font hinting when we do high DPI scalingPaul Olav Tvete2015-01-161-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | Font hinting depends on the specific pixel size, and ends up very wrong when the painter is scaled. Change-Id: I2007ec7e7ad8d52358d76e88e030ea4df7e91455 Task-number: QTBUG-43809 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
| | * QCoreTextFontDatabase: close memory leak in themeFontTim Blechmann2015-01-071-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | if the CTFontDescriptorRef is already contained in m_systemFontDescriptors we leak a reference, unless we explicitly release it. Change-Id: I5b263aa52b4433e7e28cc01164098892cc9cd2ae Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
| | * QCoreTextFontDatabase: release CTFontDescriptorRef references in dtorTim Blechmann2015-01-071-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | QCoreTextFontDatabase::m_systemFontDescriptors owns the references to the underlying CTFontDescriptorRef objects. in order to avoid a leak, we should release them Change-Id: I8fc6c158908e0173696cd91058ac34efb3de01d5 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
* | | MSVC: Disable warning C4996 for freetypeKai Koehne2015-01-191-1/+3
|/ / | | | | | | | | Change-Id: I22be0faca29989142cd2fa0eaed6846fc40d3f4b Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
* | Fix bugs generating PDF on CocoaJames Turner2015-01-172-3/+67
| | | | | | | | | | | | | | | | | | | | Provide real implementations of: properties(), faceId() and getUnscaledGlyph Task-number: QTBUG-10094 Change-Id: I5899f247742406de53c68c5cd04fee6fb9b6b7d2 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com> Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
* | Drop modularization leftoversKonstantin Ritt2014-12-121-3/+0
| | | | | | | | | | Change-Id: I39c9e1fa44993fc024fed9309bea0da6f4534592 Reviewed-by: Pierre Rossi <pierre.rossi@theqtcompany.com>
* | Add QFont::Weight enum valuesPierre Rossi2014-12-125-78/+59
| | | | | | | | | | | | | | | | | | | | And try to make good use of them in order to match the QFont request more closely. Task-number: QTBUG-38482 Change-Id: I768dfa8828e370d77a1c17ecf4796d750b3edd9b Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
* | Make more font databases report fontsAlwaysScalable()Konstantin Ritt2014-12-092-0/+6
| | | | | | | | | | | | | | | | DirectWrite and CoreText supports scaling of non-scalable fonts. Change-Id: I910c6a35e3d94c31efa9b26dd89bcb027951ac99 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@theqtcompany.com> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
* | Add Q_DECL_OVERRIDE in the src subdirectoryOlivier Goffart2014-12-033-15/+15
| | | | | | | | | | | | | | | | | | | | Done automatically with clang-modernize on linux (But does not add Q_DECL_OVERRIDE to the function that are marked as inline because it a compilation error with MSVC2010) Change-Id: I2196ee26e3e6fe20816834ecea5ea389eeab3171 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Merge remote-tracking branch 'origin/5.4' into devFrederik Gladhorn2014-11-271-15/+21
|\| | | | | | | Change-Id: Id20053d261b4fbbcc0ac8ba49dd3ef2253fa4b95
| * Windows: Respect hinting preferences with FreeType engine.Sérgio Martins2014-11-251-15/+21
| | | | | | | | | | | | | | | | | | | | One of the fontEngine()'s methods was missing hinting. This bug only manifests on Windows because on Linux QFontConfigDataBase already sets hinting on both code paths. Task-number: QTBUG-42534 Change-Id: I3a66a9d4aaa5e390fee305a3d5aacfeba38a1fc3 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
* | QFontconfigDatabase weight-matching refactoringPierre Rossi2014-11-271-19/+22
| | | | | | | | | | | | | | | | | | Factor out the piece-wise linear weight matching in an attempt to make it less error-prone to add new weights to the QFont::Weight enum. Change-Id: I5fefdba67a60a061f8b9104393194a27bc8c6e35 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
* | Merge QFontEngineMultiBasicImpl and QFontEngineMultiKonstantin Ritt2014-11-262-4/+4
| | | | | | | | | | | | | | Minor refactoring also improves the behavior and the code readability. Change-Id: Id89dd224f4132a4c0dfbc16f414ef42cc8d8a4da Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
* | Merge remote-tracking branch 'origin/5.4' into devFrederik Gladhorn2014-11-243-2/+6
|\| | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/io/qiodevice.cpp src/plugins/bearer/linux_common/qofonoservice_linux.cpp src/plugins/bearer/linux_common/qofonoservice_linux_p.h src/plugins/platforms/android/qandroidplatformtheme.cpp src/tools/bootstrap/bootstrap.pro src/widgets/styles/qmacstyle_mac.mm Change-Id: Ia02aab6c4598ce74e9c30bb4666d5e2ef000f99b
| * OSX: implement QFontMetrics::maxWidth().David Faure2014-11-241-1/+4
| | | | | | | | | | | | | | | | | | | | | | CoreText doesn't seem to provide us with a "maximum advance" value, but 0 is really wrong, it leads to QLineEdit::minimumSizeHint() being 0 since it's based on maxWidth(). It even led to a negative min width with setTextMargins(-1, 0, -1, 0). Change-Id: I4faf8ecfb6d91e9dff66ec63651d003014503cb4 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
| * Allow to use FT_Library_SetLcdFilter in bundled FreeType.Sérgio Martins2014-11-131-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | For a default Qt build this change is a NOP, ftlcdfil.c is ifdefed by FT_CONFIG_OPTION_SUBPIXEL_RENDERING, which we don't define. But for users who changed ftoption.h, or are using 3rdparty/freetype/devel/ftoption.h instead of 3rdparty/freetype/include/freetype/config/ftoption.h they can now enable Subpixel rendering without getting a build error. Change-Id: I547e8a20514fcb97e4e56cb0100e9c2ed525f483 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com> Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
| * fontconfig: do not assume the path to a font file is Latin1-encodedShawn Rutledge2014-10-291-1/+1
| | | | | | | | | | | | | | Task-number: QTBUG-42249 Change-Id: Ie5d41ed26a69103991a5189c4f42aa37ac73de26 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com> Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
* | Merge remote-tracking branch 'origin/5.4' into devFrederik Gladhorn2014-10-273-4/+23
|\| | | | | | | | | | | | | Conflicts: src/gui/text/qfontdatabase.cpp Change-Id: I6ac1f55faa22b8e7b591386fb67f0333d0ea443d
| * Add support for more font weights internallyPierre Rossi2014-10-242-1/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We should have more font weights in QFont::Weight to allow for finer grained control. For the time being, we can simply use intermediate weights to better support the different font weights falling in between the ones defined in QFont::Weight. Also amend the documentation to clarify the fact that QFont supports and can return weights falling outside the predefined values, which is already the case (e.g. when using fontconfig). Done-with: Gabriel de Dietrich Change-Id: I693cdd48b8b77e7ed550cdf991227bcb819d8e7b Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
| * Respect NoSubpixelAntialias in QCoreTextFontEngine::imageForGlyphAllan Sandfeld Jensen2014-10-241-3/+4
| | | | | | | | | | | | | | | | | | | | Adding handling of the new QFont enum NoSubpixelAntialias in QCoreTextFontEngine::imageForGlyph. Task-number: QTBUG-40396 Change-Id: I421c38554360f5e2f822a18117190456c4d04b25 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com> Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
* | Merge remote-tracking branch 'origin/5.4' into devFrederik Gladhorn2014-10-203-151/+145
|\| | | | | | | Change-Id: If7e51514ed6832750e3ad967e4d322ccf920d2bb
| * CoreText font database: Use dynamic type on iOS to resolve theme fontsRichard Moe Gustavsen2014-10-191-5/+45
| | | | | | | | | | | | | | | | | | Use Dynamic Type to resolve theme fonts, so that we get the correct font sizes and styling based on user preferences in Settings app. Change-Id: I2222199a5ba21badb2e3696993eee503e720c476 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
| * Make font hinting and antialiasing size dependent when using FontConfigAlexander Volkov2014-10-171-0/+3
| | | | | | | | | | | | | | | | | | Add the pixel size of the font to the search pattern to get size dependent font settings. This patch allows to take into account KDE settings for font sizes which should be excluded from antialiasing. Change-Id: I8bd8b7b3d585009d0a39db631cd02b7970537f5c Reviewed-by: Allan Sandfeld Jensen <allan.jensen@digia.com>
| * Reduce code duplication in QFontconfigDatabaseAlexander Volkov2014-10-162-146/+97
| | | | | | | | | | | | | | Extract common part from fontEngine() methods to setupFontEngine(). Change-Id: Id4aee43b2a477f9fd40dc564d96a2335bfde9e22 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@digia.com>
* | Merge remote-tracking branch 'origin/5.4' into devFrederik Gladhorn2014-10-091-3/+3
|\| | | | | | | Change-Id: I05fcd8dc66d9ad0dc76bb7f5bae05c9876bfba14
| * Don't use QStringLiteral in comparisonsMarc Mutz2014-10-091-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | For QLatin1String, operator== is overloaded, so comparing to a latin-1 (C) string literal is efficient, since strlen() is comparatively fast. OTOH, QStringLiteral, when not using RVO, litters the code with QString dtor calls, which are not inline. Worse, absent lambdas, it even allocates memory. So, just compare using QLatin1String instead. Change-Id: I7af3bf3a67c55dae33ffaf9922d004fa168a3f9c Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>