[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: font size override and grace notes
From: |
David Kastrup |
Subject: |
Re: font size override and grace notes |
Date: |
Fri, 19 Oct 2012 07:07:31 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.2.50 (gnu/linux) |
Matt Cary <address@hidden> writes:
>> > better use \once to override the size of the g, or revert the note heads
>> > size after the slashed grace is done:
>> >
>> > \override NoteHead #'font-size = #4 g
>> > \slashedGrace a16(
>> > \revert NoteHead #'font-size b8)
>>
>> In this particular case, it would likely be safer to use a \tweak.
>> tweaks are not timing-related and thus are impervious to the quirks of
>> grace note timing.
>>
>
> Thanks for the advice. I guess I'm surprised the revert doesn't happen
> immediately. This arose in a more complicated context where I don't think
> doing tweaks is relevant; the initial override is from a function where I'm
> notating a strum.
>
> strumFn =
> #(define-music-function
> (parser location strums)
> (ly:music?)
> #{
> \set squashedPosition = #-2
> \override NoteHead #'style = #'slash
> \override NoteHead #'font-size = #1
> \override Beam #'positions = #'(4 . 4)
> \override Stem #'length = #8
> \override Accidental #'stencil = ##f
> \override AccidentalCautionary #'stencil = ##f
>
> \stemUp
> #strums
> \stemNeutral
>
> \unset squashedPosition
> \revert NoteHead #'style
> \revert NoteHead #'font-size
> \revert Beam #'positions
> \revert Stem #'length
> \revert Accidental #'stencil
> \revert AccidentalCautionary #'stencil
>
> #})
>
> \new Voice = "melody" \with {
> \consists "Pitch_squash_engraver"
> } {
> \strumFn { c8[ c] } \acciaccatura a'16 b'8
> }
>
> \version "2.16.0"
What about
strumFn =
#(define-music-function
(parser location strums)
(ly:music?)
#{
\new Voice \with {
\consists "Pitch_squash_engraver"
squashedPosition = #-2
\override NoteHead #'style = #'slash
\override NoteHead #'font-size = #1
\override Beam #'positions = #'(4 . 4)
\override Stem #'length = #8
\override Accidental #'stencil = ##f
\override AccidentalCautionary #'stencil = ##f
\stemUp
}
{ #strums
}
#})
\new Voice = "melody"
{
\strumFn { c8[ c] } \acciaccatura a'16 b'8
}
--
David Kastrup
- font size override and grace notes, Matt Cary, 2012/10/17
- Re: font size override and grace notes, Eluze, 2012/10/18
- Re: font size override and grace notes, David Kastrup, 2012/10/18
- Re: font size override and grace notes, Matt Cary, 2012/10/18
- Re: font size override and grace notes,
David Kastrup <=
- Re: font size override and grace notes, Matt Cary, 2012/10/19
- Re: font size override and grace notes, David Kastrup, 2012/10/19
- Re: font size override and grace notes, Matt Cary, 2012/10/19
- Re: font size override and grace notes, David Kastrup, 2012/10/19
- Re: font size override and grace notes, David Kastrup, 2012/10/19