Summary: | [Qt] GraphicsContext should respect QWebView render hints | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Ariya Hidayat <ariya.hidayat> | ||||||||||
Component: | Canvas | Assignee: | Ariya Hidayat <ariya.hidayat> | ||||||||||
Status: | RESOLVED FIXED | ||||||||||||
Severity: | Normal | CC: | cmarcelo, fabrizio.machado, kenneth, kling, mdelaney7, ossy, tonikitoo | ||||||||||
Priority: | P2 | Keywords: | HTML5, Qt, QtTriaged | ||||||||||
Version: | 528+ (Nightly build) | ||||||||||||
Hardware: | PC | ||||||||||||
OS: | All | ||||||||||||
Attachments: |
|
Description
Ariya Hidayat
2010-12-16 12:47:22 PST
Created attachment 76820 [details]
Patch
What about QGraphicsWebView and our WebKit2 port? > What about QGraphicsWebView and our WebKit2 port?
For QGraphicsWebView, either the containing QWebView has to set the render hints properly (to get smooth pixmap) or we automatically set smooth pixmap in the paint function. But the latter is wrong, cause again it's clobbering the original painter's render hint.
For WebKit2, I'm not sure since I'm not familiar with it. I assume BackingStore::createGraphicsContext() is good place to insert additional set of smooth pixmap transform render hint. Are there any other places where GraphicsContext is created?
Comment on attachment 76820 [details]
Patch
r=me
For QGraphicsWebView we will (and should) just follow whatever we get from the view (set via QGraphicsView::setRenderHint())
Comment on attachment 76820 [details] Patch Clearing flags on attachment: 76820 Committed r74220: <http://trac.webkit.org/changeset/74220> All reviewed patches have been landed. Closing bug. Reopen, because a Qt API test fails after this patch: FAIL! : tst_QWebView::renderHints() '!(webView.renderHints() & QPainter::SmoothPixmapTransform)' returned FALSE. () Loc: [/home/webkitbuildbot/slaves/release32bit/buildslave/qt-linux-release/build/WebKit/qt/tests/qwebview/tst_qwebview.cpp(85)] Could you check it, please? Created attachment 76883 [details]
[Qt] GraphicsContext should respect QWebView render hints
Comment on attachment 76883 [details]
[Qt] GraphicsContext should respect QWebView render hints
I trust you here.
r=me
Comment on attachment 76883 [details] [Qt] GraphicsContext should respect QWebView render hints Clearing flags on attachment: 76883 Committed r74271: <http://trac.webkit.org/changeset/74271> All reviewed patches have been landed. Closing bug. Revision r74220 cherry-picked into qtwebkit-2.1.x with commit dcbf037442a531c9da18a879f91bedfe141aaea0 <http://gitorious.org/webkit/qtwebkit/commit/dcbf037442a531c9da18a879f91bedfe141aaea0> Revision r74271 cherry-picked into qtwebkit-2.1.x with commit 2927c9d24ce15010eece90504cc0e1fc21e851e2 <http://gitorious.org/webkit/qtwebkit/commit/2927c9d24ce15010eece90504cc0e1fc21e851e2> I am not so sure r74220 has been cherrypicked to 2.1.x. We are still seeing test cases related to this failing on Symbian with latest 2.1.x. Inside GraphicsContextPlatformPrivate::GrahicsContextPlatformPrivate() from GraphicsContextQt.cpp in 2.1.x, I do not see 'painter->setRenderHint(QPainter::Antialiasing,true)' getting called for all cases. It's only getting called if platform != Symbian, but we actually need it called for all platforms, as in trunk. Can we get this change to 2.1.x? Created attachment 88812 [details] 2.1.x branch - patch to fix wrong cherry-pick Patch to fix mistake during the cherry-pick of r74220 in branch qtwebkit-2.1.x. For the record, from IRC: <cmarcelo> lgombos: kenneth_: rubberstamp for fixing a mistake during cherry-pick (branch 2.1.x). it's the third patch in https://bugs.webkit.org/show_bug.cgi?id=51208 can one of you take a look? <lgombos> cmarcelo: ok by me Created attachment 88818 [details]
2.1.x branch - patch to fix wrong cherry-pick, v2
Fix dumb mistake, 'imageInterpolationQuality' was missing.
Fix in commit f45d42188432a78331e9fa5733863752ea81f64e of qtwebkit-2.1.x branch. Thanks for spotting this Fabrizio. No problem Caio, thanks for your help. |