Aller au contenu
Tous les transcripts
Podcast / conversationQt Group· 22 mars 2013 44 minComplaisantDivertissement

WebKit 2 - Looking Forward: Alexis Menard

Source d'origine 2 locuteurs

Transcription Whisper (large-v3), avec identification des locuteurs. À recouper avec la source d'origine.

Analyse automatique

Générée par IA — peut contenir des erreurs. Méthodologie

Chapitres

Répartition du ton (temps de parole politique)

Propositif 100 %

Questions et réponses

Taux de réponse directe : 88 % (directe = 1, partielle = 0,5, éludée = 0)

  • 38:28OuverteRéponse directe

    Will WebKit 1 be discontinued at some point in the future?

  • 39:25OuverteRéponse partielle

    I was wondering about the low-level details of the implementation.

  • 41:12OuverteRéponse directe

    I would like to know if you have multiple instances of Qt WebKit 2.

  • 42:04OuverteRéponse directe

    Is it correct that there's only one WebKit engine shared between WebKit 1 and WebKit 2?

Temps de parole

  • Présentateur86 %
  • ?11 %

≈ 85,5 interruptions / 10 min (chevauchements et interjections détectés).

Modèle mistral-small-latest · prompt v1 · les citations sont vérifiées mot pour mot dans le transcript ; le taux de réponse directe est calculé à partir des verdicts question par question. Aucun label idéologique n'est produit.

0:04
Locuteur

Bonjour,

0:05
Présentateur

merci pour être ici. Je sais que les présentations sont très, très nice. WebKit 2 n

0:12
Locuteur

'est

0:12
Présentateur

pas assez, donc c'est bien pour vous de venir ici. Donc aujourd'hui, il va être WebKit 2, en regardant. Donc l'agenda sera juste une introduction. Je vais parler rapidement sur WebKit 1. WebKit 1 est ce que vous trouverez sur Qt.

0:27
Locuteur

Et,

0:28
Présentateur

de course, je vais parler de WebKit 2, exactement ce que c

0:31
Locuteur

'est. About

0:34
Présentateur

me, so there was a mistake on the paper. My name is Alex Esmenard, I'm not Pierre Rossi. Yes, you heard well, I'm French, sorry for the accent, that's just the way it is.

0:46
Locuteur

I'm

0:46
Présentateur

the Qt WebKit team lead in INDT, so I'm taking care of like eight, seven-person team in INDT. We're working full-time on Qt WebKit.

0:56
Locuteur

I

0:57
Présentateur

used to be an Oslo troll, I was working for Nokia, Qt Development Framework. I worked in many parts in Qt, QMR, Graphics View, last year I did a

1:10
Locuteur

Q

1:11
Présentateur

Graphics View In-Depth talk,

1:12
Locuteur

so I

1:14
Présentateur

know my way in Qt.

1:17
Locuteur

I'm

1:18
Présentateur

an open source advocate, so like I'm

1:20
Locuteur

a

1:22
Présentateur

fan and I support a lot of open source projects. I think it's very good. I'm now an occasional KDE developer.

1:29
Locuteur

I

1:29
Présentateur

used to be very active, but since 2006, so I started KDE as a student project. And then after I mainly work on Plasma, then I launched a

1:39
Locuteur

mobile

1:41
Présentateur

project for

1:43
Locuteur

Plasma,

1:44
Présentateur

so it was like running KDE on small form factor like phones. Then now it's renamed and called Plasma Active and people are working full steam on it, so it's very good to see that

1:53
Locuteur

people

1:54
Présentateur

took over me.

1:55
Locuteur

And

1:56
Présentateur

now I'm just like using it and fixing it when it bothers me. That's all.

2:03
Locuteur

Working

2:03
Présentateur

for Andy is very fun because I left Oslo and by snow, the darkness, and my friend, party friends, and the awesome Norwegian food, which is sausages based, so-called Pulse, to Brazil, which is slightly different, which is beach, sun, caipirinhas, and my wife and my daughter. So it was very nice.

2:27
Locuteur

It

2:28
Présentateur

was a nice move. It was a smart move. Seriously speaking, let's go back to the presentation. So WebKit 1, KDE WebKit. So what is it? Quickly, I'm not going to go to details. There was a presentation yesterday about it. WebKit is an open source web content engine. Basically, you get HTML5

2:48
Locuteur

and

2:49
Présentateur

you, it handles it for you, basically. Very simple. So it's the most popular mobile engine. You find it on iOS, on Android, on Ream, on Symbian, on many phones. It is driving the open web on the desktop. WebKit's community is very active on W3C as like a thing for the standard to shape.

3:11
Locuteur

And

3:12
Présentateur

on the desktop, you find it on Safari, on Mac, on Windows, and in Chrome, Chromium. It's the same. Reconc and KDE or even Conqueror with

3:24
Locuteur

different

3:25
Présentateur

K parts. And then there are many cute apps that are using it. I'm not sure Google Earth is still using it, but they used to do it. And then Second Life also is using it.

3:37
Locuteur

The

3:37
Présentateur

basic architecture of WebKit, of course, I'm not going to go to details again, but like just so that you get basic ID so that we can compare to WebKit 2 afterwards. WebKit is like a

3:49
Locuteur

big

3:51
Présentateur

piece and it has like two main pieces inside. is like you have WebCore. So WebCore is everything you need to parse an HTML5,

4:01
Locuteur

understand

4:03
Présentateur

it,

4:04
Locuteur

and

4:04
Présentateur

render it. It also manages the CSS for you and all this related stuff like SVG and so on. And also you find the so-called HTML5 APIs

4:16
Locuteur

like to

4:18
Présentateur

make the HTML5 less, to follow and make the HTML5 stuff work, basically.

4:23
Locuteur

And

4:24
Présentateur

then you get another small, more smaller pieces, which is the JavaScript engine.

4:28
Locuteur

One

4:29
Présentateur

