Operating System - HP-UX
1833694 Members
3576 Online
110062 Solutions
New Discussion

Re: Problem with printing characters like gamma and beta

 
SOLVED
Go to solution
Roderick Derks
Frequent Advisor

Problem with printing characters like gamma and beta

Hello,

Got this problem with characters are not printed on paper correctly. On screen they look fine but when I print them they are not the the correct characters.
Charaters I'm talking about are i.e. gamma and beta.

Anyone any idea's? Printerdriverproblem? I'm far from being an expert on printing from Unix.
6 REPLIES 6
Mark Nieuwboer
Esteemed Contributor

Re: Problem with printing characters like gamma and beta

Hi Roderick,

Has to do with your PCL fonts list.
Which prinf command is used in the script to print the document.
You can get the pcl fonts list form your printer.

grtz. Mark
Roderick Derks
Frequent Advisor

Re: Problem with printing characters like gamma and beta

I forgot to mention that this concerns a Unix system HP11i... sorry, had a touch weekend.
The system is used for a hospital lab application.
The users log in via telnet and the characters they get to see are fine. But when a report is printed then the special characters are all wrong.
Mark Nieuwboer
Esteemed Contributor

Re: Problem with printing characters like gamma and beta

Hi Roderck,

Still it has to do with the printf command given in a shell / perl script.
it looks something like this.
printf("%c&l6D%c(10U%c(s0p12h10v0s0b8T",27,27,27)
The 10U prit special characters different then 1U for example.

grtz. Mark
Bill Hassell
Honored Contributor
Solution

Re: Problem with printing characters like gamma and beta

It's important to note that the ASCII characater set does not define any greek letters at all (see the man page: ascii). So the ability to even see Greek symbols is a feature of the program used to display your text. If the program is a native HP-UX program such as dtterm, xterm or hpterm, then the font used in that program has mapped the ASCII characters with the 8th bit turned on to special characters such as Greek symbols. But if you're not using Xwindows butg a terminal emulator on a PC, the emulator is doing the mapping for you.

In either case, printing is quite disconnected from the program itself. This is a case where what you see isn't necessarily what you get on the printer. Almost all printing mechanisms inside the programs are simply copying the ASCII characters to the printer. So the problem is matching the font used in the program with a font in the printer--not a simple task at all. The reason is that there are literally thousands of printer models and languages available and you'll have to get a complete list of the available fonts from each unique printer. Then see which font has Greek symbols available and how to select this font.

Now it gets even trickier: the printer(s) will usually have a default or standard font enabled for plain ASCII printing so thos default needs to be changed. For HP printers, you can change the font with -o options to the lp command but this must be done for each lp command. If you use a print button, there is no lp command so the printer will have to be set to the right font with either a front panel change (for printers with an interactive display) or a printer script change that changes the default for every print job. For the printer script, you'll need the actual printing codes needed to select the right font.

If this is a packaged application, the manufacturer has surely encountered this problem already and should have some suggestions. Note that Unix does not have an integrated printing subsystem like Windows. In PC Windows, character sets for the screen and for printing are (now) tightly integrated so printing appears to be seamless.


Bill Hassell, sysadmin
Roderick Derks
Frequent Advisor

Re: Problem with printing characters like gamma and beta

Manufacturer suddenly remembered other buyers of the software are having the same problem.
Solution is indeed not easy, but not a Unix problem, more an application and printer problem.
Thanks all for your input.

Roderick
Roderick Derks
Frequent Advisor

Re: Problem with printing characters like gamma and beta

Manufacturer suddenly remembered other buyers of the software are having the same problem.
Solution is indeed not easy, but not a Unix problem, more an application and printer problem.
Thanks all for your input.

Roderick