lilypond-devel
[Top][All Lists]
Advanced

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

Re: [PATCH] Re: Octavation syntax consistency (was: grand predefined-com


From: Valentin Villenave
Subject: Re: [PATCH] Re: Octavation syntax consistency (was: grand predefined-command thread)
Date: Sat, 28 Jun 2008 19:36:56 +0200

2008/6/28 Reinhold Kainhofer <address@hidden>:

>> Well, you don't need to be skilled too much, but that part about "a sec" is
>> definitely true ;-) Attached is an example.

Yes, so did I try but I misread the source code (I thought I'd have to
use ly:export, and a 'void music expression).

>> Basically, you write a music-function and inside that music function you
>> simply copy the stripped-down contents (which is only one line, anyway!) of
>> the set-octavation function, which is for some strange reason defined as a
>> scheme function rather than a music function. What's the reason for this?

My point exactly. However, I notice you didn't remove it in your patch
and that's definitely the way to go. We don't want to cause breakages,
but rather to offer our users a more convenient way.

>> ottava = #(define-music-function (parser location octave) (number?)
>>   (_i "set the octavation ")
>>   (make-ottava-set octave)
>> )

- Are you sure that the doc string is entered this way? I can't
remember having seen this syntax in the Scheme sources...

- I'd use an integer rather than a number.

- You've put a single parenthesis on the last line again ;-)
(not in the patch, though)

> Attached is a patch, which adds this music function to LilyPond and
> musicxml2ly, together with a conversion rule, docs changes (I don't know
> French, so please check if the text there needs to be changed, too!), updated
> regression tests, etc.

Its just great. Indeed, a c++ parser implementation would be much
better (such as what we have e.g. for \tempo). But a music-function
will do as well.

> I choose ottava as the name, since that's the musical term. However, there
> might arise some confusion with the function \octave, which I propose to
> rename to \octaveCheck (similar to \barNumberCheck) to make its purpose
> clearer.

Yes, this look sensible to me. \octaveCheck is a bit long to type, but
it's not like we use it everywhere :-)

Cheers,
Valentin




reply via email to

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