Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » Compartment layout problem after update to Juno
Compartment layout problem after update to Juno [message #992697] Sat, 22 December 2012 10:23 Go to next message
Axel Guckelsberger is currently offline Axel Guckelsberger
Messages: 223
Registered: July 2009
Senior Member
Hi all,

I need some help for coping with a visual problem which appeared since I've updated to Juno.

There is an entity figure with two compartments, one for the fields (list mode enabled) and one for indexes (list mode disabled). The first one can contain different field types. Almost all of these are using WrappingLabel which works fine with the list layout.
One exception is the "list field" which has multiple list entries. Therefore this one has another figure (ListFieldShape extends RoundedRectangle) and contains an inner compartment (RectangleFigure) with several list entries which are WrappingLabel instances again.

In addition I've implemented the recipe described at http://wiki.eclipse.org/GMF/Recipes#Recipe:__HowTo_reorder_children_in_a_GMF_compartment_with_Drag_.26_Drop to allow reordering fields by using drag & drop. So the fields compartment uses a FlowLayout internally.

The problem which appeared now is that list fields are not positioned within the fields compartment properly anymore, but are placed at the right side next to the other fields instead.

The following screenshots show how it looked like before Juno and how it looks like now.

I hope that the gmf newsgroup is the right one for this kind of question. If not I can also repost in the gef and draw2d groups.

Can you give me an advice how I need to change my figures in order to achieve the earlier display again? Maybe I need to use another Layout instead of the FlowLayout to enforce the old display behaviour in the compartment?

Thanks in advance for blazing a trail!

Axel
Re: Compartment layout problem after update to Juno [message #999335 is a reply to message #992697] Fri, 11 January 2013 21:10 Go to previous message
Axel Guckelsberger is currently offline Axel Guckelsberger
Messages: 223
Registered: July 2009
Senior Member
In case somebody has a similar issue: I got around this problem by using
ToolbarLayout instead of FlowLayout for the outer compartment.

Axel


Axel Guckelsberger wrote:

> Hi all,
>
> I need some help for coping with a visual problem which appeared since
> I've updated to Juno.
>
> There is an entity figure with two compartments, one for the fields (list
> mode enabled) and one for indexes (list mode disabled). The first one can
> contain different field types. Almost all of these are using WrappingLabel
> which works fine with the list layout. One exception is the "list field"
> which has multiple list entries. Therefore this one has another figure
> (ListFieldShape extends RoundedRectangle) and contains an inner
> compartment (RectangleFigure) with several list entries which are
> WrappingLabel instances again.
>
> In addition I've implemented the recipe described at
>
http://wiki.eclipse.org/GMF/Recipes#Recipe:__HowTo_reorder_children_in_a_GMF_compartment_with_Drag_.26_Drop
> to allow reordering fields by using drag & drop. So the fields compartment
> uses a FlowLayout internally.
>
> The problem which appeared now is that list fields are not positioned
> within the fields compartment properly anymore, but are placed at the
> right side next to the other fields instead.
>
> The following screenshots show how it looked like before Juno and how it
> looks like now.
>
> I hope that the gmf newsgroup is the right one for this kind of question.
> If not I can also repost in the gef and draw2d groups.
>
> Can you give me an advice how I need to change my figures in order to
> achieve the earlier display again? Maybe I need to use another Layout
> instead of the FlowLayout to enforce the old display behaviour in the
> compartment?
>
> Thanks in advance for blazing a trail!
>
> Axel
Previous Topic:Validation of root diagram element
Next Topic:Assign File to a GMF node
Goto Forum:
  


Current Time: Mon Sep 22 06:29:29 GMT 2014

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

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