Subject: Re: Waiting for a call, xeyes, and vector fields
Date: Wed, 27 Nov 2002 17:55:59 +0100
Lars Clausen wrote:
>Actually, I have an idea to make a multi-prop widget that's collapsible.
>That would neatly take care of such cluttering, and then it'd be ok to have
>it on the standard line.
>
>
Sounds great.
>
>
>>2. In the xeyes demo, you probably noticed the funny connection
>>points floating around by themselves. These connection points are
>>half-way between the line handles, even if the lines are drawn
>>somewhere else due of the gap parameters.
>>
>>
>[...]
>
>It should be in the middle of the displayed area. Fixing that in CVS.
>
>
Go ahead if you have time and want to do it. Otherwise, I think I have
figured out how to do it. Tell
me if you want me to send you a diff for CVS with all of the recent
changes (the CVS can't do the xeyes demo
until it's patched a bit more).
< if (line->absolute_start_gap || line->absolute_end_gap ||
line->fractional_start_gap || line->fractional_end_gap) {
< Point gap_endpoints[2];
<
< calculate_gap_endpoints(line, gap_endpoints);
<
connpointline_putonaline(line->cpl,&gap_endpoints[0],&gap_endpoints[1]);
< } else {
<
connpointline_putonaline(line->cpl,&conn->endpoints[0],&conn->endpoints[1]);
< }
---
>
connpointline_putonaline(line->cpl,&conn->endpoints[0],&conn->endpoints[1]);
>>But what happens when all gaps are
>>zero? In this case, the connection points will coincide with the
>>handles. Will this screw anything up? It seems like it shouldn't,
>>since the box object has connection points that coincide with the
>>handles. Since connection points may change in the future for this
>>new line object, either they should be disabled completely, or they
>>should be fixed to coincide with the VISIBLE line (maybe requiring
>>changes to connpoint_line.c), or a simple static connection point
>>configuration should be made with start/center/end of visible line
>>connections. What do you think?
>>
>>
>
>Same thing would happen if you make a zero-length line regardless of gap.
>The analogy to box isn't good, as those are different kinds of handles
>(non-connectible).
>
>
>
Yes. In fact, I patched dia-0.9 with the above code, and had problems
with the xeyes demo. The
field-line arrows had the connection points at the same place as the
handles. So, like the case of
the zero-length line you mention above, the connection point was on the
handle (and the handle turned
red, as if it was connected to something). When I tried to changed the
gaps of one of these arrows
to 0,0,0,0, the line freaked out.
Also, with the above _putonaline changes, I could not add more
connection points to version 0.9. But I have a hunch
this will work out of the box in CVS, because it seems like handles
can't connect with their own connection
points as easily...looks like you've had problems before--that you've
fixed...
We should add connection points to the ends of the visible line as well.
Dave.