[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 08:11:07 PST 2012


https://bugs.webkit.org/show_bug.cgi?id=75091





--- Comment #12 from Nikolas Zimmermann <zimmermann at kde.org>  2012-02-16 08:11:06 PST ---
(From update of attachment 127371)
View in context: https://bugs.webkit.org/attachment.cgi?id=127371&action=review

> Source/WebCore/ChangeLog:7
> +

Needs a better ChangeLog! :-)

> Source/WebCore/rendering/svg/RenderSVGInlineText.cpp:255
> +

This can be omitted.

> 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?

> 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.

> 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.

> 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.

-- 
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