lilypond-devel
[Top][All Lists]
Advanced

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

Re: Using/requiring Cairo


From: David Kastrup
Subject: Re: Using/requiring Cairo
Date: Sun, 25 Jun 2017 07:33:29 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.50 (gnu/linux)

address@hidden writes:

> Werner:
>> >> "taking care of PostScript" is not related to converting LilyPond's
>> >> graphics internals to Cairo since LilyPond's graphics internals are
>> >> not written in PostScript.
>> > 
>> > Ok, forget it then, you are not listening.  [...]
>> 
>> Why such a hostile tone, Karl?  There is no reason for this.
>
> No, that is not a hostile tone, it's a tired tone.
>
>> I have to agree with David: While having well readable PS is nice,
>> this is just a by-product of the conversion process from a .ly to a
>> .pdf file.  Essentially, the formatting of the PS stuff is of *no
>> importance* to a vast majority of users.
>
> I don't argue about that, save if you just want the ps file.
>
>> > I use the PS as is, [...]
>> 
>> So tell us what you are doing with the PS stuff.
>
> Mostly the same thing you do with your pdf's, I guess, like
> psnup, psselect, pstops, a patched version of psbook (so the paper 
> curves the right way when I fold them out of the printer),
> includegraphics from latex, and probably some more.

All of those work with PostScript created from Cairo.  All of those
utilities are also available for PDF.  Indeed, since they do not have to
rely on DSC, they work more reliably.

> And my printers doesn't take pdf.

They do take PostScript created by Cairo.  And likely print it faster
than the current LilyPond PostScript output since they don't have to
expand a number of complex commands themselves.

>> > And my interest was in reading pdf's, so I can write programs to
>> > extract the info I want from pdf's.
>> 
>> Have you tried `pdftk' to uncompress a PDF file?  It's then almost as
>> readable as a plain PS file (see attachments).
>
> No, it looks promising, thanks, now I have to find out how it does
> that.

Depending on what "Extract the info you want from PDFs" means, pdf2dsc
can be quite handy.  Basically, it gives you DSC-compliant file only
containing references into the PDF file.  That does not actually
convert/rewrite any content but yields to most PostScript manipulation
with results that are useful to processing with Ghostscript.

However, so should Cairo-generated PostScript do: using the PostScript
backend of Cairo does not run through PDF in the first place.

> Though, my conclusion was that pdf is not better than ps regarding
> postprocessing, and yes I know that pdf (depending on pdf version) has
> some features that ps don't have.

But nobody is talking about PDF.  The difference in question is
Cairo-generated PostScript vs the PostScript generated by Scheme
programming and LilyPond's music-drawing-routines.ps and encodingdefs.ps
.

-- 
David Kastrup



reply via email to

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