Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
QML - extending an existing item
How to extend an existing WebView in QML (I mean adding background in C++) and still be able to use that in QML ?
Multiinheritance of QWebView and DeclarativeItem ?
task_struct last edited by
I think it is posible by using Qt private headers.
But that means rewrite the whole public header...
remy_david last edited by
I tried this approach but gave up after a day. This is tricky because private Qt headers are very hard to understand without Qt background knowledge.
Instead I use a QGraphicsProxyWidget with qmlRegisterType to extend and expose existing QWidget to QML.
In your case you could use QGraphicsWebView.
aabc last edited by
You can extend them on QML
I am not interested in extending via QML. I have to create new item via C++ and add it (register and use) in QML/C++.
Sfiet_Konstantin last edited by
It all depends on what you want to do with this webview. And I think using a QGraphicsWebView that is registered as a QDeclarativeItem may be a good idea.
Well, does anybody have a working files, that really works, could anybody leave working example here? ... documentation is quite mean on that...