Re: shortening a stem

2013-04-08 Thread Werner LEMBERG
Have you tried using \once \override Stem.length-fraction = #(magstep -n) Yes. Unfortunately the amount of shortening is not consistent across all notes for a particular value of n. Exactly. This makes it quite inconvenient for applying a simple optical correction. Werner

Re: shortening a stem

2013-04-08 Thread Janek Warchoł
Hi, 2013/4/8 Werner LEMBERG w...@gnu.org: what must I write to shorten an unbeamed stem by, say, one unit? A naive approach would be \once \override Stem.length #(- ly:stem::calc-length 1) which doesn't work of course... David Nalesnik wrote a very versatile function that makes

Re: shortening a stem

2013-04-08 Thread Werner LEMBERG
Indeed, very nice! Thanks for the link. Unfortunately, it doesn't work with Stem.length at all because this is not an `offset'. Really? It works perfectly for me, with 2.17.13: \offset Stem #'length #2 % in positions, not ss! see attached. Interesting. Compiling your file with

Re: shortening a stem

2013-04-08 Thread David Nalesnik
Hi, On Mon, Apr 8, 2013 at 3:37 AM, Werner LEMBERG w...@gnu.org wrote: Indeed, very nice! Thanks for the link. Unfortunately, it doesn't work with Stem.length at all because this is not an `offset'. Really? It works perfectly for me, with 2.17.13: \offset Stem #'length #2 % in

Re: shortening a stem

2013-04-07 Thread Werner LEMBERG
what must I write to shorten an unbeamed stem by, say, one unit? A naive approach would be \once \override Stem.length #(- ly:stem::calc-length 1) which doesn't work of course... David Nalesnik wrote a very versatile function that makes such things very easy. You can find it in a

Re: shortening a stem

2013-04-07 Thread Nick Payne
On 08/04/13 14:31, Werner LEMBERG wrote: what must I write to shorten an unbeamed stem by, say, one unit? A naive approach would be \once \override Stem.length #(- ly:stem::calc-length 1) which doesn't work of course... David Nalesnik wrote a very versatile function that makes such things

Re: shortening a stem

2013-04-05 Thread Janek Warchoł
Hi Werner, i'm performing some archeological research on emails that were sent during my absence and i found this one: 2013/1/20 Werner LEMBERG w...@gnu.org: what must I write to shorten an unbeamed stem by, say, one unit? A naive approach would be \once \override Stem.length #(-

Re: shortening a stem

2013-04-05 Thread Urs Liska
Janek Warchoł janek.lilyp...@gmail.com schrieb: Hi Werner, i'm performing some archeological research on emails that were sent during my absence and i found this one: 2013/1/20 Werner LEMBERG w...@gnu.org: what must I write to shorten an unbeamed stem by, say, one unit? A naive approach

Re: shortening a stem

2013-04-05 Thread Urs Liska
Janek Warchoł janek.lilyp...@gmail.com schrieb: hmm, i think that your email body got eaten. Janek Oops, you're right. But before that happened I had asked whether you have included that function in our Fried library. Otherwise you should make a note to contribute it yourself to OLLib once

Re: shortening a stem

2013-04-05 Thread Janek Warchoł
2013/4/5 Urs Liska li...@ursliska.de: Janek Warchoł janek.lilyp...@gmail.com schrieb: hmm, i think that your email body got eaten. Janek Oops, you're right. But before that happened I had asked whether you have included that function in our Fried library. Otherwise you should make a note to

Re: shortening a stem

2013-04-05 Thread Urs Liska
On Fri, 5 Apr 2013 22:05:24 +0200 Janek Warchoł janek.lilyp...@gmail.com wrote: 2013/4/5 Urs Liska li...@ursliska.de: Janek Warchoł janek.lilyp...@gmail.com schrieb: hmm, i think that your email body got eaten. Janek Oops, you're right. But before that happened I had asked whether

shortening a stem

2013-01-20 Thread Werner LEMBERG
Folks, what must I write to shorten an unbeamed stem by, say, one unit? A naive approach would be \once \override Stem.length #(- ly:stem::calc-length 1) which doesn't work of course... Werner ___ lilypond-user mailing list

Re: shortening a stem

2013-01-20 Thread Eluze
: http://lilypond.1069038.n5.nabble.com/shortening-a-stem-tp139796p139797.html Sent from the User mailing list archive at Nabble.com. ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user

Re: shortening a stem

2013-01-20 Thread Werner LEMBERG
what must I write to shorten an unbeamed stem by, say, one unit? A naive approach would be \once \override Stem.length #(- ly:stem::calc-length 1) looking for \override Stem.length-fraction = #(magstep -1) Thanks, but no. I'm interested in shortening the stem by a fixed amount

Re: shortening a stem

2013-01-20 Thread David Kastrup
in shortening the stem by a fixed amount, not scaling the whole stem length by a factor. (define ((stem-reduce amount) grob) (let ((l (ly:grob-property grob 'length))) (/ (- l amount) l))) \override Stem.length-fraction = #(stem-reduce 1) This is probably slightly absurd (and untested to boot

Re: shortening a stem

2013-01-20 Thread m...@mikesolomon.org
On 20 janv. 2013, at 17:21, Werner LEMBERG w...@gnu.org wrote: Folks, what must I write to shorten an unbeamed stem by, say, one unit? A naive approach would be \once \override Stem.length #(- ly:stem::calc-length 1) which doesn't work of course... Werner This does

Re: shortening a stem

2013-01-20 Thread Xavier Scheuer
On 20 January 2013 17:21, Werner LEMBERG w...@gnu.org wrote: Folks, what must I write to shorten an unbeamed stem by, say, one unit? A naive approach would be \once \override Stem.length #(- ly:stem::calc-length 1) which doesn't work of course... Hi Werner, You might want to use

Re: shortening a stem

2013-01-20 Thread Werner LEMBERG
{ \once \override Stem.length = #(lambda (grob) (- (ly:stem::calc-length grob) 4)) a4 } Thanks! I can imagine that a lot of people just want to shorten a stem by a certain amount without actually determining the necessary length. Werner

Re: shortening a stem

2013-01-20 Thread Werner LEMBERG
You might want to use \override Stem #'no-stem-extend = ##t as well, since by default notes with ledger lines get their stems extending to the middle staff line (and maybe you do not want that with your shortened stems). In my case, this is not necessary since the shortening is just to

Re: shortening a stem

2013-01-20 Thread Werner LEMBERG
(define ((stem-reduce amount) grob) (let ((l (ly:grob-property grob 'length))) (/ (- l amount) l))) \override Stem.length-fraction = #(stem-reduce 1) This is probably slightly absurd (and untested to boot), but it would likely work. Thanks for this, too! Werner