lilypond-user
[Top][All Lists]
Advanced

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

Re: An easy way to convert from absolute to \relative?


From: PMA
Subject: Re: An easy way to convert from absolute to \relative?
Date: Wed, 21 Dec 2011 10:19:14 -0500
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.16) Gecko/20101227 Iceape/2.0.11



David Kastrup wrote:
PMA<address@hidden>  writes:

David Kastrup wrote:
Father Gordon Gilbert<address@hidden>   writes:

Hi all,

I have a number of pieces I entered quite a while ago (2.5.x, etc) in
absolute pitch -- being the easiest for me at the time.

But now I'd like to update them (2.15.x), and while convert-ly does a
good job of changing up the basic syntax, I'd like to know if there's
an easy way of getting rid of all the ' and , so the piece can be done
in \relative mode.  I did "search and replace" on one long piece,
which resulted in well over an hour's work fixing octaves.  Can this
be automated?

This appears on the feature list of the LilyPond editor Frescobaldi
<URL:http://frescobaldi.org>.

A solution within LilyPond itself would not really help as it would not
preserve the spacing of your input source.


In Linux at least, you could make the changes *and* preserve
your layout, by calling 'sed' against the .ly file to replace each
" ' " and " , " with a space.  something like

                  cat<file>.ly | sed "s/[',]/ /g">  FOO

(That's a guess.  Do check out FOO before copying it back in.)

I am afraid that converting to relative mode is more complex than that.

I didn't mean to imply that it would do everything -- just that, anticipating
inevitable adjustments, it would dependably/consistently "clear the deck".
This presumes of course that a clear deck would be helpful, as it was for
me in one such instance where the adjustments were easily/quickly then
entered by hand.  But you remind me, that may not be the case here.



reply via email to

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