[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Newsgroup Home]
|
[news.eclipse.modeling.gmf] Re: Custom Layout in Compartment
|
Hi,
I've had the same problem. After inspecting the gmf templates I've seen
a switch how to affect the generated result. A nested compartment figure
edit part is extending ListCompartmentEditPart where the inital main
compartment extends ShapeCompartmentEditPart. The key is the value for
ListLayout at the specific Gen Compartment within the created gmfgen
model. I have no glue what the initial value drives, but changing the
ListLayout to false remains recreation via gmfmap -> create generator model.
Hope this helps,
Sven
Alex Shatalin wrote:
> Hello Balthasar,
>
> Ok. I can reproduce this problem now (have to create same hierarchy
> like you).
> If you open .log file you'll see ClassCast exception there and this is
> a reason for problems with setting custom layout.
> Workarounds:
> 1. add removeEditPolicy(EditPolicy.LAYOUT_ROLE); call to the end of
> createDefaultEditPolicies() method in CompartmentEditPart
> 2. or open .gmfgen model, locate two (both) GenCompartment instances
> there and set "ListLayout" property to "true". (looks like Q&A was
> written for the case of compartment with list layout).
>
> -----------------
> Alex Shatalin
>
>