]> git.donarmstrong.com Git - lilypond.git/commitdiff
LSR import
authorPhil Holmes <mail@philholmes.net>
Wed, 16 Mar 2016 12:46:31 +0000 (12:46 +0000)
committerPhil Holmes <mail@philholmes.net>
Wed, 16 Mar 2016 13:35:31 +0000 (13:35 +0000)
Documentation/snippets/center-text-below-hairpin-dynamics.ly
Documentation/snippets/centering-markup-on-note-heads-automatically.ly [deleted file]
Documentation/snippets/contexts-and-engravers.snippet-list
Documentation/snippets/displaying-complex-chords.ly
Documentation/snippets/displaying-grob-ancestry.ly
Documentation/snippets/pitches-headword.ly
Documentation/snippets/score-for-diatonic-accordion.ly
Documentation/snippets/text.snippet-list
Documentation/snippets/tweaks-and-overrides.snippet-list
Documentation/snippets/using-tags-to-produce-mensural-and-modern-music-from-the-same-source.ly

index 1791b38b79810ac388069c2ce251590ae9ce2865..40810e6a19be23526a16ef04096f9dc4177a076a 100644 (file)
@@ -41,10 +41,8 @@ hairpinWithCenteredText =
                  (ly:grob-layout grob) 'staff-space))
                (staff-line-thickness
                  (ly:output-def-lookup (ly:grob-layout grob) 'line-thickness))
-               (grob-name (lambda (x) (assq-ref
-                 (ly:grob-property x 'meta) 'name)))
                (par-x (ly:grob-parent grob X))
-               (dyn-text (eq? (grob-name par-x) 'DynamicText ))
+               (dyn-text (grob::has-interface par-x 'dynamic-text-interface))
                (dyn-text-stencil-x-length
                  (if dyn-text
                    (interval-length
diff --git a/Documentation/snippets/centering-markup-on-note-heads-automatically.ly b/Documentation/snippets/centering-markup-on-note-heads-automatically.ly
deleted file mode 100644 (file)
index 6b48240..0000000
+++ /dev/null
@@ -1,67 +0,0 @@
-%% DO NOT EDIT this file manually; it is automatically
-%% generated from LSR http://lsr.di.unimi.it
-%% Make any changes in LSR itself, or in Documentation/snippets/new/ ,
-%% and then run scripts/auxiliar/makelsr.py
-%%
-%% This file is in the public domain.
-\version "2.18.0"
-
-\header {
-  lsrtags = "contexts-and-engravers, text, tweaks-and-overrides"
-
-  texidoc = "
-For technical reasons, text scripts attached to note heads cannot
-easily be centered on a note head's width, unlike articulations.
-
-Instead of using trial-and-error offset tweaks, this snippet uses a
-Scheme engraver to reset the horizontal parent of each markup to a
-@code{NoteColumn}.  This also allows text to follow note heads which
-have been shifted via @code{force-hshift}.
-
-
-
-"
-  doctitle = "Centering markup on note heads automatically"
-} % begin verbatim
-
-#(define (Text_align_engraver ctx)
-  (let ((scripts '())
-        (note-column #f))
-    (make-engraver
-     (acknowledgers
-      ((note-column-interface trans grob source)
-       ;; cache NoteColumn in this Voice context
-       (set! note-column grob))
-      ((text-script-interface trans grob source)
-       ;; whenever a TextScript is acknowledged,
-       ;; add it to `scripts' list
-       (set! scripts (cons grob scripts))))
-     ((stop-translation-timestep trans)
-      ;; if any TextScript grobs exist,
-      ;; set NoteColumn as X-parent
-      (for-each (lambda (script)
-                 (set! (ly:grob-parent script X) note-column))
-               scripts)
-      ;; clear scripts ready for next timestep
-      (set! scripts '())))))
-
-\layout {
-  \context {
-    \Voice
-    \consists #Text_align_engraver
-    \override TextScript.X-offset =
-      #ly:self-alignment-interface::aligned-on-x-parent
-    \override TextScript.self-alignment-X = #CENTER
-  }
-}
-
-\new Staff <<
-  \relative c'' {
-    \override NoteColumn.force-hshift = #3
-    c1-\markup { \arrow-head #Y #DOWN ##t }
-  }
-  \\
-  \relative c' {
-    a4 a-\markup { \huge ^ } a a
-  }
->>
index 66b3139c7ad3d84be2171b875ddb83b6756d1573..3b3c016eb3f53d85bbb179dfbdf7bfeb3d2a5aa2 100644 (file)
@@ -3,7 +3,6 @@ adding-an-extra-staff-at-a-line-break.ly
 adding-an-extra-staff.ly
 automatically-changing-the-stem-direction-of-the-middle-note-based-on-the-melody.ly
 centered-measure-numbers.ly
-centering-markup-on-note-heads-automatically.ly
 changing-midi-output-to-one-channel-per-voice.ly
 changing-time-signatures-inside-a-polymetric-section-using--scaledurations.ly
 chant-or-psalms-notation.ly
index a433eb96d0a6cd764b2cb22f559a3058ba82664f..b90be170835f5163faa0c615ebe0bc6c8c89801b 100644 (file)
@@ -30,6 +30,7 @@ fixB = {
   \once \override Accidental.extra-offset = #'(4 . -.1)
 }
 
+
 \relative c' {
   << { \fixA <b d!>8 } \\ { \voiceThree \fixB dis } >> s
 }
index 7a75bb1a33fa98170414298349e200e51c5c806d..47077461d92dba90a5675951c794df5ec48cee9b 100644 (file)
 
   texidoc = "
 When working with grob callbacks, it can be helpful to understand a
-grob's @qq{ancestry}. Most grobs have @qq{parents} which influence the
+grob’s ancestry. Most grobs have parents which influence the
 positioning of the grob. X- and Y-parents influence the horizontal and
 vertical positions for the grob, respectively. Additionally, each
 parent may have parents of its own.
 
 
-Unfortunately, there are several aspects of a grob's ancestry that can
+Unfortunately, there are several aspects of a grobs ancestry that can
 lead to confusion:
 
-* The types of parents a grob has may depend on context. * For some
-grobs, the X- and Y-parents are the same. * A particular @qq{ancestor}
-may be related to a grob in multiple ways. * The concept of
-@qq{generations} is misleading.
+
+* The types of parents a grob has may depend on context.
+
+* For some grobs, the X- and Y-parents are the same.
+
+* A particular “ancestor” may be related to a grob in multiple ways.
+
+* The concept of “generations” is misleading.
 
 
 For example, the @code{System} grob can be both parent (on the Y-side)
@@ -31,35 +35,27 @@ and grandparent (twice on the X-side) to a @code{VerticalAlignment}
 grob.
 
 
-This macro prints (to the console) a textual representation of a grob's
+This macro prints (to the console) a textual representation of a grobs
 ancestry.
 
+When called this way:
 
-When called this way
-
-
-@{
- \\once \\override NoteHead #'before-line-breaking = #display-ancestry
- c @}
-
+@code{@{ \\once \\override NoteHead.before-line-breaking =
+#display-ancestry c @}}
 
 The following output is generated:
 
 
-------------------------------------
-
-NoteHead X,Y: NoteColumn
-    X: PaperColumn
-       X,Y: System
-    Y: VerticalAxisGroup
-       X: NonMusicalPaperColumn
-          X,Y: System
-       Y: VerticalAlignment
-          X: NonMusicalPaperColumn
-             X,Y: System
-          Y: System
-
-
+@code{NoteHead X,Y: NoteColumn
+     X: PaperColumn
+        X,Y: System
+     Y: VerticalAxisGroup
+        X: NonMusicalPaperColumn
+           X,Y: System
+        Y: VerticalAlignment
+           X: NonMusicalPaperColumn
+              X,Y: System
+           Y: System}
 
 "
   doctitle = "Displaying grob ancestry"
index b2f27eddc97db7b66cc475d1512d3805da605e78..16859e943172a1ccaef9e3c473cdfaec353c0027 100644 (file)
@@ -75,7 +75,7 @@ Piches headword
       <bs' fs'>2
       e'2
       |
-      <b'! a'>2 -\tweak #'style #'none \cresc
+      <b'! a'>2 -\tweak style #'none \cresc
       b'4
       <e'' cs''>4
       |
index 9419a6893e7261d72cdc0b75a6b5a08a5e6663a6..fddf7c230b014720c8a6fbc924b7ae8630775274 100644 (file)
@@ -81,7 +81,7 @@ staffTabLine = \new Staff \with {
   \key c \major
   \relative c''
   {
-    % disable the following line to see the noteheads while writing the song
+    % disable the following line to see the the noteheads while writing the song
     \NoNoteHead
     \override NoteHead.no-ledgers = ##t
 
index 380f0926740f78265b73541c52b68014501205df..e87e87ed259db23ac0106359e6cc5e44c883a791 100644 (file)
@@ -6,7 +6,6 @@ aligning-objects-created-with-the--mark-command.ly
 aligning-syllables-with-melisma.ly
 blanking-staff-lines-using-the--whiteout-command.ly
 center-text-below-hairpin-dynamics.ly
-centering-markup-on-note-heads-automatically.ly
 changing-ottava-text.ly
 changing-the-default-text-font-family.ly
 combining-dynamics-with-markup-texts.ly
index 71a02386c76ee5b228ab7e03e7509a9732073d42..ed848f2c0a4941d07a3cefb7e3ec2ea32cad677d 100644 (file)
@@ -10,7 +10,6 @@ analysis-brackets-above-the-staff.ly
 asymmetric-slurs.ly
 avoiding-collisions-with-chord-fingerings.ly
 caesura-railtracks-with-fermata.ly
-centering-markup-on-note-heads-automatically.ly
 changing-a-single-notes-size-in-a-chord.ly
 changing-beam-thickness-and-spacing.ly
 changing-form-of-multi-measure-rests.ly
index 199db158e1c24a40afc96c74401cd44c83e03960..086b1b6d98b4b25491260586070a9c562cf4e915 100644 (file)
@@ -34,8 +34,8 @@ menrest = #(define-music-function (note)
 
 MensStyle = {
   \autoBeamOff
-  \override NoteHead #'style = #'petrucci
-  \override Score.BarNumber #'transparent = ##t
+  \override NoteHead.style = #'petrucci
+  \override Score.BarNumber.transparent = ##t
   \override Stem.neutral-direction = #up
 }