Hi, At https://bugs.webkit.org/show_bug.cgi?id=84953 we have been discussing about implementing a "View Source" API for QQuickWebView (WebView for QtQuick2).
Three approaches were suggested so far: 1- Implementing support to "view-source:http://www.foo.com" directly on the webView.url property, following view-source uri scheme [1] [2]; *Pros: straight-forward API, follows other browsers implementations [2]; *Cons: adds complexity to the url property, adds complexity to browser implementation for handling multiple url schemes (discussion about this on the bug). *!* Personal Pros: me gusta. 2- Implementing a bool webView.experimental.viewInSourceMode property. *Pros: straight-forward API, doesn't add any complexity to the url property; *Cons: transfers the entire decision on how to enable this to the browser implementation. *!* Personal Cons: no me gusta. 3- Implementing a WebViewSource { }, that inherits from WebView. *Pros: a specialized and separate component, doesn't add any complexity to the url property; *Cons: not that straight-forward API (?!?), transfers the entire decision on how to enable this to the browser implementation. *!* Personal Pros: me gusta mucho. Since this came up quite late on the entire API design for the brand new QtWebKit, I would like to hear from you guys what you think. Cheers and thanks in advance, jesus [1] http://www.iana.org/assignments/uri-schemes/prov/view-source [2] http://en.wikipedia.org/wiki/View-source_URI_scheme
_______________________________________________ webkit-qt mailing list [email protected] http://lists.webkit.org/mailman/listinfo.cgi/webkit-qt
