mirror of
https://github.com/RGBCube/serenity
synced 2025-07-28 21:37:35 +00:00
LibWeb: Support transforms, stroking, gradients, etc for SVG <text>
This makes use of the new Gfx::Path::text() to handle SVG text elements, with this text is just a regular path, and can be manipulated like any other graphics element. This removes the SVGTextPaintable and makes both <text> and geometry elements use a new (shared) SVGPathPaintable. This is identical to the old SVGGeometryPaintable. This simplifies painting as once something is resolved to a Gfx::Path, the painting logic is the same.
This commit is contained in:
parent
50d33f79fa
commit
4c5d48f861
30 changed files with 144 additions and 180 deletions
|
@ -4,11 +4,11 @@ Viewport <#document> at (0,0) content-size 800x600 children: not-inline
|
|||
line 0 width: 300, height: 150, bottom: 150, baseline: 150
|
||||
frag 0 from SVGSVGBox start: 0, length: 0, rect: [8,8 300x150]
|
||||
SVGSVGBox <svg> at (8,8) content-size 300x150 [SVG] children: not-inline
|
||||
SVGTextBox <text> at (8,-8) content-size 0x16 children: not-inline
|
||||
SVGTextBox <text> at (8,8) content-size 0x0 children: not-inline
|
||||
TextNode <#text>
|
||||
|
||||
ViewportPaintable (Viewport<#document>) [0,0 800x600]
|
||||
PaintableWithLines (BlockContainer<HTML>) [0,0 800x600]
|
||||
PaintableWithLines (BlockContainer<BODY>) [8,8 784x150]
|
||||
SVGSVGPaintable (SVGSVGBox<svg>) [8,8 300x150] overflow: [8,-8 300x166]
|
||||
SVGTextPaintable (SVGTextBox<text>) [8,-8 0x16]
|
||||
SVGSVGPaintable (SVGSVGBox<svg>) [8,8 300x150]
|
||||
SVGPathPaintable (SVGTextBox<text>) [8,8 0x0]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue