[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Slur with left and/or right arrow head
From: |
Thomas Morley |
Subject: |
Re: Slur with left and/or right arrow head |
Date: |
Fri, 19 Apr 2019 18:24:33 +0200 |
Am Fr., 19. Apr. 2019 um 18:01 Uhr schrieb Aaron Hill
<address@hidden>:
>
> On 2019-04-19 3:29 am, Thomas Morley wrote:
> > Am Mi., 17. Apr. 2019 um 21:16 Uhr schrieb Thomas Morley
> > <address@hidden>:
> >>
> >> Am Di., 16. Apr. 2019 um 23:45 Uhr schrieb Aaron Hill
> >
> >> > Also, I "fixed" the font-size issue by bypassing the font settings
> >> > within the grob itself, because simply scaling the glyph results in
> >> > thicker lines. So while font-size is now consistent between the
> >> > different grobs, it is unfortunately now a hard-coded value. I am
> >> > uncertain whether this tradeoff would be acceptable.
> >>
> >> Not sure either, why does Tie has a font-size property at all?
> >
> > Hi Aaron,
> >
> > still on the journey to understand all subtleties of your code...
> >
> > One detail: meanwhile I don't think it's nice hardcoding the
> > font-size, looks bad for high or low staff-spaces.
> >
> > How about looking at staff-space and derive a suitable value from it?
> > I.e. in `curve-adjusted-arrow-head´:
> >
> > [...]
> > (let* ((staff-space (ly:staff-symbol-staff-space curve))
> > ;; reducing fs-from-staff-space a bit looks nicer
> > (fs-from-staff-space (1- (magnification->font-size
> > staff-space)))
> > (grob-font
> > (ly:paper-get-font
> > (ly:grob-layout curve)
> > `(((font-encoding . fetaMusic)
> > (font-size . ,fs-from-staff-space)))))
> > [...]
>
> Seems a reasonable approach, but isn't font-size already relative to
> staff-space?
>
> My understanding is that a 20pt staff results in a 5pt staff-space and a
> font of 11pt at font-size 0. If you change the staff size, fonts will
> scale accordingly (unless you are using something like \abs-fontsize).
> That means that a font-size of 0 will always be 11/5 of the staff-space.
>
> So if the issue is the arrow head being too big, then we should only
> need to set the font-size to a smaller, though still constant, value.
Look at the attached images, the one with fixed font-sizes does not
respond to changed staff-space
staffSize = #(define-music-function (new-size) (number?)
#{
\set fontSize = #new-size
\override StaffSymbol.staff-space = #(magstep new-size)
\override StaffSymbol.thickness = #(magstep new-size)
#})
mus =
{
\pointing-curve Slur
\pointing-curve Tie
b4( b b b)
b1~ b
}
<<
\new Staff \with { \staffSize #5 } \mus
\new Staff \mus
\new Staff \with { \staffSize #-5 } \mus
>>
I think it's because you used ly:paper-get-font.
Probably it's also possible to apply current 'output-scale to get
things correct (not tested)
Cheers,
Harm
arrow-slur-font-size-from-staff-space.png
Description: PNG image
arrow-slur-font-size-hardcoded.png
Description: PNG image
- Re: Slur with left and/or right arrow head, (continued)
- Re: Slur with left and/or right arrow head, Thomas Morley, 2019/04/17
- Re: Slur with left and/or right arrow head, David Kastrup, 2019/04/17
- Re: Slur with left and/or right arrow head, Thomas Morley, 2019/04/17
- Re: Slur with left and/or right arrow head, David Kastrup, 2019/04/17
- Re: Slur with left and/or right arrow head, Thomas Morley, 2019/04/17
- Re: Slur with left and/or right arrow head, Aaron Hill, 2019/04/17
- Re: Slur with left and/or right arrow head, Carl Sorensen, 2019/04/18
- Re: Slur with left and/or right arrow head, Aaron Hill, 2019/04/17
- Re: Slur with left and/or right arrow head, Thomas Morley, 2019/04/19
- Re: Slur with left and/or right arrow head, Aaron Hill, 2019/04/19
- Re: Slur with left and/or right arrow head,
Thomas Morley <=
- Re: Slur with left and/or right arrow head, Thomas Morley, 2019/04/19
- Re[2]: Slur with left and/or right arrow head, Trevor, 2019/04/19
- Re: Re[2]: Slur with left and/or right arrow head, Thomas Morley, 2019/04/20
Re: Slur with left and/or right arrow head, Carl Sorensen, 2019/04/18