sit on the WebKit.org repository, which is JavaScript Core. JavaScript Core is the one that is developed mostly by Apple and is the one that's cheap with Safari and iOS, like Safari Mobile, so iOS. And otherwise, you get a bunch of glue codes so that you can hook up another script engine, which is the V8 one, which doesn't sit on WebKit.org project. It's another open source project and run by Google. And it's another JavaScript engine,

4:55
Locuteur

V8.

4:58
Présentateur

People say that V8 runs faster on some benchmark. I'm not gonna go into details, but basically you can hook up a JavaScript engine. The different one is JavaScript Core, but you can hook up V8. That's what Chrome is doing. Chrome is not using JavaScript Core. Chromium also.

5:15
Locuteur

And

5:16
Présentateur

then underneath this building, big blue box, we got something called the WebKit parse. And

5:21
Locuteur

you

5:22
Présentateur

have to see WebKit as like a huge

5:24
Locuteur

thing

5:27
Présentateur

that basically will understand HTML on that, but doesn't have like low-level functionality.

5:34
Locuteur

For

5:34
Présentateur

instance, WebKit will not put pixels on your screen. It will tell you, okay, I need to draw a rectangle.

5:40
Locuteur

And

5:40
Présentateur

then this is when the parse come into action. It's like they will say, okay, me, I know my part Qt. I know how to render a rectangle on the screen.

5:50
Locuteur

So

5:50
Présentateur

you basically plug your parts to the WebKit.

5:54
Locuteur

Big

5:55
Présentateur

box. And you plug your network stack. You plug your rendering stack. You plug everything. And so there are many parts.

6:03
Locuteur

I

6:04
Présentateur

just put the main ones. So Safari, also called Apple one. This is the one that's running on Mac and Windows. And

6:10
Locuteur

so

6:12
Présentateur

the API is mostly based on Cocoa, Objective-C. And there's the Google port or Chrome port,

6:18
Locuteur

which

6:19
Présentateur

is the one that you find on Google Chrome or Chromium. And also since they are working hard to unify also the Android ports into the same one. I think it's almost done. They removed the Android, like the last pieces of Android ports in WebKit. So I believe that now they fully use

6:37
Locuteur

the

6:38
Présentateur

Google port. Well, we don't know, but I believe.

6:42
Locuteur

There

6:43
Présentateur

is also our friend from GDK that have a part of WebKit that you find on Epiphany, I think, is the name of their brother. So and then the Qt port, which is us. And you have also the EFL ports, mostly pushed by Samsung. This is the one that they use on their mobile phone, I guess. We don't know exactly. And then you have also more tiny ports, like Windows C ports and so on, that's just more me now.

7:33
Locuteur

We

7:33
Présentateur

call major ports the one that are build bots running. Build bots like that's every single commit is builded and then tested. And like the one that you see here have like bots. It's like Qt has like a bots running 24 hours that check every commit, that check every test and see if there are regressions. WebKit is a very, very high-quality project because, of course, if you break something, you're going to break a lot of user web browsers, right? It's like if you break WebKit, you break all iPhones, you break all Safari browsers, all Google Chrome browsers, and all Nokia browsers. So it's like you better find the problems before they arrive on the end user's

8:09
Locuteur

hand. So

8:11
Présentateur

there's like we got like

8:13
Locuteur

a

8:14
Présentateur

huge number of layout tests that

8:16
Locuteur

check

8:17
Présentateur

website, check use cases, check APIs, check HTML use case, check CSS and so on, check handling. And

8:23
Locuteur

major

8:24
Présentateur

ports have those bots running. So GTK has one, Qt has one, Chrome has multiple, Safari has multiple. Actually, Qt has multiple. So we have like on Windows, Mac, Linux.

8:40
Locuteur

So

8:40
Présentateur

yeah, this is this. This is very basic. I'm not going to go into detail.

8:46
Locuteur

That's

8:46
Présentateur

all. This is WebKit 1 today. You find in Qt 4.7 or 4.8 through all those well-known classes, QWebView, QGraphicsWebView, QWebPage, QWebFrame. I mean, I'm not going to go into details. You

8:59
Locuteur

go

9:00
Présentateur

to the documentation of Qt, you'll find it.

9:02
Locuteur

So

9:03
Présentateur

now what is WebKit 2? So why are we looking

9:06
Locuteur

like

9:08
Présentateur

we make another version?

9:10
Locuteur

It's

9:11
Présentateur

not. WebKit 2 is not the next version of WebKit. The name is slightly confusing, especially that Qt WebKit is called Qt WebKit 2.0 or 2.1 or 2.2. Unfortunately for Qt WebKit, we came up with the name of 2.0 and so on before they announced WebKit 2. So anyways, too late. How old is this well-known like this? We cannot change, right? So it's like,

9:37
Locuteur

it's

9:38
Présentateur

not the next version. It's not. WebKit 2 actually sits on the same repository of WebKit. It's just a separate directory, right? So it's not the next version.

9:53
Locuteur

So

9:53
Présentateur

if you go back again to the basic architecture of WebKit today, so

9:57
Locuteur

this

9:59
Présentateur

is

9:59
Locuteur

the

10:00
Présentateur

purple box is your application running. So it's using Qt WebView or Qgraphics WebView.

10:06
Locuteur

It's

10:07
Présentateur

one process is your application process. And from your application, you call the API of Qt WebKit. And Qt WebKit API actually talk to WebCore, which I was explaining contain all the pieces and bits to units to run the HTML. And WebCore also

10:23
Locuteur

deal

10:24
Présentateur

with the JavaScript engine if you have a script on your web page, right? The API boundary is basically on top of QWebKit, right? This is where you call your API. This is where you call QWebFrame. This is where you call QWebPage, where you call QWebView, right?

10:39
Locuteur

So

10:40
Présentateur

this is today. One process.

10:43
Locuteur

It

10:43
Présentateur

works like this. Straightforward.

10:46
Locuteur

So

10:46
Présentateur

why WebKit 2 and what it is? So it's a new API layer. It's just an additional API that sits next to WebKit 1. It is not a compatible API, right? It's like

10:59
Locuteur

for

11:00
Présentateur

