Page 1 of 1

Support for CSS3 standard in font switching/fallback

Posted: Wed Apr 16, 2014 11:48 am
by Kae
Hi,

I would like to request for font-switching to be done on a per character basis rather than the behavior stated in http://www.oxygenxml.com/forum/topic10591.html (which works on a font level rather than a text level).

To quote the sixth item under 5.2 of http://www.w3.org/TR/css3-fonts/
If no matching face exists or the matched face does not contain a glyph for the character to be rendered, the next family name is selected and the previous three steps repeated. Glyphs from other faces in the family are not considered. The only exception is that user agents may optionally substitute a synthetically obliqued version of the default face if that face supports a given glyph and synthesis of these faces is permitted by the value of the ‘font-synthesis’ property. For example, a synthetic italic version of the regular face may be used if the italic face doesn't support glyphs for Arabic.
Thanks and regards,

Kat

Re: Support for CSS3 standard in font switching/fallback

Posted: Tue Apr 22, 2014 4:20 pm
by Radu
Hi Kat,

Thanks, we'll consider this for a future version of Oxygen.
I read the forum topic you linked to I do not understand your entire use case though. Do you have an XML document in which you have both English and Chinese content?

Regards,
Radu

Re: Support for CSS3 standard in font switching/fallback

Posted: Thu May 15, 2014 1:04 pm
by Kae
Hi Radu,

Yes, we have an XML document which contains both English and Chinese content. At the moment, we are having difficulty implementing the proper fallback system due to the current standard being used.

Thanks and regards,

Kat

Re: Support for CSS3 standard in font switching/fallback

Posted: Fri May 16, 2014 8:54 am
by Radu
Hi Kat,

I will assume that you do not have English mixed with Chinese in the same text, you probably have separate tags in which you have either English or Chinese text.
So as a workaround maybe you could set different fonts to those tags in the CSS like:

Code: Select all


*[xml:lang="ch-CH"] {
font-family: "細明體-ExtB";
}

* {
font-family: "Times New Roman";
}
or if you do not specify xml:lang on the tags containing Chinese text, maybe there is another way to differentiate them from the others.

Regards,
Radu

Re: Support for CSS3 standard in font switching/fallback

Posted: Thu Nov 20, 2014 5:27 pm
by Dan
Hi Kat,

We will fully support the fallback font switching at character level in the next oXygen version (17), in the standalone version (not in the Eclipse plugin).