summaryrefslogtreecommitdiffstats
path: root/src/webenginequick/api
Commit message (Collapse)AuthorAgeFilesLines
* Notify about global mapping changes of QQuickWebEngineViewMichal Klocek2025-12-011-5/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Chromium needs to be aware of view geometry changes. We do the sync in visualPropertiesChanged call, which in turn is called from item geometryChanged and itemChanged handlers. However, this approach is not sufficient to track global geometry changes as it only covers case where geometry change is local to item's parent. Therefore, we need watch the entire parent hierarchy to correctly handle global geometry change notifications. Note this issue only affects webenginequick as rwhv can have offset from the scene due to explicit position or anchoring within other items. Moreover, anchoring of child item can mean making offset in parent item. Add logic to track offset changes of parent items. Use 'polish' accumulate required notification and do visualPropertiesChanged() in updatePolish() call. Fixes: QTBUG-141476 Pick-to: 6.10 Change-Id: Ia35a6f243624cb06b6b45f76abf8ba544790e2c0 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
* QQuickWebEngineView: handle null qmlEngine in navigationRequested()Vladimir Belyavsky2025-11-271-1/+7
| | | | | | | | | | | | | | | | Bail out earlier and do not crash in navigationRequested callback when qmlEngine is null. This may happen when using WebEngineView e.g. in a Loader, as the QML context data is cleared before the object is destroyed and accordingly, before we unsubscribe from the callback. Note this is band aid fix, as it is still unclear why this problem did not occur here before (e.g. with Qt 6.8.3). Task-number: QTBUG-137768 Pick-to: 6.10 Change-Id: I33bbaf4240511d20f0b839317fb496fd5b270006 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
* Quick: Add runJavaScript overload with std::function callbackKaloyan Chehlarski2025-11-262-0/+9
| | | | | | | | | | | | | This is to be used in QWebView, where the WebEngine backend is based on our Quick API. With the addition of a C++ WebView API, we need a way to call C++ callbacks, and the JavaScript-based callback mechanism that's currently there is insufficient. We can't expose an std::function parameter to QML, so this overload is there for internal use only. Change-Id: I22b17c2d2ba554078d0e1e39110147399e93102b Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* Doc: Add missing property docsPaul Wicking2025-11-062-6/+22
| | | | | | Task-number: QTBUG-140629 Change-Id: Iab2d22dba0ff8728786f3554bb537808735782cd Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
* Fix QWebEngineDesktopMediaRequest registrationMichal Klocek2025-10-301-8/+8
| | | | | | | | | | | | | | Qml type registration complains about "...nor a default- and copy-constructible Q_GADGET..." Therefore change to be value type, add default constructor. This amends 6f4315175d4c7846c0591954ed03b14d405c9a90. Pick-to: 6.10 Fixes: QTBUG-141112 Change-Id: Ib230e3766bac2451d58da903ad1c1d44e5519862 Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* Minor. Clean up qquickwebengineforeigntypesMichal Klocek2025-10-301-121/+110
| | | | | | | | | | | | | | | | | | | | | Go through all foreign registered types and cleanup the code. Divide file into two sections: * qml object types * qml value type Use proper QML_VALUE_TYPE macro for registration, Add CREATE_DERIVED_FREIGN_NAMESPACE macro. Remove QML_UNCREATABLE as all value types should be default constructable. Note Fixes for QWebEngineDesktopMediaRequest are done in separete commit. Pick-to: 6.10 Change-Id: I0dfbcffc28d58c7cf46b7b7805e4ff0623f17f42 Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* Add chlid frame to qml api of webengineframeMichal Klocek2025-10-282-0/+13
| | | | | | | | | It seems that children property was overlooked. Add it so it is posible to crawl the frame tree. Pick-to: 6.10 Change-Id: Ie4e13ccbc695a4db3782ce2c993c74ebb3d1cc9a Reviewed-by: Moss Heim <moss.heim@qt.io>
* Introduce QQuickWebEngineFrameMichal Klocek2025-10-285-18/+141
| | | | | | | | | | | | | | | | | | | | QWebEngineFrame class includes QJsValue in its api, however to make it work it would require instance of Qml engine. In also means that using qwebenigneframe requires Qml module. Move the methods/logic to new class qquickwebengineframe, however keep the already added SMF and default constructor. Deprecate broken usage of functions taking QJsValue. This amends 3ee3548e4c663402848db3b1336bf56e7c6d327e. Task-number: QTBUG-139710 Pick-to: 6.10 Change-Id: Ia45a52e9d8759f6a4641f8a121e8e05cd60c2eaf Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Moss Heim <moss.heim@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* CRA mark src/webenginequickKaloyan Chehlarski2025-10-0639-3/+41
| | | | | | | | QUIP: 23 Fixes: QTBUG-138715 Pick-to: 6.10 6.9 6.8 Change-Id: Id3edb3400c98f2489cfada7edc8559110f57a3ca Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Fix -no-ssl buildPeter Varga2025-09-171-2/+6
| | | | | | | | Amends 671afae06 Add API for providing additional CA certificates Pick-to: 6.10 Change-Id: I7e40b9b24e319e89c94d13516ebbc896c8ba6f69 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Fix QML usage of QWebEngineFrameAllan Sandfeld Jensen2025-09-061-12/+21
| | | | | | | | | | It was considered incorrectly registered, and caused crashes when used. Pick-to: 6.10 6.9 6.8 Fixes: QTBUG-139710 Change-Id: I5d99c4e46274ead8330893e4d9e0aa7cc99aefc1 Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* Docs: Fix navigation between qml user script collection and web scriptMichal Klocek2025-09-011-5/+5
| | | | | | | | | | | | Use lower case for webEngineScript. Use correct 'qmlvaluetype' section. This amends 1eb2cb02f7ebdfc15a0d2ddc7837d4cffe073006. Fixes: QTBUG-139624 Pick-to: 6.10 6.9 Change-Id: I4766ac876401ac2937af33383dfad48a5f6d1498 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Docs: Fix user script collections docMichal Klocek2025-09-011-2/+2
| | | | | | | | We replaced js array with a qml list for user script collection. Pick-to: 6.10 6.9 Change-Id: Ibef8443c89127cde784aa8e25d62259ad86c51c1 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Remove unnecessary QQmlEngine usageAllan Sandfeld Jensen2025-08-269-172/+18
| | | | | | | | | | Reverts most of f5fbc34fc16fc9c6e7f7e8bbbf60f5b343b9466d, relying on better implicit QML conversion since. Fixes: QTBUG-138881 Pick-to: 6.10 6.9 6.8 Change-Id: Ic23579e421f737b9a4d85c7e4f1a4019323c4be9 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Mark extensionManager as a constantAllan Sandfeld Jensen2025-08-201-1/+1
| | | | | | Pick-to: 6.10 Change-Id: I93acb15935ac43baf72006e2e563c5485f7e173d Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Associate permissions with framesKaloyan Chehlarski2025-08-203-69/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | Previously, permisions were associated with the originating WebContents, as the PermissionManager API uses those in its function calls. This is insufficient, however, as it results in iframes not receiving the correct permissions (because they were instead granted to the root frame instead. This change modifies the internals of PermissionManagerQt to use GlobalRenderFrameHostTokens, and modifies relevant functions across the codebase to pass those around instead of WebContents. Media and mouse lock permissions now also query the permission manager before issuing a request, which avoids some cases of the same request being sent multiple times in a row. As a side effect, the behavior of non-persistent permissions (as well as the behavior of ALL permissions when running in AskEveryTime mode) is standardized so that a permission is remembered as long as the associated frame is alive. Fixes: QTBUG-134637 Fixes: QTBUG-135787 Pick-to: 6.10 6.9 Change-Id: I650e3328ef3830d06206acafc3305566d3a10d86 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Export qml extension types in webenginequickAllan Sandfeld Jensen2025-08-171-0/+24
| | | | | | | | From API review. Pick-to: 6.10 Change-Id: Ibcdf7780d1c03f601a703b35118d0b439e4df62c Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Fix case of QML webEngineScript documentationAllan Sandfeld Jensen2025-08-161-9/+9
| | | | | | Pick-to: 6.10 6.9 6.8 Change-Id: Ia7e65f9050a1e57a3a2c7da69088e68fc7874ef1 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* WebEngineQuick: Expose QWebEngineClientHints to QMLOlivier De Cannière2025-08-151-0/+10
| | | | | | | | | | | | The type already had registration macros but because the header was added to a non-QML module these didn't come into effect. Add a foreign type to register it properly. Task-number: QTBUG-138589 Pick-to: 6.10 6.9 Change-Id: I5a960cf77b71ff4f2b7ddc03b1583029b86d84bc Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* WebEngineQuick: Expose QWebEngineDesktopMediaRequest to QMLOlivier De Cannière2025-08-141-0/+9
| | | | | | | Task-number: QTBUG-138589 Pick-to: 6.10 Change-Id: If8eb6447c3380efa03258f478da68feddccd1988 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Add PersistentCookiesPolicy::OnlyPersistentCookiesMoss Heim2025-08-113-1/+11
| | | | | | | | | | | This new policy prevents session cookies from being saved to disk even for crash recovery purposes. Persistent cookies are still stored. As a drive-by add a missing data row in a QWebEngineProfileBuilder test Task-number: QTBUG-135799 Change-Id: I55364aa96c07ce83d3f30d812450421354310d72 Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* Stop using private V4 APIAllan Sandfeld Jensen2025-08-071-13/+7
| | | | | | | | Everything we need have long been available through public API. Pick-to: 6.10 6.9 6.8 Change-Id: Ifc3925971e8b81852ad42d5dd535ffa9eec1b37b Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* Add setting to trim accessibility identifiersKaloyan Chehlarski2025-08-012-0/+27
| | | | | | | | | | | | | | | | | | | By default, Qt's accessibility code will provide an object's full accessible hierarchy inside the Identifier string that's passed to a screen reader or automation software. This may be undesirable for users who use WebEngine for automated testing. This change adds a new QWebEngineSetting that disables this behavior, and instead makes sure that the HTML 'id' attribute is passed cleanly to accessibility software. When there is no 'id' attribute, the default Qt behavior still applies, and the Identifier string is still the full object hierarchy. Fixes: QTBUG-134762 Change-Id: Ica0b626c05b5cdca0bad83280ba15183ff9480f6 Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* Remove FINAL marker on new propertyAllan Sandfeld Jensen2025-07-251-2/+1
| | | | | | | | | Not allowed any more. API review Pick-to: 6.10 Task-number: QTBUG-137478 Change-Id: I4559e3d00af0be46ec90bdcfff81a7b39d984bb8 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Adaptations for Chromium 132Allan Sandfeld Jensen2025-07-141-1/+2
| | | | | | Pick-to: 6.10 Change-Id: Id2d09604201b2c007c76328f92bb4e0c0d802cae Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* Fix crash if ui delegates are not deployedMichal Klocek2025-07-031-2/+6
| | | | | | | | | | | | | | | | In case delegate for touch handle can not be loaded bail out and simply return nullptr as TouchHandleDrawableQt works fine without delegate (guards against nullptr). Note all other dialog already bailout in case default delegate can not be loaded. Tested on bookworm with 6.8.3 Fixes: QTBUG-111907 Pick-to: 6.10 6.9 6.8 Change-Id: Ib509b63010888fa718f23148c06d973382cad428 Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* Fix build with QtDeclarative 6.11Allan Sandfeld Jensen2025-06-181-1/+1
| | | | | | | | | getV4Engine() was removed, and never needed in Qt6. Pick-to: 6.10 Fixes: QTBUG-137854 Change-Id: I50f168bd7dae2523632705a0612450345dff5117 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Normalize signal/slot signatures 2025Marc Mutz2025-06-041-1/+1
| | | | | | | | | | | This is the result of running util/normalize on the code base. The following manual edits were needed: (none) Pick-to: 6.10 6.9 6.8 6.5 Change-Id: Ia59174aaf154559f7445e13d059723a282f75aae Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Add API for extension managementMartin Negyokru2025-05-292-0/+20
| | | | | | | | | | | | | | | Introduce QWebEngineExtensionManager and QWebEngineExtensionInfo. The manager has methods to load and install Chrome extensions from the filesystem. QWebEngineExtensionInfo provides information about a loaded extension. The current state of our js extension API support is very limited meaning most of the extensions downloaded from Chrome extension store won't work. Adding support for these APIs will be done in followup patches. Fixes: QTBUG-118452 Task-number: QTBUG-61676 Change-Id: I017ad5e8d2ba963afbd2f31ac36fee9451a951bd Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Add API for providing additional CA certificatesKai Uwe Broulik2025-05-273-2/+60
| | | | | | | | | | This allows to provide additional certificates that are considered when verifying a certificate. This is done by the cert verifier downstream of the platform-specific cert store. Fixes: QTBUG-50586 Change-Id: Ie90547f1013f22f994aaff536fadf906a44a88ef Reviewed-by: Moss Heim <moss.heim@qt.io>
* Fix QWebEngineDownloadRequest::pause()Szabolcs David2025-02-242-2/+2
| | | | | | | | | | | | | | Calling pause() (or any method which causes state update) in a directly connected signal handler of a download request causes an assertion fail in DownloadItemImpl::UpdateObservers() because it is protected from nested updates. Use QTimer::singleShot() to detach download requests and updates from the direct code path. Add auto test to check if pausing and resuming a download work. Pick-to: 6.8 6.9 Change-Id: Ia8c977a626fd0d39ca51df42984381a75cca2101 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Port to new Q_UNREACHABLE_RETURN()Marc Mutz2025-02-111-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a semantic patch using ClangTidyTransformator to convert sequences of Q_UNREACHABLE() + return into Q_UNREACHABLE_RETURN(), newly added to qtbase. const std::string unr = "unr", val = "val", ret = "ret"; auto makeUnreachableReturn = cat("Q_UNREACHABLE_RETURN(", ifBound(val, cat(node(val)), cat("")), ")"); auto ignoringSwitchCases = [](auto stmt) { return anyOf(stmt, switchCase(subStmt(stmt))); }; makeRule(stmt(ignoringSwitchCases(stmt(isExpandedFromMacro("Q_UNREACHABLE")).bind(unr)), nextStmt(returnStmt(optionally(hasReturnValue(expr().bind(val)))).bind(ret))), {changeTo(node(unr), cat(makeUnreachableReturn, ";")), // TODO: why is the ; lost w/o this? changeTo(node(ret), cat(""))}, cat("use ", makeUnreachableReturn)); a.k.a qt-use-unreachable-return. subStmt() and nextStmt() are non-standard matchers. Also made a manual scan to update the patch to 6.10. Pick-to: 6.9 Change-Id: Ic612e11dce9180f5e3e81b377985332e6f26bacb Reviewed-by: Ivan Solovev <ivan.solovev@qt.io> Reviewed-by: Marc Mutz <marc.mutz@qt.io> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* QQuickWebEngineProfile: make the new ctor explicitMarc Mutz2025-02-101-1/+1
| | | | | | | | | | | | | A QString is a not a faithful representation of a QQuickWebEngineProfile, so the constructor should be explicit. Found in API-review. Amends d472a95b3b2e7783ab1c42a5fb6406f7eebf1c60. Pick-to: 6.9 Change-Id: I8f9091933bd0ef56c59315c2e6247e780fa7dbf6 Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* Add setting to enable back/forward cacheSzabolcs David2025-02-102-0/+26
| | | | | | | | | | Implement an option to speed up back/forward navigation with bfcache feature. (Disabled by default.) Fixes: QTBUG-131324 Change-Id: I5ddb45b6a23ef587e868162b26368f5bc4933742 Reviewed-by: Moss Heim <moss.heim@qt.io> Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
* QuickWebenginView: Fix crash when assessing m_profileCarl Schwan2025-01-311-0/+1
| | | | | | | | | | | | | | | | | | | | | Ensure the profile is initialized before calling m_profile, otherwise this will crash. This happens with the following code: WebEngineView { userScripts { collection: [ { injectionPoint: WebEngineScript.DocumentReady, sourceCode: scriptContent, worldId: WebEngineScript.UserWorld } ] } } Pick-to: 6.9 Change-Id: I9d2d626ea51fb619b32147d8883701b40eab6c6e Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* QQuickWebEngineProfilePrototype: Post API reviewAnu Aliyas2025-01-161-1/+1
| | | | | | | | | | The following changes are made based on the review comments: - Renamed the function argument of setStorageName(). The corresponding change in the source file is not needed, as it is using the current argument name. Change-Id: Id5a3bd5f1fe2b60ad522a76700edb9789e8546c8 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Rename JSTouchEventsEnabled to TouchEventsApiEnabledAllan Sandfeld Jensen2025-01-152-11/+11
| | | | | | | | | Api-review Pick-to: 6.9 Change-Id: I06c5400c50f30c7473bee8e82f9f63fad2875930 Reviewed-by: Michal Klocek <michal.klocek@qt.io> Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
* Ensure unique data path for the profileAnu Aliyas2024-12-061-0/+30
| | | | | | | | | | | Added data path verification to restrict profile creation. This change ensures that no two profiles can use the same data path. Any request to create a profile with the duplicate data path will now return nullptr. Change-Id: Ifb25861756775fb484b02a23c802bffb791c88bb Reviewed-by: Michael Brüning <michael.bruning@qt.io> Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* Add WebEngineProfilePrototype for profile creation from qmlAnu Aliyas2024-12-065-0/+415
| | | | | | | This is a wrapper designed to handle profile construction from qml. Change-Id: I6f3c9e06052c08e81422e148c75c599cc361be95 Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* Lazy initialization for offTheRecord settingAnu Aliyas2024-11-201-1/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | As per the current design when switching from profile from OTR to non-OTR requires valid storage name. If it is not there, then QtWebEngine display a warning message and and don't switch to disk based behavior for qml. This impose the restriction on qml initialization order, for non-OTR profile, the initialization should be of the order given below WebEngineProfile { offTheRecord: false storgaeName: 'Test' } Otherwise it won't switch to non-OTR profile. For example a setting like WebEngineProfile { StorageName: 'Test' offTheRecord: false } won’t create a non-OTR profile. Though from an end user perspective these two initialization are identical, the order of initialization is different and due to which these two settings yield different profiles. Added a single shot signal handler on the offTheRecord setter to handle such cases, and it will switch the profile to non-OTR mode only when the storage name is set. Amends 5f42c1b7877b0c74d939af0f04d09a23482bc74a Fixes: QTBUG-131397 Pick-to: 6.8 Change-Id: I1c1c21808cb49dfa3ba4340b000242a0f54e59e5 Reviewed-by: Michael Brüning <michael.bruning@qt.io> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit 3477d952575a8ad8a8ca70c04a7cd3aa5d7d5f81) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Correct behavior of JavscriptCanAccessClipboardMoss Heim2024-11-041-6/+14
| | | | | | | | | | | | | | | | Previously, sanitized clipboard writes were only enabled with JavascriptCanPaste AND JavascriptCanAccessClipboard enabled. This broke backward compatibility with code that expected it to only be enabled by JavascriptCanAccessClipboard. This compatibility is now restored. In the permission manager, all writes and reads are still controlled by ClipboardReadWrite. Pick-to: 6.8 Fixes: QTBUG-130599 Change-Id: I03dc2ea739782e475faacc0900804708c37763cc Reviewed-by: Michal Klocek <michal.klocek@qt.io> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Do not override signals in qml delegatesMichal Klocek2024-10-311-2/+4
| | | | | | | | | | | | | | Since 36478e25 in qtdeclarative overriding signals is reported as warning and will be dropped in the future as it is not supported. Drop 'accepted' and 'rejected' signals and use signals from base component, which is the "correct" way of handling it. Remove some logic coming from qqc1. Pick-to: 6.8 Change-Id: I3eeeca4b25fb866d0c6e3da01c1513afd85904f0 Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* Add setting for JS touch events APIMartin Negyokru2024-10-292-0/+32
| | | | | | | | | | | | | | | | | | Currently we enable the touch events API by default if a touch screen is detected by the system. Some websites use this api to decide if they are on a mobile device or desktop and base their design on it. This can cause unwanted results on touch screen laptops or other setups that emulate a fake touch device. Add option to explicitly set the touch events API. Keep old behavior if the option is not used. [ChangeLog][Settings] Added JSTouchEventsEnabled setting Task-number: QTBUG-115764 Change-Id: Ica860f54557ee21f00c63a3d30f9074a0278bc8c Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Make download API asynchronousSzabolcs David2024-10-241-11/+10
| | | | | | | | | | | | | | | | | | | | | | | | Modify the already existing downloadRequest() API. Now the requests not necessarily have to be answered in a directly connected signal handler and the API users can postpone their user's decision. The only exceptions are automatically accepted save page requests. There is no better place to call their callback than directly after the signal emission. Adapt auto tests to the new lifecycle of download items. Modify the quicknanobrowser example to use a simple async method to wait for the user's decision. Keep simplebrowser to use its old synchronous method to illustrate that it's still possible. Correct documentation at some places. [ChangeLog] QWebEngineProfile::downloadRequested() is not limited to synchronous usage anymore. QWebEngineDownloadRequest can be accepted or rejected later without blocking the browsing session. Fixes: QTBUG-118584 Change-Id: Ic1be6508126574dc77aa686f85bf35feafdb080d Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
* Add PreferCSSMarginsForPrinting to QWebEngineSettingsSzabolcs David2024-10-212-0/+26
| | | | | | | | | | | | Add an option to choose between margins of the specified QPageLayout and the margins of the @media rules of CSS. [ChangeLog] New API added to QWebEngineSettings to optionally prefer CSS margin rules over QPageLayout for printing results. Task-number: QTBUG-58669 Change-Id: Idfec2deca0d326ea9339f67bce937e24ae5128f2 Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* Add PrintHeaderAndFooter to WebEngineSettingsSzabolcs David2024-10-172-0/+28
| | | | | | | | | | Allow users to generate basic header and footer when printing. Pages will contain the URL, title, date and the page number. Add corresponding WebEngineSettings flags to the Core and Quick APIs. Task-number: QTBUG-70125 Change-Id: Icadd15c16267a204c900aa6895db73b2172e47bc Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
* QQuickWebEngineView: silence deprecation warningVladimir Belyavsky2024-09-171-1/+1
| | | | | | | | Silence deprecation warning "'QJSValue::QJSValue': Use fromUtf8, QStringLiteral, or QLatin1StringView" when build with -DFEATURE_webengine_printing_and_pdf=OFF Change-Id: I2f165329caf6fc8bab4ec78c828c5d4a3cb923e7 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
* Fix not working popup with qquick on eglfsMichal Klocek2024-08-281-2/+3
| | | | | | | | | | | After refactoring in 5d1ef38 we lost popups with qquick. Unfortunately we do not have tests for it as we do not run eglfs on ci. Pick-to: 6.8 6.7 Fixes: QTBUG-119908 Change-Id: Iea6cadf96dcac488898bb31132938fe8020d4d79 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Make QQuickWebEngineDownloadRequest publicAllan Sandfeld Jensen2024-08-233-20/+10
| | | | | | | | | | We only really need the QWebEngineDownloadRequest, but the fact it was just that was in the private header. Pick-to: 6.8 Fixes: QTBUG-120370 Change-Id: I9bcd79e068e67ec0ed07ae31cfb2a0d4e011e22b Reviewed-by: Anu Aliyas <anu.aliyas@qt.io>
* Doc: Replace \instantiates with \nativetypePaul Wicking2024-08-206-12/+12
| | | | | | | | | | | Since the implementation of the `\nativetype`-command in QDoc, the `\instantiates`-command is deprecated. Replace the use of the deprecated command in favor of its replacement. Pick-to: 6.8 Task-number: QTBUG-128216 Change-Id: I10cad9942e34301ded99c7014c1c70375e0698e1 Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>