Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » Layout provider: a bottom-up layout?
Layout provider: a bottom-up layout? [message #501880] Fri, 04 December 2009 09:49 Go to next message
Giovanni De Sossi is currently offline Giovanni De SossiFriend
Messages: 161
Registered: October 2009
Location: Rome, Italy
Senior Member

Hi,
I'm trying to modify the default layout provider in my GMF RCP application; I extended LeftRightProvider and overridden the createGraph() method:

public class BottomUpLayoutProvider extends LeftRightProvider {

protected DirectedGraph createGraph() {
DirectedGraph g = super.createGraph();
g.setDirection(PositionConstants.NORTH);
return g;
}
}


but it doesn't work, no changes are visible when I click the "arrange" menu item. I modified the plugin.xml to declare the new layout provider, of course.

Any ideas?

Thanx,
giovanni.
Re: Layout provider: a bottom-up layout? [message #511031 is a reply to message #501880] Fri, 29 January 2010 15:45 Go to previous message
Giovanni De Sossi is currently offline Giovanni De SossiFriend
Messages: 161
Registered: October 2009
Location: Rome, Italy
Senior Member

Hi,

as usual no one answered this question; I've found a solution, and I post back:

due the bug#159558, to obtain a "DownTop" layout in a RCP product you have to modify the plugin.xml:

<extension id="presentationLayoutProvider" name="%ext.presentationLayoutProvider" point="org.eclipse.gmf.runtime.diagram.ui.layoutProviders">
<layoutProvider
class=" org.eclipse.emf.ecoretools.diagram.providers.DownTopProvider ">
<Priority name="Medium"/>
</layoutProvider>
</extension>

Regards,

Giovanni
Previous Topic:How to set default values of model elements in GMF based Editor?
Next Topic:GMF mapping trouble
Goto Forum:
  


Current Time: Mon Apr 19 01:25:43 GMT 2021

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

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

Back to the top