Use make-fontsize-markup
http://codereview.appspot.com/330500043
Unlike normal note heads, the note heads used after easyHeadsOn don’t correctly heed the fontSize context property, as altered by \huge and similar. The size of the letters in the note heads is changed indeed, but not the note heads themselves.
:::TeX
\version "2.19.49"
mus = {
c' d' e' f'
\easyHeadsOn
c' d' e' f'
\easyHeadsOff
c' d' e' f'
}
<<
\new Staff { \huge \mus }
\new Staff { \teeny \mus }
>>
Reported by Tanner Noguess, https://lists.gnu.org/archive/html/bug-lilypond/2016-11/msg00009.html.
The problem also occurs when overriding NoteHead.font-size directly, which also highlights the actual problem behind this. The actual NoteHead is not taken from a font with
easyHeadsOn, which is why it doesn’t respond to font size settings.Nevertheless I consider the feature request valid.
More precisely, the note-head for easyHeads is constructed with note-head::brew-ez-stencil from scm/output-lib.scm. The used markup-commands are ensuring the final circle fits exactly between staff-lines by looking at staff-space (and line-thickness). So any size of the font will take no effect on the note-head-circle, unless staff-space changes.
In other words, the current coding disregards font changes by purpose.
So I'd say a design-decision is needed.
Obviously Simon votes for making it more flexible.
Others?
Well, so my vote would be, but I’d say it counts very little, since I have no experience at all using these easyHeads, nor do I know the reasoning behind wanting their size altered.
Still, the analogy to normal note heads suggests that it would be more consistent and intuitive to have their size follow along, in spite of not fitting the staff lines.
Last edit: Simon Albrecht 2016-11-12
Because grace notes don’t work well with current easyHeads (
\graceand friends seem to override thefont-sizefrom -8 to -3 instead of -11) I second that.easyHeads respect font-size/fontSize
Easy note heads are now scaled correctly when the NoteHead size is
changed by \override NoteHead.font-size = -3, \set fontSize = -3,
\teeny, \grace etc.
This is achieved by moving the responsibility of scaling the letters
from the definition of \easyHeadsOn to the stencil and scaling the note
heads/circles too.
Also contains addition to regtest.
http://codereview.appspot.com/329410043
This patch passes make, make check and a full make doc.
Reg test diff attached.
Issue 4996/2: Make easyHeads correctly heed the fontSize context property
This retains the previous default behavior by hard-coding the font-size offset
of -8 into the stencil routine for easy noteheads.
Issue 4996/1: Add regtest for scalable easy noteheads
http://codereview.appspot.com/330500043
Passes make, make check and a full make doc.
No reg test diff was generated - apart frm the 'normal' stuff.
Well, yes: new regtests are not included in the diff. If you want to check the difference, you need to check the first commit (which contains only the regtest) against the second (which has all other changes). Unfortunately, on Rietveld you don't get to see the two commits: you'd have to do that split manually.
The regtest, as indicated by its version number, compiles with older versions, looking ugly.
Should I’ve added that I was working on a patch which I uploaded a few minutes later?
Last edit: Malte Meyn 2017-10-07
"Malte Meyn" maltem@users.sf.net writes:
Aw shucks. Maybe mark yourself as owner and the issue as "Started"?
I like my regtest better. Did not remember about make-fontsize-markup
which also changes baseline-skip and word-space but I consider it
unlikely we'd ever need them.
Your version applies the fontsize change twice in different locations:
not an efficiency problem since only one version will get called, but
not as nice for code maintenance.
So what are we going to do? Want to fix up your version with my regtest
and possibly factor
make-fontsize-markupintoletter?--
David Kastrup
Good to know, I’ll do that next time.
If I understand correctly it’s no problem for Phil (?) to use either of our patches. So I’d suggest to use yours, but maybe use make-fontsize-markup instead of an override.
James does the patches. I do GUB builds.
--
Phil Holmes
----- Original Message -----
From: Malte Meyn
To: [testlilyissues:issues]
Sent: Saturday, October 07, 2017 3:35 PM
Subject: [testlilyissues:issues] Re: #4996 Make easyHeads correctly heed the fontSize context property
Good to know, I’ll do that next time.
If I understand correctly it’s no problem for Phil (?) to use either of our patches. So I’d suggest to use yours, but maybe use make-fontsize-markup instead of an override.
[issues:#4996] Make easyHeads correctly heed the fontSize context property
Status: Started
Created: Fri Nov 11, 2016 11:51 PM UTC by Simon Albrecht
Last Updated: Sat Oct 07, 2017 02:30 PM UTC
Owner: David Kastrup
Attachments:
Unlike normal note heads, the note heads used after easyHeadsOn don’t correctly heed the fontSize context property, as altered by \huge and similar. The size of the letters in the note heads is changed indeed, but not the note heads themselves.
\version "2.19.49"
mus = {
c' d' e' f'
\easyHeadsOn
c' d' e' f'
\easyHeadsOff
c' d' e' f'
}
<<
\new Staff { \huge \mus }
\new Staff { \teeny \mus }
Sent from sourceforge.net because you indicated interest in https://sourceforge.net/p/testlilyissues/issues/4996/
To unsubscribe from further messages, please visit https://sourceforge.net/auth/subscriptions/
I'll test both anyway - no skin of my nose
Use make-fontsize-markup
http://codereview.appspot.com/330500043
Diff:
Passes make, make check and a full make doc.
Patch on countdown for Oct 14th
Patch counted down - please push
Patch counted down - please push