Building-QtWebKit-for-Blackberry: Difference between revisions

From Qt Wiki
Jump to navigation Jump to search
No edit summary
 
No edit summary
Line 1: Line 1:
=Building Qt 5 QtWebKit for BlackBerry=
[[Category:BlackBerry]]<br />[[Category:HowTo]]<br />[[Category:Developing_with_Qt::Qt 5]]


==Setting up the environment==
[toc align_right=&quot;yes&amp;quot; depth=&quot;2&amp;quot;]


See [[BlackBerry]] for instructions. Furthermore see [[Building-Qt5-for-Blackberry|Building Qt5 for Blackberry]] as a prerequisite.
= Building Qt 5 QtWebKit for BlackBerry =


==Getting the source==
== Setting up the environment ==
 
See [[Blackberry]] for instructions. Furthermore see [[Building Qt5 for Blackberry]] as a prerequisite.
 
== Getting the source ==


We will clone the git repository of webkit from Gitorious. Note that this takes a very long time and includes lots of test data, leading to a whopping 5GB disk space requirement for the checkout.
We will clone the git repository of webkit from Gitorious. Note that this takes a very long time and includes lots of test data, leading to a whopping 5GB disk space requirement for the checkout.


==Building==
<code><br />$ git clone git://gitorious.org/webkit/webkit.git<br /></code>
 
== Building ==


There are two ways of building QtWebKit:
There are two ways of building QtWebKit:


===Usage/Testing===
=== Usage/Testing ===


The suggested way is to build QtWebKit just like any other Qt5 module via QMake. See [[Building-Qt5-for-Blackberry|Building Qt5 for Blackberry]] on how to call QMake.
The suggested way is to build QtWebKit just like any other Qt5 module via QMake. See [[Building Qt5 for Blackberry]] on how to call QMake.


===Development===
=== Development ===


There is a second process of building QtWebKit which differs from the other Qt5 modules. This is the suggested way to use when you want to develop QtWebKit. you still have to have configured your environment to use the <span class="caps">BBNDK</span> as described in [[BlackBerry]]! Especially ensure that the QMake binary in your <span class="caps">PATH</span> is the Blackberry version.
There is a second process of building QtWebKit which differs from the other Qt5 modules. This is the suggested way to use when you want to develop QtWebKit. you still have to have configured your environment to use the BBNDK as described in [[Blackberry]]! Especially ensure that the QMake binary in your PATH is the Blackberry version.


This will compile QtWebKit for <span class="caps">QNX</span> in a folder called WebKitBuild/Release in your webkit checkout.
<code><br />$ cd webkit<br />$ # here &lt;N&amp;gt; is the number of parallel make jobs to run. This is often set to &lt;No. of CPU cores + 1&amp;gt;. adapt this<br />$ perl Tools/Scripts/webkit-build —qt —install-libs=&quot;$(qmake -query QT_INSTALL_PREFIX)&quot; —makeargs=&quot;<s>j&amp;amp;lt;N&amp;amp;gt;&quot;<br /></code>
<br />This will compile QtWebKit for QNX in a folder called WebKitBuild/Release in your webkit checkout.
<br />After this process, you should have a Qt5 QtWebKit located in your Qt install prefix (i.e. $HOME/development/qnx/qt5 or in C:stall, depending of your operating system</s> if you followed the other howtos).


After this process, you should have a Qt5 QtWebKit located in your Qt install prefix (i.e. $HOME/development/qnx/qt5 or in C:\dev\qt5install, depending of your operating system – if you followed the other howtos).
=== See also ===


===See also===
* [[Building Qt5 for Blackberry]]
* [[A HelloWorld using the Blackberry NDK CLI tools]]
* [[Building_and_Deploying_Qt_Applications_to_the_Playbook]]
* [[Deploying_Qt_to_a_central_place_on_Blackberry_devices]]


* [[Building-Qt5-for-Blackberry|Building Qt5 for Blackberry]]
== Known Issues ==
* [[A-HelloWorld-using-the-Blackberry-NDK-CLI-tools|A HelloWorld using the Blackberry <span class="caps">NDK</span> <span class="caps">CLI</span> tools]]
* [[Building and Deploying Qt Applications to the Playbook|Building_and_Deploying_Qt_Applications_to_the_Playbook]]
* [[Deploying Qt to a central place on Blackberry devices|Deploying_Qt_to_a_central_place_on_Blackberry_devices]]


