;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 1998--2005 Jan Nieuwenhuizen <janneke@gnu.org>
+;;;; (c) 1998--2006 Jan Nieuwenhuizen <janneke@gnu.org>
;;;; Han-Wen Nienhuys <hanwen@cs.uu.nl>
;;; end of tablature functions
(define-public (make-stencil-boxer thickness padding callback)
+
"Return function that adds a box around the grob passed as argument."
- (lambda (grob) (box-stencil (callback grob) thickness padding)))
+ (lambda (grob)
+
+ (box-stencil (callback grob) thickness padding)))
(define-public (make-stencil-circler thickness padding callback)
"Return function that adds a circle around the grob passed as argument."
(define-public (print-circled-text-callback grob)
(let* ((text (ly:grob-property grob 'text))
+
(layout (ly:grob-layout grob))
(defs (ly:output-def-lookup layout 'text-font-defaults))
(props (ly:grob-alist-chain grob defs))
- (circle (Text_interface::interpret_markup
- layout props (make-draw-circle-markup 0.8 0.1 #f)))
- (text-stencil (Text_interface::interpret_markup layout props text)))
-
- (ly:stencil-add (centered-stencil text-stencil) circle)))
+ (circle (ly:text-interface::interpret-markup
+ layout props (make-circle-markup text))))
+ circle))
;;(define (mm-to-pt x)
(define-public (first-bar-number-invisible barnum) (> barnum 1))
-;; See documentation of Item::visibility_lambda_
+;; See documentation of ly:item::visibility-lambda-
(define-public begin-of-line-visible
#(#f #f #t))
(define-public end-of-line-visible
(".|." . (".|." . ()))
("" . ("" . ""))
(":" . (":" . ""))
+ ("." . ("." . ()))
("empty" . (() . ()))
("brace" . (() . "brace"))
("bracket" . (() . "bracket")) )))
(index-cell (cdr result) dir)
#f)))
)
-
- (if glyph-name
- (set! (ly:grob-property grob 'glyph-name) glyph-name)
- (ly:grob-suicide! grob))))
+
+ (if (not glyph-name)
+ (ly:grob-suicide! grob))
+
+ glyph-name))
(define-public (shift-right-at-line-begin g)
(ly:stencil-translate-axis lp (- (car x-ext) padding) X)
(ly:stencil-translate-axis rp (+ (cdr x-ext) padding) X))
))
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;;
+
+(define-public (chain-grob-member-functions grob value . funcs)
+ (for-each
+ (lambda (func)
+ (set! value (func grob value)))
+ funcs)
+
+ value)