bug-lilypond
[Top][All Lists]
Advanced

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

Bug with (banjo) tablature rendering (workaround possible)


From: Dirk De Wachter
Subject: Bug with (banjo) tablature rendering (workaround possible)
Date: Thu, 29 Dec 2011 18:42:07 +0000 (UTC)
User-agent: Loom/3.14 (http://gmane.org/)

> I'm not top posting.
The script should explain it all. 
It is written for the latest stable lilypond.
It is somewhat lengthy as 4 different cases are shown.
----------- cut here -------------
% A grace note (\grace, \acciaccatura, \appoggiatura) at the beginning 
%   of a score results in a 6 bar tablature for (5-string) banjo with 
%   noteheads between lines instead of upon the line, except for this 
%   first grace note. (case 2 & 3).
% This does not happen if no grace note is at the beginning of the 
%   score (case 1 & 4)
\version "2.14.2"

gracemusic = { \acciaccatura g8\5 }
music =  {
        <b\2 d,\4>4 \gracemusic <<{c4.\2( b8\2)} \\ {e,4\4}>>
        g16\5(a\2 b c\5)
}
extraPause = { \partial 8 s8 }

normalmusic = { \gracemusic \music }
noGrace = { \music }
withPause = { \extraPause \gracemusic \music }

sarabandeN = \context Staff 
        \relative c'' { \noGrace }
sarabande = \context Staff 
        \relative c'' { \normalmusic }
sarabandeP = \context Staff 
        \relative c'' { \withPause }

sarabandeBN = \context TabStaff 
<<
        \set TabStaff.tablatureFormat = #fret-number-tablature-format-banjo
        \set TabStaff.stringTunings = #banjo-open-g-tuning
        \relative c'' { \noGrace }
>>
sarabandeB = \context TabStaff 
<<
        \set TabStaff.tablatureFormat = #fret-number-tablature-format-banjo
        \set TabStaff.stringTunings = #banjo-open-g-tuning
        \relative c'' { \normalmusic }
>>
sarabandeBP = \context TabStaff 
<<
        \set TabStaff.tablatureFormat = #fret-number-tablature-format-banjo
        \set TabStaff.stringTunings = #banjo-open-g-tuning
        \relative c'' { \withPause }
>>

\book
{
        \markuplines { \column {
\bold \large "Wrong number of Tablature lines with grace note"
" A grace note (\grace, \acciaccatura, \appoggiatura) at the start of a score" 
"   results in a 6 bar tablature for banjo"
"   with noteheads between lines instead of"
"   on the line, except for this first grace note. (case 2 & 3)."
" This does not happen if no grace note is at the beginning of the score"
"  (case 1 & 4)"
                \hspace #40
        } }
        \score { 
                \new StaffGroup 
                << 
                        \sarabandeN 
                        \sarabandeBN
                >>
                \header { 
                        piece = 
"1. No grace note at beginning: correct rendering" }
        }
        \score { 
                \new StaffGroup 
                << 
                        \sarabande 
                        \sarabandeB
                >>
                \header { 
                        piece = 
                                \markup { 
                                \wordwrap { 
"2. " \bold {"With"} " grace note at beginning:"
\bold {" Incorrect"} " rendering with 6 bars." 
"Grace note is on the line, while other noteheads are between tablature lines." 
"First grace note fret is completely wrong"} } }
        }
        \score { 
                \new StaffGroup 
                << 
                        \sarabande 
                        \sarabandeBN
                >>
                \header { 
                        piece = \markup { \wordwrap {
"3. Even with the grace note not in the Tablature but only in the music Staff," 
"rendering is faulty with 6 lines in the Tablature." } } }
        }
        \score { 
                \new StaffGroup 
                << 
                        \sarabandeP 
                        \sarabandeBP
                >>
                \header { 
                        piece = 
"4. With something in front of the grace note, rendering is OK." }
        }
}








reply via email to

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