Eclipse Community Forums - RDF feed
https://www.eclipse.org/forums/
Eclipse Community ForumsUnexpected layout of elements inside Component
https://www.eclipse.org/forums/index.php/mv/msg/172456/548720/#msg_548720
Originally posted by: harrisb.ociweb.com
Hello,
I'm trying to use the UML2Tool's Component diagram element defined in
componentDiagram_classifiers.gmfgraph with my own mapping. When I do
this the elements inside the component stack on top of each other with
each element nearly the same width as the component. By contrast, when I
create a component using UML2Tools, I can place elements anywhere inside
the component with any size.
In other words, the layout for a Component using UML2Tools appears to be
using the GMF XY Layout. However, inspecting the graphical definition
model I looks like a custom border is used for the figure that
corresponds to the compartment holding the component elements.
I concluding this by looking in project org.eclipse.uml2.diagram.def
graphical definition model found in
structures/componentDiagram_classifiers.gmfgraph. For figure
ComponentFigure_Body used by the compartment the custom layout
org.eclipse.gmf.runtime.draw2d.ui.figures.OneLineBorder is used. Is this
the reason the elements I'm putting in the component just stack up? I
would have expected that XY Layout would be used.
Can someone help explain why I can't position my elements anywhere in
the component?
Thanks,
Byron Harris]]>2010-07-22T18:03:48-00:00Re: Unexpected layout of elements inside Component
https://www.eclipse.org/forums/index.php/mv/msg/172456/551735/#msg_551735
sometimes it helps to inspect the gmfgen-file (the generator model). Because here you also have the possibility to make some changes. You mustn't use it as it is. As long as you only overwrite the gmfgen all previously made manual changes remain in this file. So maybe you'll find here the answer to your question.
Else I would look at the code: Maybe there's some custom code (besides the OneLineBorder) which does the job.
Regards
Christian Waniek]]>Christian Waniek2010-08-09T11:57:24-00:00Re: Unexpected layout of elements inside Component
https://www.eclipse.org/forums/index.php/mv/msg/172456/625888/#msg_625888
sometimes it helps to inspect the gmfgen-file (the generator model). Because here you also have the possibility to make some changes. You mustn't use it as it is. As long as you only overwrite the gmfgen all previously made manual changes remain in this file. So maybe you'll find here the answer to your question.
Else I would look at the code: Maybe there's some custom code (besides the OneLineBorder) which does the job.
Regards
Christian Waniek]]>Christian Waniek2010-08-09T11:57:24-00:00Re: Unexpected layout of elements inside Component
https://www.eclipse.org/forums/index.php/mv/msg/172456/625959/#msg_625959
Originally posted by: harrisb.ociweb.com
Hi Christian,
Yes, I eventually found out there was a setting for my compartment's
listlayout that was set to “true” in the .gmfgen file that was
overriding the layout setting in the graphic definition model. Once I
set listlayout to "false" I got the behavior I was expecting.
I wonder why listlayout is needed?
Byron
Christian Waniek wrote:
> Hello
>
> sometimes it helps to inspect the gmfgen-file (the generator model).
> Because here you also have the possibility to make some changes. You
> mustn't use it as it is. As long as you only overwrite the gmfgen all
> previously made manual changes remain in this file. So maybe you'll find
> here the answer to your question.
>
> Else I would look at the code: Maybe there's some custom code (besides
> the OneLineBorder) which does the job.
>
> Regards
> Christian Waniek]]>2010-08-09T17:09:34-00:00Re: Unexpected layout of elements inside Component
https://www.eclipse.org/forums/index.php/mv/msg/172456/551834/#msg_551834
Originally posted by: harrisb.ociweb.com
Hi Christian,
Yes, I eventually found out there was a setting for my compartment's
listlayout that was set to “true” in the .gmfgen file that was
overriding the layout setting in the graphic definition model. Once I
set listlayout to "false" I got the behavior I was expecting.
I wonder why listlayout is needed?
Byron
Christian Waniek wrote:
> Hello
>
> sometimes it helps to inspect the gmfgen-file (the generator model).
> Because here you also have the possibility to make some changes. You
> mustn't use it as it is. As long as you only overwrite the gmfgen all
> previously made manual changes remain in this file. So maybe you'll find
> here the answer to your question.
>
> Else I would look at the code: Maybe there's some custom code (besides
> the OneLineBorder) which does the job.
>
> Regards
> Christian Waniek]]>2010-08-09T17:09:34-00:00