Article View: comp.fonts
Article #621Re: Why Windows 3.1 blocks out some of the upper ASCII codes?
From: Berthold K.P. Horn
Date: Wed, 19 Aug 1992 00:42
Date: Wed, 19 Aug 1992 00:42
56 lines
3450 bytes
3450 bytes
In article <18AUG92.15521044@wl.aecl.ca> desikacharyk@wl.aecl.ca writes: I have a Font with all the upper ascii slots (codes from 128-255) populated. It is a custom designed font that exists in Type 1 and Type 3 PS Formats and also in the TrueType Format on Mac. It works fine on Mac. I can display and print the whole font on Mac. I have used Altsys Corporation's Metamorphasis Professional program to convert it into IBM PC compatible Type 1 PS and TrueType formats. When I installed these fonts under Windows 3.0, I found that I cannot display/print 27 upper ASCII characters. Then I tried them under Windows 3.1. Things are slightly etc etc Read it and weep: there is no fixed relationship between character code number and character. This is called the encoding vector and the default encoding vector differs from platform to platform. On the Mac it is `standard roman encoding', in MS Windows it is `Windows ANSI', and who knows what it is on Unix... It does not make sense to speak of ASCII codes above 127, since the ASCII standard is only defined for codes from 32 to 127 (actually 126 to be pedantic). When you say you can't get a character in positions 208, 215, 221, 222, 240, 253, and 254, this is because Windows ANSI has Eth, multiple, Yacute, Thorn, eth, yacute, and thorn in those positions, and these characters do not occur in Mac `standard roman encoding'. You also say, you can't get anything in code position 194. This is probably a typo, since Windows ANSI has Acircumflex there, which exists in the Mac encoding. Or maybe you don't have a character in that position: Acircumflex is in code position 229 on the Mac. DON'T think in terms of NUMBERS, but CHARACTERS (character names maybe). The whole idea of the PostScript font encoding vector is lost on most people, including software vendors. Some font generation software for example has a fixed hard-wired `encoding vector' which totally defeates the purpose (i.e. NUL stands for 0, DEL for 127 etc). It just substitutes (meaningless) names for numbers... You can force Windows to NOT reencode the font to Windows ANSI, but this requires a tool for generating a PFM file with appropriate bits set. Then it just shows the characters where they occur in the encoding vector in the font. Similarly, you can set up the FOND resource in a screen font on the Mac so as to not reencode to Mac `standard encoding'. But most people don't have tools to do things like that. Also, if you plan to use ATM in Windows and you have accented characters you cannot use this technique, since ATM has hard-wired positions for accents: 0 for caron, 1 for dotlessi, etc. This does work fine on the Mac. Maybe it is time for UNICODE so we can avoid this reencoding mess once and for all. Just which the UNICODE priests would believe more in ligatures... Berthold K.P. Horn Cambridge, Massachusetts, USA
Technical Details
Message-ID:
<26724@life.ai.mit.edu>Path:
arc1-ca.pugleaf.net!sparky!uunet!wupost!darwin.sura.net!jvnc.net!yale.edu!yale!mintaka.lcs.mit.edu!ai-lab!wheat-chex!bkphReferences:
<18AUG92.15521044@wl.aecl.ca>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!wupost!darwin.sura.net!jvnc.net!yale.edu!yale!mintaka.lcs.mit.edu!ai-lab!wheat-chex!bkph From: bkph@wheat-chex.ai.mit.edu (Berthold K.P. Horn) Newsgroups: comp.fonts Subject: Re: Why Windows 3.1 blocks out some of the upper ASCII codes? Message-ID: <26724@life.ai.mit.edu> Date: 19 Aug 92 00:42:39 GMT References: <18AUG92.15521044@wl.aecl.ca> Sender: news@ai.mit.edu Lines: 56 In-reply-to: desikacharyk@wl.aecl.ca's message of 18 Aug 92 21:52:10 GMT