[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.modeling.gmf] Re: Parent-child layout problem

Perhaps I am not asking my question very clear...
In the example application I posted there are no elements with affixed 
parent side set. This is also not my intention. I "simply" try to use the 
provided layouts. When I do this with "static" elements, the layouts seem to 
function OK - I can easy display 20 boxes with different colors in 5 rows, 4 
columns per row. But when I try to use childs, instead of static elements, 
the childs are not ordered in 5 rows, 4 columns per row - they are not 
displayed at all.
I don't think the question is concerning the affixed parent side feature, 
please correct me if I am wrong?

Can anyone please post a simple example using BorderLayout or GridLayout?
Any ideas/suggestions/explanations are more than welcome...

Regards,
Krasi


"Cherie Revells" <crevells@xxxxxxxxxx> wrote in message 
news:46F7B689.1000309@xxxxxxxxxxxxx
> Krassimir,
>
> The last time I checked, the affixed parent side figures have their 
> locations determined by a locator.  The layouts you mentioned should not 
> be affecting the affixed parent side figures.  Put a breakpoint in the 
> setBounds() of the affixed parent side figure to see how it's location is 
> being set.
>
> Regards,
> Cherie
>
> Krassimir Kondarev wrote:
>> Hi Cherie,
>>
>> thanks for answering, I use currently exactly affixed parent side in my 
>> prototype - this is working more or less as expected.
>>
>> My question is about the layout usage in GMF - the example is with 
>> BorderLayout, but the same issue is noticed with other layouts as well - 
>> GrigLayout as example. Somehow I am not able to use other layout than 
>> Flow and XY.
>>
>> I posted the model files - probably I do something wrong? But what? Same 
>> models work fline with only changing the layout to Flow.
>>
>> Any further help is greatly appreciated...
>>
>>
>> "Cherie Revells" <crevells@xxxxxxxxxx> wrote in message 
>> news:fd163r$mf0$1@xxxxxxxxxxxxxxxxxxxx
>>> Merlin,
>>>
>>> The behavior you are seeing use the affixed parent side is expected. 
>>> There is a locator used to determine where these border item figures 
>>> should be placed.  You can customize the locator used to place the 
>>> figures where you want.
>>>
>>> Regards,
>>> Cherie
>>>
>>>
>>> Merlin wrote:
>>>> Hi, I am new with GMF and I am trying to get use of the layouts... but 
>>>> somehow I am not able to do it right. What I want to achieve is the 
>>>> following - one figure which children (two types of children) are 
>>>> displayed left and right (according to the type) at the figure rand. I 
>>>> thought using BorderLayout and two compartments for the childes, but I 
>>>> can't get it right. The best I got was by using affixed parent side, 
>>>> bit this solution seems not stable enough - when I resize the figure or 
>>>> add more childes, it is not clear where the new child will appear - on 
>>>> top, bottom or even on the opposite side of the figure - when there are 
>>>> more childes.
>>>>
>>>> This is what I want to achieve:
>>>> _____________
>>>> |             |
>>>> |O           O|
>>>> |O            |
>>>> |             |
>>>> |_____________|
>>>>
>>>> Can someone please post an example how a parent can layout it's 
>>>> childes?
>>>> Some clues at least?
>>>>
>>>> Thanks a lot, I am really stuck for some time...
>>>>
>>>> Merlin
>>>>
>>