[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Lilypond-auto] Issue 3330 in lilypond: bracketify-stencil moves gro
From: |
lilypond |
Subject: |
Re: [Lilypond-auto] Issue 3330 in lilypond: bracketify-stencil moves grob's refpoint |
Date: |
Wed, 24 Apr 2013 13:42:13 +0000 |
Comment #5 on issue 3330 by address@hidden: bracketify-stencil moves grob's
refpoint
http://code.google.com/p/lilypond/issues/detail?id=3330
There is also issue 732 involved. This is a wildly inconsistent mess. Let
me state a set of requirements that the bunch of increasingly fragile
patches tries to meet at the same time:
\markup \parenthesize x should maintain the reference point of x
\markup { a \parenthesize b c } should allow sufficient space for the the
parentheses
\markup { a \hspace #-1 b } should backspace b over a
\markup { a \null b } should have the same spacing as \markup { a b }
The spacing in a line is solely determined by stencil dimensions.
The reference point of a stencil is solely determined by stencil dimensions.
So if we can't use our X stencil dimensions for figuring out our X
placement, let's draw the Y stencil dimensions into it:
commit a10833e185f24d63ba084634e24933347e347185
Author: Keith OHara <address@hidden>
Date: Tue Dec 4 21:34:32 2012 -0800
stencil.cc: Backspacing stencils are not empty
diff --git a/lily/stencil.cc b/lily/stencil.cc
index a488c59..eb3420d 100644
--- a/lily/stencil.cc
+++ b/lily/stencil.cc
@@ -66,10 +66,13 @@ Stencil::extent (Axis a) const
bool
Stencil::is_empty () const
+/* If only one of X- or Y-extent is empty; such a stencil can be useful
+ * for backspacing, as with \hspace #-2, so we do not consider it empty.
+ */
So now if only one extent is empty, it can be used for backspacing, but
only in one direction. So now our bracket/paren is backspacing into the
previous character in a line as its other extent is not empty.
How do we get out of this nuthouse?
Here are a few observations:
a) negative escapements/dimensions are considered valid, so it does not
make sense to declare one dimension "empty" unless we are talking about the
untouched +inf,-inf dimension pair. left > right is not at all the same
as "empty" when we allow for backspacing material
b) if we distinguish backspacing/non-backspacing alone from the stencil
dimensions and want \parenthesize x to have the same reference point as x,
this stencil must not backspace inside of a line in spite of having a
negative x-min.
c) if \hspace #-3 is supposed to backspace, in contrast, the distinguishing
difference should be that \hspace #-3 has an _empty_ Y interval (currently
it is a _non_-empty one).
And empty does _not_ mean min>max like it does with intervals. People
still with me on this?
--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings
- [Lilypond-auto] Issue 3330 in lilypond: bracketify-stencil moves grob's refpoint, lilypond, 2013/04/23
- Re: [Lilypond-auto] Issue 3330 in lilypond: bracketify-stencil moves grob's refpoint, lilypond, 2013/04/24
- Re: [Lilypond-auto] Issue 3330 in lilypond: bracketify-stencil moves grob's refpoint, lilypond, 2013/04/24
- Re: [Lilypond-auto] Issue 3330 in lilypond: bracketify-stencil moves grob's refpoint, lilypond, 2013/04/24
- Re: [Lilypond-auto] Issue 3330 in lilypond: bracketify-stencil moves grob's refpoint, lilypond, 2013/04/24
- Re: [Lilypond-auto] Issue 3330 in lilypond: bracketify-stencil moves grob's refpoint,
lilypond <=
- Re: [Lilypond-auto] Issue 3330 in lilypond: bracketify-stencil moves grob's refpoint, lilypond, 2013/04/25
- Re: [Lilypond-auto] Issue 3330 in lilypond: bracketify-stencil moves grob's refpoint, lilypond, 2013/04/25
- Re: [Lilypond-auto] Issue 3330 in lilypond: bracketify-stencil moves grob's refpoint, lilypond, 2013/04/27
- Re: [Lilypond-auto] Issue 3330 in lilypond: bracketify-stencil moves grob's refpoint, lilypond, 2013/04/27
- Re: [Lilypond-auto] Issue 3330 in lilypond: bracketify-stencil moves grob's refpoint, lilypond, 2013/04/28
- Re: [Lilypond-auto] Issue 3330 in lilypond: bracketify-stencil moves grob's refpoint, lilypond, 2013/04/28
- Re: [Lilypond-auto] Issue 3330 in lilypond: bracketify-stencil moves grob's refpoint, lilypond, 2013/04/28
- Re: [Lilypond-auto] Issue 3330 in lilypond: bracketify-stencil moves grob's refpoint, lilypond, 2013/04/28
- Re: [Lilypond-auto] Issue 3330 in lilypond: bracketify-stencil moves grob's refpoint, lilypond, 2013/04/28
- Re: [Lilypond-auto] Issue 3330 in lilypond: bracketify-stencil moves grob's refpoint, lilypond, 2013/04/28