lilypond-user
[Top][All Lists]
Advanced

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

Re: Glissando between single notes in chord


From: pabuhr
Subject: Re: Glissando between single notes in chord
Date: Sat, 06 Oct 2012 15:21:12 -0700

    I'm using glissandos to indicate a guide finger in fingering, and in ...

Hey Nick, we certainly struggle with indicating a guide finger. 8-)

First, an observation, which I know you are already aware of, but I'll make it
anyway.  It is important to differentiate between the glissando, which makes a
sound, and a guide finger, which is finger movement without a sound (like a
breath mark).  Therefore, the notation for these two items needs
differentiation or the guitar player can make an uncalled for sound. Clearly,
the glissando with a finger number implies a guide finger.  The notation I like
for the guide finger is a short mark before the finger number so there is less
chance of mistaking it for a glissando.

Below is my attempt at a guide finger (which I'm sure you saw a few months
ago).  I redefined your "guide" to "Guide" so both are available in the
example. My complain with your version is that I would play it as a glissando
rather than take it as an instruction for a guide finger.  The problem with my
version is that the combined guide/finger-number are centred above/below the
note. I don't know how to get the finger number centred above the note (i.e.,
right justify the entire glyph); any help would be appreciated. I did try
ly:stencil-aligned-to but no change in the output.

Anyway, my 2 cents on this on-going struggle. ;-)


\version "2.16.0"
\language english
#(set-global-staff-size 30)

% left-hand finger guide finger between notes
#(define (gx slope character fingering)
  ;; Purpose
  ;;   add ornamentation character before fingering symbol
  ;; Parameters
  ;;   slope : angle of rotation around right centre
  ;;   character : ornamentation character for fingering
  ;;   fingering : fingering designation for note
  ;; Examples
  ;;   (gx 0 #x2013 fingering)
  ;;       unicode #x2011 <-> #x2015 are different length "-" punctuation
  (let ((music (make-music 'FingeringEvent))
                (finger (ly:music-property fingering 'digit))
                (guide-char character))
        (set! (ly:music-property music 'tweaks)
          (acons 'stencil
                 (lambda (grob)
                   (ly:stencil-combine-at-edge
                     (ly:stencil-rotate (grob-interpret-markup grob (markup 
#:char guide-char))
                          slope 1 0)            ;; rotate "slope" around right 
centre
                     X 1                                ;; combine stencils 
along X-axis on right
                     (grob-interpret-markup grob (number->string finger))
                     0.2)
                 )                              ;; add padding to move guide 
slightly left from finger number
                 (ly:music-property music 'tweaks)))
        music))

% guide-neutral
%   <c-\gn-1>4  c4^\gn^2  c4-\gn-3  c4_\gn_4
gn = #(define-music-function (parser location fingering) (ly:music?)
           (gx 0 #x2013 fingering))
% guide-down
%   <c-\gd-1>4  c4^\gd^2  c4-\gd-3  c4_\gd_4
gd = #(define-music-function (parser location fingering) (ly:music?)
           (gx 20 #x2013 fingering))
% guide-up
%   <c-\gu-1>4  c4^\gu^2  c4-\gu-3  c4_\gu_4
gu = #(define-music-function (parser location fingering) (ly:music?)
           (gx -20 #x2013 fingering))
% guide slope
%   <c-\gsl #-15 -1>4  c4^\gsl #45 ^2  c4-\gsl #-15 -3  c4_\gsl# -14 _4
gsl = #(define-music-function (parser location slope fingering) (number? 
ly:music?)
           (gx slope #x2013 fingering))
% guide slope unicode
%   <c-\gsl #-15 ##x2011 -1>4  c4^\gsl #45 ##x2012 ^2  c4-\gsl #-15 ##x2013 -3  
c4_\gsl #-14 ##x2014 _4
gsn = #(define-music-function (parser location slope unicode fingering) 
(number? number? ly:music?)
                (gx slope unicode fingering))
% guide slope character
%   <c-\gsl #-15 ##\+ -1>4  c4^\gsl #45 ##\+ ^2  c4-\gsl #-15 ##\! -3  c4_\gsl 
#-14 ##\! _4
gsc = #(define-music-function (parser location slope character fingering) 
(number? char? ly:music?)
                (gx slope (char->integer character) fingering))

Guide = #(define-music-function (parser location padleft padright shift 
missacc) (number? number? pair? boolean?)
#{
    \once \override Glissando #'(bound-details left padding) = #padleft
    \once \override Glissando #'(bound-details right padding) = #padright
    \once \override Glissando #'extra-offset = #shift
    \once \override Glissando #'(bound-details right end-on-accidental) = 
#missacc
    \once \override Glissando #'breakable = ##t
    \once \override Glissando #'after-line-breaking = ##t
#})

fl = \set fingeringOrientations = #'(left)

\relative c'' {
  \Guide #1 #0.5 #'(0 . 1.4) ##f <fs^4 b, a ds,>2\glissando <g^4 b, g e> |
  <fs^4 b, a ds,>2 <g-\gd^4 b, g e> |
  <fs^4 b, a ds,>2 <g-\gsn #10 ##x2014 ^4 b, g e> |
  \fl <fs-4 b, a-2 ds,>2 <g-\gd^4 b, g-\gu^2 e> |
}


% Local Variables: %
% tab-width: 4 %
% compile-command: "lilypond --ps test6.ly" %
% End: %



reply via email to

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