now, it's not a one-on-one API. What you do with WebKit 1, you cannot yet do with WebKit 2.

11:07
Locuteur

We're

11:07
Présentateur

still working on it. WebKit 2 is designed for a split process model. It means that you have multiple processes.

11:18
Locuteur

It's

11:18
Présentateur

a different API for the original WebKit 1. Just because it's a split process model doesn't mean that you can have the exact same API. It will not be the case.

11:28
Locuteur

And

11:29
Présentateur

as I said, it sits on the same request story. So you don't see it as a new version. It's just another additional API. It gives more choice to the user, basically. Why WebKit 2?

11:41
Locuteur

So

11:42
Présentateur

the main goals of WebKit 2 is

11:44
Locuteur

to

11:45
Présentateur

make the UI more responsive.

11:47
Locuteur

What

11:48
Présentateur

we don't want is letting your application event loop deal with patching the HTML from the network, getting all the signals when the bytes arrive,

11:58
Locuteur

and

11:59
Présentateur

then passing the HTML,

12:02
Locuteur

rendering

12:02
Présentateur

it, constructing all the objects, evaluating JavaScript and so on. This

12:06
Locuteur

makes

12:07
Présentateur

your application event loop busy. And we actually want to free it from that so that it's always free for managing user interaction. Read, first use case, scrolling.

12:20
Locuteur

You

12:21
Présentateur

basically want a smooth scrolling all the time, right? But if, for instance, you are trying to load like a huge image or rendering a huge image, then your event loop is going to be super busy, and your app's super busy, and the CPU's super busy

12:31
Locuteur

dealing

12:33
Présentateur

with that image, and then the scrolling is going to be slow.

12:36
Locuteur

And

12:37
Présentateur

so that, and of course, it's like on desktop, it doesn't show that much. But it's like on mobile phone like this, that's a huge issue.

12:49
Locuteur

If

12:49
Présentateur

you have multiple process,

12:51
Locuteur

it

12:52
Présentateur

improves the stability because

12:54
Locuteur

if

12:55
Présentateur

the web process, like the process, the separate process where you deal with the web, crashes,

13:00
Locuteur

then

13:00
Présentateur

it doesn't bring the UI with it.

13:02
Locuteur

You

13:03
Présentateur

can still restart the process, right? So today, if something happened bad in Qwebkit and it crashes, your application goes with it. There's nothing you can do.

13:14
Locuteur

So let's

13:17
Présentateur

say plugins like Flash,

13:19
Locuteur

which

13:20
Présentateur

are not very high-quality plugins, then you, if they crashes, then the entire Qwebkit goes down and then your application crashes, right? Which is very bad.

13:29
Locuteur

So

13:30
Présentateur

Apple,

13:31
Locuteur

for

13:31
Présentateur

instance, on the 5.0 Safari, they put the plugin separate process, right? So that if they crash, then just the plugin crash, right? We didn't do that in WebKit.

13:42
Locuteur

And

13:43
Présentateur

actually, after this, like, Apple thought about, like, yeah, let's actually make the entire web wandering into a separate process rather than just the plugin.

13:53
Locuteur

And so

13:54
Présentateur

today, for instance, if you could use Qwebkit and then use WebKit 2, then if it crashes, then it doesn't bring the UI with it, which is very, very good. It improves also a bit the security because

14:06
Locuteur

if

14:08
Présentateur

you've run an exploit for the web browser you're using based on Qwebkit or based on any WebKit port,

14:16
Locuteur

then

14:17
Présentateur

you will only access to the web process context, right? It's a separate process. So in theory, like, for instance, on Mac OS Lion, you can sandbox the web process. Like, sandbox the separate process. And then you can say, okay, well, this web process, this process will only have access to

14:30
Locuteur

what

14:32
Présentateur

the sandbox provide, which means that if you write any exploit with it, like, it was going to

14:36
Locuteur

limitate

14:37
Présentateur

the damage you could do because it's running in the sandbox, right? So this only for now, I'm aware, it's only existing in Mac OS Lion because they implemented the sandboxing at the kernel level so you can actually create processes that are sandboxed. Linux doesn't have this feature as well as Windows, but

14:55
Locuteur

maybe

14:56
Présentateur

it will come so we can actually do it. So here's the basic architecture of WebKit today. So

15:05
Locuteur

as

15:06
Présentateur

you can see, there are two processes. There is one that we call web process. This is the one that we take care of rendering, parsing, fetching the HTML and so on, making the website look something.

15:18
Locuteur

And

15:18
Présentateur

there's the UI process, which is the one your application is running on. Then you're going to have an API that you deal with it. And then seamlessly, it's going to be translucent for you.

15:30
Locuteur

It

15:31
Présentateur

will manage the process to create the process for you to run down and communicate with it. And actually afterwards, you can see it on your application, right? So the API boundary is still on the UI process. On your application, you deal with this new API.

15:47
Locuteur

And

15:47
Présentateur

then on the back, there will be a communication between the two process to first run it, then start fetching the... So if you say, I want to go to google.com, then the UI process will send a message to the web process. We're then going to start fetching google.com or start resolving the URL and then getting the HTML code for it.

16:07
Locuteur

And

16:08
Présentateur

the actual old web core and JavaScript engine and so on sit on this other process, right? This is the one that will render, that will fetch, that will parse, that will resolve the style, that will do everything in time. And then you've got a communication between both.

16:22
Locuteur

I

16:23
Présentateur

have

16:23
Locuteur

another

16:24
Présentateur

explanation afterwards.

16:26
Locuteur

So

16:27
Présentateur

the main difference is two processes, right? One where your application sit, the UI process, and the other that is taking care of rendering the web content or parsing it and fetching it and so on. But for you, the API boundary is still the same. You don't have to care about the IPC. You don't have to care about the other process. You

16:47
Locuteur

don't even

16:47
Présentateur

know if

16:48
Locuteur

that

16:49
Présentateur

it exists. For you, it's totally transparent

16:51
Locuteur

in

16:53
Présentateur

