creating mutliple edit parts [message #146806] |
Sun, 08 August 2004 14:41  |
Eclipse User |
|
|
|
all,
i wish to create multiple figures when dragging an item from the palette.
i am not sure the best approach to take for this. an edit part can onlt
create a single figure, so i assume i need to create more than one edit
part.
further, i would like to link these two edit parts (or whatever technique
is best) together. are there existing listeners between edit parts, or
should i make my own inter-editpart communication.
thanks in advance,
steve
|
|
|
|
|
Re: creating mutliple edit parts [message #147159 is a reply to message #146885] |
Tue, 10 August 2004 22:08   |
Eclipse User |
|
|
|
brian and randy,
thank you for the advise.
specifically, i want to seperate out the text from the figure. i want to
be able to "grab" the text from a figure and move it so it can be anywhere
inside or outside of the figure. to do this, i want every shape figure to
have an associated figure that is the text figure (just a rectangle
without border and transparent fill). both would be added to the diagram
model and they would have enough knowledge of each other so
moving/resizing/rotating/etc would effect both.
i really like the model-based control and i believe i will research this
avenue. any other advise would be appreciated.
my goal is to have the main selection tool always "select" the shape
figure regardless whether the associated text figure was selected (this i
know how to do). if you use the text tool, then selecting the shape
figure always selects the text figure.
steve
Randy Hudson wrote:
> What Brian said, except I think you should describe you application since it
> is hard to recommend a certain course of action without knowing the context.
> "steven melzer" <smelzer@paymentech.com> wrote in message
> news:cf5s3s$l12$1@eclipse.org...
> > all,
> >
> > i wish to create multiple figures when dragging an item from the palette.
> > i am not sure the best approach to take for this. an edit part can onlt
> > create a single figure, so i assume i need to create more than one edit
> > part.
> >
> > further, i would like to link these two edit parts (or whatever technique
> > is best) together. are there existing listeners between edit parts, or
> > should i make my own inter-editpart communication.
> >
> > thanks in advance,
> > steve
> >
|
|
|
|
Re: creating mutliple edit parts [message #147330 is a reply to message #147159] |
Wed, 11 August 2004 12:40  |
Eclipse User |
|
|
|
Originally posted by: none.us.ibm.com
You could also acheive this with a special invible handle which floats on
top of the text. When you drag the text, just the text is moved, even
though it is not a separate, selectable editpart. The text label could be
inside the shape, or floating on top of it on some layer. A graphical
editpart can have two separate figures on two separate layers. You could
just extend the parent's remove/addChildVisuals() to call getFigure2(), and
add it to a separate "contents" pane such as the connection layer, etc..
"steven melzer" <steven.melzer@verizon.net> wrote in message
news:cfbv2j$1dq$1@eclipse.org...
> brian and randy,
>
> thank you for the advise.
>
> specifically, i want to seperate out the text from the figure. i want to
> be able to "grab" the text from a figure and move it so it can be anywhere
> inside or outside of the figure. to do this, i want every shape figure to
> have an associated figure that is the text figure (just a rectangle
> without border and transparent fill). both would be added to the diagram
> model and they would have enough knowledge of each other so
> moving/resizing/rotating/etc would effect both.
>
> i really like the model-based control and i believe i will research this
> avenue. any other advise would be appreciated.
>
> my goal is to have the main selection tool always "select" the shape
> figure regardless whether the associated text figure was selected (this i
> know how to do). if you use the text tool, then selecting the shape
> figure always selects the text figure.
>
> steve
>
> Randy Hudson wrote:
>
> > What Brian said, except I think you should describe you application
since it
> > is hard to recommend a certain course of action without knowing the
context.
>
> > "steven melzer" <smelzer@paymentech.com> wrote in message
> > news:cf5s3s$l12$1@eclipse.org...
> > > all,
> > >
> > > i wish to create multiple figures when dragging an item from the
palette.
> > > i am not sure the best approach to take for this. an edit part can
onlt
> > > create a single figure, so i assume i need to create more than one
edit
> > > part.
> > >
> > > further, i would like to link these two edit parts (or whatever
technique
> > > is best) together. are there existing listeners between edit parts,
or
> > > should i make my own inter-editpart communication.
> > >
> > > thanks in advance,
> > > steve
> > >
>
>
|
|
|
Powered by
FUDForum. Page generated in 0.05100 seconds