Opened 11 years ago

Closed 10 years ago

#9569 closed bug (no change required)

[WebKit] claims to support SVG but doesn't

Reported by: waddlesplash Owned by: leavengood
Priority: normal Milestone: R1
Component: Applications/WebPositive Version: R1/alpha4.1
Keywords: Cc: ajcsweb@…
Blocked By: Blocking: #10721
Platform: All

Description

NOTE: I am posting this here because http://webpositive.haiku-os.org/ is down.

Example: open http://defi.ant.ly/2011/06/inline-svg-experiment/ and scroll down. Where it says "Free Tomatoes" with a bunch of dates, there is supposed to be an inline SVG graph. Web+ shows nothing

If you go to http://html5test.com, "SVG in text/html" has "Yes" on it. CSS3 gradients are also claimed to be supported (and attempt to be drawn, see background on http://html5test.com) but eat time to render and are not displayed properly. Perhaps it's time that WebKit for Haiku gets an update?

Change History (9)

comment:1 by waddlesplash, 11 years ago

Cc: ajcsweb@… added

comment:2 by richienyhus, 11 years ago

AFAIK http://webpositive.haiku-os.org/ is meant to be in read only/archival mode anyway.

comment:3 by waddlesplash, 10 years ago

SVG works in some places, but the above inline SVG link doesn't. I wonder why...?

comment:4 by pulkomandy, 10 years ago

I think they work, but our drawing code is missing so much stuff (mostly in the management of transformations) that the SVG renders at the wrong place, possibly out of screen.

comment:5 by X512, 10 years ago

It's a good chance to improve native drawing API to support SVG rendering, because it can be used for other applications too.

comment:6 by pulkomandy, 10 years ago

Some more details on what's missing: WebKit SVG drawing make use of affine transforms to translate the SVG drawing to the right place on the page. For this to work, we need to implement GraphicsContext::concatCTM in https://github.com/haiku/webkit/blob/rebased/Source/WebCore/platform/graphics/haiku/GraphicsContextHaiku.cpp.

This in turn requires arbitrary transformations support in BView, likely using the existing BAffineTransform class for the API. On app_server side, this can be converted into an agg matrix.

We still need to defie how this should be interacting with the existing methods to set the view scale and offset. These could be applied before or after the matrix, or they could modify the matrix instead of working separately. Quick tests with concatCTM also show some unexpected results with regard to clipping. I don't know if an actual implementation on BView side would have similar problems.

comment:7 by pulkomandy, 10 years ago

Blocking: 10721 added

(In #10721) Duplicate indeed, these are SVG images and we still lack some support for that.

comment:8 by pulkomandy, 10 years ago

Some progress here: now the graph renders properly, but the text (legends on the axes, etc) went missing...

comment:9 by pulkomandy, 10 years ago

Resolution: no change required
Status: newclosed

This page is not online anymore. Closing this ticket since we have at least some SVG support, please open separate issues for any rendering glitch you find.

Note: See TracTickets for help on using tickets.