[Webkit-unassigned] [Bug 75091] [SVG] Text does not show after scripted scaling.
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Thu Feb 16 12:51:17 PST 2012
https://bugs.webkit.org/show_bug.cgi?id=75091
--- Comment #15 from Philip Rogers <pdr at google.com> 2012-02-16 12:51:17 PST ---
(In reply to comment #12)
> (From update of attachment 127371 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=127371&action=review
>
> > Source/WebCore/ChangeLog:7
> > +
>
> Needs a better ChangeLog! :-)
Fixed
>
> > Source/WebCore/rendering/svg/RenderSVGInlineText.cpp:255
> > +
>
> This can be omitted.
Fixed
>
> > Source/WebCore/rendering/svg/RenderSVGInlineText.cpp:272
> > + fontDescription.setComputedSize(CSSStyleSelector::getComputedSizeFromSpecifiedSize(document, scalingFactor, fontDescription.isAbsoluteSize(), fontDescription.computedSize(), DoNotUseSmartMinimumForFontSize));
>
> Nothing changed here, why does it list it as change?
Fixed (I think I had removed a tab)
>
> > Source/WebCore/rendering/svg/RenderSVGTransformableContainer.cpp:46
> > + m_didTransformToRootUpdate = m_needsTransformUpdate || SVGRenderSupport::transformToRootChanged(parent());
>
> What if the viewBox of an inner <svg> changes? This viewBox transformation is handled in RenderSVGViewportContainer - which overrides calculateLocalTransform IIRC.
> That would mean viewBox changes of inner <svg> elements, don't cause m_didTransformToRootUpdate to switch to true. Can you add/extend a test, and fix RenderSVGViewportContainer as well?
>
> > Source/WebCore/rendering/svg/SVGRenderSupport.cpp:252
> > + if (ancestor->isSVGTransformableContainer()) {
>
> Unneeded braces.
Fixed
>
> > Source/WebCore/rendering/svg/SVGRenderSupport.cpp:270
> > + if (transformChanged) {
>
> You could add a small comment here, as it's done for layoutSizeChanged=true, as well.
Fixed
>
> > LayoutTests/svg/text/text-rescale.html:46
> > +</svg>
>
> I'd add another test that uses:
> <svg> <svg id="inner" viewBox="0 0 100 100"><text y="0.3" x="0.3" font-size="0.1">Foo</text>.
> And then script inner.viewBox to be 0 0 1 1 - that should lead to a recalculation of the text scaledFont, hopefully.
As usual, you were spot-on with the viewport issues. I added the same transform propagation support to SVGViewportContainer that SVGTransformableContainer has, and added the appropriate test (note: it failed before the patch, and now passes).
--
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
More information about the webkit-unassigned
mailing list