lilypond-user
[Top][All Lists]
Advanced

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

How to submit improved LSR entry?


From: Lukas-Fabian Moser
Subject: How to submit improved LSR entry?
Date: Fri, 19 Jun 2020 21:14:34 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.8.0

Folks,

some months ago I tried to improve an LSR snippet (http://lsr.di.unimi.it/LSR/Item?id=792 "Clef change at the beginning of a piece"); namely, I added support for the use of key signatures which the original LSR solution messes up (*).

Following the instructions in http://lsr.di.unimi.it/LSR/html/contributing.html, I posted a new snippet (http://lsr.di.unimi.it/LSR/Item?id=1109 "Clef change at the beginning of a piece [corrected, now prints key signatures correctly]"). But this seems not to have been taken up for the database, neither as an addition nor as a replacement for 792 (see http://lsr.di.unimi.it/LSR/Search?q=clef+change).

Did I do something wrong?

Lukas



(*) For those who want to see the problem in the original version:

%% http://lsr.di.unimi.it/LSR/Item?id=792
%% see also http://lilypond.org/doc/v2.18/Documentation/notation/displaying-pitches

% Append markup in the text property to the grob
#(define (append-markup grob old-stencil)
  (ly:stencil-combine-at-edge
    old-stencil X RIGHT (ly:text-interface::print grob)))

trebleToBass = {
  \clef bass
  % Fake staff clef appearance
  \once \override Staff.Clef.glyph-name = #"clefs.G"
  \once \override Staff.Clef.Y-offset = #-1
  % Append change clef to the time signature
  \once \override Staff.TimeSignature.text = \markup {
    \hspace #1.2
    \raise #1
    \musicglyph #"clefs.F_change"
  }
  \once \override Staff.TimeSignature.stencil = #(lambda (grob)
    (append-markup grob (ly:time-signature::print grob)))
}

bassToTreble = {
  \clef treble
  % Fake staff clef appearance
  \once \override Staff.Clef.glyph-name = #"clefs.F"
  \once \override Staff.Clef.Y-offset = #1
  % Append change clef to the time signature
  \once \override Staff.TimeSignature.text = \markup {
    \hspace #1.2
    \lower #1
    \musicglyph #"clefs.G_change"
  }
  \once \override Staff.TimeSignature.stencil = #(lambda (grob)
    (append-markup grob (ly:time-signature::print grob)))
}

\relative c {
  \key f \major  % Not in original LSR entry
  \trebleToBass
  c4 d e f
  % This should not be visible
  \clef bass
  g a b c
  % This should be visible
  \clef treble
  d e f g
}





reply via email to

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