summaryrefslogtreecommitdiffstats
path: root/src/gui
Commit message (Collapse)AuthorAgeFilesLines
...
* Doc: Add since versionPaul Wicking2019-12-191-0/+2
| | | | | | | | | | for QCursor::swap and QOperatingSystemVersion::currentType. Fixes: QTBUG-80854 Fixes: QTBUG-80891 Change-Id: Ia256fa0d3ad4665f44b933f5a4a8d4ee87e9fc13 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* Sync implementation of QGuiApplication and QApplication setPaletteTor Arne Vestbø2019-12-171-3/+4
| | | | | | | | | The two static setPalette methods in QApplication and QGuiApplication should have the same behavior in terms of what signals and events they emit. Change-Id: I54579d490e31f3783e2d4fea689ca799a070ff1d Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* Let sendApplicationPaletteChange() decide when it needs to exit earlyTor Arne Vestbø2019-12-171-2/+4
| | | | | Change-Id: I7a8e6c0b54d2a16a17b292a4102e05f743bcbe29 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* Remove ApplicationResourceFlags::ApplicationPaletteExplicitlySetTor Arne Vestbø2019-12-171-4/+1
| | | | | | | | | After 8fb881900c7b it's tracked by AA_SetPalette. Since the latter is publicly observable we remove the internal flag instead. Change-Id: Ie69799f1b45d68017cb9eaab2a9986cc9ac9ca38 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Fix QPainter::drawLines() with cosmetic penEirik Aavitsland2019-12-171-0/+1
| | | | | | | | | | | Even though each line in the array passed to drawLines() should be rendered as an independent line, some state was kept in the cosmetic stroker from one line to the next. This could result in visible rendering errors. Fixes: QTBUG-80834 Change-Id: Ief7bf78eab83ae34459802bff5a57d6beec4a5e5 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* QTextDocument: compile with QT_NO_PRINTERChristian Ehrlicher2019-12-161-0/+2
| | | | | | | | | | The implementation of QTextDocument::print() is not available when QT_NO_PRINTER is defined but the declaration was so when someone is using this function (and QT_NO_PRINTER) a linker error will occur. Fixes: QTBUG-56916 Change-Id: I49aaaa643c4d8587a66fc95733060cea11994872 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Use pkg-config to find libjpegMarius Kittler2019-12-151-0/+1
| | | | | Change-Id: I42d877fbca5d746114cc28f8ee4db3e54754cd24 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* OpenGL: Fix signature of GLDEBUGPROC in qopenglextrafunctions.hAlexandru Croitor2019-12-131-1/+1
| | | | | | | | | | | | | The typedef "QOPENGLF_APIENTRYP" was incompatible to the one in "src/opengl/qopengldebug.cpp" which used "QOPENGLF_APIENTRY". Note the misisng "P " ending. The type is meant to be a function pointer, not a pointer to a function pointer, so remove the extra P. Change-Id: I229b73ca8e7367f88a2b48e2728e615605f02da3 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* Doc: Fix qdoc compilation errors qtbaseNico Vertriest2019-12-122-2/+2
| | | | | | Task-number: QTBUG-79824 Change-Id: I6557de598de1931fc30556951d35783d02b83abe Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Move the tooltip out of the way of very large mouse cursorsVolker Hilsheimer2019-12-092-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | Users that have large mouse pointers configured in their settings can not see tooltips, as they are obscured by the pointer. Native applications on Windows and macOS have the same problem, which includes the tooltips for the minimize/maximize/close controls in the window frame of e.g. Explorer. Introduce QPlatformCursor::size that returns a value that is based on the user's settings, or a default value. We can then use that value to move the tooltip out of the way. On Windows, the calculation of the cursor size is based on experimenting with the settings, which are in logical independent pixels. The placement of the tooltip attempts to keep existing behavior, and to not end up with a tooltip that's very far away from the tip of the arrow even for very large mouse cursors. [ChangeLog][QtWidgets][QToolTip] Make sure that the tooltip is not obscured by very large mouse pointers on Windows and macOS. Change-Id: I8e13b7a166bfe8b59cef4765c950f90fefeaef9d Fixes: QTBUG-79627 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* rhi: metal: Do not fail pipeline creation upon compiler warningsLaszlo Agocs2019-12-091-1/+4
| | | | | | Change-Id: I39384de56d74cf9f1d345a5d395cc07030c6a2ab Fixes: QTBUG-80629 Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
* Fix crash on debug output of null QColorSpaceAllan Sandfeld Jensen2019-12-091-4/+6
| | | | | Change-Id: I7d1d20d7dc2c5ac10dbe8d0a0b4111e8198bfabf Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
* Fix updating the text cursor position after editingSona Kurazyan2019-12-061-0/+1
| | | | | | | | | | | | | In some cases when editing the text (for example when removing the selected text, or pasting a text block) the text cursor position is updated, but its visual x position is not updated. This causes the next cursor movements to start from a wrong position. Force the update for those cases. Fixes: QTBUG-78479 Change-Id: Ia496be62beec58660f5e1695e5aafae09c79684e Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
* Copy formatting attributes when cloning an empty QTextDocumentSona Kurazyan2019-12-051-1/+13
| | | | | | | | | | | | | | | When cloning a QTextDocument, the text fragment of the original document is copied into the new one, which results into copying also the formatting attributes. However, when the text document is empty, the corresponding text fragment is also empty, so nothing is copied. If we want to transfer the formatting attributes for an empty document, we need to set them explicitly. Fixes: QTBUG-80399 Change-Id: I382cd0821723436120af47c06ec7bfa849636307 Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io> Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
* Fix assert in QTextDocument CSS parser on "border-width: 1pt"David Faure2019-12-033-4/+8
| | | | | | | | | | | | | | | | | The code was assuming that if the parsing of the value worked, then it must be a list of 4 variants. But in this case it's just a single length. This came from <td> using 4 values for border-width while other elements use a single value. But the storage is shared. So the fix is to use 4 values everywhere. When reading 4 and there's only one, it gets duplicated, so the caller can just use the first one in that case. Task-number: QTBUG-80496 Change-Id: I682244b6e3781c4d673a62d5e6511dac263c58e8 Reviewed-by: Nils Jeisecke <nils.jeisecke@saltation.com> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* rhi: Remove unused compat functionsLaszlo Agocs2019-12-031-20/+0
| | | | | | | | | These were kept around to keep Qt Quick compiling, but the migration there has been done a long time ago. Remove these leftovers now. Change-Id: Ibd47381b410b11b5475a85c7ed3cb05c22f7adbb Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* RHI/Vulkan: Fix buildFriedemann Kleint2019-12-021-0/+1
| | | | | | | | | | Add missing include, fixing: rhi\qrhivulkan.cpp(6273): error C2027: use of undefined type 'QWindow' Amends 0f812db558df072a411ade3305b796d54bccd996. Change-Id: Ide61b713e958877f18a45a89b36a4e1330f75821 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* rhi: vulkan: Remove unused includeLaszlo Agocs2019-11-291-1/+0
| | | | | | | | QVulkanWindow support has long been removed from the Vulkan backend. The include is a leftover from those times. Change-Id: Ie68ac3611b24310f2b6111a72dd0679adafdc74d Reviewed-by: Johan Helsing <johan.helsing@qt.io>
* wasm: Disable TextureSwizzleFredrik Orderud2019-11-281-2/+6
| | | | | | | | | | | The WebGL 2.0 specification explicitly does not support texture swizzles. Therefore, disabling it when targeting WASM. This fixes "WebGL: INVALID_ENUM: texParameter: invalid parameter name" when running in Chrome or Firefox. Change-Id: Ic7e22e0f623095245274924095cb63fd0ff7e8c2 Reference: https://www.khronos.org/registry/webgl/specs/latest/2.0/#5.19 Fixes: QTBUG-80287 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* Silence intel compiler warning about float comparisonOlivier Goffart2019-11-286-0/+6
| | | | | | | | Add the equivalent intel warning macro in public header where there was already the macro for -Wfloat-equal Change-Id: I8f20400f0b95c8f3857fa7a0a33464c8c34d5c0e Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* rhi: gl: Fix ms renderbuffer on WASM with WebGL2Laszlo Agocs2019-11-281-2/+1
| | | | | | | | | | | | | Unlike renderbufferStorage, renderbufferStorageMultisample is not guaranteed to accept the unsized GL_DEPTH_STENCIL internalformat. For the former, WebGL 2 guarantees it for compatibility for WebGL 1, but the multisample version does not exist in WebGL 1, so from the specs it is not given at all that the unsized format would be accepted. So use the ES 3.0 sized format instead, like we would on a "real" ES 3.0 implementation. Fixes: QTBUG-80296 Change-Id: I822ae382097085c0a3279c16bb69a173dbf15093 Reviewed-by: Andy Nichols <andy.nichols@qt.io>
* Fix renderbufferStorageMultisample: invalid internalformatFredrik Orderud2019-11-261-4/+2
| | | | | | | | | | | | | | | Chrome 78 is outputting "INVALID_ENUM: renderbufferStorageMultisample: invalid internalformat" when running a Qt application after building it for WebAssembly (WASM) against the Qt 5.13 branch using the Emscripten 1.39.3 (upstream) compiler. The problem appear to be caused by glRenderbufferStorageMultisample not supporting GL_DEPTH_STENCIL directly. Instead, GL_DEPTH24_STENCIL8 or GL_DEPTH32F_STENCIL8 should be passed. Keeping the glRenderbufferStorage call as-is. Change-Id: I777dbc26b1d989950525a434a25ed344389f5059 Reference: https://www.khronos.org/registry/OpenGL-Refpages/es3.0/html/glRenderbufferStorageMultisample.xhtml Fixes: QTBUG-80286 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* rhi: d3d11: Do not rely on Win10-only enum valueLaszlo Agocs2019-11-221-1/+1
| | | | | | | | | | | When building against a 8.1 or older SDK the Windows 10-only value DXGI_SWAP_EFFECT_FLIP_DISCARD may not be present. Just use the value directly. At runtime that code path cannot be hit anyway when running on 8.1 or older. Task-number: QTBUG-80084 Change-Id: I0974b82db770e5487315798432ee601937b96c5e Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Don’t warn on QT_AUTO_SCREEN_SCALE_FACTOR usageMorten Johan Sørvig2019-11-201-6/+3
| | | | | | | | | | | | | This warning turned out to be spammy, since the env. variable may be set by KDE, in which case there is nothing the user or app developer can do to fix the situation. QT_AUTO_SCREEN_SCALE_FACTOR is now Done on X11, and remains Deprecated on all other platforms. Change-Id: I9d372655624b0e0b822f0a70e9aec4b18ab98630 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* QWheelEvent: add \since flag for ctorChristian Ehrlicher2019-11-191-0/+1
| | | | | | | | | c08bf215cceda784cd02f8fa20e5b2431e0d9ef9 added a new QWheelEvent ctor but missed the \since flag. Fixes: QTBUG-80088 Change-Id: I6c81179999dd100162dc0cd5dc28e7b5b843b437 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* HiDPI: Select most fitting pixel ratio when painting QIconFlorian Korsakissok2019-11-181-1/+6
| | | | | | | | | There is a way to select a better pixel ratio when the QPainter has a valid pointer to a QPaintDevice than simply getting the global app pixel ratio. Change-Id: I8f89fd01094bbac7a01a83be89991730b0fa6597 Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
* Fix: QIcon high dpi scaling when aspect ratio differsEirik Aavitsland2019-11-151-0/+5
| | | | | | | | | | | | When an icon engine is asked to produce a pixmap scaled to a certain size, it may return one with a different aspect ratio than requested. In particular, an SVG will use its own aspect ratio, as it should. QIcon's DPR calculation would break down in this case, resulting in ugly scaling. Fixes: QTBUG-79371 Change-Id: Id97049259dcee1a2980474250ef1163be5639085 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* Compile fix for MinGW 8.1.0Cristian Adam2019-11-141-0/+8
| | | | | | | | Workaround for libpng bug in GCC 8.1.0. Task-number: QTQAINFRA-3303 Change-Id: Id7668e795cb4ab16de3199fc3727d844aa31bfad Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io>
* Be explicit about QDataStream serialization: explicit casts to intThiago Macieira2019-11-141-3/+3
| | | | | | | The reader uses int variables, so use the same in the writer. Change-Id: I1496b069cc534f1a838dfffd15c94c7cacd3dd93 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* Use default QTD font size for mono font when importing markdownEike Ziller2019-11-131-0/+4
| | | | | | | | | | QFontDatabase::systemFont(FixedFont) determines the font for inline code and code blocks in a markdown document. Now we change the size of that font to the same size as QTextDocument::defaultFont() so that the user has the ability to customize the font size in each document instead of only system-wide. Change-Id: Ief7367336f7613e88695dbb08bcb7e9f50db8961 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Merge remote-tracking branch 'origin/5.13' into 5.14Liang Qi2019-11-131-0/+7
|\ | | | | | | | | | | | | | | Conflicts: examples/widgets/widgets/scribble/mainwindow.cpp This amends cb54c16584cf3be746a1a536c1e37cb3022a2f1b. Change-Id: Iaae60a893330524b2973917e23b31f9d51f8bd38
| * syncqt: Add a means to suspend/resume the processing of a fileAndy Shaw2019-11-061-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Rather than tweaking the parser to cover every eventuality with corner case lines that could cause incorrect header files to be created then the means to suspend/resume the processing of a file is added. This enables us to have it skip over the template line that is causing a QList header to be created as part of the QtGui headers. This patch includes the fix to solve this in addition. Fixes: QTBUG-68129 Change-Id: I751646c4b20a4434347c149ae5e6dcb6e7618853 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* | Windows QPA: Fix wrong scaling of fixed size in window creation phaseFriedemann Kleint2019-11-082-4/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | When a fixed size the window is moved to another screen by QPlatformWindow::initialGeometry(), the size constraints would be incorrectly scaled using the initial screen in the handling of WM_GETMINMAXINFO. To fix this, pass the resulting screen out of QPlatformWindow::initialGeometry() and use it during the window creation phase. Fixes: QTBUG-77307 Change-Id: I149a2a65e816da841a32abc14a495925bf9cc6f6 Reviewed-by: André de la Rocha <andre.rocha@qt.io> Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* | QHighDpiScaling: impove readability of screenSubfactor methodVitaly Fanaskov2019-11-071-10/+11
| | | | | | | | | | | | Task-number: QTBUG-53022 Change-Id: Idae4379dd78d3125c375fad37a5a3af5bbcdc51e Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | Fix accuracy of ARGB32->A2RGB30 conversionsAllan Sandfeld Jensen2019-11-073-50/+67
| | | | | | | | | | | | | | | | | | | | | | | | | | It was converted over ARGB32PM, when it should have been directly converted to not lose accuracy, instead there was an unnecessary direct ARGB32->RGB30 conversion, which was converted to the necessary type. This also improves the selection of conversion over ARGB32PM or RGBA64PM for ARGB32 and RGBA8888 by using 32-bit conversion when alpha is not relevant. Change-Id: I5990d8a23b2909d3910d8c1213fa46477742b052 Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
* | QHighDpiScaling: fix potential null pointer dereferenceVitaly Fanaskov2019-11-071-1/+2
| | | | | | | | | | | | | | | | | | | | It's not guaranteed that QPlatformScreen::screen should always return a valid pointer. Furthermore, you can run into this situation with, for example, two screens setup. Task-number: QTBUG-53022 Change-Id: Ic23bb2c30b1245f98a793a44cc5e0b39f9afac4b Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | Merge remote-tracking branch 'origin/5.13' into 5.14Qt Forward Merge Bot2019-11-064-7/+9
|\| | | | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf mkspecs/features/mac/default_post.prf src/corelib/tools/qsimd_p.h src/platformsupport/fontdatabases/mac/qcoretextfontdatabase.mm util/qfloat16-tables/gen_qfloat16_tables.cpp Change-Id: If48fa8a3bc3c983706b609a6d3822cb67c1352a4
| * If only family is set, prefer that in the families list after resolvingAndy Shaw2019-11-051-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If a font with only a family set is resolved with one that has been setup with setFamilies() then the family needs to be prepended to the families list after resolving. This is so that the font still prefers the one set as just a family with no famillies set. This also amends the QFontDialog test to account for this too. [ChangeLog][QtGui][Text] Resolving a font that just has a family set with families set will prepend the family to the families so that it is still the first preference for the font. Task-number: QTBUG-46322 Change-Id: Icc4005732f95b2b4c684e592b06b31e133270e44 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
| * QImageIOHandler: remove #if around virtual method name()David Faure2019-11-012-5/+1
| | | | | | | | | | | | | | | | | | It makes -DQT_DISABLE_DEPRECATED_BEFORE=0x050d00 (in an application) trigger a binary incompatible change and crash. Change-Id: I9b9783d134821697180dc3fd8f2f69a51ddb7ac6 Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
| * QFontDatabase: improve logging outputMitch Curtis2019-10-281-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Log the style name, add more descriptions of what's being logged. Before: Adding font "Lucida Grande" 50 QFont::StyleNormal 0 aa true fixed false After: Adding font family "Lucida Grande" stylename "Regular" weight 50 style QFont::StyleNormal pixelSize 0 antialiased true fixed false Change-Id: I138f1b9f41dc41c528c830d81f8018fc16561631 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* | QTextMarkdownWriter: preserve empty listsv5.14.0-beta3Shawn Rutledge2019-11-051-1/+2
| | | | | | | | | | | | | | | | | | | | You can save a "skeletal" document with list items to fill in later, the same as you can do in HTML or ODF format. Reading them back via QTextDocument::fromMarkdown() isn't always perfect though. Fixes: QTBUG-79217 Change-Id: Iacdb3e6792250ebdead05f314c9e3d00546eeb9f Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | Avoid crashing when the end of an empty markdown list is detectedShawn Rutledge2019-11-051-6/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The markdown parser generates empty lists in some cases when a character that can be used as a bullet is found on a line by itself. cbEnterBlock() and cbLeaveBlock() are called symmetrically in such cases. QStack::pop() on an empty stack triggers an assert, so push and pop need to be done symmetrically too. But it's difficult to actually create the list as soon as the MD_BLOCK_UL or MD_BLOCK_OL callback occurs, without breaking the case fixed in 7224d0e427d71e559b928c44634839b4791c1416 (and probably other cases). That's because QTextCursor::insertList() creates a list item at the same time as it creates the list itself, and also inherits block formatting from the previous block. We now insert empty lists with empty items whenever the need for that is detected though, and there's a failsafe to prevent popping in case something still goes wrong with that logic. We aren't strict about reproducing the original markdown when regenerating it via toMarkdown(), but it's getting closer. Fixes: QTBUG-78870 Change-Id: Ided194ce7aec2710c60dbac42761ee4169ed9b78 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Robert Loehning <robert.loehning@qt.io>
* | Fix check for EGL on INTEGRITYKai Koehne2019-11-041-1/+1
| | | | | | | | | | | | | | | | | | | | | | This fixes a regression introduced in c00487d588f. Fixes: QTBUG-79285 Change-Id: I95f073d019d6e909f8de132ea9f27002043d5d52 Reviewed-by: Kimmo Ollila <kimmo.ollila@qt.io> Reviewed-by: Timo Aarnipuro <timo.aarnipuro@qt.io> Reviewed-by: Tasuku Suzuki <tasuku.suzuki@tqcs.io> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* | Fix text-rendering regression on semi-transparent background on LinuxAllan Sandfeld Jensen2019-10-311-2/+2
| | | | | | | | | | | | | | | | | | | | The short-cut for semi-transparent backgrounds has to take precedence over the disabled gamma-correction short-cut. The order got inversed in one function during 5.14 refactoring. Change-Id: I0e54428839428068b602a13eddbf69897ed0797d Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
* | qpa: Add note about QScreen taking care of primary screen during removalTor Arne Vestbø2019-10-291-1/+2
| | | | | | | | | | | | Change-Id: I31b4ed6e6597e22172dcca7180750f1392b9ad68 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* | Merge remote-tracking branch 'origin/5.13' into 5.14Qt Forward Merge Bot2019-10-283-8/+12
|\| | | | | | | | | | | | | Conflicts: src/corelib/serialization/qjson_p.h Change-Id: I83cea141a4de8b3998478bfded84ca9029f7a2a9
| * Drag'n'Drop: fix attached Drag object deleted when DnD is progressingYulong Bai2019-10-273-8/+12
| | | | | | | | | | | | | | | | | | | | The attached Drag object's owner, i.e. its parent, is also the dragged item. So the attached Drag object will also be destroyed as the dragged item is deleted. Fixes: QTBUG-65701 Change-Id: I39b0a3180f205c427deed5c70cd1912524f9324e Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | QFontDatabase: Delete redundant semicolonsJüri Valdmann2019-10-252-2/+2
| | | | | | | | | | | | | | | | | | There are too many semicolons. Delete some. Fixes two warnings from Clang 9.0.1. Change-Id: I363a6a2de9c075c03da62c58ad46828c04a95440 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | Enforce QTextDocument::MarkdownFeature compatibility at compile timeShawn Rutledge2019-10-244-18/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We use md4c for parsing markdown. It provides flags to control the feature set that will be supported when parsing particular documents. QTextMarkdownImporter::Feature is a fine-grained set of flags that exactly match the md4c feature flags that we support in Qt so far. QTextMarkdownImporter is a private exported class (new in 5.14). We don't expect the corresponding flags in md4c to change in incompatible ways in the future: the md4c authors have as much respect for avoiding compatibility issues as we do, and likely will only add features, not remove them. We now enforce QTextMarkdownImporter::Features compatibility with QTextDocument::MarkdownFeatures by setting them directly. We check QTextMarkdownImporter::Features compatibility with md4c's #define'd feature flags using static asserts, so that any hypothetical incompatibility would be detected at compile time. The enum conversion from QTextDocument::MarkdownFeatures to QTextMarkdownImporter::Features is moved to a new QTextMarkdownImporter constructor; thus the conversions from QTextDocument::MarkdownFeatures to QTextMarkdownImporter::Features, and then to unsigned (in QTextMarkdownImporter::import()) are adjacent in the same private class implementation. If incompatibility ever occurred, we would need to replace one or both of those with another suitable conversion function. Change-Id: I0bf8a21eb7559df1d38406b948ef657f9060c67b Reviewed-by: Vitaly Fanaskov <vitaly.fanaskov@qt.io>
* | QKeySequence: Add missing names for multimedia keysAlexander Volkov2019-10-241-0/+6
| | | | | | | | | | | | Task-number: QTBUG-40030 Change-Id: Ib34bcbf42d6dd1206209c2d76444fd8c777278fe Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>