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

Re: moving lines with shapes



On Tue, 22 May 2001, Aaron Trevena wrote:

>
> a major bug bear of mine and many people I have spoken to is the lack of
> intelligence in lines. ie they stay attached to shapes, but don't follow
> them.
>
> This can greatly increase the amount of time taken to do a serious
> diagram, and particaulraly in my case removes some of the benefit of
> automatic the shape and line creation.
>
> is anybody working on some more intelligence in lines so they 'follow'
> shapes? or is it in 0.88 which I have yet to download?
>
> If not I may write something simple to try and find the locations of teh
> two connection points, which I assume are properties of teh line anyway
> and work out if the line is within a box bounded by the two connection
> points as corners.
>
> i.e.
>    -------------
>    |           |
> ---|---        |
>    |  |        |
>   .|..|........|.
> ---x---        |.
>   .            |.
>   .        ----x----
>   .........|.....  |
>            |       |
>            ---------
>
> shouldn't occur as the line is outside the box represented by the
> dots. Would it be wrong to try and add some logic to ensure that each
> time a shape attached to a line moves then the line shecks that it is
> still within the box boudned by its connections?

I see the point.  It would similarly be nice if Dia figured out to
initially place the line more sensible, perhaps even avoid other objects to
some degree.  We've had 'smart' line placement discussed before, and agreed
that while it is a good idea, a) we have more pasic things to work on first
(like good text support, better arrowheads and such), and b) it must be
optional.  Several Visio users expressed frustration with the smart lines
there.

Using just the bounding box would only be a partial fix -- consider this:

  +----------+
  |          |
  |    +-------------------------+
  |    v     |           +-------x-------+
  +----x-----+           |               |
                         |               |
                         +---------------+

Here, the line is still broken, even though it's inside the BB.

> This relatively simple feature (to the opuitsider looking in at
> least) would make a huge difference to visio usability. I'd be happy to
> code it if somebody gave me some big pointers on where and how to start
> and what to look out for. Dia is a bit big for me to master most of its
> code in order to just fix line behaviour, and I'm hoping that my current
> extra freetime (did I mention I was looking for work) will be somewhat
> less in the near future.

The first thing to do (IMO) is to be able to ask an object for the
orthogonal angle at a connectionpoint.  That would take adding a function
in lib/object.h and add support in objects/*/*.c (for objects with
connectionpoints).

I have in fact several functions I wish to add, including a standard
function for importers to create shapes with.

-Lars

--
Lars Clausen (http://shasta.cs.uiuc.edu/~lrclause) | Hårdgrim of Numenor
"I do not agree with a word that you say, but I    | Retainer of Sir Kegg
will defend to the death your right to say it."    |   of Westfield
    --Evelyn Beatrice Hall paraphrasing Voltaire   | Chaos Berserker of Khorne




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index] Mail converted by Mofo Magic and the Flying D

 
All trademarks and copyrights are the property of their respective owners.

Other Directory Sites: SeekWonder | Directory Owners Forum

GuideSMACK