the API. Okay.

16:56
Locuteur

For

16:56
Présentateur

the curious,

16:58
Locuteur

Chromium

16:59
Présentateur

also have some kind of like multiple,

17:01
Locuteur

like

17:03
Présentateur

every single tab of the Chromium or Google Chrome runs into a separate process, right?

17:09
Locuteur

And for

17:10
Présentateur

them, it's different. They don't use WebKit 2 or at least for now, they don't. I'm not sure they will ever, but perhaps.

17:19
Locuteur

They

17:19
Présentateur

have something they call host process,

17:22
Locuteur

which

17:22
Présentateur

is where the application is, like Google Chrome,

17:25
Locuteur

right?

17:25
Présentateur

And then the application is responsible of creating the processes, right? So every single tab is responsible for creating the process that will actually run down the page.

17:36
Locuteur

And

17:36
Présentateur

then they have an API which is called what? Like the application has a render process.

17:41
Locuteur

And

17:41
Présentateur

then they just load the API inside, like the WebKit API inside. So the API boundary is not on the UI process. It's actually on the render process or some kind of web process, right?

17:52
Locuteur

So

17:52
Présentateur

as

17:52
Locuteur

you

17:52
Présentateur

can see, it's very different. WebKit 2, that's transparent for the application. On Chromium, they manage themselves the thread. So Google Chrome manage themselves the processes.

18:06
Locuteur

So it's

18:07
Présentateur

just a different approach. They actually came up with the approach before WebKit 2.

18:13
Locuteur

So

18:15
Présentateur

that's the main difference between Chromium and Google Chrome and WebKit 2.

18:23
Locuteur

So there

18:24
Présentateur

are two key subsystems that support the process division in WebKit 2. There is something they call core IPC.

18:31
Locuteur

So

18:31
Présentateur

it's an abstraction for general message passing between processes, right? It's so that the processes can communicate together.

18:40
Locuteur

See

18:41
Présentateur

it like a bit of a very, very simplified version of Dbus, basically, on Linux. They made their own because, for instance, it's...

18:49
Locuteur

I

18:50
Présentateur

mean, Apple came up with WebKit 2 project, right? So it's like, it's not the Qt team that came up with it.

18:56
Locuteur

It's

18:56
Présentateur

Apple, right? So Apple has this tendency of rewriting everything. So it's like,

19:02
Locuteur

in

19:03
Présentateur

theory, they could have used another IPC system, right? But, like, they've worked their own. It's very simple.

19:12
Locuteur

And

19:12
Présentateur

then there is...

19:14
Locuteur

Of

19:15
Présentateur

course, what I'm talking here is very oversimplified. But so that for you, it's an introduction, right? I'm not going to the core details, basically. But it's like, there is also a drawing area, which is an abstraction for cross-process drawing. So it's

19:28
Locuteur

like... So

19:30
Présentateur

that the web process can render into a shared places that the UI process can read to actually show it on the screen, right? So it's like, it's like some kind of shared memory that you can... One render, and when they finish, then the other reads to show it on the UI process, right? So show it on your application.

19:48
Locuteur

There

19:48
Présentateur

are multiple drawing strategies. Of course, this most simple one is a shared memory bitmap, right? You just write it when it's finished, and you just show it.

19:57
Locuteur

I'm

19:57
Présentateur

not going to talk about more complicating stuff like accelerated compositing when you accelerate animations on, but, like, this is the most basic architecture, right? I'm drawing into this shared place, and then I show it on the other process when I'm done.

20:15
Locuteur

So

20:15
Présentateur

I made a very, very simple example on how this happened. So for instance, in your application, if you ask, okay, could you please load google.com, then it's going to talk to the WebKit 2 layer

20:27
Locuteur

that

20:28
Présentateur

will then send a message to the IPC bus that will say, okay, I'd like to load this URL. Then the IPC will then forward it to the web process. The web process will get the message and say, ah, I need to load, and we'll start fetching the... like reserving the UI, then getting the HTML file, and then start rendering.

20:47
Locuteur

And

20:47
Présentateur

then the rendering stuff will basically render into this drawing area. It's

20:52
Locuteur

the

20:52
Présentateur

same. It's very over... It's very simplified,

20:54
Locuteur

right? But...

20:55
Présentateur

So you get an idea.

20:58
Locuteur

And

20:59
Présentateur

then when it's finished, then it will send back a message to say, oh, I'm finished loading. Then it goes through the IPC. The IPC gets to the WebKit layer on the UI process, and then you finally get the signal on your application, right? Everything is asynchronous, right? Of course, loading a URL is by default asynchronous, right? But like every API that will be with WebKit 2 is asynchronous, of course, because we have to send it to the IPC, and then we have to wait the answer off the web process, right?

21:24
Locuteur

And

21:25
Présentateur

then when it's done or undoing, then

21:27
Locuteur

the

21:27
Présentateur

UI process knows that it can

21:29
Locuteur

read

21:30
Présentateur

from the drawing area, and then you will start painting it, right?

21:34
Locuteur

And

21:35
Présentateur

in that case,

21:36
Locuteur

Qt

21:37
Présentateur

is going to do the painting for you, right? So, Qpator, right? So Qt WebKit 2 requirements are Qt 5 within graph.

21:52
Locuteur

Why

21:52
Présentateur

Qt 5? Because since it's a huge rewrite, I mean, we cannot just port QwebView to this. It's just a rewrite of the API. We said, well, you know, it's like,

22:03
Locuteur

there

22:04
Présentateur

will be no Qt 4 X release, you know? What's the point trying to develop for it? Let's just go to Qt 5 since we're going to break everything anyway. It's like the API needs to be changed. It's a new API, asynchronous, and so on. And also the fact that there was SynGraph, which is very good because

22:19
Locuteur

we

22:20
Présentateur

wanted to use like on mobile phones, so we used like this like tile backing store, you know, when you have tiles so that the scrolling is faster on mobile phones. And then SynGraph would match really nicely for us,

22:32
Locuteur

so

22:32
Présentateur

