Skip to main content



      Home
Home » Modeling » Graphiti » Move and Add with highlight
Move and Add with highlight [message #899398] Tue, 31 July 2012 12:48 Go to next message
Eclipse UserFriend
Hi everyone
Do you think it is possible to highlight the position where the new shape is gonna be positionate

I'm trying to do a semi-automatic layout, this is, I'm aligning objects regarding the position they are dropped.

So I want to give feedback, drawing a dashed line or something, at the position where the object goes efectively.

I noticed that in CanCreate Context parameter we can get the mouse position, but What can I invoke to draw and undraw this dashed line.

Do you think it's possible?
And accessing some internal?

Thanks in advance
Re: Move and Add with highlight [message #899477 is a reply to message #899398] Wed, 01 August 2012 02:24 Go to previous messageGo to next message
Eclipse UserFriend
There is a method isShowGuides() in the IToolBehaviorProvider. The default implementation simply returns TRUE.

In this case helper lines will be drawn to simplify the alignment of shapes. Did you see this? Is that sufficient for you?

BR,
Matthias
Re: Move and Add with highlight [message #899500 is a reply to message #899477] Wed, 01 August 2012 04:15 Go to previous messageGo to next message
Eclipse UserFriend
Hi. Maybe. I'm gonna try.
Later I post feedback.

Anyway, where should I draw the alignment line. In this method (isShowGuides?) Confused


Thank you for replying.
Rui.

[Updated on: Wed, 01 August 2012 04:22] by Moderator

Re: Move and Add with highlight [message #899531 is a reply to message #899500] Wed, 01 August 2012 06:18 Go to previous messageGo to next message
Eclipse UserFriend
Hi again.

Is it possible to redefine somewhere how the guidelines are drawn?

Thanks
Re: Move and Add with highlight [message #899544 is a reply to message #899531] Wed, 01 August 2012 07:17 Go to previous messageGo to next message
Eclipse UserFriend
If you return TRUE in the method isShowGuides() the alignment lines will be drawn automatically.

Currently it is not possible for the Graphiti customer (editor developer) to draw anything while moving/adding a shape in/to the diagram.
Re: Move and Add with highlight [message #899568 is a reply to message #899544] Wed, 01 August 2012 09:11 Go to previous messageGo to next message
Eclipse UserFriend
Ah. Ok then. I thought it could be done somehow.
Actually I managed to draw a line, recurring to static references (bad practices), in createfeature.

In createfeature , I assign some value to a public static field, and invoke parent layout (which checks the value of the static field).

But I can't remove or change line properties, because layout is not invoked when the mouse is over something else (palete, other eclipse view, or other forbiden container... etc)

If you any hint else, please post.

Thanks anyway.
Re: Move and Add with highlight [message #899775 is a reply to message #899568] Thu, 02 August 2012 06:09 Go to previous message
Eclipse UserFriend
HI again.
Maybe Mathias can answer me to this question, and maybe this is not the right place to post it.

Regarding the behaviour I explained in this thread: with GMF, would it be possible to achieve that beaviour: highlight the place during the process of creation..

I'm exploring my hypothesis, and as I only have used GME before (Academic/Vanderbuilt) and DSLTools (Comercial), I'd like to know if it would be possible with GMF or even with EuGENia.

Thanks in advance. If someone can advise me, i'd be grateful.

Rui
Previous Topic:Move Shepe
Next Topic:Diagram Options mixture
Goto Forum:
  


Current Time: Tue Jul 22 20:53:52 EDT 2025

Powered by FUDForum. Page generated in 0.07032 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top