Login | Register
My pages Projects Community openCollabNet

Discussions > dev > [gef-dev] ArgoUML issue 1048.

gef
Discussion topic

Back to topic list

[gef-dev] ArgoUML issue 1048.

Reply

Author dthompson
Full name Dave Thompson
Date 2008-12-09 12:51:19 PST
Message Hi,

Since what I'm about to talk about really is a GEF question, not an ArgoUML
one, I'm sending it to the GEF list.

While working on issue1048, I have come to the problem of accessing the
PathItemPlacementStrategy for a given Fig (such as a label) on a FigEdge. I
need to access the PathItemPlacementStrategy, so that I can modify it's fields.

In the repository at the moment, once a pathItem has been created, I think
the access I have at a later date is quite limited. Assuming all I've got is
a reference to the FigEdge, all I can do is use
FigEdge.getPathItemStrategies() to get a list of all of the pathitems used
within that fig. Unfortunately, this does not help me to find out which
PathItem is associated with the Fig I am interested in. I can iterate
through the list, but all I can do is paint() or getPoint(), neither of these
helps me pin down the fig.

Possible options (there may be more!):

A) One option is of course to add more to the PathItemPlacementStrategy
interface, with a getFig() method for getting the anchored Fig. I could then
use this method during my search, to try each pathitem until the getFig()
pointed to the fig I was interested in.

B) My preferred option would be to add a method to figEdge:
getPathItemPlacement​Strategy(Fig fig). This method could be used to directly
return the PathItemPlacementStrategy for a particular fig. I think that if
we did this, we would probably no longer need the getPathItemStrategies() method.

I've out B and it works, with a few other changes to ArgoUML. Attached is my
patch.

(Bob?) please advise on which way you would like me to proceed.

Kind regards,

Dave

« Previous message in topic | 1 of 7 | Next message in topic »

Messages

Show all messages in topic

[gef-dev] ArgoUML issue 1048. dthompson Dave Thompson 2008-12-09 12:51:19 PST
     Re: [gef-dev] ArgoUML issue 1048. bobtarling Bob Tarling 2008-12-09 13:26:04 PST
         Re: [gef-dev] ArgoUML issue 1048. dthompson Dave Thompson 2008-12-09 13:36:04 PST
             Re: [gef-dev] ArgoUML issue 1048. bobtarling Bob Tarling 2008-12-09 13:46:30 PST
                 Re: [gef-dev] ArgoUML issue 1048. dthompson Dave Thompson 2008-12-09 14:42:37 PST
                     Re: [gef-dev] ArgoUML issue 1048. bobtarling Bob Tarling 2008-12-09 14:46:54 PST
                         Re: [gef-dev] ArgoUML issue 1048. dthompson Dave Thompson 2008-12-10 00:29:15 PST
Messages per page: