lilypond-user
[Top][All Lists]
Advanced

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

Re: Help with scheme


From: Michael Gerdau
Subject: Re: Help with scheme
Date: Thu, 22 Aug 2024 07:12:46 +0200

Dear William,

thanks a lot for your help. With your changes I got the scores to compile.

With the problem of getting the score compiled solved I investigated how 
possibly those options could be set or used.

There is no documentation included as to how the option clefs is supposed to 
work. There is documentation claiming providing „-d ‚A4=#t’“ will select A4 
paper which does not work as you mentioned.

I searched the entire score and the function/macro insertClef is not used at 
all (could have done that before asking my question…) and so I conclude it is 
part of a more general set of included files the original author uses for all 
his scores.

My guess is these are set elsewhere when used.

Kind regards,
Michael 

Mobil gesendet

> Am 21.08.2024 um 16:06 schrieb William Rehwinkel 
> <william@williamrehwinkel.net>:
> 
> Dear Michael,
> 
> When I change
> 
> #(define *clefs-option* (ly:get-option 'clefs))
> 
> to
> 
> #(define *clefs-option* 'gamba)
> 
> and
> 
> (#t (define *use-gamba-clefs* #t))
> 
> to
> 
> (#t (set! *use-gamba-clefs* #t)) ; note "set!"
> 
> 
> lilypond 2.25.18 compiles the code without any errors. But I don't know if 
> this will make this example actually work.
> 
> Also, the use of ly:get-option is odd to me, I didn't know that the user 
> could define custom options (if I do `lilypond -dclefs=normal clefs.ly` it 
> says "warning: no such program option: clefs").
> 
> Could you show us a minimum example including an excerpt of music that 
> renders using different clefs?
> 
> Thanks,
> -William
> 
>> On 8/21/24 09:19, Michael Gerdau wrote:
>> Dear lilyponders,
>> I've donwloaded some older lilypond sources (version 2.18.2) from cpdl.org 
>> and am trying to make them work with 2.25.18.
>> Most things are straight forward however there is some scheme code that 
>> allows to switch between different clefs.
>> Could someone with better scheme fu than I have tell me how I should adjust 
>> the code for 2.25.18?
>> The error I get is:
>> Starte lilypond 2.25.18 [scheme-error.ly]...
>> Processing `/home/mgd/lilypond-Noten/scheme-error.ly'
>> Parsing...
>> /home/mgd/lilypond-Noten/scheme-error.ly:10:2: error: Guile signaled an 
>> error for the expression beginning here
>> #
>>  (cond
>> Syntax error:
>> /home/mgd/lilypond-Noten/scheme-error.ly:10:0: body should end with an 
>> expression in form (let () (define *use-gamba-clefs* #t))
>> fatal error: failed files: "/home/mgd/lilypond-Noten/scheme-error.ly"
>> Wurde mit dem Return-Code 1 beendet.
>> Trying to make sense of the errormsg I verbatim replaced
>>   (#t (define *use-gamba-clefs* #t))
>> with
>>   (let () (define *use-gamba-clefs* #t))
>> but that doesn't work either (the error is different though).
>> snip -- snip -- snip -- snip -- snip -- snip -- snip -- snip -- snip
>> \version "2.25.18"
>> #(define *clefs-option* (ly:get-option 'clefs))
>> % #(display "\nDEBUG: *clefs-options* = ") #(display (ly:get-option 'clefs)) 
>> #(display "\n")
>> #(define *use-recorder-clefs* (eq? *clefs-option* 'recorder))
>> #(define *use-gamba-clefs*    (eq? *clefs-option* 'gamba))
>> #(define *use-original-clefs* (eq? *clefs-option* 'original))
>> #(cond
>>   (*use-recorder-clefs*  (display "\nUsing recorder clefs.\n"))
>>   (*use-gamba-clefs*     (display "\nUsing gamba clefs.\n"))
>>   (*use-original-clefs*  (display "\nUsing original clefs.\n"))
>>   (#t (define *use-gamba-clefs* #t))
>>   )
>> insertClef = #(cond
>>                (*use-recorder-clefs*  #{ \clef treble #})
>>                (*use-gamba-clefs*     #{ \clef alto #})
>>                (*use-original-clefs*  #{ \clef mezzosoprano #})
>>                )
>> snip -- snip -- snip -- snip -- snip -- snip -- snip -- snip -- snip
>> Kind regards,
>> Michael
> 
> --
> William Rehwinkel (any pronouns)
> Juilliard School '26 - Oberlin Conservatory '24
> william@williamrehwinkel.net - https://williamrehwinkel.net
> PGP Public Key: https://ftp.williamrehwinkel.net/pubkey.txt
> <OpenPGP_signature.asc>




reply via email to

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