Edit Rename Changes History Upload Download Back to Top

Euro symbol in Postscript

I ran into the problem that the Euro character ￿ is not yet supported in VW7 (and presumably VW5i and VW3) Postscript printing package and fixed this problem as described next.

To get the Euro character being printed the first thing to do is to add the Euro unicode values ('Euro' 16r20AC) to the method PostScriptFontBody class >> psCodes (PostScriptFontBody-eurosymbol-support.st)

Now the width of the Euro character has to be known to the VW. This information is obtained from fontmetric files. The standard set of font metric files is available in the DONWLOAD directory of this wiki. The files however do not include the Euro character information. Therefore a new set of fontmetric files is needed. I found some files on the internet, and put them here as fontmets2.zip in de DOWNLOAD section. Keep in mind that not all fonts in the set Cincom is offering are included in the set I put here. Just the basic fonts are included. You can read the font files using PostScriptFontBody class >> rescanFontMetrics or better use the PSFontPrinting5i parc goodie. You need a fix of PostScriptFontBody class >> nameToken: (also in PostScriptFontBody class >> PostScriptFontBody-eurosymbol-support.st to read the .notdef symbol in this new version metric files.

The quick way without having to read font metric files

Another way to print the Euro symbol without reading it's width from the font metrics file is to let the width method return a maximum character width when the character width is not available. To do this I changed the methods PostScriptFontBody >> encodeSymbolic: and PostScriptFontBody >> widthAt: (get changes here). The Euro character then is taking maximum space, which isn't very neat, but may work for some cases.

In order to have Euro support in Postscrip out of the box maybe Cincom can modify the VW code and supply updated fontmetrics files.

Ype Hemstra
EDS Travel & Transport Solutions
The Netherlands


Edit Rename Changes History Upload Download Back to Top