Walt Mankowski on 7 Jun 2018 20:23:40 -0700


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: [PLUG] Printer font problem in Ubuntu 18.04


We talked about this at PLUG last night and I've done some more
experimentation. I still haven't solved it, but I'm getting closer!

Last night someone suggested I try printing the PLUG home page, since
it's not doing anything fancy with fonts. I still had the same
problem, namely that it looked fine when printed from Ubuntu, but the
fonts were all messed on when printed from the Mac.

However, I discovered that when it tries to print HTML, CUPS converts
it to a PDF, prints that, and leaves the PDF lying around in /tmp. I
was able to find 2 of my experiments, which we'll call mac.pdf and
ubuntu.pdf. Thinking it's likely a font problem, I ran pdffonts on
each file and found some interesting results:

$ pdffonts ubuntu.pdf
name                                 type              encoding         emb sub uni object ID
------------------------------------ ----------------- ---------------- --- --- --- ---------
DejaVuSans                           CID TrueType      Identity-H       yes no  yes      8  0
LiberationSerif-Bold                 CID TrueType      Identity-H       yes no  yes      9  0
LiberationSerif                      CID TrueType      Identity-H       yes no  yes     10  0

$ pdffonts mac.pdf
name                                 type              encoding         emb sub uni object ID
------------------------------------ ----------------- ---------------- --- --- --- ---------
PRIMCA+Times-Bold                    TrueType          MacRoman         yes yes no      42  0
PFIADN+Times-Roman                   TrueType          MacRoman         yes yes no      43  0

When I tried printing ubuntu.pdf from the command line with

  lpr ubuntu.pdf

it failed in the same manner as before. But if I opened it with

  xpdf ubuntu.pdf

it looked fine! And I could print it!

I sorted all the fonts under /usr/share/fonts/truetype by access time,
and it appears that xpdf is using the Liberation fonts. Which raises
the question -- if xpdf can figure out which fonts to use, why can't
CUPS?

Unfortunately now I'm stuck again. Anyone have any advice on how to
fix CUPS?

Walt

On Mon, Jun 04, 2018 at 09:49:38PM -0400, Walt Mankowski wrote:
> I'm having an odd printing problem since upgrading from Ubuntu 17.10
> to 18.04. I've got an Ubuntu box that I've been using as a shared
> printer. I've also got a MacBook running the latest version of macOS,
> which is where most of my print jobs originate. The printer in
> question is an HP LaserJet P1006.
> 
> If I print from the Ubuntu box while the printer is plugged into it
> (it's USB-only), everything looks fine. Similarly, if I plug the
> printer into the Mac and print from there, it also looks fine.
> However, if the printer's plugged into the Ubuntu box and I print from
> the Mac, the fonts are all messed up. If I print, say, the Google home
> page, the images look fine, but the text areas render as a bunch of
> boxes and random characters.
> 
> I also tried printing a PDF that I created with LaTeX. Interestingly,
> that printed perfectly! That makes me think that there is some sort of
> font mismatch, since LaTeX embeds the fonts in the PDF.
> 
> This same setup had been working fine up in 17.04 and 17.10, but
> failed the first time I tried to print after switching to 18.04.
> 
> I've tried reinstalling the drivers on both ends, but it didn't help.
> 
> I've looked at all the CUPS settings but I don't see anything that
> might be causing this behavior. Is anyone else having this problem? Or
> can anyone suggest how I might go about trying to fix it?
> 
> Thanks.
> 
> Walt



> ___________________________________________________________________________
> Philadelphia Linux Users Group         --        http://www.phillylinux.org
> Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce
> General Discussion  --   http://lists.phillylinux.org/mailman/listinfo/plug

Attachment: signature.asc
Description: PGP signature

___________________________________________________________________________
Philadelphia Linux Users Group         --        http://www.phillylinux.org
Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce
General Discussion  --   http://lists.phillylinux.org/mailman/listinfo/plug