we can have tiles on those SynGraph and so

22:34
Locuteur

on.

22:34
Présentateur

And so that was one good

22:37
Locuteur

something

22:39
Présentateur

that was pushing us to move to Qt 5. And also, of course, that

22:43
Locuteur

OpenGL

22:45
Présentateur

is mandatory because SynGraph, right? So it's like, it can be software emulated or hardware, but like we use OpenGL because OpenGL is very nice for us for everything that is related to, you know, CSS animation and, you know, stuff like WebGL.

23:01
Locuteur

We

23:02
Présentateur

need OpenGL. So it's like,

23:03
Locuteur

it's

23:04
Présentateur

easier for us, you know, to have one supported code path, which is the OpenGL one that we know that's going to perform very well because it match really well.

23:13
Locuteur

The

23:14
Présentateur

problem we have today with Qt WebKit 1 API is like this millions of combination you have with accelerated compositing. If you use a graphics view, if you use a QWadget or if you use a graphics view with a GL viewport and stuff like that, then for us it was just hell because we have like millions of combinations possible and then

23:33
Locuteur

you

23:34
Présentateur

always have

23:35
Locuteur

cases

23:36
Présentateur

where Qt WebKit was underperforming, like WebGL process. Or CSS animations, stuff like that. Now that we have one supported code path which is going to be OpenGL, then

23:48
Locuteur

we

23:49
Présentateur

know that this one was going to, or will work hard to make that one work fast.

23:56
Locuteur

That's

23:56
Présentateur

what I said. We'll make it easier for us to support WebKit pictures like WebGL and so on. If we make the OpenGL mandatory, then it's over for us. We know that WebGL is going to, we can work and make it work fast because there is no other combination to support like software or other stuff.

24:14
Locuteur

The

24:15
Présentateur

API today, which of course is subject to change, of course, because we are still working hard on it. But we decided to split the API into two use cases,

24:25
Locuteur

the

24:25
Présentateur

desktop one

24:26
Locuteur

and

24:27
Présentateur

the touch one. Why? Because, for instance, on the Qdesk, like we found out that, for instance, having one view is like, makes code very complicated, especially when you need to handle the touch stuff. And QGraphics WebView is like, touch handling is a mess, especially when you're just in the case of, I'm a desktop, I just use the mouse, I just don't care of, you know, managing touch events, right?

24:54
Locuteur

So

24:55
Présentateur

it's like,

24:56
Locuteur

in

24:57
Présentateur

order to simplify everything, we decided to split up. And also, many APIs, you know, it doesn't make sense in a touch view, right? Why you need all the links on a touch screen, right? Like, you don't have all the events on a touch screen. So it's like, simplifying the, like we have a common, like on the implementation, we have like a common part, basically. But like, the API itself is much more simpler in the touch web view than the desktop web view, just because some feature doesn't apply on the touch wall.

25:27
Locuteur

So

25:27
Présentateur

we decided to split up for code simplicity and for also not bloating the API on,

25:32
Locuteur

on

25:33
Présentateur

feature that doesn't make sense in some of the walls.

25:37
Locuteur

The

25:38
Présentateur

API is focused on QML. So we want to have QML elements. So you will do like, import Qt Web Kits, and then you get a QML element up and ready for,

25:50
Locuteur

for using

25:51
Présentateur

it in your app.

25:54
Locuteur

But

25:54
Présentateur

don't worry, C++ API is still here. I mean, the QML element is using the C++ API. We just have a plug-in for it. It's just like,

26:03
Locuteur

by

26:04
Présentateur

API focused to QML, I meant that

26:06
Locuteur

it's

26:08
Présentateur

going to be an API property base, right? Because QML. QML is just about properties, right? So of course, you know, like, you will have like a bunch of properties that, you know, in C++ you could just have solved them with Enum. But Enum is not very usable in QML, or it doesn't really make sense. So for instance,

26:26
Locuteur

we

26:26
Présentateur

have like, the API will look nice for QML, but it will be usable in C++, but it will not be the main candidates for API decision. Like, we're not going to say, ah, we are not putting, we are not, we, for instance, we say, we're going to put properties rather than Enum because we want to focus for QML. So in C++, it's going to look more verbose, but it's still going to work, right? It's just that we are not going to put Enum for it,

26:49
Locuteur

as

26:50
Présentateur

the example I was explaining. But the API is there. Symbols are exported.

26:55
Locuteur

H

26:55
Présentateur

file are there. Documentation will be here. So you can still use it in C++. It doesn't make

27:00
Locuteur

sense.

27:01
Présentateur

And the QML elements,

27:02
Locuteur

you

27:02
Présentateur

use them. So

27:03
Locuteur

make

27:04
Présentateur

no mistake, there will be C++ API. Just that the API is going to look nice for QML rather than C++. So a tiny example, for instance, where you can create this desktop preview in QML.

27:20
Locuteur

You

27:20
Présentateur

can fill it with, like, the Encore. It has all the Encore property stuff like in QML. And you've got a bunch of signal, you know, also slots, and so that you can connect them

27:29
Locuteur

in

27:29
Présentateur

QML when

27:30
Locuteur

the

27:31
Présentateur

loading starts, when the load succeeds, when the load fails. You've got parameters with the signal, you know, so you can get the error code and do something in your application.

27:41
Locuteur

And

27:41
Présentateur

for instance, you get on link over. This is for the desktop use case, right? It doesn't make sense on the touch screen, right? So this API doesn't exist on the touch web view, for instance, right? And in other part of the code, for instance, you can use it, webview.load, and then you just give the URL and

27:57
Locuteur

it

27:58
Présentateur

starts loading for you.

27:59
Locuteur

So

28:00
Présentateur

very convenient to use, very, very fast.

28:08
Locuteur

But

28:09
Présentateur

WebKit

28:09
Locuteur

2 has,

28:09
Présentateur

like, huge challenges.

28:11
Locuteur

Of

28:12
Présentateur

course, I was explaining, it's asynchronous.

28:14
Locuteur

That

28:15
Présentateur

