WebEngine QML Type
提供访问所有网络引擎视图共享的默认设置和配置文件的权限。更多
Import Statement: | import QtWebEngine |
Since: | QtWebEngine 1.1 |
属性
- defaultProfile : WebEngineProfile
(since QtWebEngine 1.1)
- settings : WebEngineSettings
(since QtWebEngine 1.1)
方法
- WebEngineScript script()
(since QtWebEngine 6.2)
详细说明
WebEngine 单例类型可访问默认配置文件和所有网络引擎视图共享的默认设置。如以下代码片段所示,它可用于全局更改设置:
Component.onCompleted: { WebEngine.settings.pluginsEnabled = true; }
属性文档
defaultProfile : WebEngineProfile |
settings : WebEngineSettings |
方法文档
|
构造WebEngineScript ,可以使用WebEngineScriptCollection 为WebEngineView.userScripts 或WebEngineProfile.userScripts 设置并插入到用户脚本集合中。
该方法在 QtWebEngine 6.2 中引入。
© 2025 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.