summaryrefslogtreecommitdiffstats
path: root/src/platformsupport
Commit message (Collapse)AuthorAgeFilesLines
* QCoreTextFontDatabase: reduce memory consumptionJ-P Nurmi2014-09-041-0/+3
| | | | | | | | | ATSFontNotify() allocates over 30MB for no apparent reason for applications that don't register fonts. Change-Id: I7bbc97f53b76be1e638de8ca0d1be3a08586cf00 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com> Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* QCoreTextFontDatabase: Remove number type asserts.Morten Johan Sørvig2014-08-281-2/+0
| | | | | | | | | On iOS 8, the value 0 is returned as a kCFNumberIntType. The code still works - CFNumberGetValue converts it to a 0.0 double. Change-Id: Ic50900b22e4fa19ad1481e8e0e293559bbfd8cd2 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
* Font Database: Add support for private, system UI font familiesGabriel de Dietrich2014-08-112-24/+170
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We introduce QPlatformFontDatabase::isPrivateFontFamily() to allow testing for private, system UI font families. Both QFontComboBox and QFontDialog need to filter out those private font families which, by definition, should be hidden from the end user. (The textedit example had to be updated to fix the issue where the default font would be private. In 5.4, we will be adding an equivalent, public API in QFontDatabase, and a better solution for the textedit example and QTexEdit in general). In particular, on OS X and iOS, private fonts are used for the system UI font. Those have their font family name prefixed by a dot. QCoreTextFontDatabase knows about this, and makes sure those are tested positive as private font families. In order to have a cleaner layer separation, we moved the QPA theme font resolution from the platform theme classes into QCoreTextFontDatabase for both Cocoa and iOS QPA plugins. In both cases, we use CoreText's CTFontCreateUIFontForLanguage(), that nicely maps to the HITheme API we were using so far on Mac. That means one HITheme dependency less. We also cache the font descriptors we get for these font for each time QCTFD::populateFamilies() gets called. (While not common, this currently happens in auto-tests, like tst_QFontDatabase, and could happen in actual applications -- specially when adding and removing application fonts.) Change-Id: Ic6f0b60f9f597afee1a43596a669742dc546b97f Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
* Add missing power button keycode to keymapRainer Keller2014-07-311-0/+1
| | | | | | Change-Id: I03682716aaea8344ebb5b71dcea5fe18babcd610 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@digia.com> Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* QCoreTextFontDatabase: Fix font weight value when populating a familyGabriel de Dietrich2014-07-291-3/+13
| | | | | | | | | | kCTFontWeightTrait returns a normalized value between -1.0 (lightest) and 1.0 (heaviest), 0.0 being the regular font weight. The threshold values used in this change have been estimated from the weight values of fonts from the Helvetica Neue and Myriad Pro font families. Change-Id: I49de8e8bd5894107de4842aeda7ace2e83f95be3 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
* Accessibility Linux: Fix crashes when accessing invalid functionsFrederik Gladhorn2014-07-031-6/+13
| | | | | | | | | | There is no way to prevent ATs from calling random functions on DBus. While these functions shouldn't exist when we don't advertise the interface, they should just fail gracefully. Task-number: QTBUG-40044 Change-Id: Ia29b49b16feabc0beb80007456e53497f230c7d4 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* Fix visual selection with EGL on xcbLaszlo Agocs2014-06-061-25/+14
| | | | | | | | | | | Using a 24-bit visual for 8888 configs is wrong since we loose the alpha channel. This breaks translucent windows and, among others, leads to not showing drag pixmaps (that typically have transparent areas) properly. Change-Id: I516c84327680b76996b622831e431c29d840471e Task-number: QTBUG-35126 Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
* egl cursor: The sampler is a uniform not an attributeLaszlo Agocs2014-05-191-1/+1
| | | | | Change-Id: Ibae21653040f1d8dff2d2c0b7c1b2812d9e14551 Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* Accessibility: Update ComboBox text on arrow keysFrederik Gladhorn2014-05-161-7/+20
| | | | | | | | | | Use ValueChanged to notify of changes in the ComboBox. On Linux we need to update name and then send selection-changed for Orca. Task-number: QTBUG-36814 Change-Id: Icdd34adddeac532476a6dd910d1e8bd33bcd590b Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
* qmacmime: rename and move QMacPasteboardMimePlainText to the cocoa pluginRichard Moe Gustavsen2014-05-161-62/+0
| | | | | | | | | | | | | | | | com.apple.traditional-mac-plain-text is not in use on iOS according to Apples UTType reference. So we enable it only for OS X by moving it into the cocoa port. The order in which we instanciate convertors matters when the application is reading data from the pasteboard. But since QMacPasteboardMimePlainText should come before the other "text/plain" convertors on OS X, moving it to the cocoa port is safe as those convertors are instanciated after those in qmacmime. Change-Id: I76b9b14e5ce78f34e0f1ecbfee71e48a27a4687b Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
* qmacmime: add support for public.rtfRichard Moe Gustavsen2014-05-161-0/+88
| | | | | | | | | Application like Safari on iOS posts rtf to the pasteboard when copying html. With this converter added, you can then paste rtf as html into Qt Change-Id: I6b62bcc9cfc0b16a47d44bd8d74062226522526d Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
* qmacmime: add support for public.textRichard Moe Gustavsen2014-05-141-0/+65
| | | | | | | | | | | | | | | | Copying a URL from Safari to Qt app does not work. The reason is that it lies on the pasteboard as public.text, which we don't support. This patch will implement support for public.text. The UTI public.text is documented as text with an unspecified encoding. On iOS, this turns out to be UTF8 (which also matches [UIPasteboard generalPasteboard].string). Task-number: QTBUG-38551 Change-Id: I216dab206d3bff2dde99927ed7e5a3d85309f2a2 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
* Fix crash when loading invalid font data in QRawFontEskil Abrahamsen Blomfeldt2014-05-141-0/+3
| | | | | | | | | | | | | | | When passing invalid data to QRawFont, we need to fail gracefully and mark the font as invalid, instead of crashing. This crashed because of different missing sanity checks in the Windows and FontConfig font databases. [ChangeLog][Text] Fixed crash when trying to load a font from invalid data. Task-number: QTBUG-37190 Change-Id: I62c81217ec7d873350b575c9d4ae8e6f0a939540 Reviewed-by: Michael Bruning <michael.bruning@digia.com> Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
* Merge "Merge remote-tracking branch 'origin/release' into stable" into ↵Frederik Gladhorn2014-05-131-3/+2
|\ | | | | | | refs/staging/stable
| * Merge remote-tracking branch 'origin/release' into stableFrederik Gladhorn2014-05-121-3/+2
| |\ | | | | | | | | | Change-Id: I9300572e2b74f0564b2589cbd0fbdf24850f68df
| | * Avoid using repeat on widget textures in eglfsLaszlo Agocs2014-05-091-3/+2
| | | | | | | | | | | | | | | | | | | | | | | | Otherwise widgets will not be shown on some embedded systems. Task-number: QTBUG-38866 Change-Id: Id16408dc7eb657c052bbe3bdb86e35ab2f062632 Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* | | CoreText: Prevent creation of CGContext for glyphs with empty bounding boxTor Arne Vestbø2014-05-121-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If the alphaMapBoundingBox of a glyph is empty we don't want to create a CGBitmapContext on it, as that will fail, and any further operations on the invalid context will result in possibly fatal errors from CG. This issue can be observed when drawing some glyphs of the Apple Color Emoji font. Change-Id: Ia45ba858b5fb6afa91e6d686a9c55e350d4095f3 Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
* | | Allow QFont lookups using localized family names by adding family aliasTor Arne Vestbø2014-05-121-1/+8
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | After fbaa6d3ca6fc269 QFont family names are non-localized on iOS/OS X, which means applications that try to initialize QFont with a localized family name (explicitly, or from user input), will fail, and get the fallback font instead. We now add font family aliases for the localized family names, so that font matching will work even for localized family names. Note that QFontDatabase::families() still returns a non-localized list. Task-number: QTBUG-38628 Change-Id: Id351befa69916ce162c939733bbfcc774f075120 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
* | Merge remote-tracking branch 'origin/release' into stableFrederik Gladhorn2014-05-032-3/+43
|\| | | | | | | | | | | | | Manually fixed up: isES -> isOpenGLES src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp Change-Id: I57d2ef26c3d4a7b40ace09f4e8560b7686650ea5
| * Avoid reentering processMouseEvents on embeddedLaszlo Agocs2014-04-282-3/+43
| | | | | | | | | | | | | | Task-number: QTBUG-38597 Change-Id: I168c9401863bace711d0d8409bf3da30a34185bd Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* | Merge remote-tracking branch 'origin/release' into stableFrederik Gladhorn2014-05-011-2/+2
|\| | | | | | | | | | | This merge adds the opengl rename. Change-Id: I84ea0b6abee9780ebb2cf3f64ab9e3fdf2acab3e
| * Rename new QOpenGLContext APIsLaszlo Agocs2014-04-251-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | isES() becomes isOpenGLES(). The library type enums are changed DesktopGL -> LibGL and GLES2 -> LibGLES. This removes the now unnecessary version number, the confusing "desktop" term and provides better readability. The old function/values are kept until the related qtdeclarative changes are integrated. Task-number: QTBUG-38564 Change-Id: Ibb0a1209985f1ce4bb9451f9b7b093c2b68a6505 Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* | Fix up EGL config selection commentsLaszlo Agocs2014-04-241-18/+32
|/ | | | | | | | | | After cross-checking with the spec and some embedded devices providing both 888 and 565 configs, it turns out the behavior and the old legacy comments are correct. Rephrase and extend the comments a bit to make it maintainable. Change-Id: If6043a39ca0129cfd075c997f362891f0c28dc2c Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* Fix: Initialize all needed member varsMartin Koller2014-04-041-1/+1
| | | | | Change-Id: I74b71d93e25e4b3b0c1a5766f2fbc4f71aebecbb Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
* Fix application font removal when using FontConfigFabian Bumberger2014-03-271-108/+112
| | | | | | | | | | | | | | | | | This patch fixes an issue when a font that was added with QFontDatabase::addApplicationFont can not be removed any more. The reason for that is that QFontconfigDatabase::addApplicationFont adds the font to the FontConfig application set from where it cannot be removed any more and is picked up every time the font database is repopulated (e.g. after a call to QFontDatabase::removeApplicationFont). This also fixes the QFontDatabase autotest which unfortunately does not fail on linux, because it tries to add "FreeMono" (which in most cases is already there as a system font). So this patch removes FreeMono and adds LED_REAL as test font. Change-Id: I70fc823075923aa426da1eb3e052affcc416e399 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
* Android: Fix font mergingEskil Abrahamsen Blomfeldt2014-03-252-2/+6
| | | | | | | | | | | | | Our fallback fonts would contain a minimal list of hardcoded fallback fonts, which is neither sufficient for displaying all text, nor portable to different vendors which can supply different font sets. [ChangeLog][Android] Fixed font merging problem which caused e.g. missing glyphs for Arabic numerals. Task-number: QTBUG-37738 Change-Id: Ic971343a1cd5610c79a81f6f6152c637937b5626 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
* egl: Remove commented codeLaszlo Agocs2014-03-251-10/+1
| | | | | | | Fix also the statement about buffer size handling. Change-Id: I94e93fa4df7fee9b789ecca33d8722fbfc86ccc5 Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* Remove unused ifdefLaszlo Agocs2014-03-251-26/+6
| | | | | | | | | | The QEGL_DEBUG defines have been removed some time ago from eglfs and eglconvenience, except for this one. It is also inconvenient due to the OpenGL dependency of it. Quick apps can anyway get the same information with QSG_INFO=1. Change-Id: Ie25c5286234a10699652d618d6f4174c6d3238e2 Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* eglfs: Print the chosen config in debug modeLaszlo Agocs2014-03-252-3/+8
| | | | | | | | | q_printEglConfig has been left unused. Start using it again, in case QT_QPA_EGLFS_DEBUG is set. This will, similarly to QSG_INFO, help debugging, especially on embedded devices. Change-Id: I1448632ed055dd71e98259f042d3cac64620a4ce Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* Apply fontconfig settings to custom fontsAllan Sandfeld Jensen2014-03-223-0/+52
| | | | | | | | | | | Currently QtWebKits custom fonts does not follow the system settings on Linux. This is because they are only handled by the basic fontdatabase. This patch adds handling of custom fonts to QFontconfigDatabase. Change-Id: I676fc97840766b58cd937bb8e2c9f166f30c8a6e Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com>
* Cleanup and refactor QFontconfigDatabase::fontEngineAllan Sandfeld Jensen2014-03-211-65/+74
| | | | | | | | | | | | Refactors the logic to parse the font configuration from fontconfig, so that it maybe reused for custom fonts in a later patch. Also fixes a minor mistake that meant we defaulted to medium hinting, where we tried to default full hinting. Change-Id: I1e135b8b1e3faeb213aa370ea59ebde3a671273d Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com>
* Teach font database to populate families lazilyTor Arne Vestbø2014-03-202-13/+37
| | | | | | | | | | | | | | | | | | | | | | Instead of requiring that QPlatformFontDatabase::populateFontDatabase() populates every single font in the system by calling registerFont(), we now allow the platform database to call registerFontFamily() instead, and then keep track of which families we've yet to fully populate in the font database. Once a property of a family is requested (such as its writing system, style, etc), the family is lazily populated by calling back to the platform database through QPlatformFontDatabase::populateFamily(), which in turn does the final call to registerFont() as before. This cuts application startup on OS X and iOS (of which the font population used to be a major limiting factor) from roughly one second to about 350ms. Task-number: QTBUG-37165 Change-Id: Ic2fc3447beb818ffe23635a5b7816ed7e70c93a7 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com> Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* QOpenGLContext: Use color depth information from QSurfaceFormatKurt Pattyn2014-03-191-0/+8
| | | | | | | | | | | When a new QOpenGLContext is requested, the color depth information is now also taken into account on OS X and WGL. Task-number: QTBUG-37411 Change-Id: I69d04989a20de3ace041b009fbbdc03fa02cfdf8 Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com> Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Fix bundled HarfBuzz-NG build outside QtGuiKonstantin Ritt2014-03-191-10/+21
| | | | | | | | | | | | | | On Mac, hb_coretext requires both CTFont and CGFont. Due to not supporting the 0 tag by CoreText, hb_blob_get_data() always fails causing the hb_coretext_shaper initialization to fail, too. Since HarfBuzz-NG is not a part of QtGui module anymore, there are two possibilities to workaround this: either engineer the font data by querying tables one-by-one and generating the font directory table, or pass CTFont and CGFont refs directly to hb_coretext via the hb_face's user_data. This patch implements the latter. Change-Id: I7d2e2df00818ea811642cb6a6c3b9c9abd5d7b94 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Fix no-opengl build with eglLaszlo Agocs2014-03-171-17/+20
| | | | | | | | | | | | Disable eglfs and similar plugins when opengl is not enabled. (but egl is present) GL-dependent parts of eglconvenience need to be skipped too. Task-number: QTBUG-37457 Change-Id: I44d49495241551bc7b1f565aa0b5ace9f310628e Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* Cocoa: Set "Stereo" OpenGL format option.Morten Johan Sørvig2014-03-171-0/+3
| | | | | | | Task-number: QTBUG-35548 Change-Id: I60b633ae44b8b4b353a7328eb0922b9301e1460c Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Don't populate font families using localized family names on OS X/iOSTor Arne Vestbø2014-03-131-5/+5
| | | | | | | | | | | | The font database and QFont should have normalized font family names, so using CTFontDescriptorCopyLocalizedAttribute is not a good idea. If the feature of reporting the localized name of a font family or style is needed in for example the font selection dropdown or dialog, it should be exposed as an explicit property of the font. Change-Id: Iaa15ad861043f4c78a38080608b6fe4d99efee18 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Fix a few build warnings on iOS due to unused functionsTor Arne Vestbø2014-03-131-0/+4
| | | | | Change-Id: If345a4137986a7d5032a2b48d92c08bc58e02144 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Remove need to populate font database on OS X to get fallback familiesTor Arne Vestbø2014-03-112-45/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Populating the whole database takes a while, and it's very easy to trigger the fallback family code path through eg. matching or getting the default font family from QFont. Instead of relying on populate to resolve family name to a PostScript name (which was required when using CTFontCreateWithName), we instead use the CTFontDescriptorCreateWithAttributes() function to create a descriptor based on the family name, and then use CTFontCreateWithFontDescriptor(). The other way around, we use CTFontDescriptorCreateWithNameAndSize, and then pull out the family name from the descriptor. The need for creating a CTFont for private fonts (eg '.Apple Symbols Fallback') does not seem necessary anymore, as tested on 10.7-10.9. The disadvantage of creating font descriptors instead of re-using the data computed by population is that we're doing the same work twice, but the end result is making the font database more lazy, and the 80% use-case is assumed to be that you're only interested in the fallback of a small number of fonts, which means you don't want to populate all of the fonts in the system (taking about 1100ms on the test system). Looking up the fallback of a single family or style now takes about 15-25ms. Task-number: QTBUG-37165 Change-Id: I6b904dbe796a3f236919d778d0168fdef9a20e69 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com> Reviewed-by: Simon Hausmann <simon.hausmann@digia.com> Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* Add EGL_KHR_create_context supportLaszlo Agocs2014-03-102-36/+123
| | | | | | | | [ChangeLog] GLES3 and desktop OpenGL are now fully supported with EGL Task-number: QTBUG-37332 Change-Id: Ic695db573d90b3a204941d105a370f5c63182b63 Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* egl: Choose GLES3 capable configs when neededLaszlo Agocs2014-03-101-2/+13
| | | | | | | | | | | | | | Passing OpenGLES and majorVersion 3 in a QSurfaceFormat selects GLES3 in case it is supported. This works fine already now, but is not safe since the config choosing logic does not request a GLES3-capable configuration and so it may end up with a non-GLES3 compatible one. This is now corrected by passing the EGL_OPENGL_ES3_BIT_KHR bit when EGL_KHR_create_context is available. Change-Id: Iacee1e1819b944c0f7c1062666106abddf59272b Reviewed-by: Sean Harmer <sean.harmer@kdab.com> Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* egl: Update the OpenGL version in the context's QSurfaceFormatLaszlo Agocs2014-03-101-0/+31
| | | | | | | | | | The GLX and WGL support code does this already. Do it for EGL too since requesting OpenGLES with majorVersion 3 results in GLES3 (where supported) and in this case the expected majorVersion in QOpenGLContext::format() is 3. Change-Id: I73d61d7569e6ebaa91aef57fb1b0051a77a73355 Reviewed-by: Sean Harmer <sean.harmer@kdab.com> Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* Remove unused parameter from QEGLPlatformContext constructorLaszlo Agocs2014-03-103-11/+4
| | | | | | | | The API is chosen via QSurfaceFormat, the constructor argument is ignored. Remove this historical artifact. Change-Id: I4a5c1e12cb297de22f239ad0a6747c1c36168eed Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* qmacmime: bugfix unicode::canConvertRichard Moe Gustavsen2014-03-061-1/+2
| | | | | | | | | | | | | | | The UnicodeText converter is a bit special since it can convert to both utf8 and utf16 for text/plain. But since flavorFor("text/plain") can only return one UTI, it returns utf16. And this means that canConvert will return false if given utf8 as argument. On iOS this is often the only format available on the pasteboard, which means that pasting text from another app app will fail. This patch will ensure that it returns true for both utf8 and utf16. Change-Id: I31697f1815c19113393a8ef48f2ead4d7f1078ec Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
* Cocoa/Platformsupport: move qmacmime from cocoa to platformsupportRichard Moe Gustavsen2014-03-064-0/+938
| | | | | | | Share qmacmime with iOS Change-Id: Ied1b6ed74f2d63ef34d818554827a6165651b6a1 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
* Avoid polluting debug output in eglfs and linuxfbLaszlo Agocs2014-03-061-8/+12
| | | | | | | | Size hints will not be implemented. Grabs maybe some day but the warnings should be silenced for now. Change-Id: I1f4861454d45e668c4d758c7f82940cd1136d0c8 Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* Prevent repeated and unnecessary font population QCoreTextFontDatabaseTor Arne Vestbø2014-03-052-19/+30
| | | | | | | | | | | | | | | | | | | | | | The platform font database is populated from QFontDatabase, through the static initializeDb() function, whenever the font database determines that the platform database has not been initialized (by checking if the font database is empty). There are other clients of QPlatformFontDatabase though, such as QFont, which uses the platform font database to check for the default family. The CoreText implementation of determining the default family relies on data that is computed during font population, and hence does an internal (self-triggered) populate. To prevent repeated populates as a result of calling QFont::defaultFamily() we guard the populate by a similar isEmpty() check as QFontDatabase does, but to ensure that this check works in the case of an invalidated font database, we need to propagate the font database invalidation down to the platform font database. Change-Id: I8d06c6f6fc5da6353c087335859eaca008c2f6a6 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
* Make QFontEngine::type() non-virtualKonstantin Ritt2014-03-052-2/+2
| | | | | Change-Id: I24ece90d6d8f96dad0c41a474a491b4ea96d97c3 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Get rid of QFontEngine::name()Konstantin Ritt2014-03-051-2/+0
| | | | | | | | It was only used in QFontCache debug output, and some engines weren't even report a name. Change-Id: I6cec4b75f105f5a4e1405f50188bebb3a3f04e33 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Dynamic GL: remove exporting symbolsLaszlo Agocs2014-03-042-5/+11
| | | | | | | | | | | | | | | | | | | | | Remove the opengl proxy for now. Later it will either be moved into a separate library or replaced by a QOpenGLFunctions-based approach. This means that the -opengl dynamic configuration is not usable for the time being. The rest of the enablers remain in place. The convenience function QOpenGLFunctions::isES() is now moved to QOpenGLContext and is changed to check the renderable type. This is extremely useful since besides supporting dynamic GL it solves also the problem of GL_ARB_ES2_compatibility (i.e. it triggers the real ES path when creating an ES-compatible context with a desktop OpenGL implementation). Task-number: QTBUG-36483 Task-number: QTBUG-37172 Change-Id: I045be3fc16e9043e1528cf48e6bf0903da4fa7ca Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>