lilypond-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Uses the pure-from-neighbor-interface for NonMusicalPaperColumn horizont


From: mtsolo
Subject: Uses the pure-from-neighbor-interface for NonMusicalPaperColumn horizontal spacing. (issue 5432070)
Date: Fri, 25 Nov 2011 05:27:53 +0000

Reviewers: ,

Message:
This is the second of the three-part pure-from-neighbor-interface code
rewrite.  It uses extra-spacing-height for certain important non-musical
grobs in order to prevent other grobs for passing over or under them via
the pure-from-neighbor-interface.

The last step, after this is pushed, will be changing the BarLine
extra-spacing-height function to block all accidentals from passing over
barlines.

Cheers,
MS

Description:
Uses the pure-from-neighbor-interface for NonMusicalPaperColumn
horizontal spacing.

Please review this at http://codereview.appspot.com/5432070/

Affected files:
  A input/regression/lyrics-pass-under-bar.ly
  M scm/define-grobs.scm


Index: input/regression/lyrics-pass-under-bar.ly
diff --git a/input/regression/lyrics-pass-under-bar.ly b/input/regression/lyrics-pass-under-bar.ly
new file mode 100644
index 0000000000000000000000000000000000000000..11a7fcc6d8391e12e9f6a6027e42b96941b2a91c
--- /dev/null
+++ b/input/regression/lyrics-pass-under-bar.ly
@@ -0,0 +1,10 @@
+\version "2.15.21"
+
+\header {
+  texidoc = "Long lyrics should be allowed to pass under
+the bar line.
+"
+}
+
+\relative c''' { c2 c c c }
+\addlyrics { foo bar foooooooo bar }
Index: scm/define-grobs.scm
diff --git a/scm/define-grobs.scm b/scm/define-grobs.scm
index 9cb0e6b5e1a6c9818f4c53c8006c858f1c6eef7c..99d2c240c886df9afa4133ac2a1f0bd1c1fe1001 100644
--- a/scm/define-grobs.scm
+++ b/scm/define-grobs.scm
@@ -520,7 +520,7 @@
(break-align-anchor . ,ly:break-aligned-interface::calc-extent-aligned-anchor)
        (break-align-symbol . clef)
        (break-visibility . ,begin-of-line-visible)
-       ;(extra-spacing-height . 
,pure-from-neighbor-interface::extra-spacing-height)
+ (extra-spacing-height . ,pure-from-neighbor-interface::extra-spacing-height)
        (glyph-name . ,ly:clef::calc-glyph-name)
        (non-musical . #t)
        (space-alist . ((cue-clef . (extra-space . 2.0))
@@ -534,12 +534,12 @@
        (stencil . ,ly:clef::print)
        (Y-offset . ,ly:staff-symbol-referencer::callback)
        (meta . ((class . Item)
- ;(object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common) - ; (pure-relevant-grobs . ,ly:pure-from-neighbor-interface::calc-pure-relevant-grobs))) + (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common) + (pure-relevant-grobs . ,ly:pure-from-neighbor-interface::calc-pure-relevant-grobs)))
                 (interfaces . (break-aligned-interface
                                clef-interface
                                font-interface
-                               ;pure-from-neighbor-interface
+                               pure-from-neighbor-interface
                                staff-symbol-referencer-interface))))))

     (ClusterSpanner
@@ -588,7 +588,7 @@
(break-align-anchor . ,ly:break-aligned-interface::calc-extent-aligned-anchor)
        (break-align-symbol . cue-clef)
        (break-visibility . ,begin-of-line-visible)
-       ;(extra-spacing-height . 
,pure-from-neighbor-interface::extra-spacing-height)
+ (extra-spacing-height . ,pure-from-neighbor-interface::extra-spacing-height)
        (font-size . -4)
        (glyph-name . ,ly:clef::calc-glyph-name)
        (non-musical . #t)
@@ -604,12 +604,12 @@
        (stencil . ,ly:clef::print)
        (Y-offset . ,ly:staff-symbol-referencer::callback)
        (meta . ((class . Item)
- ;(object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common) - ; (pure-relevant-grobs . ,ly:pure-from-neighbor-interface::calc-pure-relevant-grobs))) + (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common) + (pure-relevant-grobs . ,ly:pure-from-neighbor-interface::calc-pure-relevant-grobs)))
                 (interfaces . (break-aligned-interface
                                clef-interface
                                font-interface
-                               ;pure-from-neighbor-interface
+                               pure-from-neighbor-interface
                                staff-symbol-referencer-interface))))))

     (CueEndClef
@@ -618,7 +618,7 @@
(break-align-anchor . ,ly:break-aligned-interface::calc-extent-aligned-anchor)
        (break-align-symbol . cue-end-clef)
        (break-visibility . ,begin-of-line-invisible)
-       ;(extra-spacing-height . 
,pure-from-neighbor-interface::extra-spacing-height)
+ (extra-spacing-height . ,pure-from-neighbor-interface::extra-spacing-height)
        (font-size . -4)
        (glyph-name . ,ly:clef::calc-glyph-name)
        (non-musical . #t)
@@ -635,12 +635,12 @@
        (stencil . ,ly:clef::print)
        (Y-offset . ,ly:staff-symbol-referencer::callback)
        (meta . ((class . Item)
- ;(object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common) - ; (pure-relevant-grobs . ,ly:pure-from-neighbor-interface::calc-pure-relevant-grobs))) + (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common) + (pure-relevant-grobs . ,ly:pure-from-neighbor-interface::calc-pure-relevant-grobs)))
                 (interfaces . (break-aligned-interface
                                clef-interface
                                font-interface
-                               ;pure-from-neighbor-interface
+                               pure-from-neighbor-interface
                                staff-symbol-referencer-interface))))))

     (Custos
@@ -1127,15 +1127,15 @@
                        (first-note . (fixed-space . 2.5))))
        (stencil . ,ly:key-signature-interface::print)
        (extra-spacing-width . (0.0 . 1.0))
-       ;(extra-spacing-height . 
,pure-from-neighbor-interface::extra-spacing-height-including-staff)
+ (extra-spacing-height . ,pure-from-neighbor-interface::extra-spacing-height-including-staff)
        (Y-offset . ,ly:staff-symbol-referencer::callback)
        (meta . ((class . Item)
- ;(object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common) - ; (pure-relevant-grobs . ,ly:pure-from-neighbor-interface::calc-pure-relevant-grobs))) + (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common) + (pure-relevant-grobs . ,ly:pure-from-neighbor-interface::calc-pure-relevant-grobs)))
                 (interfaces . (break-aligned-interface
                                font-interface
                                key-signature-interface
-                               ;pure-from-neighbor-interface
+                               pure-from-neighbor-interface
                                staff-symbol-referencer-interface))))))


@@ -1409,8 +1409,6 @@
        (before-line-breaking . ,ly:paper-column::before-line-breaking)
        (full-measure-extra-space . 1.0)
        (horizontal-skylines . ,ly:separation-item::calc-skylines)
-       ;; sufficient padding to prevent ledger lines from moving over/under
-       (skyline-vertical-padding . 0.6)
        ;;                    (stencil . ,ly:paper-column::print)

        (keep-inside-line . #t)
@@ -2280,7 +2278,7 @@
        (break-align-symbol . time-signature)
        (break-align-anchor-alignment . ,LEFT)
        (break-visibility . ,all-visible)
-       ;(extra-spacing-height . 
,pure-from-neighbor-interface::extra-spacing-height-including-staff)
+ (extra-spacing-height . ,pure-from-neighbor-interface::extra-spacing-height-including-staff)
        (extra-spacing-height . (-1.0 . 1.0))
        (extra-spacing-width . (0.0 . 0.8))
        (non-musical . #t)
@@ -2292,11 +2290,11 @@
        (stencil . ,ly:time-signature::print)
        (style . C)
        (meta . ((class . Item)
- ;(object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common) - ; (pure-relevant-grobs . ,ly:pure-from-neighbor-interface::calc-pure-relevant-grobs))) + (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common) + (pure-relevant-grobs . ,ly:pure-from-neighbor-interface::calc-pure-relevant-grobs)))
                 (interfaces . (break-aligned-interface
                                font-interface
-                               ;pure-from-neighbor-interface
+                               pure-from-neighbor-interface
                                time-signature-interface))))))

     (TrillPitchAccidental





reply via email to

[Prev in Thread] Current Thread [Next in Thread]