Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » Setting color for connection object
Setting color for connection object [message #183933] Wed, 23 April 2008 04:20 Go to next message
Asha is currently offline AshaFriend
Messages: 18
Registered: July 2009
Junior Member
Hello,

I want to set the color of connection object. It is done in factory and
editpart classes. Color set from factory class is getting set, but not
the one from editpart.

In Factory class , line color is set in the following way
((LineStyle) view.getStyle(NotationPackage.eINSTANCE.getLineStyle()))
.setLineColor(lineColor.getRGB().hashCode());

In Edit part
generatedConnectionFigure.setForegroundColor(ColorConstants. blue);


I have to set the color from EditPart. Any idea how to achieve this?
Re: Setting color for connection object [message #184003 is a reply to message #183933] Wed, 23 April 2008 09:46 Go to previous message
Alexander Shatalin is currently offline Alexander ShatalinFriend
Messages: 2928
Registered: July 2009
Senior Member
Hello Asha,

See ConnectionEditPart.refreshForegroundColor() - this is a place where connection
foreground color synchronized with one from notation model. If you need to
break this behavior then you have to override this method.

-----------------
Alex Shatalin
Previous Topic:Change the Tabbed view sections
Next Topic:editorProviders extension point
Goto Forum:
  


Current Time: Fri Apr 26 19:05:49 GMT 2024

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

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

Back to the top