Hello Nicolas,

Am 24.12.2011 11:13, schrieb Nicolas Sceaux:
Le 23 déc. 2011 à 09:39, Marc Hohl a écrit :

#(ly:add-option 'no-slurs #f
      "Whether to print a slur or not.")
The "no-" prefix is dealt with specially for options.
For instance, considering an option named `foo', if you use the
command line switch:

   lilypond -dno-foo ...

then (ly:get-option 'foo) will return #f

Is this mentioned anywhere in the documentation? I didn't find
anything about "no-" ...
=======foo.ly
#(ly:add-option 'foo #t "Fooing something")

#(format #t "~%foo option: ~a" (ly:get-option 'foo))
========

$ lilypond toto.ly
foo option: #t

$ lilypond -dno-foo toto.ly
foo option: #t

I don't know wheter this is a typo above (two times #t), but
if I use this file "foo.ly":

\version "2.15.23"

#(ly:add-option 'foo #t "Fooing something")

#(format #t "~%foo option: ~a" (ly:get-option 'foo))

I get:

marc@olivia:~/sandbox$ Lilypond foo.ly
GNU LilyPond 2.15.23
»foo.ly« wird verarbeitet
Analysieren...
foo option: #t
Success: compilation successfully completed

marc@olivia:~/sandbox$ Lilypond -dno-foo foo.ly
GNU LilyPond 2.15.23
Warnung: keine solche interne Option: no-foo
»foo.ly« wird verarbeitet
Analysieren...
foo option: #t
Success: compilation successfully completed

so the value remains #t in both cases, and the option
"no-foo" is marked as an unknown interal option.

What is wrong here?

Thanks,

Marc




_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user

Reply via email to