[frogs] Re: Scheme music function attempt

[ Thread Index | Date Index | More lilynet.net/frogs Archives ]


Yes, that helped a lot. Thanks!
That's how I made the first step work now, in case of interest.

#(define (root-name music)
   (let* ((e (car (ly:music-property music 'elements)))
          (p (ly:music-property e 'pitch)))
     (if (ly:pitch? p)
	 (let ((n (ly:pitch-notename p)))
	   (if (number? n)
	       (number->string n))))))
		 
cs = #(define-music-function (parser location pitch) (ly:music?)
	(let ((rn (root-name pitch)))
	  #{ \mark \markup { $rn } #}))

\new Staff { c'1 \cs c'1 c'1 }

Also I didn't know about the scheme-way of using display.
It'll make trying out a lot easier.

Thanks again.

Regards,

Tao
-- 
NUR NOCH BIS 31.01.! GMX FreeDSL - Telefonanschluss + DSL 
für nur 16,37 EURO/mtl.!* http://dsl.gmx.de/?ac=OM.AD.PD003K11308T4569a

---

----
Join the Frogs!


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/