What js engine qt use under the hood?
-
Hi!
I little bit confuse about what does js engine qt use?
I know about QML and Qt WebKit Widgets.
As I can see Qt WebKit Widgets uses http://doc.qt.io/qt-5/qtwebkit-bridge.html that uses http://code.woboq.org/qt5/qtdeclarative/src/qml/jsapi/qjsengine.cpp.html that uses v8 google js engine.
I wonder that I can debug JS inside QML block in qtcreator. What does engine qt use here?Besides I hear that qt has got own virtual machine/engine for js - v4vm.
But also I see that qt forbid qtwebkit/qtdeclarative and qtscipt http://wiki.qt.io/New-Features-in-Qt-5.5#Deprecated_Functionality
Why?
How do you use js in future qt gui projects? -
Hi and welcome to devnet,
These modules are not forbidden, they are deprecated. You can still use them but should not start new software with them.
As for why, here you have the explanation for QtWebKit. For QtQuick 1, read the following mail thread.
Use the QML module which is the replacement for QtScript
-
Hi and welcome to devnet,
These modules are not forbidden, they are deprecated. You can still use them but should not start new software with them.
As for why, here you have the explanation for QtWebKit. For QtQuick 1, read the following mail thread.
Use the QML module which is the replacement for QtScript
-
The V4 engine
-
What platform is that ?
-
Then you should check the hpux family of mkspec
-
@SGaist As I can see in the code:
switch (mode) { case use_masm: case use_moth: { QV4::EvalISelFactory* iSelFactory = 0; if (mode == use_moth) { iSelFactory = new QV4::Moth::ISelFactory; #ifdef V4_ENABLE_JIT } else { iSelFactory = new QV4::JIT::ISelFactory; #endif // V4_ENABLE_JIT } QV4::ExecutionEngine vm(iSelFactory); QV4::Scope scope(&vm); QV4::ScopedContext ctx(scope, vm.rootContext());
My purpose are port qtdeclarative on the new platform.
First of all I'm going to add masm classes and some declaration statements in qv4global_p.h and qv4targetplatform_p.h.
My question is - What is Moth? Is it aot compiler for js or interpeter? Why the Moth's files are placed in compiler directory? -
That's something I can't answer, I haven't worked on the internals of the V4 engine. You should rather ask this on the development mailing list. You'll find there Qt's developers/maintainers (this forum is more user oriented). There's also the #qt IRC channel