]> git.donarmstrong.com Git - lilypond.git/blob - input/test/move-accidentals.ly
Added texinfo index.
[lilypond.git] / input / test / move-accidentals.ly
1 \version "1.7.18"
2 % possible rename to scheme- or something like that.  -gp
3 \header { texidoc= "@cindex Scheme Manual Accidentals
4 Positions of accidentals may be manually set. This
5 involves some scheme code. " }
6
7 #(define (make-acc-position-checker pos)
8   (lambda (elt)
9    (and
10       (not (eq? #f (memq 'accidental-interface
11                     (ly:get-grob-property elt 'interfaces))))
12       (eq? (ly:get-grob-property
13             (ly:get-parent elt 1) 'staff-position) pos))))
14
15 \score {
16   \context Voice \notes \relative c'' {
17     c2.
18     <
19 \property Staff.AccidentalPlacement = \turnOff
20 \context Staff \outputproperty #(make-acc-position-checker 9)
21                                #'extra-offset = #'(-1 . 0)
22 \context Staff \outputproperty #(make-acc-position-checker 5)
23                                #'extra-offset = #'(-2 . 0)
24 \context Staff \outputproperty #(make-acc-position-checker 3)
25                                #'extra-offset = #'(-3 . 0)
26 \context Staff \outputproperty #(make-acc-position-checker 2)
27                                #'extra-offset = #'(-4 . 0)
28       d!4
29       eis
30       gis
31       d'!
32     >
33   }
34   \paper {
35     raggedright = ##t
36   }
37 }
38 %% new-chords-done %%