Trying to render a Hebrew text along a path in SVG causes a bug in Chrome - the glyphs are rendered backwards (left-to-right), making the text unreadable.
<svg height="220" width="190">
<defs>
<path id="MyPath2" d="M0,100 L200,100" />
</defs>
<use xlink:href="#MyPath2" fill="none" stroke="red" />
<text text-anchor="middle" dx="100" dy="0" writing-mode="rl" direction="rtl">
<textPath xlink:href="#MyPath2">
הטקסט הזה ייראה הפוך
</textPath>
</text>
</svg>
Is there a way to get around this? Is this a known bug or is there an attribute I should've used?
JSFIddle: http://jsfiddle.net/j9RnL/
unicode-bidi
. You could try "embed" or "bidi-override" values to see if they have the desired effect. You could also try drawing the path in the opposite direction, i.e. in the direction you want the text to go, liked="M200,100 L0,100"
. JSFiddle is currently giving me an error face instead of a result frame, so I can't test it out myself. It might come down to a Chrome bug; support for RTL languages in SVG is not as good as the people who wrote the specs envisioned. – Rebelliousdx
attr on the<tspan>
, the text appears RTL. – Cerellia