==Known Issues==
=== WebKit1/C++ ===


===WebKit1/C++===
QtWebKit applications using the WebKit1/C++ API are a bad fit for touch devices like the PlayBook. To simulate mouse events out of touch events, call the following on your QWebView:


QtWebKit applications using the WebKit1/C++ <span class="caps">API</span> are a bad fit for touch devices like the PlayBook. To simulate mouse events out of touch events, call the following on your QWebView:
<code><br />webView-&gt;setAttribute(Qt::WA_AcceptTouchEvents, false);<br /></code>


If you do not do this, touch events are accpted and delegated to the JavaScript, but you will not be able to interact with the WebView, meaning: You cannot scroll, click links or do anything with it.
If you do not do this, touch events are accpted and delegated to the JavaScript, but you will not be able to interact with the WebView, meaning: You cannot scroll, click links or do anything with it.


===WebKit1/QML===
=== WebKit1/QML ===
 
Using QtWebKit with the old QtQuick1 <span class="caps">QML</span> <span class="caps">API</span> is currently broken. Eventually, this code will be moved from QtWebKit to the QtQuick1 module and reactivated.
 
===WebKit2/QML===
 
The new WebKit2/QML <span class="caps">API</span> is meant to be the holy grail of web-enabled apps running on touch devices. Sadly, this is not yet working properly, as it requires QtWebKit with OpenGL support. This is a work in progress, see https://bugs.webkit.org/show_bug.cgi?id=95466 .


===Categories:===
Using QtWebKit with the old QtQuick1 QML API is currently broken. Eventually, this code will be moved from QtWebKit to the QtQuick1 module and reactivated.


* [[:Category:BlackBerry|BlackBerry]]
=== WebKit2/QML ===
* [[:Category:Developing with Qt|Developing_with_Qt]]
** [[:Category:Developing with Qt::Qt-5|Qt 5]]
* [[:Category:HowTo|HowTo]]

Revision as of 09:55, 24 February 2015



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

Building Qt 5 QtWebKit for BlackBerry

Setting up the environment

See Blackberry for instructions. Furthermore see Building Qt5 for Blackberry as a prerequisite.

Getting the source

We will clone the git repository of webkit from Gitorious. Note that this takes a very long time and includes lots of test data, leading to a whopping 5GB disk space requirement for the checkout.

<br />$ git clone git://gitorious.org/webkit/webkit.git<br />

Building

There are two ways of building QtWebKit:

Usage/Testing

The suggested way is to build QtWebKit just like any other Qt5 module via QMake. See Building Qt5 for Blackberry on how to call QMake.

Development

There is a second process of building QtWebKit which differs from the other Qt5 modules. This is the suggested way to use when you want to develop QtWebKit. you still have to have configured your environment to use the BBNDK as described in Blackberry! Especially ensure that the QMake binary in your PATH is the Blackberry version.

<br />$ cd webkit<br />$ # here &lt;N&amp;gt; is the number of parallel make jobs to run. This is often set to &lt;No. of CPU cores + 1&amp;gt;. adapt this<br />$ perl Tools/Scripts/webkit-build qt install-libs=&quot;$(qmake -query QT_INSTALL_PREFIX)&quot; makeargs=&quot;<s>j&amp;amp;lt;N&amp;amp;gt;&quot;<br />


This will compile QtWebKit for QNX in a folder called WebKitBuild/Release in your webkit checkout.
After this process, you should have a Qt5 QtWebKit located in your Qt install prefix (i.e. $HOME/development/qnx/qt5 or in C:stall, depending of your operating system if you followed the other howtos).

See also

Known Issues

WebKit1/C++

QtWebKit applications using the WebKit1/C++ API are a bad fit for touch devices like the PlayBook. To simulate mouse events out of touch events, call the following on your QWebView:

<br />webView-&gt;setAttribute(Qt::WA_AcceptTouchEvents, false);<br />

If you do not do this, touch events are accpted and delegated to the JavaScript, but you will not be able to interact with the WebView, meaning: You cannot scroll, click links or do anything with it.

WebKit1/QML

Using QtWebKit with the old QtQuick1 QML API is currently broken. Eventually, this code will be moved from QtWebKit to the QtQuick1 module and reactivated.

WebKit2/QML