lilypond-user
[Top][All Lists]
Advanced

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

Re: How to write slurs and ties with scheme


From: Thomas Morley
Subject: Re: How to write slurs and ties with scheme
Date: Tue, 29 Sep 2015 23:04:59 +0200

2015-09-29 12:26 GMT+02:00 David Kastrup <address@hidden>:
> Rachael Thomas <address@hidden> writes:
>
>> Hello All:
>>
>> I am attempting to typeset some fingerstyle guitar music.  We extensively
>> use the TabStaff for the visual representation of this music.  I have a lot
>> of trouble with Slurs and Ties in the TabStaff.  If I could individually
>> instantiate Slurs and Ties my life would be much easier. I think that the
>> easiest way to do this is through a scheme function involving SlurEvent and
>> Spanners. However, my coding is not up to this at the moment.
>>
>> I really like the solution that was proposed for Issue 3031:
>>
>> https://code.google.com/p/lilypond/issues/detail?id=3031#c2
>>
>> However, it truly doesn't do anything.  Could someone enlightenment me as
>> to why it isn't doing anything?
>
> Because it states "So some 'fully tie and slur' syntax would be
> ideal. Some ideas:"
>
> This is not a solution.  It is a proposal for user interfaces for the
> not-yet-existing solution.
>
>> An example of what I want is attached as well as a brief snippet of code
>> which demonstrates that I am unable to get the desired effect.
>>
>> \version "2.18.2"
>>
>> \new TabStaff {
>>   \tabFullNotation
>> < bis'\1 g\4>16[( < fis'\2 ees\5> < g d>)]
>> }
>
> At the current point of time, slurs are only from one chord in a Voice
> to the next chord in a Voice.  So you'd need to put your notes into
> different Voice contexts in order to be able to slur them individually.
> However, Stems are strictly a single-Voice phenomenon.  So you need to
> put your notes in the same Voice.
>
> Solutions to this contradictions may involve putting invisible noteheads
> in a separate Voice and place a slur to them, or move the Stem_engraver
> to Staff level (which is infeasible if you ever have more than one Stem
> per timestep) or create an optional context level below Voice level and
> move the Slur_engraver there.
>
> Or wait for someone to implement slurs starting from a particular note
> rather than a whole chord.
>
> --
> David Kastrup



I'm thinking about the problem for some time now.
Another part of the problem is that most occurences of slurs in
TabStaff with \tabFullNotation are not really Slurs but what is called
'hammering on'/'pulling off'.

The initial example can be made work with (most of the additions in
\with are for the requested Stem):

\version "2.19.28"

m = {
  \set tieWaitForNote = ##t
  <bis'\1 g\4~ >16[ <fis'\2 ees\5> <g d>]
}

<<
\new Staff
  { \clef "G_8" \m }
\new TabStaff
  \with {
    \tabFullNotation
    %% for the Stems:
    \override Stem #'avoid-note-head = ##f
    \override Stem.layer = -100
    \override TabNoteHead.stem-attachment = #'(0 . 0)
    \override TabNoteHead.stencil =
    #(lambda (grob)
      (let ((default-stil (tab-note-head::print grob)))
        (ly:make-stencil
          (ly:stencil-expr default-stil)
          (ly:stencil-extent default-stil X)
          (interval-widen (ly:stencil-extent default-stil Y) 0.2))))
  }
  \m
>>

Pretty strange and although the wished output for the Tabstaff, it's
basicaly wrong (feels like bug-using).

Nevertheless, in _TabStaff_ we would need some curves (maybe Slur,
Tie, whatever) indicating 'hammering on'/'pulling off' with their
first and last control-point at the _same_ y-value.

Up to now I've not a really good idea how to achieve this ...


Cheers,
  Harm

Btw, I'm very curious which key this music should be

Attachment: atest-25.png
Description: PNG image


reply via email to

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