lilypond-user
[Top][All Lists]
Advanced

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

Scheme function with boolean argument.


From: Pierre Perol-Schneider
Subject: Scheme function with boolean argument.
Date: Fri, 11 Apr 2014 13:32:45 +0200


Hi,

I'd like to understand why the following function has no effect :

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\version "2.19.3"


myFunctionFalse = \override Score.BarNumber.break-visibility = ##(#f #f #f)

myFunctionTrue = \override Score.BarNumber.break-visibility = ##(#f #t #t)


myFunction =

#(define-music-function (parser location arg) (boolean?)

   #{

     \override Score.BarNumber.break-visibility = ##(#f $arg $arg)

   #})


{

   \myFunctionFalse

   \repeat unfold 16 c'1

   \myFunctionTrue

   \repeat unfold 16 c'1

%%% no/wrong effect here :

   \myFunction ##f

   \repeat unfold 16 c'1

   \myFunction ##t

   \repeat unfold 16 c'1

}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


Cheers,

~Pierre



reply via email to

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