Project ERROR: Unknown module(s) in QT: webkitwidgets
-
Hi! I get the error: Project ERROR: Unknown module(s) in QT:
webkitwidgets
when includedQWebView
.pro
QT += widgets core gui network webkitwidgets webenginewidgets concurrent
.h file
#include <QWebView>
or
#include <QtWebKitWidgets/QWebView>
Also when hover on the include it displays:
No such file or directory
Qt version:
5.7.1
.
I can't useQWebEngineView
because it breaks my application theme. How to includeQWebView
? Thanks. -
Hi
Please see here
https://forum.qt.io/topic/76739/webkit-status-2017Its no longer part of the official download.
-
Hi,
There is downloads as link says
https://github.com/annulen/webkit/releasesSo i think there is no need to build one yourself if you can find the right version
There is
qtwebkit_tp4_qt57_msvc2015_x64.zip
which might suit you fine? -
Ok. I need
x86
. So I have downloaded theqtwebkit_tp4_qt57_msvc2015_x86.zip
.For example:
Path:C:\Qt\5.7\msvc2015
So I need to copy it to the
Qt
directory? -
@Cobra91151
Thats a good question how to correctly install.
But yes, it should be copied into place so the module etc works
but never tried it myself :)There is no install doc in zip or anything like that?
-
The problem now is with the object:
test.h
QtWebView *mapBrowserView;
Errors:
error: C2143: syntax error: missing ';' before '*' error: C4430: missing type specifier - int assumed. Note: C++ does not support default-int
So it doesn't work. I think installation should be different.
Using QtWebKit in your project
https://github.com/annulen/webkit/wiki/Using-QtWebKit-in-your-projectI will try to compile it.
-
@Cobra91151
Ok, i assume it would be precompiled as else no reason for compiler versions.- It seems I have circular include QtWebView but I included it only once. It's strange.
You can turn on Include view and see if something shows up
-
My includes screenshot:
Maybe this project has (https://github.com/annulen/webkit/releases) circular include, or bugs in the code.
Also I have downloadedqtwebview-opensource-src-5.7.1
from officialQt
source. But I don't know where to install it? Is there any documentation link how to installsubmodules
? Thanks. -
@Cobra91151 said in Project ERROR: Unknown module(s) in QT: webkitwidgets:
But I don't know where to install it? Is there any documentation link how to install submodules? Thanks.
Hi, normally you would do
qmake
make
make installfor such a source zip
-
I get
'qmake' is not recognized as an internal or external command, operable program or batch file.
when running onqtwebview-opensource-src-5.7.1
(Developer Command Prompt for VS2015)?I have these files after extraction from archive:
Should I copy these files to the path:
C:\Qt\5.7\Src\qtbase
and qmake
make
make install? -
I have reinstall
Qt 5.7.1
and my .pro include isQT += widgets core gui network webview concurrent
test.h
#include <QtWebView>
But the error is the same when initialize
QtWebView *mapBrowserView;
QtWebView is not the class, it is the namespace, image:
-
Now I have figured it out -
Qt WebView provides a way to display web content in a QML application
but I'm developingWin API
application only forWindows
OS. So it will not work. -
So here is how I have fixed it:
- Copy the contents of the archive
qtwebkit_tp4_qt57_msvc2015_x86.zip
toC:\Qt\5.7\msvc2015
; - Include
webkitwidgets
to.pro
file; - Include
#include <QtWebKitWidgets/QWebView>
- Initialized the
QWebView *mapBrowserView;
object;
Now it's all compile and work.
- Copy the contents of the archive
-
@Cobra91151 Hi i also face same issue, you have any Qtwebkitwidgets install setup document?
-