makes API design really, really tough to make, as like. And some of the APIs are very, very complicated, two parts. Namely, QWebElements, Everlet JavaScript, and Add to JavaScript window objects. So those are, like, for those people that make hybrid applications.

28:36
Locuteur

Why?

28:37
Présentateur

Because

28:38
Locuteur

those

28:39
Présentateur

guys, they rely a lot on WebCore internal. So you remember WebCore is, like, all these, like, tools that you need to run under the HTML page and so on.

28:47
Locuteur

And

28:48
Présentateur

these APIs, they sit on the UI process, right?

28:51
Locuteur

But

28:51
Présentateur

the WebCore is not anymore on the same process, right? It's on the other one. So it's, like, start to be really, really bad. And so,

29:01
Locuteur

yeah,

29:02
Présentateur

so they rely on WebCore internal. So, of course, it's on the other process, which means that you cannot use them directly. So it has to go through IPC.

29:11
Locuteur

And then, Everlet

29:13
Présentateur

JavaScript is, like, synchronous, right? So, like, you call something and then you get a written value.

29:17
Locuteur

It's

29:17
Présentateur

like, we cannot have synchronous calls from the UI process, right? It's going to block the web process while doing stuff. It's just wrong, right? We don't want synchronous API. Now, of course, we have to solve it. And we know that, you know, hybrids applications and hybrids features of QWebKit is one of the strong point of WebKit.

29:42
Locuteur

So

29:42
Présentateur

now, we're still looking at how we could solve those hybrid use cases.

29:47
Locuteur

And we

29:48
Présentateur

don't have yet the big picture, but

29:50
Locuteur

we're

29:52
Présentateur

going to change the way

29:53
Locuteur

your

29:54
Présentateur

application is talking to WebKit. Like, QWebElement, the way it exists today, it's not going to be the same way for WebKit 2 just because it's asynchronous.

30:03
Locuteur

And it

30:04
Présentateur

may not, you know, it's like WebKit 2 is a huge work for us. It may not be yet already that in 5.0 you have, like, already a one-to-one mapping for hybrid functionalities.

30:17
Locuteur

But

30:18
Présentateur

it will come with, like, 5.1 or 5.2, right? It's like,

30:21
Locuteur

5

30:21
Présentateur

.0 is not the last version of Qt 5, right? So it's like,

30:25
Locuteur

we'll

30:26
Présentateur

still work on it. But basically, it will change the way you talk. It's like,

30:30
Locuteur

it's

30:31
Présentateur

going to be more like JSWorker if you know what it is. Like, JSWorker is like when you thread, like, you can make

30:36
Locuteur

JavaScript

30:39
Présentateur

execution on separate threads, right? So it's like, you can say, okay, this piece of code of JavaScript is very heavy. I'm going to just throw it on a separate thread. This is HTML5 feature, right?

30:47
Locuteur

And

30:48
Présentateur

then

30:48
Locuteur

this,

30:49
Présentateur

this, how this API works is like, is messages and callback, right? You communicate to this thread by messages and then you get callbacks when, for instance, the thread is done.

30:57
Locuteur

And

30:58
Présentateur

I think it's going to be the same way. You're going to say, okay, I'd like to send this message with this JavaScript code. And then it's going to go to the web process. And then when the web process finishes with it, then you're going to get a callback.

31:08
Locuteur

So

31:09
Présentateur

it's going to be, rather than being a synchronous method like evaluate JS, it's going to be like, I send this and I'm going to callback. And for instance, there was like a lot of use cases that are like, you know, custom network access manager.

31:25
Locuteur

Of

31:25
Présentateur

course, you know, as I said, the API manage for you the web process, right? You don't know that it exists. Like, you just call WebKit APIs and then, you know, it's created the web process for you, make the communication between.

31:36
Locuteur

So,

31:37
Présentateur

but the actual network access manager set on the other process, right? And many applications,

31:43
Locuteur

they

31:43
Présentateur

have their own network access manager. And it was one of the strengths of the use case. Same. We have to be,

31:49
Locuteur

we

31:49
Présentateur

have to make that possible. How? I see two options. Either we make a plug-in on the web process side, so that when the web process is created, it will look for a plug-in that contains a network access manager that you can specify.

32:04
Locuteur

Or we

32:05
Présentateur

make the web process like a tiny library that's so that you create the web, like, so that we know that and then you create the web process. So, like,

32:14
Locuteur

the

32:15
Présentateur

main function is you that you create, so you create the web process with a tiny API and then you attach your network manager on it and then we use that one for creating the web process.

32:23
Locuteur

There's

32:24
Présentateur

also, you know,

32:24
Locuteur

in

32:29
Présentateur

WebKit 1, you could call render, you know, and then you could render a part of the web page and then put that into a Pixmap or show it somewhere.

32:37
Locuteur

That

32:38
Présentateur

was a good use case of there, but, like, you made circuit.

32:40
Locuteur

You

32:40
Présentateur

wanted to make an app and then you show a piece of the website in your app or any website. Same, you know, how, the UI process doesn't know anything but the web process, right? Like, except talking to it. So, how you can, like, how we could

32:55
Locuteur

ask

32:56
Présentateur

you to render synchronously and then get that to a Pixmap is going to be very complicated.

33:02
Locuteur

So,

33:02
Présentateur

same, I think we are going to have a dedicated

33:04
Locuteur

elements

33:06
Présentateur

or class for doing that, right? So, for instance, a dedicated, like, I don't

33:10
Locuteur

know,

33:10
Présentateur

WebSliceElements, QMLElements, where you specify the WebView you're using and then you specify a selector, you know, like a GS, GQuery selector. You say,

33:19
Locuteur

oh,

33:19
Présentateur

I'd like

33:19
Locuteur

this

33:21
Présentateur

element ID, you know, full bar, and then he's going to render only that one for you. But it's not going to be, like, you call render and so on.

33:29
Locuteur

And

33:29
Présentateur

it's, like, it's going to be dedicated APIs for it because we just can't do those anymore. It was just the process splitting. I just have a little demo. So, by the

