[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: nopc -- Proposed Predefines
From: |
Carl D. Sorensen |
Subject: |
Re: nopc -- Proposed Predefines |
Date: |
Mon, 14 Jul 2008 04:28:31 -0600 |
On 7/14/08 3:24 AM, "Nicolas Sceaux" <address@hidden> wrote:
> Le 14 juil. 08 à 04:21, Carl Sorensen a écrit :
>
>> I propose some new predefined functions:
>>
>> \pointAndClickOn
>>
>> pointAndClickOn = #(ly:set-option 'point-and-click #t)
>>
>> and
>>
>> \pointAndClickOff
>>
>> pointAndClickOff = #(ly:set-option 'point-and-click #f)
>
>
> These do not do what you think they do.
> When the first "pointAndClickOn = ..." is read by the parser, the
> scheme expression that is following is evaluated, and thus
> point-and-click is turned on. pointAndClickOn then holds the value
> returned by ly:set-option (which is #t I guess).
> So what you have done here, is to set pointAndclickOn to #t, and
> pointAndClickOff to #f, and turned on then off the point and click
> function.
>
> The music function mentionned by James in the first place did what
> you want:
>
>> noPointAndClick =
>> #(define-music-function (parser location) ()
>> (ly:set-option 'point-and-click #f)
>> (make-music 'SequentialMusic 'void #t))
>
> here, the option is set when \noPointAndClick is invoked, not
> when it is defined.
>
Thanks, Nicolas. I should have recognized that, because I've just been
doing some work with void music functions.
OK, so now we have the right functions; do we want to have this added as a
predefined command? So far I count one yes and one no on user.
Carl
- Re: nopc -- Proposed Predefines, (continued)
- Re: nopc -- Proposed Predefines, Reinhold Kainhofer, 2008/07/15
- Re: nopc -- Proposed Predefines, Bertalan Fodor (LilyPondTool), 2008/07/15
- Re: nopc -- Proposed Predefines, luis jure, 2008/07/15
- Re: nopc -- Proposed Predefines, Valentin Villenave, 2008/07/14
- Re: nopc -- Proposed Predefines, Trevor Daniels, 2008/07/14
- Re: nopc -- Proposed Predefines, Nicolas Sceaux, 2008/07/14
- Re: nopc -- Proposed Predefines,
Carl D. Sorensen <=
- Re: nopc -- Proposed Predefines, James E. Bailey, 2008/07/14
- Re: nopc -- Proposed Predefines, Carl D. Sorensen, 2008/07/22