lilypond-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

strange behaviour of relative_coordinate


From: Janek Warchoł
Subject: strange behaviour of relative_coordinate
Date: Mon, 11 Mar 2013 12:12:06 +0100

Hi,

I'm poking around self-alignment-interface and functions that work
with extents, offsets etc.  I've found a Grob method

relative_coordinate (Grob const *refp, Axis a)

and i suppose its purpose is to return the offset between me and refp
along axis a.  So far so good, but i've noticed that it says the
distance from refp to me is different than distance from me to refp -
??

For example take this snippet: { a' } \addlyrics { mam }
When i use relative_coordinate for measuring offset between LyricText
and Stem (see attached short patch), i get:

I'm a LyricText and I've caught the Stem of my parent NoteHead
relative coordinate from stem to me is: 1.251178
relative coordinate from me to stem is: 0.000000

Is this intentional?
If so, why?
I expected that the second number would be -1.251178.

cheers,
Janek

PS I've cc'd Han-Wen and Jan because git says they wrote relative_coordinate.

Attachment: 0001-relative-coordinate-diagnostics.patch
Description: Binary data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]