On Wed, 20 May 2015 08:51:16 -0600 Amelia Bellamy-Royds <amelia.bellamy.royds@...400...> wrote:
I played around a little more with my language settings, and got the same result as you.
On Chrome, the SVG always uses the language I have set for the interface (e.g., the language used for the browser menus and dialogs) regardless of the order of preferred languages for content. This also probably explains why Chrome wasn't matching any country codes.
I have filed a bug report with Chromium:
In Firefox (and iceweasel), I'm not sure why there is a difference between SVG and HTML. Within SVG, the "allowReorder" attribute (which is not in SVG, but is in SMIL) is really important. Without it, Firefox follows the specs literally and uses the first language option in the document that matches *any* of the users preferred language. Try changing the order of the languages so that "es" is before "en", and see what happens. Here is more about that:
However, the "allowReorder" attribute seems to be ignored in HTML. I've filed a bug (& am hoping Robert Longson jumps on it, he's pretty good about fixing these things!):
I will make a note to update the SVG2 specs to be more clear about using user preferences and to include the "allowReorder" attribute.
It is all a little disappointing. We can still go ahead with making it work in Inkscape, but we can't rely on it always having a useful result in browsers.
A feature that we probably want to have in Inkscape is the ability to export the SVG in a specific language, instead of with switches. That way, the author could have a single multilingual file for editing, but could create files for the web or printing that always display a specific way, without having to worry about browser differences.
Dear Jabier & Amelia,
Do either of you have experience with DocBook http://www.docbook.org/ ? This is a widely used documentation system system into which SVG documents are commonly embedded. DocBook supports multiple languages on most XML elements and you might benefit from reading about the approach they use to process documents. Of particular interest is the chapters on graphics and languages DocBook XML: The Complete Guide which is available via that website.
I am sorry for the noise if you know about this already.
Yours,
Is.