Herbert,
I have followed your advise, doing three separate chapters for defaults, font substitution (including multiple names) and glyph substitution. When you have a moment, please look at it again, to see if it is correct. My ideas are much clearer now.
http://khmeros.info/tools/localization_of_openoffice_2.0.html#VCL
Javier
Herbert Duerr wrote:
Hello Javier,
Thanks. I have added the information to the font substitution section of the OOo 2.0 localization document in:
http://khmeros.info/tools/localization_of_openoffice_2.0.html#VCL
Could you please give it a quick look to make sure that it is correct?
I'd rename part 11 from 11) Include the automatic font substitution table for the language (locale) to 11) Define the default fonts for the language (locale) and mention that the VCL.xcu file is an UTF-8 encoded file, which could be destroyed when it gets written by a non-UTF-8 able editor.
For the font fallback issue I'd add another chapter, e.g. 12) add font substitutions for fonts often used in a language (locale) When a font is not available a related font should be used. The relationship of the fonts is defined in the <node oor:name="FontSubstitutions"> of the VCL.xcu file. At least for the fonts defined in the default font lists (see chapter 11) font fallbacks should be defined.
As an example you could use is the "Kodig" font. When the name shows up in an imported document OOo would have no idea how to substitute it if it is not available on the system. It is also not obvious that the font is normal width, normal weight and typically used for Korean script. Also OOo needs info whether the font needs some special substitution when exported a *.html document or to a *.doc type document often used on Windows machines. Or if postscript printers know it under a different name etc. Here is the example entry:
<node oor:name="kodig" oor:op="replace"> <prop oor:name="SubstFonts"> <value>gulim;gulimche;? ?;sundotum;baekmukgulim;dotum;dotumche;roundgothic;kodig;andalesansui;? ?;sungulim;hymyeongjolightk;myeongjo;? ?;sunbatang;batang;batangche;gungsuh;gungsuhche;myeomjo;andalesansui;arialunicodems;lucidaunicode</value> </prop> <prop oor:name="SubstFontsMS"><value/></prop> <prop oor:name="SubstFontsPS"> <value/> </prop> <prop oor:name="SubstFontsHTML"><value/></prop> <prop oor:name="FontWeight"><value>Normal</value> </prop><prop oor:name="FontWidth"><value>Normal</value></prop> <prop oor:name="FontType"><value>CJK,CJK_KR</value></prop> </node>
Please note that the font names are normalized, which means that they are lower case and non-alphanumeric characters stripped out etc. If possible the english name version of the name should be used.
When adding a new font like Kodig also the substituted fonts should get a fallback to it. That means that e.g. gulim should fall back kodig, sungulim should fall back to kodig, etc.
We know that this method is maintenance unfriendly from both "quadratic complexity" of adding new fonts and that the nodes are difficult to track in CVS. This maintainability problem will become attacked in OOo 3, but for now we have to live what we have.
Maybe you should also add another chapter 13 about "glyph fallback" and move the first paragraph of your current chapter 11 there.
-- Herbert
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
