Henrik Frisk wrote:
Pedro Kröger <[EMAIL PROTECTED]> wrote:
Han-Wen Nienhuys <[EMAIL PROTECTED]> writes:
I think it would also be better if the code just used numbers, and does
a (format "~a" NUMBER) or (number->string NUMBER) in the end.
Here it is. I also made Graham's suggestion of switching the numbers,
like (compound-time grob 3 16 5 8). This is a very cool example (thanks
Henrik!). I think the ultimate would be to merge the 2 functions and or
detect the behavior automatically or have it passed as a keyword (like
compound-time :equal-div)
All these suggestions make a lot of sense, and thanks Pedro for implementing it
and thanks for clarifying let* as compared to define. The code looks better! I
will take a look at the autobeaming suggested by Graham. I also thought about
merging the two functions. Rather than using a keyword, if the function is
called with divtwo==0 use equal divisor. In other words: (compound-time grob 3
8 5 8) would result in 3/8+5/8 and (compound-time grob 3 8 5 0) would give
3+5/8 (as I believe it's a matter of taste what way you want to notate it).
Does that make sense? Maybe a keyword makes it simpler to understand?
Have you considered using optional arguments?
(define (func a b . rest)
..
)
rest is a list containing the rest of the arguments.
BTW, can you adjust your mailreader to break lines at 72 columns? When I
answer you, I get your text in a single-line paragraph.
--
Han-Wen Nienhuys - [EMAIL PROTECTED] - http://www.xs4all.nl/~hanwen
_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user