Difference between revisions of "Category:Developing Qt::Qt Script"

From Qt Wiki
Jump to: navigation, search
 
Line 1: Line 1:
=QtScript=
+
[toc align_right="yes" depth="2"]
 +
 
 +
= QtScript =
  
 
QtScript provides a JavaScript environment for Qt applications and libraries.
 
QtScript provides a JavaScript environment for Qt applications and libraries.
  
The [http://doc.qt.nokia.com/latest/qtscript.html QtScript module] ''[doc.qt.nokia.com]'' provides a C++ <span class="caps">API</span> for embedding JavaScript into your application or library. The basic JavaScript environment (based on the [http://www.ecma-international.org/publications/standards/Ecma-262.htm <span class="caps">ECMAS</span>cript standard] ''[ecma-international.org]'') can be extended through a rich <span class="caps">API</span>.
+
The &quot;QtScript module&amp;quot;:http://doc.qt.nokia.com/latest/qtscript.html provides a C++ API for embedding JavaScript into your application or library. The basic JavaScript environment (based on the &quot;ECMAScript standard&amp;quot;:http://www.ecma-international.org/publications/standards/Ecma-262.htm) can be extended through a rich API.
  
==Mission Statement==
+
== Mission Statement ==
  
The long-term goal of QtScript development is for QtScript to be '''the''' JavaScript engine used in the Qt/Nokia software stack, providing great integration with other Qt/C++ components (notably <span class="caps">QML</span>), and delivering the performance needed by JavaScript-intensive Qt applications.
+
The long-term goal of QtScript development is for QtScript to be '''the''' JavaScript engine used in the Qt/Nokia software stack, providing great integration with other Qt/C++ components (notably QML), and delivering the performance needed by JavaScript-intensive Qt applications.
  
==Getting Involved==
+
== Getting Involved ==
  
There is a mailing list for QtScript development. You can subscribe to it at http://lists.qt.nokia.com/mailman/listinfo/qt-script ''[lists.qt.nokia.com]''
+
There is a mailing list for QtScript development. You can subscribe to it at &quot;http://lists.qt.nokia.com/mailman/listinfo/qt-script&amp;quot;:http://lists.qt.nokia.com/mailman/listinfo/qt-script
  
We have an <span class="caps">IRC</span> channel on FreeNode: #qt-script (For a full list of <span class="caps">IRC</span> channels of interest to Qt developers, see [[OnlineCommunities]].)
+
We have an IRC channel on FreeNode: #qt-script (For a full list of IRC channels of interest to Qt developers, see [[OnlineCommunities]].)
  
For contributing to QtScript, see the [http://qt.gitorious.org/qt/pages/QtContributionGuidelines Qt Contribution Guidelines] ''[qt.gitorious.org]''.
+
For contributing to QtScript, see the &quot;Qt Contribution Guidelines&amp;quot;:http://qt.gitorious.org/qt/pages/QtContributionGuidelines.
  
==Scope==
+
== Scope ==
  
 
The scope of QtScript — or more precisely, the scope of JavaScript support in Qt — has grown since the QtScript module was introduced in Qt 4.3.
 
The scope of QtScript — or more precisely, the scope of JavaScript support in Qt — has grown since the QtScript module was introduced in Qt 4.3.
  
===Making Applications Scriptable===
+
=== Making Applications Scriptable ===
  
 
The original scope of QtScript was to make Qt applications scriptable, primarily by making it easy to export Qt/C++ objects (properties and methods) to JavaScript.
 
The original scope of QtScript was to make Qt applications scriptable, primarily by making it easy to export Qt/C++ objects (properties and methods) to JavaScript.
  
===QtWebKit===
+
=== QtWebKit ===
 
 
The [http://doc.qt.nokia.com/4.7/qtwebkit.html QtWebKit module] ''[doc.qt.nokia.com]'' was introduced in Qt 4.4. It includes a JavaScript runtime. Ideally, QtScript and QtWebKit would share the JavaScript implementation, and you would be able to use the QtScript <span class="caps">API</span> to access the browser JavaScript environment from C++. This work can be tracked at http://bugreports.qt.nokia.com/browse/QTWEBKIT-2 .
 
 
 
===Qt Quick===
 
 
 
In Qt 4.7, [http://doc.qt.nokia.com/4.7/qtquick.html Qt Quick] ''[doc.qt.nokia.com]'' was introduced. The basis of Qt Quick is the <span class="caps">QML</span> language. <span class="caps">QML</span> effectively embeds JavaScript into the language. The <span class="caps">QML</span>/JS implementation is powered by QtScript. In other words, Qt Quick relies on QtScript to perform well and be standards-compliant.
 
 
 
====What’s <span class="caps">NOT</span> in Scope====
 
 
 
Providing Qt integration with languages other than JavaScript (such as Python and Lua).
 
 
 
==History==
 
 
 
===<span class="caps">QSA</span>===
 
 
 
QtScript was preceded by <span class="caps">QSA</span> — [http://doc.qt.nokia.com/qsa-1.2.2/index.html Qt Script for Applications] ''[doc.qt.nokia.com]''. <span class="caps">QSA</span> implements a subset of a draft of the (never-completed) <span class="caps">ECMAS</span>cript 4 language. It also contained <span class="caps">API</span> for embedding script editing and “user script execution” into your application (<span class="caps">QSA</span> Workbench).
 
 
 
===Qt 4.3===
 
  
The QtScript module introduced in Qt 4.3 was inspired by <span class="caps">QSA</span>, but doesn’t share any <span class="caps">API</span> or implementation.
+
The &quot;QtWebKit module&amp;quot;:http://doc.qt.nokia.com/4.7/qtwebkit.html was introduced in Qt 4.4. It includes a JavaScript runtime. Ideally, QtScript and QtWebKit would share the JavaScript implementation, and you would be able to use the QtScript API to access the browser JavaScript environment from C+''. This work can be tracked at http://bugreports.qt.nokia.com/browse/QTWEBKIT-2 .
 
+
<br />h3. Qt Quick
QtScript took the core idea of <span class="caps">QSA</span> (making Qt applications scriptable) and stripped away anything having to do with <span class="caps">GUI</span>. The scope of QtScript should be limited to JavaScript execution and essential C++ integration; script editing, graphical debugging and the like should be left to other components and tools (such as Qt Creator).
+
<br />In Qt 4.7, &quot;Qt Quick&amp;quot;:http://doc.qt.nokia.com/4.7/qtquick.html was introduced. The basis of Qt Quick is the QML language. QML effectively embeds JavaScript into the language. The QML/JS implementation is powered by QtScript. In other words, Qt Quick relies on QtScript to perform well and be standards-compliant.
 +
<br />h4. What's NOT in Scope
 +
<br />Providing Qt integration with languages other than JavaScript (such as Python and Lua).
 +
<br />h2. History
 +
<br />h3. QSA
 +
<br />QtScript was preceded by QSA — &quot;Qt Script for Applications&amp;quot;:http://doc.qt.nokia.com/qsa-1.2.2/index.html. QSA implements a subset of a draft of the (never-completed) ECMAScript 4 language. It also contained API for embedding script editing and &quot;user script execution&amp;quot; into your application (QSA Workbench).
 +
<br />h3. Qt 4.3
 +
<br />The QtScript module introduced in Qt 4.3 was inspired by QSA, but doesn't share any API or implementation.
 +
<br />QtScript took the core idea of QSA (making Qt applications scriptable) and stripped away anything having to do with GUI. The scope of QtScript should be limited to JavaScript execution and essential C''+ integration; script editing, graphical debugging and the like should be left to other components and tools (such as Qt Creator).
  
 
The QtScript runtime was built on an in-house-developed, bytecode-based interpreter that performed well for its time.
 
The QtScript runtime was built on an in-house-developed, bytecode-based interpreter that performed well for its time.
  
===Qt 4.4===
+
=== Qt 4.4 ===
 
 
Qt 4.4 added the [http://doc.qt.nokia.com/4.7/qscriptengineagent.html QScriptEngineAgent] ''[doc.qt.nokia.com]'' class, which provides an <span class="caps">API</span> for hooking into low-level events in the script engine. This class could be used to implement debugging- and profiling-related tools for QtScript.
 
  
Qt 4.4 also introduced [http://doc.qt.nokia.com/4.7/qscriptclass.html QScriptClass] ''[doc.qt.nokia.com]'', an interface for implementing “catch-all” (interceptor-based) access to script objects; and [http://doc.qt.nokia.com/4.7/qscriptstring.html QScriptString] ''[doc.qt.nokia.com]'', a class that represents interned property names (for faster comparison and property access).
+
Qt 4.4 added the &quot;QScriptEngineAgent&amp;quot;:http://doc.qt.nokia.com/4.7/qscriptengineagent.html class, which provides an API for hooking into low-level events in the script engine. This class could be used to implement debugging- and profiling-related tools for QtScript.
  
===Qt 4.5===
+
Qt 4.4 also introduced &quot;QScriptClass&amp;quot;:http://doc.qt.nokia.com/4.7/qscriptclass.html, an interface for implementing &quot;catch-all&amp;quot; (interceptor-based) access to script objects; and &quot;QScriptString&amp;quot;:http://doc.qt.nokia.com/4.7/qscriptstring.html, a class that represents interned property names (for faster comparison and property access).
  
Qt 4.5 introduced the [http://doc.qt.nokia.com/4.5/qtscripttools.html QtScriptTools] ''[doc.qt.nokia.com]'' module, which provides a graphical debugger for QtScript.
+
=== Qt 4.5 ===
  
===Qt 4.6===
+
Qt 4.5 introduced the &quot;QtScriptTools&amp;quot;:http://doc.qt.nokia.com/4.5/qtscripttools.html module, which provides a graphical debugger for QtScript.
  
No new QtScript <span class="caps">API</span> was introduced in Qt 4.6. However, under the hood a significant change was made: The in-house interpreter was replaced by JavaScriptCore, the JavaScript runtime used by WebKit. JavaScriptCore features a Just-In-Time (<span class="caps">JIT</span>) compiler, and this contributed to dramatically improved performance of long-running scripts (see [http://labs.qt.nokia.com/2009/11/23/qtscript-in-46/ this blog] ''[labs.qt.nokia.com]'').
+
=== Qt 4.6 ===
  
The constraint for replacing the engine was to preserve QtScript’s source and binary compability, but also maintain behavorial compatibility. This presented a challenge; the QtScript <span class="caps">API</span> was not originally designed with replacement of the JavaScript back-end in mind, and so parts of the <span class="caps">API</span> exposed implementation details (tracked at http://bugreports.qt.nokia.com/browse/QTBUG-15571). This made it necessary to patch JavaScriptCore in select places (tracked at http://bugreports.qt.nokia.com/browse/QTBUG-11467).
+
No new QtScript API was introduced in Qt 4.6. However, under the hood a significant change was made: The in-house interpreter was replaced by JavaScriptCore, the JavaScript runtime used by WebKit. JavaScriptCore features a Just-In-Time (JIT) compiler, and this contributed to dramatically improved performance of long-running scripts (see &quot;this blog&amp;quot;:http://labs.qt.nokia.com/2009/11/23/qtscript-in-46/).
  
The patches to JavaScriptCore makes it incompatible with the version that QtWebKit expects, which is obviously the big blocker for being able to mix the QtScript <span class="caps">API</span> with the QtWebKit <span class="caps">API</span>.
+
The constraint for replacing the engine was to preserve QtScript's source and binary compability, but also maintain behavorial compatibility. This presented a challenge; the QtScript API was not originally designed with replacement of the JavaScript back-end in mind, and so parts of the API exposed implementation details (tracked at http://bugreports.qt.nokia.com/browse/QTBUG-15571). This made it necessary to patch JavaScriptCore in select places (tracked at http://bugreports.qt.nokia.com/browse/QTBUG-11467).
  
===Qt 4.7===
+
The patches to JavaScriptCore makes it incompatible with the version that QtWebKit expects, which is obviously the big blocker for being able to mix the QtScript API with the QtWebKit API.
  
Qt 4.7 introduced [http://doc.qt.nokia.com/4.7/qscriptprogram.html QScriptProgram] ''[doc.qt.nokia.com]'', a class for retaining the compiled form a script for faster repeated execution. QtScript’s copy of JavaScriptCore was updated to a more recent version, which provided a nice speed boost, and the delta between QtScript’s patched JavaScriptCore and the upstream version was made smaller.
+
=== Qt 4.7 ===
  
==Tests and Benchmarks==
+
Qt 4.7 introduced &quot;QScriptProgram&amp;quot;:http://doc.qt.nokia.com/4.7/qscriptprogram.html, a class for retaining the compiled form a script for faster repeated execution. QtScript's copy of JavaScriptCore was updated to a more recent version, which provided a nice speed boost, and the delta between QtScript's patched JavaScriptCore and the upstream version was made smaller.
  
The autotest results effectively act as a progress indicator and “level of completeness” when QtScript is ported to a new back-end, such as JavaScriptCore or V8.<br /> There ''will'' be differences in the back-ends that are difficult to mask (e.g. different wording in error messages), but we try to keep the tests as back-end-agnostic as possible, so that the same tests can be run against different versions of Qt/QtScript.
+
== Tests and Benchmarks ==
  
===Imported Test Suites===
+
The QtScript autotests are located in the <code>tests/auto<code> directory in the Qt repository (all subdirectories with prefix &quot;qscript&amp;quot; — see script.pro).
  
===Benchmarks===
+
The autotest results effectively act as a progress indicator and &quot;level of completeness&amp;quot; when QtScript is ported to a new back-end, such as JavaScriptCore or V8.<br />There ''will'' be differences in the back-ends that are difficult to mask (e.g. different wording in error messages), but we try to keep the tests as back-end-agnostic as possible, so that the same tests can be run against different versions of Qt/QtScript.
  
In addition to benchmarks for the C++ <span class="caps">API</span>, the SunSpider and V8 benchmarks have been imported.<br /> These benchmarks can be used to compare the performance of different versions of Qt/QtScript, in particular to ensure that there are no performance regressions between versions.
+
=== Imported Test Suites ===
  
==Bug Tracker==
+
In addition to tests for the C++ API, there are two imported JavaScript test suites: </code>qscriptjstestsuite</code> (from the Mozilla project), and </code>qscriptv8testsuite</code> (from the V8 project), that have been integrated into Qt's automated test system. These are useful for testing ECMA compliance and compatibility with other JS engines. A handful of the tests are failing on various Qt platforms. The failures are marked as expected, since they are due to the back-end, which is now maintained outside of Qt. However, not all failures have been reported upstream yet, which is something we should try to fix (http://bugreports.qt.nokia.com/browse/QTBUG-16606).
  
We use the [http://bugreports.qt.nokia.com Qt Bug Tracker] ''[bugreports.qt.nokia.com]'' to track QtScript bugs; QtScript has its own [http://bugreports.qt.nokia.com/browse/QTBUG/component/19162 category] ''[bugreports.qt.nokia.com]''. If a bug is specific to the back-end, we report it in the corresponding upstream bug tracker (e.g. http://bugs.webkit.org for JavaScriptCore bugs).
+
=== Benchmarks ===
  
==QtScript and JavaScriptCore==
+
The QtScript benchmarks are located in the <code>tests/benchmarks/script<code> directory in the Qt repository.<br />In addition to benchmarks for the C++ API, the SunSpider and V8 benchmarks have been imported.<br />These benchmarks can be used to compare the performance of different versions of Qt/QtScript, in particular to ensure that there are no performance regressions between versions.
  
The QtScript implementation introduced in Qt 4.6 uses internal JavaScriptCore <span class="caps">API</span>. An effort was started to upstream QtScript to the WebKit project (see [http://www.pubbs.net/200908/webkit/55633-webkit-dev-qtish-api-for-javascriptcore.html this thread] ''[pubbs.net]''), using only the public JavaScriptCore C <span class="caps">API</span>, since that <span class="caps">API</span> is stable and remains source/binary compatible. Information about this project can be found at https://trac.webkit.org/wiki/QtScript ''[trac.webkit.org]''.
+
== Bug Tracker ==
  
The main challenge with this project is that the C <span class="caps">API</span> is limited compared to QtScript’s <span class="caps">API</span>, so a lot of functionality will have to be added to the C <span class="caps">API</span> before the QtScript <span class="caps">API</span> can be completed on top.
+
We use the &quot;Qt Bug Tracker&amp;quot;:http://bugreports.qt.nokia.com to track QtScript bugs; QtScript has its own &quot;category&amp;quot;:http://bugreports.qt.nokia.com/browse/QTBUG/component/19162. If a bug is specific to the back-end, we report it in the corresponding upstream bug tracker (e.g. http://bugs.webkit.org for JavaScriptCore bugs).
  
This project is currently paused while [http://code.google.com/p/v8/ V8] ''[code.google.com]'' is being investigated as an alternative.
+
== QtScript and JavaScriptCore ==
  
==QtScript and V8==
+
The QtScript implementation introduced in Qt 4.6 uses internal JavaScriptCore API. An effort was started to upstream QtScript to the WebKit project (see &quot;this thread&amp;quot;:http://www.pubbs.net/200908/webkit/55633-webkit-dev-qtish-api-for-javascriptcore.html), using only the public JavaScriptCore C API, since that API is stable and remains source/binary compatible. Information about this project can be found at &quot;https://trac.webkit.org/wiki/QtScript&amp;quot;:https://trac.webkit.org/wiki/QtScript.
  
See [http://developer.qt.nokia.com/wiki/V8_Port separate article] ''[developer.qt.nokia.com]''.
+
The main challenge with this project is that the C API is limited compared to QtScript's API, so a lot of functionality will have to be added to the C API before the QtScript API can be completed on top.
  
===There is only one article in "Developing_Qt -&gt; Qt_Script":===
+
This project is currently paused while &quot;V8&amp;quot;:http://code.google.com/p/v8/ is being investigated as an alternative.
  
===V===
+
== QtScript and V8 ==
* [[V8 Port|V8_Port]]
 

Revision as of 08:53, 24 February 2015

[toc align_right="yes&quot; depth="2&quot;]

QtScript

QtScript provides a JavaScript environment for Qt applications and libraries.

The "QtScript module&quot;:http://doc.qt.nokia.com/latest/qtscript.html provides a C++ API for embedding JavaScript into your application or library. The basic JavaScript environment (based on the "ECMAScript standard&quot;:http://www.ecma-international.org/publications/standards/Ecma-262.htm) can be extended through a rich API.

Mission Statement

The long-term goal of QtScript development is for QtScript to be the JavaScript engine used in the Qt/Nokia software stack, providing great integration with other Qt/C++ components (notably QML), and delivering the performance needed by JavaScript-intensive Qt applications.

Getting Involved

There is a mailing list for QtScript development. You can subscribe to it at "http://lists.qt.nokia.com/mailman/listinfo/qt-script&quot;:http://lists.qt.nokia.com/mailman/listinfo/qt-script

We have an IRC channel on FreeNode: #qt-script (For a full list of IRC channels of interest to Qt developers, see OnlineCommunities.)

For contributing to QtScript, see the "Qt Contribution Guidelines&quot;:http://qt.gitorious.org/qt/pages/QtContributionGuidelines.

Scope

The scope of QtScript — or more precisely, the scope of JavaScript support in Qt — has grown since the QtScript module was introduced in Qt 4.3.

Making Applications Scriptable

The original scope of QtScript was to make Qt applications scriptable, primarily by making it easy to export Qt/C++ objects (properties and methods) to JavaScript.

QtWebKit

The "QtWebKit module&quot;:http://doc.qt.nokia.com/4.7/qtwebkit.html was introduced in Qt 4.4. It includes a JavaScript runtime. Ideally, QtScript and QtWebKit would share the JavaScript implementation, and you would be able to use the QtScript API to access the browser JavaScript environment from C+. This work can be tracked at http://bugreports.qt.nokia.com/browse/QTWEBKIT-2 .
h3. Qt Quick
In Qt 4.7, "Qt Quick&quot;:http://doc.qt.nokia.com/4.7/qtquick.html was introduced. The basis of Qt Quick is the QML language. QML effectively embeds JavaScript into the language. The QML/JS implementation is powered by QtScript. In other words, Qt Quick relies on QtScript to perform well and be standards-compliant.
h4. What's NOT in Scope
Providing Qt integration with languages other than JavaScript (such as Python and Lua).
h2. History
h3. QSA
QtScript was preceded by QSA — "Qt Script for Applications&quot;:http://doc.qt.nokia.com/qsa-1.2.2/index.html. QSA implements a subset of a draft of the (never-completed) ECMAScript 4 language. It also contained API for embedding script editing and "user script execution&quot; into your application (QSA Workbench).
h3. Qt 4.3
The QtScript module introduced in Qt 4.3 was inspired by QSA, but doesn't share any API or implementation.
QtScript took the core idea of QSA (making Qt applications scriptable) and stripped away anything having to do with GUI. The scope of QtScript should be limited to JavaScript execution and essential C+ integration; script editing, graphical debugging and the like should be left to other components and tools (such as Qt Creator).

The QtScript runtime was built on an in-house-developed, bytecode-based interpreter that performed well for its time.

Qt 4.4

Qt 4.4 added the "QScriptEngineAgent&quot;:http://doc.qt.nokia.com/4.7/qscriptengineagent.html class, which provides an API for hooking into low-level events in the script engine. This class could be used to implement debugging- and profiling-related tools for QtScript.

Qt 4.4 also introduced "QScriptClass&quot;:http://doc.qt.nokia.com/4.7/qscriptclass.html, an interface for implementing "catch-all&quot; (interceptor-based) access to script objects; and "QScriptString&quot;:http://doc.qt.nokia.com/4.7/qscriptstring.html, a class that represents interned property names (for faster comparison and property access).

Qt 4.5

Qt 4.5 introduced the "QtScriptTools&quot;:http://doc.qt.nokia.com/4.5/qtscripttools.html module, which provides a graphical debugger for QtScript.

Qt 4.6

No new QtScript API was introduced in Qt 4.6. However, under the hood a significant change was made: The in-house interpreter was replaced by JavaScriptCore, the JavaScript runtime used by WebKit. JavaScriptCore features a Just-In-Time (JIT) compiler, and this contributed to dramatically improved performance of long-running scripts (see "this blog&quot;:http://labs.qt.nokia.com/2009/11/23/qtscript-in-46/).

The constraint for replacing the engine was to preserve QtScript's source and binary compability, but also maintain behavorial compatibility. This presented a challenge; the QtScript API was not originally designed with replacement of the JavaScript back-end in mind, and so parts of the API exposed implementation details (tracked at http://bugreports.qt.nokia.com/browse/QTBUG-15571). This made it necessary to patch JavaScriptCore in select places (tracked at http://bugreports.qt.nokia.com/browse/QTBUG-11467).

The patches to JavaScriptCore makes it incompatible with the version that QtWebKit expects, which is obviously the big blocker for being able to mix the QtScript API with the QtWebKit API.

Qt 4.7

Qt 4.7 introduced "QScriptProgram&quot;:http://doc.qt.nokia.com/4.7/qscriptprogram.html, a class for retaining the compiled form a script for faster repeated execution. QtScript's copy of JavaScriptCore was updated to a more recent version, which provided a nice speed boost, and the delta between QtScript's patched JavaScriptCore and the upstream version was made smaller.

Tests and Benchmarks

The QtScript autotests are located in the tests/auto directory in the Qt repository (all subdirectories with prefix "qscript&quot; — see script.pro).

The autotest results effectively act as a progress indicator and "level of completeness&quot; when QtScript is ported to a new back-end, such as JavaScriptCore or V8.
There will be differences in the back-ends that are difficult to mask (e.g. different wording in error messages), but we try to keep the tests as back-end-agnostic as possible, so that the same tests can be run against different versions of Qt/QtScript.

Imported Test Suites

In addition to tests for the C++ API, there are two imported JavaScript test suites: qscriptjstestsuite (from the Mozilla project), and qscriptv8testsuite (from the V8 project), that have been integrated into Qt's automated test system. These are useful for testing ECMA compliance and compatibility with other JS engines. A handful of the tests are failing on various Qt platforms. The failures are marked as expected, since they are due to the back-end, which is now maintained outside of Qt. However, not all failures have been reported upstream yet, which is something we should try to fix (http://bugreports.qt.nokia.com/browse/QTBUG-16606).

Benchmarks

The QtScript benchmarks are located in the tests/benchmarks/script directory in the Qt repository.
In addition to benchmarks for the C++ API, the SunSpider and V8 benchmarks have been imported.
These benchmarks can be used to compare the performance of different versions of Qt/QtScript, in particular to ensure that there are no performance regressions between versions.

Bug Tracker

We use the "Qt Bug Tracker&quot;:http://bugreports.qt.nokia.com to track QtScript bugs; QtScript has its own "category&quot;:http://bugreports.qt.nokia.com/browse/QTBUG/component/19162. If a bug is specific to the back-end, we report it in the corresponding upstream bug tracker (e.g. http://bugs.webkit.org for JavaScriptCore bugs).

QtScript and JavaScriptCore

The QtScript implementation introduced in Qt 4.6 uses internal JavaScriptCore API. An effort was started to upstream QtScript to the WebKit project (see "this thread&quot;:http://www.pubbs.net/200908/webkit/55633-webkit-dev-qtish-api-for-javascriptcore.html), using only the public JavaScriptCore C API, since that API is stable and remains source/binary compatible. Information about this project can be found at "https://trac.webkit.org/wiki/QtScript&quot;:https://trac.webkit.org/wiki/QtScript.

The main challenge with this project is that the C API is limited compared to QtScript's API, so a lot of functionality will have to be added to the C API before the QtScript API can be completed on top.

This project is currently paused while "V8&quot;:http://code.google.com/p/v8/ is being investigated as an alternative.

QtScript and V8

This category currently contains no pages or media.