Support for CSS3 standard in font switching/fallback

Are you missing a feature? Request it's implementation here.
Kae
Posts: 12
Joined: Tue Apr 01, 2014 9:39 am

Support for CSS3 standard in font switching/fallback

Post by Kae » Wed Apr 16, 2014 11:48 am

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

Radu
Posts: 6708
Joined: Fri Jul 09, 2004 5:18 pm

Re: Support for CSS3 standard in font switching/fallback

Post by Radu » Tue Apr 22, 2014 4:20 pm

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
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com

Kae
Posts: 12
Joined: Tue Apr 01, 2014 9:39 am

Re: Support for CSS3 standard in font switching/fallback

Post by Kae » Thu May 15, 2014 1:04 pm

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

Radu
Posts: 6708
Joined: Fri Jul 09, 2004 5:18 pm

Re: Support for CSS3 standard in font switching/fallback

Post by Radu » Fri May 16, 2014 8:54 am

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
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com

Dan
Posts: 440
Joined: Mon Feb 03, 2003 10:56 am

Re: Support for CSS3 standard in font switching/fallback

Post by Dan » Thu Nov 20, 2014 5:27 pm

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

Post Reply