lydown 0.9.0 → 0.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (40) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +159 -2
  3. data/lib/lydown.rb +8 -2
  4. data/lib/lydown/cache.rb +54 -0
  5. data/lib/lydown/cli.rb +1 -0
  6. data/lib/lydown/cli/commands.rb +27 -9
  7. data/lib/lydown/cli/compiler.rb +218 -54
  8. data/lib/lydown/cli/diff.rb +1 -1
  9. data/lib/lydown/cli/proofing.rb +3 -3
  10. data/lib/lydown/cli/signals.rb +23 -0
  11. data/lib/lydown/cli/support.rb +23 -1
  12. data/lib/lydown/core_ext.rb +41 -5
  13. data/lib/lydown/{rendering/defaults.yml → defaults.yml} +3 -3
  14. data/lib/lydown/errors.rb +3 -0
  15. data/lib/lydown/lilypond.rb +73 -31
  16. data/lib/lydown/ly_lib/lib.ly +297 -0
  17. data/lib/lydown/parsing.rb +1 -2
  18. data/lib/lydown/parsing/lydown.treetop +16 -10
  19. data/lib/lydown/parsing/nodes.rb +29 -5
  20. data/lib/lydown/rendering.rb +32 -6
  21. data/lib/lydown/rendering/command.rb +79 -2
  22. data/lib/lydown/rendering/figures.rb +29 -8
  23. data/lib/lydown/rendering/literal.rb +7 -0
  24. data/lib/lydown/rendering/movement.rb +61 -0
  25. data/lib/lydown/rendering/music.rb +37 -5
  26. data/lib/lydown/rendering/notes.rb +26 -8
  27. data/lib/lydown/rendering/settings.rb +41 -13
  28. data/lib/lydown/rendering/skipping.rb +43 -10
  29. data/lib/lydown/rendering/staff.rb +72 -16
  30. data/lib/lydown/templates.rb +8 -2
  31. data/lib/lydown/templates/lilypond_doc.erb +10 -1
  32. data/lib/lydown/templates/movement.erb +87 -34
  33. data/lib/lydown/templates/multi_voice.erb +1 -1
  34. data/lib/lydown/templates/part.erb +83 -55
  35. data/lib/lydown/templates/variables.erb +38 -0
  36. data/lib/lydown/version.rb +1 -1
  37. data/lib/lydown/work.rb +39 -26
  38. data/lib/lydown/work_context.rb +252 -14
  39. metadata +138 -8
  40. data/lib/lydown/rendering/lib.ly +0 -88
@@ -1,88 +0,0 @@
1
- \header {
2
- tagline = \markup {
3
- Engraved using \bold {
4
- \with-url #"http://github.com/ciconia/lydown" {
5
- Lydown
6
- }
7
- }
8
- and \bold {
9
- \with-url #"http://lilypond.org/" {
10
- Lilypond
11
- }
12
- }
13
- }
14
- }
15
-
16
- segno = {
17
- \once \override Score.RehearsalMark #'font-size = #-2
18
- \mark \markup { \musicglyph #"scripts.segno" }
19
- }
20
-
21
- segnobottom = {
22
- \once \override Score.RehearsalMark #'direction = #DOWN
23
- \once \override Score.RehearsalMark #'font-size = #-2
24
- \mark \markup { \musicglyph #"scripts.segno" }
25
- }
26
-
27
- dalsegno = {
28
- \once \override Score.RehearsalMark #'break-visibility = #begin-of-line-invisible
29
- \once \override Score.RehearsalMark #'direction = #DOWN
30
- \once \override Score.RehearsalMark #'self-alignment-X = #RIGHT
31
- \once \override Score.RehearsalMark #'font-size = #-2
32
- \mark \markup { \fontsize #2 {"dal segno "} \musicglyph #"scripts.segno" }
33
- }
34
-
35
- dacapo = {
36
- \once \override Score.RehearsalMark #'break-visibility = #begin-of-line-invisible
37
- \once \override Score.RehearsalMark #'direction = #DOWN
38
- \once \override Score.RehearsalMark #'self-alignment-X = #RIGHT
39
- \mark \markup {\bold {\italic {"Da capo"}}}
40
- }
41
-
42
- dalsegnoadlib = {
43
- \once \override Score.RehearsalMark #'direction = #DOWN
44
- \once \override Score.RehearsalMark #'self-alignment-X = #LEFT
45
- \once \override Score.RehearsalMark #'font-size = #-2
46
- \mark \markup { \musicglyph #"scripts.segno" ad lib }
47
- }
48
-
49
- editF = \markup { \center-align \concat { \bold { \italic ( }
50
- \dynamic f \bold { \italic ) } } }
51
- editP = \markup { \center-align \concat { \bold { \italic ( }
52
- \dynamic p \bold { \italic ) } } }
53
- editPP = \markup { \center-align \concat { \bold { \italic ( }
54
- \dynamic pp \bold { \italic ) } } }
55
-
56
- doux = \markup { \center-align \bold { \italic doux }}
57
- fort = \markup { \center-align \bold { \italic fort }}
58
-
59
- ten = \markup { \italic ten. }
60
-
61
- ficta = {
62
- \once \override AccidentalSuggestion #'avoid-slur = #'outside
63
- \once \set suggestAccidentals = ##t
64
- }
65
-
66
- prallupbefore = {
67
- \mark\markup {
68
- \musicglyph #"scripts.prallup"
69
- \hspace #1
70
- }
71
- }
72
-
73
- %{
74
- http://www.lilypond.org/doc/v2.18/Documentation/snippets/editorial-annotations#editorial-annotations-adding-links-to-objects
75
- %}
76
- #(define (add-link url-strg)
77
- (lambda (grob)
78
- (let* ((stil (ly:grob-property grob 'stencil)))
79
- (if (ly:stencil? stil)
80
- (begin
81
- (let* (
82
- (x-ext (ly:stencil-extent stil X))
83
- (y-ext (ly:stencil-extent stil Y))
84
- (url-expr (list 'url-link url-strg `(quote ,x-ext) `(quote ,y-ext)))
85
- (new-stil (ly:stencil-add (ly:make-stencil url-expr x-ext y-ext) stil)))
86
- (ly:grob-set-property! grob 'stencil new-stil)))
87
- #f))))
88
-