Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » How Can I Enable Delete From Diagram Button
How Can I Enable Delete From Diagram Button [message #1016978] Fri, 08 March 2013 12:45 Go to next message
serhat gezgin is currently offline serhat gezginFriend
Messages: 242
Registered: January 2013
Location: Izmir
Senior Member
Hi all,

First of all i m new to GMF.

Problem;

When i create diagram from gmf always delete from diagram button is disabled.

So what i must do, i need these button cause of working large models. Anyone can help

me ?
Re: How Can I Enable Delete From Diagram Button [message #1017004 is a reply to message #1016978] Fri, 08 March 2013 14:38 Go to previous messageGo to next message
Andreas Muelder is currently offline Andreas MuelderFriend
Messages: 71
Registered: July 2011
Member
Hi,
that delete form diagram is disabled may be an indication that your diagram has
canonical behavior.

Best regards,

Andreas

Re: How Can I Enable Delete From Diagram Button [message #1017008 is a reply to message #1017004] Fri, 08 March 2013 14:51 Go to previous messageGo to next message
serhat gezgin is currently offline serhat gezginFriend
Messages: 242
Registered: January 2013
Location: Izmir
Senior Member
Hi,

In the xxEditPart.java file found in the path
src\org\xx\diagram\edit\parts,
Comment the following lines
//installEditPolicy(
// EditPolicyRoles.CANONICAL_ROLE,
//new xx.diagram.edit.policies.xxCanonicalEditPolicy());


I am not sure if this is the right way to do,but it worked. But when i was delete

element on my diagram i cant reload element again Smile. I Confused just i need

when i want to delete element on diagram i can delete but later i can be reload this

too. ( Because i need views of my Model ). But i cant reload that element again
Re: How Can I Enable Delete From Diagram Button [message #1017102 is a reply to message #1017008] Sat, 09 March 2013 09:50 Go to previous messageGo to next message
Aurelien Pupier is currently offline Aurelien PupierFriend
Messages: 579
Registered: July 2009
Location: Grenoble, FRANCE
Senior Member

Hi,

so what you want is just to hide/show elements and not delete them. Please see: http://wiki.eclipse.org/GMF_Newsgroup_Q_and_A#How_can_I_hide_an_edge_on_a_diagram.3F

regards,


Aurélien Pupier - Bonitasoft S.A.
My company Eclipse-related blog
Re: How Can I Enable Delete From Diagram Button [message #1017226 is a reply to message #1017102] Mon, 11 March 2013 08:58 Go to previous messageGo to next message
serhat gezgin is currently offline serhat gezginFriend
Messages: 242
Registered: January 2013
Location: Izmir
Senior Member
Hi,

Yeah Hide and show fine for me but when i hide more then 1 element on my model

i cant find list of hide elements to select one for Show. Only posibbleties is Show

all. So how can i show just one element from Hided more than 1 model elements?

Regards.
Re: How Can I Enable Delete From Diagram Button [message #1017243 is a reply to message #1017226] Mon, 11 March 2013 09:41 Go to previous messageGo to next message
Aurelien Pupier is currently offline Aurelien PupierFriend
Messages: 579
Registered: July 2009
Location: Grenoble, FRANCE
Senior Member

Hi,

I think that you might find some ideas in Mylyn/Modeling bridge: http://wiki.eclipse.org/Mylyn/Modeling_Bridge

regards,


Aurélien Pupier - Bonitasoft S.A.
My company Eclipse-related blog
Re: How Can I Enable Delete From Diagram Button [message #1176713 is a reply to message #1017243] Fri, 08 November 2013 14:02 Go to previous message
serhat gezgin is currently offline serhat gezginFriend
Messages: 242
Registered: January 2013
Location: Izmir
Senior Member
Hi,

when i remove canonical behavior, my diagram and model can't be synchronized when i create element from model it don't appair on diagram ?

I can't find any solution

Regards
Previous Topic:Extend External Label representation and only show it by hovering the mouse
Next Topic:ModelingAssistantProvider
Goto Forum:
  


Current Time: Sun Dec 21 04:19:57 GMT 2014

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

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