Operating System - HP-UX
1837262 Members
2694 Online
110115 Solutions
New Discussion

Re: X Print and font size

 
SOLVED
Go to solution
Doug Wheeler_1
Frequent Advisor

X Print and font size

I have an HP4000n connected to our network via JetDirect. When I print using :
more testfile.txt | lp , all is fine.
all is fine.

If I attempt to print the file from text editor, the font size is very small (all 42 lines fit in a two inch space).

I assume that there is either a config mismatch or I haven't configured something.

This is a recent HPUX 11.i install (new, not upgrade)
8 REPLIES 8
Robert-Jan Goossens
Honored Contributor

Re: X Print and font size

Hi,

Take a look at next question/answer your question is quit simular.

http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0x0602a24d9abcd4118fef0090279cd0f9,00.html

Hope it helps,

Robert-Jan.
Doug Wheeler_1
Frequent Advisor

Re: X Print and font size

Robert-Jan,
Thank you. I still don't have it working - I get a 'Cannot establish any listening sockets' error. However, I think this points me in th eright direction.
Doug
Alex Glennie
Honored Contributor
Solution

Re: X Print and font size

Sounds like you are using TPS Technical Print Server in conjunction with the CDE desktop.

My advise is disable it, it's a horrible product

How do I disable it?


Current CDE patches allow configuring CDE to revert to the older
HP-UX 10.20 behavior of routing the text to the lp spooler rather
than using TPS.
(Starting with [PHSS_25138/PACHRDME/English] for HP-UX 11.00 and
[PHSS_25197/PACHRDME/English] for HP-UX 11.11)

If the system has a current CDE patch installed:

A. Edit the file "/etc/rc.config.d/desktop" and add the following line:

DTPRTSVR=LP

or run the following command:

ch_rc -a -p DTPRTSVR=LP /etc/rc.config.d/desktop

NOTE: This environment variable does not exist by default;
therefore, it must be added and set to "LP" in order to overwrite
the system-default setting of TPS. It must be entirely entered
in uppercase.

B. Stop and Restart CDE

NOTE: insure that all users are currently logged out of CDE

'/sbin/init.d/dtlogin.rc stop'
'/sbin/init.d/dtlogin.rc start'

However


How do I change override the fonts used to print?

The X resources for CDE applications need to modified.
The defaults reside in "/usr/dt/app-defaults/C" directory.
The contents of this directory should not be modified. To customize
on a user basis, the resources should be set in "$HOME/.Xdefaults".
For a system-wide customization, files need to be created
in the "/etc/dt/app-defaults/C" directory that have the
same names as those in the "/usr/dt/app-defaults/C" directory.
I.e. Dtpad, Dtcm, etc.

To override the size change all of the "-0-0-m-*-*-*" entries
for "*Print*" lines. For example:

FROM:

Dtpad*Print*Page*HeaderLeft.renderTable:
-dt-application-bold-r-normal-serif-0-120-0-0-m-0-*-*


TO:

Dtpad*Print*Page*HeaderLeft.renderTable:
-adobe-courier-bold-r-normal-*-*-120-300-300-m-*-*-*:

Notes: 1) the "0-0" has been changed to "300-300" as an
example 2) the font name was changed 3) These are really
one long line -- cannot be separate or have any trailing
characters.

More detailed info on how to configure TPS can be found in the ITRC doc KBRC00009165



Doug Wheeler_1
Frequent Advisor

Re: X Print and font size

This just gets messier and messier.

Thanks, Alex. I do believe that the Technical Print Server was running. (I did a default Technical Computing OE install.)

Setting the DTPRTSVR=LP did not do it on it's own.

I then proceeded to load the patch (PHSS_25197).

The HP patch site recommended installing PHSS 26493,27428, PHNE 28103 & PHCO 24777.

The install went well, except....

Now CDE won't start. Luckily this is on a test box & not the production workstation.

So....now what?

--short rant--
This seems to be a lot of pain just so a user who is working in an X Window commercial app (SDRC-IDEAS) can print. This doesn't seem like such a weird request to me, but why does HP make it so hard?
Thanks for listening.
--eor--

Doug

Alex Glennie
Honored Contributor

Re: X Print and font size

OK so do you see a dtlogin process running ?

If not try /sbin/init.d/dtlogin.rc start result / errors ?

I presume if we are talking Ideas this is a workstation right ? what appears on the locale graphics console ?

consider running dr_dt

checking /var/dt/Xerros ?

rant excused

Doug Wheeler_1
Frequent Advisor

Re: X Print and font size

Hi Alex,
I am now back from rantland.

You are correct, this is a workstation (C3600 - the production unit is a J5600)

I rebooted the sytem and watched the process. Interesting points:


1. Start CDE login server shows [N/A]

2. Should I have also seen a Font server start box?

3. The Xerrors file contains several lines of :

---[start sample]---

/usr/bin/X11/xset: bad font path element (#40), possible causes are:
Directory does not exist or has wrong permissions
Directory missing fonts.dir
Incorrect font server address or syntax
Warning: Missing charsets in String to FontSet conversion
Warning: Cannot convert string "-dt-interface user-medium-r-normal-l*-*-*-*-*-*-
*-*-*" to type FontSet

---[end of sample]---

4. I see no dtlogin processes.

5. Running dr_dt kicks up 5 warnings :

in short :
/usr/spool directory not properly configured
/usr/spool/sockets/X11 not properly configured
/usr/bin/X11/X not properly configured

How bad is it?
Thanks,
Doug
Alex Glennie
Honored Contributor

Re: X Print and font size

not too sure and I have to go, ignore Xerrors, try running dtlogin.rc start and check / post contents of /etc/rc.config.d.desktop and check it's permissions ... I'll be back tomorrow but hopefully someone can pick up where I've left off
Doug Wheeler_1
Frequent Advisor

Re: X Print and font size

Success! Whoo! Hoo!
Here's what I did -

1. Ran /usr/dt/bin/dtconfig -e : this set CDE to start on boot.

2. Set DTPRTSVR=LP in /etc/rc.config.d/desktop

3. As final check, rebooted system.

All is good. I do believe that Alex was correct in indicating that the Technical Print Server was the issue.

I think the patch upgrade just injected some side issues that for now seem OK.

Thanks all for the help.
Doug