33:41
Locuteur

way... So,

33:45
Présentateur

I think I'm...

33:45
Locuteur

It's

33:46
Présentateur

fine. I'm going to hold it. So, this little demo, by the way, so this presentation was, like, HTML5 based

33:54
Locuteur

and

33:55
Présentateur

it's

33:56
Locuteur

running

33:57
Présentateur

on the web browser that is

33:58
Locuteur

made

33:59
Présentateur

in QML, QML2.

34:01
Locuteur

So,

34:01
Présentateur

running in Qt5 and this presentation was run out using WebKit2.

34:06
Locuteur

So, as

34:07
Présentateur

you can see here, I go, there's a web browser. So, it's...

34:11
Locuteur

You

34:11
Présentateur

have full screen mode.

34:12
Locuteur

You

34:12
Présentateur

can leave the full screen mode.

34:14
Locuteur

And

34:14
Présentateur

then,

34:14
Locuteur

you

34:15
Présentateur

can open new tab.

34:17
Locuteur

And

34:17
Présentateur

then, you can go to AV images

34:20
Locuteur

website.

34:22
Présentateur

I'm not on the network.

34:25
Locuteur

That's

34:25
Présentateur

where

34:26
Locuteur

I'm... Hopefully,

34:31
Présentateur

it's going to work. There's a network,

34:38
Locuteur

so...

34:57
Présentateur

Well, I have no network. But, anyway. So, as, like... Unfortunately, I cannot show you, but it's a bit bad.

35:03
Locuteur

But,

35:04
Présentateur

yeah. So, it's like... It's a web browser, like, basic bookmark support. So, you see, you can start doing stuff without the API we are developing.

35:12
Locuteur

And so,

35:13
Présentateur

you can, of course, you know, reload the presentation like this. And then...

35:17
Locuteur

So,

35:18
Présentateur

I'm going to go to the end.

35:21
Locuteur

And you

35:22
Présentateur

can move the tabs around.

35:25
Locuteur

So... Whoops. So,

35:29
Présentateur

a bit like Chrome, basically. And... So, yeah. It's like... The cool part of it is, like, if you go to this, for instance, up. And then, you do PS, aux.

35:44
Locuteur

And

35:45
Présentateur

then, you

35:45
Locuteur

grab... Grab

35:48
Présentateur

for... Cut. You see that there is this cut web. I'm going to increase the font.

35:56
Locuteur

You

35:59
Présentateur

increase it.

36:01
Locuteur

With

36:01
Présentateur

one hand, it's going to be tough. So, as you can see, there is this cut web process right running. As well as, if I grab for my application, which is called Snowshoe. It's an open source project, by the way. So, you see, there is my UI, Snowshoe. And then, there is this web process. That is the web process I was talking about. Now, here, it is the web process right running. And then, let's say, I emulate a crash.

36:26
Locuteur

So, I'm

36:29
Présentateur

going to kill the web process, right?

36:31
Locuteur

So,

36:31
Présentateur

let's say I was using a

36:32
Locuteur

Flash

36:33
Présentateur

plugin,

36:34
Locuteur

and

36:34
Présentateur

it crashes.

36:36
Locuteur

So,

36:36
Présentateur

I kill. Boom.

36:38
Locuteur

My

36:38
Présentateur

UI is still here. Right?

36:40
Locuteur

The

36:40
Présentateur

web process crashed, but my UI is still here.

36:43
Locuteur

And

36:43
Présentateur

I just do a reload,

36:46
Locuteur

and

36:47
Présentateur

it's going to reload it.

36:48
Locuteur

Right? So,

36:49
Présentateur

that's cool, right? So, whatever happened on the web process,

36:53
Locuteur

it

36:53
Présentateur

brings, it doesn't bring down your UI. You just reload it, and then,

36:57
Locuteur

you're

36:57
Présentateur

good to go.

36:58
Locuteur

So,

36:59
Présentateur

it makes more robust application.

37:04
Locuteur

So, of

37:05
Présentateur

course, we want your feedback, especially for the hybrid use case,

37:08
Locuteur

as

37:09
Présentateur

we are discussing the APIs on the mailing list, and discussing,

37:12
Locuteur

you

37:12
Présentateur

know, different approaches we can have.

37:15
Locuteur

We

37:15
Présentateur

already have quite a lot of feedback from Richard Moore, which is not here. It's too bad. And so, of course, we'd like you to, you know, participate with us, and try the new APIs, and say that,

37:26
Locuteur

tells

37:27
Présentateur

us if you can solve your hybrid use case or not. And we are usually on IRC, either WebKit or Qt WebKit. Otherwise, you can find on list.webkit.org, there is a Qt mailing list, and you can register

37:39
Locuteur

to

37:39
Présentateur

it, and, you know, tell us about your hybrid use case that you,

37:42
Locuteur

that

37:43
Présentateur

may not work with WebKit, too.

37:45
Locuteur

But

37:45
Présentateur

keep in mind that

37:46
Locuteur

we

37:47
Présentateur

are still working on, you know,

37:49
Locuteur

the

37:49
Présentateur

basic functional idea right now. So, it's like,

37:52
Locuteur

we

37:52
Présentateur

may not have all the hybrid features back for 4.0,

37:56
Locuteur

but they

37:57
Présentateur

will come at some point. We know that it's a very important use case of Qt WebKit.

38:00
Locuteur

But

38:01
Présentateur

we just want the stuff up and running first, like, you know, just run on web pages.

38:06
Locuteur

So,

38:07
Présentateur

that's all.

38:08
Locuteur

Thank

38:08
Présentateur

you for your attention.

38:10
Locuteur

If

38:10
Présentateur

you have any questions,

38:11
Locuteur

go

38:11
Présentateur

for it.

38:16
Locuteur

I

38:17
Présentateur

have to wait the microphone.

38:20
Locuteur

Are

38:21
Invité

there any questions?

38:22
Présentateur

Yeah.

38:22
Invité

