{"id":653,"date":"2013-04-11T19:48:05","date_gmt":"2013-04-11T17:48:05","guid":{"rendered":"http:\/\/blogs.igalia.com\/carlosgc\/?p=653"},"modified":"2013-04-11T19:48:05","modified_gmt":"2013-04-11T17:48:05","slug":"webkitgtk-2-0-0","status":"publish","type":"post","link":"https:\/\/blogs.igalia.com\/carlosgc\/2013\/04\/11\/webkitgtk-2-0-0\/","title":{"rendered":"WebKitGTK+ 2.0.0"},"content":{"rendered":"<p>After more than two years of development the <a href=\"http:\/\/www.igalia.com\">Igalia<\/a> <a href=\"http:\/\/www.igalia.com\/webkit\/\">WebKit team<\/a> is proud to announce <a href=\"https:\/\/lists.webkit.org\/pipermail\/webkit-gtk\/2013-March\/001406.html\">WebKitGTK+ 2.0.0<\/a>.<\/p>\n<h2>But what&#8217;s so special about WebKitGTK+ 2.0?<\/h2>\n<p>The <a href=\"http:\/\/webkitgtk.org\/reference\/webkit2gtk\/stable\/index.html\">WebKit2GTK+ API<\/a> is now the default one. This means that it&#8217;s now considered stable from the API\/ABI backwards compatibility point of view, and that the old <a href=\"http:\/\/webkitgtk.org\/reference\/webkitgtk\/stable\/index.html\">WebKit1 API<\/a> is in maintenance mode and kind of deprecated. We will maintain both APIs, but we don&#8217;t plan to work on WebKi1 other than fixing bugs.<\/p>\n<p>We encourage everybody to port their existing WebKitGTK+ applications to WebKit2, although we know the WebKit2 GTK+ API is not ready for all applications yet. We will work on adding new API during next release cycle, so let us know if you are missing some API that prevents you from porting your project.<\/p>\n<p><a href=\"http:\/\/projects.gnome.org\/epiphany\/\">Epiphany<\/a>, the <a href=\"http:\/\/www.gnome.org\/\">GNOME<\/a> Web browser, has been <a href=\"http:\/\/blogs.gnome.org\/xan\/2013\/03\/25\/web-3-8-the-peace-dividends-release\/\">successfully ported to WebKit2<\/a> and uses it by default since <a href=\"http:\/\/www.gnome.org\/news\/2013\/03\/gnome-3-8-released\/\">GNOME 3.8<\/a>.<\/p>\n<h2>What are the benefits of the WebKit2 GTK+ API?<\/h2>\n<p>We have talked several times about the advantages of the multi-process architecture of WebKit2, robustness, responsiveness, security, etc. All of the details of the multi-process separation are mostly transparent for the API users, bringing all those benefits for free to any application using WebKit2 GTK+. We have developed the API on top of this multi-process architecture, but also with the experience of several years developing and maintaining the WebKit1 GTK+ API, learning from the mistakes made in the past and keeping the good ideas. As a result, the WebKit2 API is very similar to the WebKi1 in some parts and quite different in others. We started from scratch with the following goals:<\/p>\n<ul>\n<li><strong>Simple and easy to use<\/strong>. Instead of porting the WebKit1 API to WebKit2, we decided to add new API on demand. We set some milestones based on porting real applications, adding new API required to port them. This also allowed us to design the API, not only thinking about what we want or need to expose, but also how the applications expect to use the API.<\/li>\n<li><strong>Consistency<\/strong>. We have tried hard to be consistent with the names of the functions, signals and properties exposed by the API.<\/li>\n<li><strong>Flexibility<\/strong>. When possible, the API allows to use your own implementation of some parts that can be adopted to different platforms. So, you can use your own file chooser, JavaScript dialogs, context menu, print dialog, etc.<\/li>\n<li><strong>It works by default<\/strong>. For all those features where a custom implementation can be used, there&#8217;s a default implementation in WebKit that just works by default.<\/li>\n<li><strong>Unit tests<\/strong>. We have enforced all new patches adding API to WebKit2 GTK+ to include also unit tests, so the whole API is covered by unit tests.<\/li>\n<\/ul>\n<p>Let&#8217;s see the major changes and advantages of this new WebKi2 API.<\/p>\n<h3>WebKitWebView is a scrolling widget<\/h3>\n<p>For API users this means that <a href=\"http:\/\/webkitgtk.org\/reference\/webkit2gtk\/stable\/WebKitWebView.html\">WebKitWebView<\/a> should not be added to a <a href=\"https:\/\/developer.gnome.org\/gtk3\/stable\/GtkScrolledWindow.html\">GtkScrolledWindow<\/a>, the widget is scrollable by itself. Actually this is also the case of the WebKitWebView in WebKit1, but some hacks were introduced to allow the widget to be used inside a GtkScrolledWindow. This caused a lot of headaches due to the synchronization between the internal scrolling and the GTK+ scroll adjustments. So now the main scrollbars are also handled by the WebKitWebView which, among other things, fixed the problem of the double scrollbars in some web sites.<\/p>\n<p><a href=\"http:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/webkit-double-scrollbar.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-medium wp-image-656\" src=\"http:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/webkit-double-scrollbar-300x126.png\" alt=\"Double scrollbar issue\" width=\"300\" height=\"126\" srcset=\"https:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/webkit-double-scrollbar-300x126.png 300w, https:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/webkit-double-scrollbar-1024x433.png 1024w, https:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/webkit-double-scrollbar.png 1725w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n<h3>Embedded HTTP authentication dialog<\/h3>\n<p>The default implementation of the HTTP authentication embeds a dialog in the WebView instead of using a real GtkDialog. It&#8217;s also integrated with the keyring by default using <a href=\"https:\/\/live.gnome.org\/Libsecret\">libsecret<\/a>.<\/p>\n<p><a href=\"http:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/http-auth-dialog.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-medium wp-image-657\" src=\"http:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/http-auth-dialog-300x235.png\" alt=\"HTTP authentication dialog\" width=\"300\" height=\"235\" srcset=\"https:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/http-auth-dialog-300x235.png 300w, https:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/http-auth-dialog.png 913w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n<h3>GTK+ 2 plugins (flash)<\/h3>\n<p>Plugins also run in a different process that is built with GTK+ 2 to support the most popular plugins like flash that still use GTK+ 2.<\/p>\n<p><a href=\"http:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/youtube-flash.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-medium wp-image-658\" src=\"http:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/youtube-flash-300x187.png\" alt=\"MiniBrowser showing a youtube video using flash plugin\" width=\"300\" height=\"187\" srcset=\"https:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/youtube-flash-300x187.png 300w, https:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/youtube-flash-1024x638.png 1024w, https:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/youtube-flash.png 1029w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n<h3>Web Inspector<\/h3>\n<p>The Web Inspector works automatically in both docked and undocked states without requiring any API call.<\/p>\n<p><a href=\"http:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/inspector-docked.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-medium wp-image-660\" src=\"http:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/inspector-docked-300x242.png\" alt=\"Inspector docked\" width=\"300\" height=\"242\" srcset=\"https:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/inspector-docked-300x242.png 300w, https:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/inspector-docked-1024x829.png 1024w, https:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/inspector-docked.png 1099w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n<p>It also has support for remote inspecting.<\/p>\n<p><a href=\"http:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/remote-inspecting.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-medium wp-image-659\" src=\"http:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/remote-inspecting-300x146.png\" alt=\"Remote inspecting\" width=\"300\" height=\"146\" srcset=\"https:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/remote-inspecting-300x146.png 300w, https:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/remote-inspecting-1024x501.png 1024w, https:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/remote-inspecting.png 1815w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n<h3>Accelerated compositing<\/h3>\n<p>Accelerated compositing is always enabled in WebKit2.<\/p>\n<p><a href=\"http:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/poster-circle.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-medium wp-image-661\" src=\"http:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/poster-circle-264x300.png\" alt=\"Poster circle\" width=\"264\" height=\"300\" srcset=\"https:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/poster-circle-264x300.png 264w, https:\/\/blogs.igalia.com\/carlosgc\/files\/2013\/04\/poster-circle.png 825w\" sizes=\"auto, (max-width: 264px) 100vw, 264px\" \/><\/a><\/p>\n<h2>Future plans<\/h2>\n<p>During the <a href=\"https:\/\/live.gnome.org\/ThreePointNine\">next release cycle<\/a> we&#8217;ll work on fixing bugs and completing the API, see our <a href=\"http:\/\/trac.webkit.org\/wiki\/WebKitGTK\/WebKit2Roadmap\">RoadMap<\/a> for further details, but we&#8217;ll also explore some other areas not directly related the the API:<\/p>\n<ul>\n<li>Multiple web processes support<\/li>\n<li>Sandboxing<\/li>\n<li>Network Process<\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>After more than two years of development the Igalia WebKit team is proud to announce WebKitGTK+ 2.0.0. But what&#8217;s so special about WebKitGTK+ 2.0? The WebKit2GTK+ API is now the default one. This means that it&#8217;s now considered stable from &hellip; <a href=\"https:\/\/blogs.igalia.com\/carlosgc\/2013\/04\/11\/webkitgtk-2-0-0\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":9,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3,7,8],"tags":[21,22],"class_list":["post-653","post","type-post","status-publish","format-standard","hentry","category-free-software","category-igalia","category-webkit","tag-epiphany","tag-webkit"],"_links":{"self":[{"href":"https:\/\/blogs.igalia.com\/carlosgc\/wp-json\/wp\/v2\/posts\/653","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blogs.igalia.com\/carlosgc\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blogs.igalia.com\/carlosgc\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blogs.igalia.com\/carlosgc\/wp-json\/wp\/v2\/users\/9"}],"replies":[{"embeddable":true,"href":"https:\/\/blogs.igalia.com\/carlosgc\/wp-json\/wp\/v2\/comments?post=653"}],"version-history":[{"count":7,"href":"https:\/\/blogs.igalia.com\/carlosgc\/wp-json\/wp\/v2\/posts\/653\/revisions"}],"predecessor-version":[{"id":670,"href":"https:\/\/blogs.igalia.com\/carlosgc\/wp-json\/wp\/v2\/posts\/653\/revisions\/670"}],"wp:attachment":[{"href":"https:\/\/blogs.igalia.com\/carlosgc\/wp-json\/wp\/v2\/media?parent=653"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blogs.igalia.com\/carlosgc\/wp-json\/wp\/v2\/categories?post=653"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blogs.igalia.com\/carlosgc\/wp-json\/wp\/v2\/tags?post=653"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}