]> git.donarmstrong.com Git - lilypond.git/blob - Documentation/snippets/new/guitar-slides.ly
Run scripts/auxiliar/update-with-convert-ly.sh
[lilypond.git] / Documentation / snippets / new / guitar-slides.ly
1 \version "2.16.0"
2
3 \header {
4   lsrtags = "fretted-strings"
5
6   texidoc = "
7 Unlike glissandos, slides may go from an imprecise point of the
8 fretboard to a specific fret. A good way to do that is to add a grace
9 hidden note before the note which is actually played, as demonstrated
10 in the following example.
11 "
12   doctitle = "Guitar slides"
13 }
14
15 %% Hide fret number: useful to draw slide into/from a casual point of
16 %% the fretboard.
17 hideFretNumber = {
18   \once \override TabNoteHead #'transparent = ##t
19   \once \override NoteHead #'transparent = ##t
20   \once \override Stem #'transparent = ##t
21   \once \override Flag #'transparent = ##t
22   \once \override NoteHead #'no-ledgers = ##t
23   \once \override Glissando #'(bound-details left padding) = #0.3
24 }
25
26 music= \relative c' {
27   \grace { \hideFretNumber d8\2 \glissando s2 } g2\2
28   \grace { \hideFretNumber g8\2 \glissando s2 } d2 |
29
30   \grace { \hideFretNumber c,8 \glissando s } f4\5^\markup \tiny { Slide into }
31   \grace { \hideFretNumber f8 \glissando s } a4\4
32   \grace { \hideFretNumber e'8\3 \glissando s } b4\3^\markup \tiny { Slide from }
33   \grace { \hideFretNumber b'8 \glissando s2 } g4 |
34 }
35
36 \score {
37   <<
38     \new Staff {
39       \clef "G_8"
40       \music
41     }
42     \new TabStaff {
43       \music
44     }
45   >>
46 }