diff options
author | EuAndreh <eu@euandre.org> | 2022-06-01 21:41:57 -0300 |
---|---|---|
committer | EuAndreh <eu@euandre.org> | 2022-06-01 21:41:57 -0300 |
commit | 3b88471ab8ed28ff66657957c2a3f3882cc6aeac (patch) | |
tree | ce82f6c0d2eeb434991b7ca98481fee12d460d7e /music/guitar.ly.include | |
parent | Move files.mk and deps.mk into generated.mk (diff) | |
download | euandre.org-3b88471ab8ed28ff66657957c2a3f3882cc6aeac.tar.gz euandre.org-3b88471ab8ed28ff66657957c2a3f3882cc6aeac.tar.xz |
Generate LilyPond files in dynamic.mk
Diffstat (limited to 'music/guitar.ly.include')
-rw-r--r-- | music/guitar.ly.include | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/music/guitar.ly.include b/music/guitar.ly.include new file mode 100644 index 0000000..592ad5c --- /dev/null +++ b/music/guitar.ly.include @@ -0,0 +1,33 @@ + +pestanaPrivate = \markup { + \fontsize #-2 + \combine + \roman C + \translate #'(0.6 . -0.4) \draw-line #'(0 . 2.0) +} + +pestanaSingle = + #(define-music-function (fret-number music) (string? ly:music?) + #{ + $music ^\markup { \pestanaPrivate \fontsize #-2 $fret-number } + #}) + +pestanaSpan = + #(define-music-function (fret-number) (string?) + #{ + \once \override TextSpanner.font-shape = #'upright + \once \override TextSpanner.style = #'solid + \once \override TextSpanner.bound-details.left.stencil-align-dir-y = #CENTER + \once \override TextSpanner.bound-details.right.text = \markup { \draw-line #'(0 . -.5) } + \once \override TextSpanner.bound-details.left.text = \markup { \pestanaPrivate \fontsize #-2 $fret-number } + #}) + +corda = + #(define-music-function (string-number) (string?) + #{ + \once \override TextSpanner.style = #'solid + \once \override TextSpanner.font-size = #-5 + \once \override TextSpanner.bound-details.left.stencil-align-dir-y = #CENTER + \once \override TextSpanner.bound-details.right.text = \markup { \draw-line #'( 0 . -.5) } + \once \override TextSpanner.bound-details.left.text = \markup { \circle \number $string-number } + #}) |