]> git.donarmstrong.com Git - lilypond.git/blobdiff - scm/tablature.scm
Run grand-replace for 2010.
[lilypond.git] / scm / tablature.scm
index 33d28dd1778a33edc9bbebf3819f63f17ed56579..702d15108b187a64184462978f887bd0335f6a32 100644 (file)
@@ -1,6 +1,6 @@
 ;;;; This file is part of LilyPond, the GNU music typesetter.
 ;;;;
-;;;; Copyright (C) 2009 Marc Hohl <marc@hohlart.de>
+;;;; Copyright (C) 2009--2010 Marc Hohl <marc@hohlart.de>
 ;;;;
 ;;;; LilyPond is free software: you can redistribute it and/or modify
 ;;;; it under the terms of the GNU General Public License as published by
 (add-new-clef "moderntab" "markup.moderntab" 0 0 0)
 
 ;; define sans serif-style tab-Clefs as a markup:
-(define-builtin-markup-command (customTabClef
+(define-markup-command (customTabClef
                                 layout props num-strings staff-space)
   (integer? number?)
-  music
-  ()
+  #:category music
   "Draw a tab clef sans-serif style."
   (define (square x) (* x x))
   (let* ((scale-factor (/ staff-space 1.5))
     (if (string=? glyph "markup.moderntab")
         ;; if it is "moderntab", we'll draw it
         (let* ((staff-symbol (ly:grob-object grob 'staff-symbol))
-               (line-count (ly:grob-property staff-symbol 'line-count))
+               (line-count (if (ly:grob? staff-symbol)
+                              (ly:grob-property staff-symbol 'line-count)
+                              0))
                (staff-space (ly:staff-symbol-staff-space grob)))
 
           (grob-interpret-markup grob (make-customTabClef-markup line-count
                                         (lambda (grob)
                                           (parenthesize-tab-note-head grob))))
              ;; tab note head is invisible
-             (ly:grob-set-property! tied-tab-note-head 'transparent #t)))
+             (begin
+               (ly:grob-set-property! tied-tab-note-head 'transparent #t)
+               (ly:grob-set-property! tied-tab-note-head 'whiteout #f))))
 
         ;; tie is not split -> make fret number invisible
-        (ly:grob-set-property! tied-tab-note-head 'transparent #t))))
+        (begin
+          (ly:grob-set-property! tied-tab-note-head 'transparent #t)
+          (ly:grob-set-property! tied-tab-note-head 'whiteout #f)))))
 
 ;; repeat ties occur within alternatives in a repeat construct;
 ;; TabNoteHead #'details handles the appearance in this case