PDA

View Full Version : Is webkit functionality a superset of qtscript?



jurojon
15th October 2008, 15:20
Hi, I am just picking Qt basics. I am wondering why Qt provides both qtscript engine and webkit, when the webkit javascript engine is already integrated with QObject and given some binding it seems able to do whatever qtscript is doing. So why have two script environments?

Can someone enlightenment me on this? Thanks you.

wysota
16th October 2008, 22:49
QtScript was integrated into Qt before Webkit entered the picture so currently we have to live with two javascript engines. There are plans to integrate the two into one entity in future.

jurojon
17th October 2008, 19:53
That's great, will be a better XUL I hope. What I want is to manipulate the DOM / javascript objects in webpage with QtScript / C++. I might be wrong, currently it seems hard to do, having to export everything into webkit javascript engine and evaluate scripts in it. It would be great if I can use QtScript API to manipulate webkit. Is it the direction Qt is heading?

wysota
17th October 2008, 20:13
Neither QtScript nor Webkit's Javascript engine have anything to do with XUL. Currently there are no means to manipulate a webpage's DOM from C++, you have to do that using javascript. There are plans to make it possible in future though.

jurojon
17th October 2008, 23:09
Thanks for the explanation. I know webkit isn't XUL, I just mean that the integration of Qt UI and webkit makes it similar to XUL in functionality.

wysota
17th October 2008, 23:12
Personally I think it is much much more than XUL.