lilypond-devel
[Top][All Lists]
Advanced

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

Issues when setting the staff size for a single staff


From: Paolo Prete
Subject: Issues when setting the staff size for a single staff
Date: Thu, 28 Jan 2021 20:11:53 +0100

(cross-posting this, because I don't know if it's more appropriate for the
user or for the devel ml)
Hi everyone,

I'm experiencing issues with the magnification of single staves.
In the following snippet, if I modify the line with:

# (set-global-staff-size 10)

with

\new Staff \with { \magnifyStaff #1/2 }

AFAIK, the output should be the same, and instead I find the tweaked
objects misplaced.

Is there any error in my snippet or are they bugs? In case of bugs, is
there any trace of them?

In this post I also attach a LibreOffice table with the test results, for
various versions of Lilypond (2.19.84, 2.20.0, 2.22.0, 2.23.0)

Thanks for your feedback!

--------------------------------------------------
https://github.com/paolo-prete/Spontini
--------------------------------------------------

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\version "2.19.84"

\paper {
  indent = 0\cm
  top-margin = 16
  print-page-number = ##f
}

\layout {
  \context {
    \Score
    \omit BarNumber
    \remove "Bar_number_engraver"
  }
}

fakeRuler = {
  \once \hide Stem
  \once \hide NoteHead
}

%#(set-global-staff-size 10)
\new Staff \with { \magnifyStaff #1/2 }
{

  \override Score.TimeSignature.stencil = ##f
  \time 11/4

  % Dynamics
  c' \tweak extra-offset #'(-0.194 . -11.858) \mf
  \fakeRuler c,,,
  c' \tweak X-offset -10.6 \mf
  \fakeRuler c,,,
  c'  \tweak DynamicLineSpanner.Y-offset -17  \mf
  \fakeRuler c,,,
  c' \tweak DynamicLineSpanner.padding 12.809 \mf
  \fakeRuler c,,,
  c' \tweak DynamicLineSpanner.outside-staff-padding 12.588 \mf
  \fakeRuler c,,,
  c' \tweak DynamicLineSpanner.staff-padding 14.988 \mf
  \break

  % Scripts
  c' \tweak extra-offset #'(-0.194 . -11.858) _>
  \fakeRuler c,,,
  c' \tweak X-offset -10.6 _>
  \fakeRuler c,,,
  c'  \tweak Y-offset -17  _>
  \fakeRuler c,,,
  c' \tweak padding 12.809 _>
  \fakeRuler c,,,
  \once \override Script.outside-staff-priority = 100
  c' \tweak outside-staff-padding 12.588 _>
  \fakeRuler c,,,
  c' \tweak staff-padding 14.988 _>
  \break

  % TextScript
  c' \tweak extra-offset #'(-0.194 . -11.858) _"XXX"
  \fakeRuler c,,,
  c' \tweak X-offset -10.6 _"XXX"
  \fakeRuler c,,,
  c'  \tweak Y-offset -17  _"XXX"
  \fakeRuler c,,,
  c' \tweak padding 12.809 _"XXX"
  \fakeRuler c,,,
  \once \override Script.outside-staff-priority = 100
  c' \tweak outside-staff-padding 12.588 _"XXX"
  \fakeRuler c,,,
  c' \tweak staff-padding 14.988 _"XXX"
  \break

  % Beams (angles are ~ at the same level of ruler)
  c'8\once \offset positions #'(0 . 7.128)[ c' c' c']
  \fakeRuler c''''4
  c'8\once \offset positions #'(7.128 . 0)[ c' c' c']
  s1.
  \break

  % Curves (control points intentionally placed so to be near the ruler)
  c'8\shape #'((0 . 0) (0.015 . -4.815) (-9.225 . -14.324) (7.605 .
-16.544)) ( c' c' c')
  \fakeRuler c,,,,4
  \fakeRuler c'''''4
  c''8\shape #'((-17.02 . 9.386) (10.245 . 7.166) (0 . 0) (0 . 0)) ( c''
c'' c'')
  s1 s4
  \break

  % NoteColumn (the second note is placed at the middle of the segment
between ref point and the first note)
  c'
  \once \override Staff.NoteColumn.X-offset = -8.8 << c' \\ s >>
  c'
  s1 s1
  \pageBreak

  s1
}

Attachment: test-staff-magnification.ods
Description: application/vnd.oasis.opendocument.spreadsheet

Attachment: test-staff-magnification.ly
Description: Text Data


reply via email to

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