lilypond-devel
[Top][All Lists]
Advanced

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

Whither the switch to OpenType fonts? (they break my printer)


From: John Hawkinson
Subject: Whither the switch to OpenType fonts? (they break my printer)
Date: Mon, 17 Apr 2006 20:36:36 -0400
User-agent: Mutt/1.5.6i

I mentioned in a separate thread ("Why is %%PageMedia: a4 hardcoded?")
some problems with LilyPond's Postscript hanging my printer (as of
2.7.38 and later; 2.7.36 and prior worked fine).

At first, I presumed that this was a result of having a potentially
non-8-bit clean path to my printer because of site-local spooling
system issues, but I've verified that's not the case (spooling files
to the printer directly with netcat, etc.).

It seems that the binary OTF encodings of both Aybabtu-Regular and
Emmentaler-18 give this problem. Going and hand-editing the postscript
and replacing the OTF versions with the type1 versions (and renaming
the references to the fonts from Aybabtu-Regular to
PFAAybabtu-Regular, etc.,) produces a file that works fine (though it
is 26% larger).

How does it crash the printer? Well, various ways. Most clearly is
that sometimes it produces a 79.00FE crash on the front panel, and
other times it simply hangs the printer such that it does not respond
to input over the network or on the front panel. I haven't pursued it
with HP, but they do have a history of having a myriad of such
problems with strange binary encodings. The printer in question is an
HP8150DN (of which we have a whole slew around here) running the most
recent firmware (20041013 MB7.119).

One workaround I tried was to convert the fonts to hex, and wrap their
encoding in:
        currentfile /ASCIIHexDecode filter cvx exec
        %...hex of the font here...
        >

This does not work. It seems to work for Aybabtu, but not for
Emmentaler, which causes an error even with ghostscript. (Error:
/invalidfont in --.type42execchar--) I'm not sure why...

So anyhow:

.       Can LilyPond go back to Type 1 fonts in the interest of
        broader compatibility? Or perhaps this could be an option (but
        they would have to be generated at build time, anyhow). On the
        other hand, is there anything to be gained by OTF fonts?
        having the PS files a bit smaller probably doesn't matter for
        the ghostscript ps->pdf conversion, and doesn't seem a big price
        to pay for better compatibility.

.       Why do the different encodings (Type1 PFA, OTF) produce
        differing-named fonts (PFAAybabtu-Regular vs. Aybabtu-Regular)?
        [hence the necessity for munge-lily-font-name].

It seems like this has potentially been a problem before.
Revs 1.84 through 1.86 of scm/framework-ps.scm share this log message
tidbit:

* scm/framework-ps.scm (munge-lily-font-name): new function
(write-preamble): hack: insert PFA equivalent of CFF into
.PS. This makes LilyPond output printable on normal PS printers
again.


I suppose that I could attempt to take up this issue with HP,
and perhaps get it fixed in a new firmware version half a year
from now (not that they've released any in the past 2 years),
but I must say I'm not enthusiastic.


In that other thread, <address@hidden> wrote on Mon, 17
Apr 2006 at 13:14:03 +0200 in
<address@hidden>:

> It sure would be a fine thing if the PostScript could be sent to a 
> PostScript printer without problems.

Great!

--jhawk


John Hawkinson <address@hidden> wrote on Sun, 16 Apr 2006
at 21:34:22 -0400 in <address@hidden>:

> Date: Sun, 16 Apr 2006 21:34:22 -0400
> From: John Hawkinson <address@hidden>
> To: address@hidden
> Message-ID: <address@hidden>
> In-Reply-To: <address@hidden>
> Subject: Re: Why is %%PageMedia: a4 hardcoded?
> 
> I <address@hidden> wrote (quite a few hours ago...) on Sun, 16 Apr 2006
> at 10:55:43 -0400 in <address@hidden>:
> 
> > p.s.: In moving from LilyPond 2.6.3 to 2.9.2, I find that spooling
> > postscript crashes my HP LaserJet 8150DN.  Haven't finished
> > figuring out why yet... I'll get there...
> 
> It appears that this broke between 2.7.36 and 2.7.38,
> and it seems to be a result of the massive font changes
> that happened therein (apparently moving to embedding
> opentype fonts instead of Type 1 fonts?).
> 
> I can't seem to find a discussion of the rationale for all of this on
> lilypond-{user,devel} or bug-lilypond. Am I just missing it, or could
> someone point me to the discussion?
> 
> 
> Perhaps it has something to do with my print spooling environment, but
> it seems like the non-eight-bit-clean nature of the generated
> PostScript is likely to be my problem...
> 
> Thanks for any pointers...
> 
> --jhawk
> 
> 
> _______________________________________________
> lilypond-devel mailing list
> address@hidden
> http://lists.gnu.org/mailman/listinfo/lilypond-devel




reply via email to

[Prev in Thread] Current Thread [Next in Thread]