Oh, okay. Yes. Thank you. Will WebKit 1 be discontinued at some point in the future?

38:32
Présentateur

Like,

38:33
Locuteur

it's

38:33
Présentateur

just like QWidgets. It's going to ship with 5.0. As I was explaining, it's a separate API.

38:40
Locuteur

It's

38:40
Présentateur

going to be there in 5.0.

38:42
Locuteur

We're

38:42
Présentateur

just not going to work

38:43
Locuteur

anymore

38:45
Présentateur

on it, at least the Nokia employees.

38:48
Locuteur

It

38:48
Présentateur

works, right? It's tested. We have bots running

38:51
Locuteur

with

38:52
Présentateur

it every day. So, if we break something, we are going to know about it. So, it's not going to get worse. But it's not going to receive any new improvement, at least from Nokia, because we don't think it's the future. We think we should focus on that one.

39:04
Locuteur

And

39:04
Présentateur

get the hybrid use case back in shape.

39:07
Locuteur

Get

39:07
Présentateur

everything up and running. And then, so that people can switch to that one. Because we think it's better. You see, right?

39:18
Locuteur

Like... It's

39:20
Présentateur

good.

39:24
Invité

Hi. Thanks for the presentation. I was wondering about the low-level details of the implementation. I mean, especially when we're talking about Q platform abstraction, QPA.

39:36
Locuteur

How

39:37
Invité

is this surface going to be rendered? I mean, the QPA offers the acceleration,

39:44
Locuteur

but

39:45
Invité

then you have to map this area on the same memory? Like a map?

39:50
Présentateur

Oh, it's...

39:53
Locuteur

So... How

39:54
Présentateur

I can explain it easy?

39:57
Locuteur

It's

39:58
Présentateur

like...

39:59
Locuteur

We

40:00
Présentateur

just draw it. It's like...

40:01
Locuteur

See

40:02
Présentateur

it as a Qpix map, right? So, it doesn't matter which platform we're running.

40:06
Locuteur

We

40:06
Présentateur

just draw that surface, right? It's like if you call Qpainter, draw a Pix map.

40:11
Locuteur

So,

40:12
Invité

we're not going to have a... We're only going to have the raster painter,

40:17
Locuteur

right?

40:18
Présentateur

No. It's going to be... It's like... As I said, we're using Graph. It's going to be OpenGL.

40:22
Locuteur

Okay.

40:23
Présentateur

We'll run all this surface using OpenGL.

40:27
Locuteur

And

40:28
Présentateur

also, in the future, it's like going to be... All CSS animations, stuff like that, it's going to be OpenGL accelerated.

40:38
Locuteur

Ah!

40:38
Présentateur

The process is raster, right?

40:40
Locuteur

It's

40:41
Présentateur

like the process... The web process run with raster today, right? It's like today, it's still using

40:46
Locuteur

Qstyle,

40:50
Présentateur

Qpainter, and friends. Because we haven't yet get

40:53
Locuteur

other

40:55
Présentateur

alternatives. But, yeah, to actually render in the surface itself, it's the rest of the web process. But then to draw it on the UI, it's using Syngraph and OpenGL.

41:11
Locuteur

I

41:12
Invité

would like to know if you have multiple instances of Qt WebKit 2.

41:18
Présentateur

Is there then only one process in background or...? So today, the implementation has one web process.

41:26
Locuteur

So

41:27
Présentateur

if you have multiple pages, like in the web browser I was running, so like here,

41:31
Locuteur

I

41:31
Présentateur

have one web process for those two,

41:33
Locuteur

for

41:33
Présentateur

the three tabs.

41:35
Locuteur

Just

41:35
Présentateur

because WebKit 2 today, but it's almost there, doesn't support multiple web processes. One per page, basically. But it's on the pipe.

41:45
Locuteur

What

41:46
Présentateur

that means is like when you create your web view with your web page, it's going to load one process delegated for each one, right?

41:52
Locuteur

Today

41:53
Présentateur

is not the case.

41:53
Locuteur

Is

41:54
Invité

it possible to make a decision in

41:55
Locuteur

what you use?

41:57
Présentateur

We'll probably make a decision. You'll be able to decide.

41:59
Locuteur

Okay. Thank

42:00
Invité

you.

42:00
Locuteur

So

42:04
Invité

I'm wondering if it's, is it correct that there's only one WebKit

42:09
Locuteur

web

42:10
Invité

engine

42:12
Locuteur

and

42:13
Invité

that's shared between,

42:14
Locuteur

call

42:15
Invité

it WebKit 1 and WebKit 2? Yes. And so does that mean that as WebKit development continues with like HTML5.1 or whatever,

42:24
Locuteur

that

42:24
Invité

those will sort of implicitly come also to the WebKit 1 bindings?

42:28
Locuteur

Yes. Exactly. I mean,

42:30
Présentateur

it's like, it's like, you have to see that the WebKit layer, like the Qt WebKit layer is tiny. It's not that much code. We use the WebCore and the development of HTML features happen in WebCore. So even though we are not going to work on Qt WebKit 1, or at least no company are not going to do it, I think, we

42:48
Locuteur

are

42:50
Présentateur

not going to improve the API, right? We're not going to add API, but the features in the engine itself, you'll get them for free. I mean, if we support, I don't know,

43:01
Locuteur

new

43:02
Présentateur

input type in HTML, those will work for free on the WebKit 1 API,

43:06
Locuteur

right?

43:06
Présentateur

Because

43:06
Locuteur

there's

43:08
Présentateur

no, it's like, there's, they use WebCore, right? So it's like, those will work. So WebKit 1 will still evolve as WebCore is continuing evolving.

43:17
Locuteur

What

43:17
Présentateur

we're not, what's, what I think we should not focus on is adding more APIs in Q WebView and Q Desktop WebView and so on. But having

43:25
Locuteur

improvement

43:27
Présentateur

from the engine, you'll get them for free for sure.

43:29
Locuteur

And

43:32
Présentateur

thank you for assisting. And I hope you'll enjoy the conference.

43:35
Locuteur

Thank you.