FlowLayout class, modifications.

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
13 messages Options
Reply | Threaded
Open this post in threaded view
|

FlowLayout class, modifications.

Pierre Chanson

Hello,

To FlowLayout users, I am modifying RTAbstractFlowLayout and subclasses for Roassal2 and I would appreciate to hear your opinions on some modifications:


First I changed the Flow layout maxWith value at the initialization to take account of the global area of elements and gapsize. (see screen1,  RTObject https://www.dropbox.com/s/7hlsmiklqefb7cn/screen1.png?dl=0 )

Then I fixed the align Bottom, so the elements do not collide each others. The only remaining difference is the first line is the less filled. It is due to creating the layout from bottom to up. (The order of elements still remain the same from the left top corner to the right down.) (see screen2 https://www.dropbox.com/s/7kr3gy4e3gwvvgl/screen2.png?dl=0) Does this difference have any importance ?


Finally i am adding a HorizontalFlow layout. (right queued or left queued, using align bottom) See the screen3 (https://www.dropbox.com/s/nmgq8cg0f4p3m6u/screen3.png?dl=0), the alignement is vertical, do you think it’s usefull ? Should I make a horizontal alignement (In that case it would only be a increasement of maxWidth…) ?

Thank you !

Pierre Chanson

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: FlowLayout class, modifications.

Tudor Girba-2
Hi,

Nice work.

The only thing I do not quite understand is why the first line of the bottom aligned flow layout is shorter. The result should remain the same, only there should be an extra step to move at the end.

Also, if you are at it, would it be possible to produce a center aligned version?

Cheers,
Doru


On Wed, Oct 22, 2014 at 10:09 PM, Pierre CHANSON <[hidden email]> wrote:

Hello,

To FlowLayout users, I am modifying RTAbstractFlowLayout and subclasses for Roassal2 and I would appreciate to hear your opinions on some modifications:


First I changed the Flow layout maxWith value at the initialization to take account of the global area of elements and gapsize. (see screen1,  RTObject https://www.dropbox.com/s/7hlsmiklqefb7cn/screen1.png?dl=0 )

Then I fixed the align Bottom, so the elements do not collide each others. The only remaining difference is the first line is the less filled. It is due to creating the layout from bottom to up. (The order of elements still remain the same from the left top corner to the right down.) (see screen2 https://www.dropbox.com/s/7kr3gy4e3gwvvgl/screen2.png?dl=0) Does this difference have any importance ?


Finally i am adding a HorizontalFlow layout. (right queued or left queued, using align bottom) See the screen3 (https://www.dropbox.com/s/nmgq8cg0f4p3m6u/screen3.png?dl=0), the alignement is vertical, do you think it’s usefull ? Should I make a horizontal alignement (In that case it would only be a increasement of maxWidth…) ?

Thank you !

Pierre Chanson

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev




--

"Every thing has its own flow"

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: FlowLayout class, modifications.

Pierre Chanson
hello !

thank you Doru, the thing is the max width is not based on number of elements but their size in pixel so we can't predict what will be the elements (and so the biggest element height) in the next line so, as a reversed align top, I put the elements from the bottom right corner to the top left. (Just put the elements in the reverse order) The last line is the fist one and less filled. But there is certainly a simple trick to fix this. What about the extra step to move at the end ?

yes I will take a look at the center aligned version, I thought this one was already working but with a closer look, it's not :)

Pierre


_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: FlowLayout class, modifications.

Tudor Girba-2
Hi,

> On 23 Oct 2014, at 15:26, Pierre CHANSON <[hidden email]> wrote:
>
> hello !
>
> thank you Doru, the thing is the max width is not based on number of elements but their size in pixel so we can't predict what will be the elements (and so the biggest element height) in the next line so, as a reversed align top, I put the elements from the bottom right corner to the top left. (Just put the elements in the reverse order) The last line is the fist one and less filled. But there is certainly a simple trick to fix this. What about the extra step to move at the end ?

Exactly :). We need an extra step at end to shift the smaller boxes.

> yes I will take a look at the center aligned version, I thought this one was already working but with a closer look, it's not :)

Thanks!

Doru


> Pierre
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: FlowLayout class, modifications.

abergel
In reply to this post by Pierre Chanson
Hi Pierre!

I agree with Doru, the layout should remain the same. Maybe we could have a look at your algorithm next week, but it is doable.

Alexandre


> Le 23-10-2014 à 10:26, Pierre CHANSON <[hidden email]> a écrit :
>
> hello !
>
> thank you Doru, the thing is the max width is not based on number of elements but their size in pixel so we can't predict what will be the elements (and so the biggest element height) in the next line so, as a reversed align top, I put the elements from the bottom right corner to the top left. (Just put the elements in the reverse order) The last line is the fist one and less filled. But there is certainly a simple trick to fix this. What about the extra step to move at the end ?
>
> yes I will take a look at the center aligned version, I thought this one was already working but with a closer look, it's not :)
>
> Pierre
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: FlowLayout class, modifications.

Pierre Chanson
I am sorry Doru but in fact I did not well understood what you meant by "shift the smaller boxes",

But I finally changed the solution, as another problem came with this first solution: as I put the last element at 0:0 position then the positions to the fist element are in negative x and y.

So now I browse the elements in the normal order, I just pre-compute the next line to get the next line biggest element height before creating the line. Not a miracle solution but it works.

thanks !!

pierre

2014-10-23 15:32 GMT-03:00 Alexandre Bergel <[hidden email]>:
Hi Pierre!

I agree with Doru, the layout should remain the same. Maybe we could have a look at your algorithm next week, but it is doable.

Alexandre


> Le 23-10-2014 à 10:26, Pierre CHANSON <[hidden email]> a écrit :
>
> hello !
>
> thank you Doru, the thing is the max width is not based on number of elements but their size in pixel so we can't predict what will be the elements (and so the biggest element height) in the next line so, as a reversed align top, I put the elements from the bottom right corner to the top left. (Just put the elements in the reverse order) The last line is the fist one and less filled. But there is certainly a simple trick to fix this. What about the extra step to move at the end ?
>
> yes I will take a look at the center aligned version, I thought this one was already working but with a closer look, it's not :)
>
> Pierre
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev


_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: FlowLayout class, modifications.

Tudor Girba-2
Hi Pierre,

You pretty much doing the same thing as I said only in the reverse order. My idea was to do a normal flow layout with top alignment and traverse again each line and shift the nodes to the bottom.

But, your algorithm has about the same complexity, so it should be quite fine.

Cheers,
Doru



On Thu, Oct 23, 2014 at 8:38 PM, Pierre CHANSON <[hidden email]> wrote:
I am sorry Doru but in fact I did not well understood what you meant by "shift the smaller boxes",

But I finally changed the solution, as another problem came with this first solution: as I put the last element at 0:0 position then the positions to the fist element are in negative x and y.

So now I browse the elements in the normal order, I just pre-compute the next line to get the next line biggest element height before creating the line. Not a miracle solution but it works.

thanks !!

pierre

2014-10-23 15:32 GMT-03:00 Alexandre Bergel <[hidden email]>:

Hi Pierre!

I agree with Doru, the layout should remain the same. Maybe we could have a look at your algorithm next week, but it is doable.

Alexandre


> Le 23-10-2014 à 10:26, Pierre CHANSON <[hidden email]> a écrit :
>
> hello !
>
> thank you Doru, the thing is the max width is not based on number of elements but their size in pixel so we can't predict what will be the elements (and so the biggest element height) in the next line so, as a reversed align top, I put the elements from the bottom right corner to the top left. (Just put the elements in the reverse order) The last line is the fist one and less filled. But there is certainly a simple trick to fix this. What about the extra step to move at the end ?
>
> yes I will take a look at the center aligned version, I thought this one was already working but with a closer look, it's not :)
>
> Pierre
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev


_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev




--

"Every thing has its own flow"

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: FlowLayout class, modifications.

Pierre Chanson
hi Doru,

haa yes I understand now ! Yes it should be the same complexity as we traverse
each line twice =).

Thanks !!

Pierre

2014-10-23 16:04 GMT-03:00 Tudor Girba <[hidden email]>:
Hi Pierre,

You pretty much doing the same thing as I said only in the reverse order. My idea was to do a normal flow layout with top alignment and traverse again each line and shift the nodes to the bottom.

But, your algorithm has about the same complexity, so it should be quite fine.

Cheers,
Doru



On Thu, Oct 23, 2014 at 8:38 PM, Pierre CHANSON <[hidden email]> wrote:
I am sorry Doru but in fact I did not well understood what you meant by "shift the smaller boxes",

But I finally changed the solution, as another problem came with this first solution: as I put the last element at 0:0 position then the positions to the fist element are in negative x and y.

So now I browse the elements in the normal order, I just pre-compute the next line to get the next line biggest element height before creating the line. Not a miracle solution but it works.

thanks !!

pierre

2014-10-23 15:32 GMT-03:00 Alexandre Bergel <[hidden email]>:

Hi Pierre!

I agree with Doru, the layout should remain the same. Maybe we could have a look at your algorithm next week, but it is doable.

Alexandre


> Le 23-10-2014 à 10:26, Pierre CHANSON <[hidden email]> a écrit :
>
> hello !
>
> thank you Doru, the thing is the max width is not based on number of elements but their size in pixel so we can't predict what will be the elements (and so the biggest element height) in the next line so, as a reversed align top, I put the elements from the bottom right corner to the top left. (Just put the elements in the reverse order) The last line is the fist one and less filled. But there is certainly a simple trick to fix this. What about the extra step to move at the end ?
>
> yes I will take a look at the center aligned version, I thought this one was already working but with a closer look, it's not :)
>
> Pierre
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev


_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev




--

"Every thing has its own flow"

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev



_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: FlowLayout class, modifications.

Pierre Chanson

2014-10-23 16:37 GMT-03:00 Pierre CHANSON <[hidden email]>:
hi Doru,

haa yes I understand now ! Yes it should be the same complexity as we traverse
each line twice =).

Thanks !!

Pierre

2014-10-23 16:04 GMT-03:00 Tudor Girba <[hidden email]>:

Hi Pierre,

You pretty much doing the same thing as I said only in the reverse order. My idea was to do a normal flow layout with top alignment and traverse again each line and shift the nodes to the bottom.

But, your algorithm has about the same complexity, so it should be quite fine.

Cheers,
Doru



On Thu, Oct 23, 2014 at 8:38 PM, Pierre CHANSON <[hidden email]> wrote:
I am sorry Doru but in fact I did not well understood what you meant by "shift the smaller boxes",

But I finally changed the solution, as another problem came with this first solution: as I put the last element at 0:0 position then the positions to the fist element are in negative x and y.

So now I browse the elements in the normal order, I just pre-compute the next line to get the next line biggest element height before creating the line. Not a miracle solution but it works.

thanks !!

pierre

2014-10-23 15:32 GMT-03:00 Alexandre Bergel <[hidden email]>:

Hi Pierre!

I agree with Doru, the layout should remain the same. Maybe we could have a look at your algorithm next week, but it is doable.

Alexandre


> Le 23-10-2014 à 10:26, Pierre CHANSON <[hidden email]> a écrit :
>
> hello !
>
> thank you Doru, the thing is the max width is not based on number of elements but their size in pixel so we can't predict what will be the elements (and so the biggest element height) in the next line so, as a reversed align top, I put the elements from the bottom right corner to the top left. (Just put the elements in the reverse order) The last line is the fist one and less filled. But there is certainly a simple trick to fix this. What about the extra step to move at the end ?
>
> yes I will take a look at the center aligned version, I thought this one was already working but with a closer look, it's not :)
>
> Pierre
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev


_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev




--

"Every thing has its own flow"

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev




_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: FlowLayout class, modifications.

Tudor Girba-2
Awesome. Where is the code?

Doru

On Fri, Oct 24, 2014 at 5:11 PM, Pierre CHANSON <[hidden email]> wrote:

2014-10-23 16:37 GMT-03:00 Pierre CHANSON <[hidden email]>:

hi Doru,

haa yes I understand now ! Yes it should be the same complexity as we traverse
each line twice =).

Thanks !!

Pierre

2014-10-23 16:04 GMT-03:00 Tudor Girba <[hidden email]>:

Hi Pierre,

You pretty much doing the same thing as I said only in the reverse order. My idea was to do a normal flow layout with top alignment and traverse again each line and shift the nodes to the bottom.

But, your algorithm has about the same complexity, so it should be quite fine.

Cheers,
Doru



On Thu, Oct 23, 2014 at 8:38 PM, Pierre CHANSON <[hidden email]> wrote:
I am sorry Doru but in fact I did not well understood what you meant by "shift the smaller boxes",

But I finally changed the solution, as another problem came with this first solution: as I put the last element at 0:0 position then the positions to the fist element are in negative x and y.

So now I browse the elements in the normal order, I just pre-compute the next line to get the next line biggest element height before creating the line. Not a miracle solution but it works.

thanks !!

pierre

2014-10-23 15:32 GMT-03:00 Alexandre Bergel <[hidden email]>:

Hi Pierre!

I agree with Doru, the layout should remain the same. Maybe we could have a look at your algorithm next week, but it is doable.

Alexandre


> Le 23-10-2014 à 10:26, Pierre CHANSON <[hidden email]> a écrit :
>
> hello !
>
> thank you Doru, the thing is the max width is not based on number of elements but their size in pixel so we can't predict what will be the elements (and so the biggest element height) in the next line so, as a reversed align top, I put the elements from the bottom right corner to the top left. (Just put the elements in the reverse order) The last line is the fist one and less filled. But there is certainly a simple trick to fix this. What about the extra step to move at the end ?
>
> yes I will take a look at the center aligned version, I thought this one was already working but with a closer look, it's not :)
>
> Pierre
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev


_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev




--

"Every thing has its own flow"

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev




_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev




--

"Every thing has its own flow"

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: FlowLayout class, modifications.

Pierre Chanson
In my image :D.

But I need to refactor it I think, because there is now much code for each self isAlignTop... And I also need to see to pass the tests because the positions are a little bit different from the test expected positions as the test was based on the old flow layout version.

(moreover i'm also working on a new HorizontalFlow class which needs some fix)

Pierre

2014-10-24 12:13 GMT-03:00 Tudor Girba <[hidden email]>:
Awesome. Where is the code?

Doru

On Fri, Oct 24, 2014 at 5:11 PM, Pierre CHANSON <[hidden email]> wrote:

2014-10-23 16:37 GMT-03:00 Pierre CHANSON <[hidden email]>:

hi Doru,

haa yes I understand now ! Yes it should be the same complexity as we traverse
each line twice =).

Thanks !!

Pierre

2014-10-23 16:04 GMT-03:00 Tudor Girba <[hidden email]>:

Hi Pierre,

You pretty much doing the same thing as I said only in the reverse order. My idea was to do a normal flow layout with top alignment and traverse again each line and shift the nodes to the bottom.

But, your algorithm has about the same complexity, so it should be quite fine.

Cheers,
Doru



On Thu, Oct 23, 2014 at 8:38 PM, Pierre CHANSON <[hidden email]> wrote:
I am sorry Doru but in fact I did not well understood what you meant by "shift the smaller boxes",

But I finally changed the solution, as another problem came with this first solution: as I put the last element at 0:0 position then the positions to the fist element are in negative x and y.

So now I browse the elements in the normal order, I just pre-compute the next line to get the next line biggest element height before creating the line. Not a miracle solution but it works.

thanks !!

pierre

2014-10-23 15:32 GMT-03:00 Alexandre Bergel <[hidden email]>:

Hi Pierre!

I agree with Doru, the layout should remain the same. Maybe we could have a look at your algorithm next week, but it is doable.

Alexandre


> Le 23-10-2014 à 10:26, Pierre CHANSON <[hidden email]> a écrit :
>
> hello !
>
> thank you Doru, the thing is the max width is not based on number of elements but their size in pixel so we can't predict what will be the elements (and so the biggest element height) in the next line so, as a reversed align top, I put the elements from the bottom right corner to the top left. (Just put the elements in the reverse order) The last line is the fist one and less filled. But there is certainly a simple trick to fix this. What about the extra step to move at the end ?
>
> yes I will take a look at the center aligned version, I thought this one was already working but with a closer look, it's not :)
>
> Pierre
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev


_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev




--

"Every thing has its own flow"

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev




_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev




--

"Every thing has its own flow"

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev



_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: FlowLayout class, modifications.

abergel
In reply to this post by Tudor Girba-2
We have included this yesterday.
The version of RTFlowLayout seems much better now than before. It is usable :-)

Cheers,
Alexandre


> On Oct 24, 2014, at 12:13 PM, Tudor Girba <[hidden email]> wrote:
>
> Awesome. Where is the code?
>
> Doru
>
> On Fri, Oct 24, 2014 at 5:11 PM, Pierre CHANSON <[hidden email]> wrote:
> hello,
>
> just a small up,
>
> align Top: https://www.dropbox.com/s/7hlsmiklqefb7cn/screen1.png?dl=0
>
> align Bottom: https://www.dropbox.com/s/7kr3gy4e3gwvvgl/screen2.png?dl=0
>
> align Center: https://www.dropbox.com/s/nmgq8cg0f4p3m6u/screen3.png?dl=0
>
> cheers,
> Pierre
>
> 2014-10-23 16:37 GMT-03:00 Pierre CHANSON <[hidden email]>:
>
> hi Doru,
>
> haa yes I understand now ! Yes it should be the same complexity as we traverse
> each line twice =).
>
> Thanks !!
>
> Pierre
>
> 2014-10-23 16:04 GMT-03:00 Tudor Girba <[hidden email]>:
>
> Hi Pierre,
>
> You pretty much doing the same thing as I said only in the reverse order. My idea was to do a normal flow layout with top alignment and traverse again each line and shift the nodes to the bottom.
>
> But, your algorithm has about the same complexity, so it should be quite fine.
>
> Cheers,
> Doru
>
>
>
> On Thu, Oct 23, 2014 at 8:38 PM, Pierre CHANSON <[hidden email]> wrote:
> I am sorry Doru but in fact I did not well understood what you meant by "shift the smaller boxes",
>
> But I finally changed the solution, as another problem came with this first solution: as I put the last element at 0:0 position then the positions to the fist element are in negative x and y.
>
> So now I browse the elements in the normal order, I just pre-compute the next line to get the next line biggest element height before creating the line. Not a miracle solution but it works.
>
> thanks !!
>
> pierre
>
> 2014-10-23 15:32 GMT-03:00 Alexandre Bergel <[hidden email]>:
>
> Hi Pierre!
>
> I agree with Doru, the layout should remain the same. Maybe we could have a look at your algorithm next week, but it is doable.
>
> Alexandre
>
>
> > Le 23-10-2014 à 10:26, Pierre CHANSON <[hidden email]> a écrit :
> >
> > hello !
> >
> > thank you Doru, the thing is the max width is not based on number of elements but their size in pixel so we can't predict what will be the elements (and so the biggest element height) in the next line so, as a reversed align top, I put the elements from the bottom right corner to the top left. (Just put the elements in the reverse order) The last line is the fist one and less filled. But there is certainly a simple trick to fix this. What about the extra step to move at the end ?
> >
> > yes I will take a look at the center aligned version, I thought this one was already working but with a closer look, it's not :)
> >
> > Pierre
> >
> > _______________________________________________
> > Moose-dev mailing list
> > [hidden email]
> > https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>
>
>
>
> --
> www.tudorgirba.com
>
> "Every thing has its own flow"
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>
>
>
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>
>
>
>
> --
> www.tudorgirba.com
>
> "Every thing has its own flow"
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev

--
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel  http://www.bergel.eu
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.




_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: FlowLayout class, modifications.

Tudor Girba-2
Great.

Doru

On Tue, Oct 28, 2014 at 1:28 PM, Alexandre Bergel <[hidden email]> wrote:
We have included this yesterday.
The version of RTFlowLayout seems much better now than before. It is usable :-)

Cheers,
Alexandre


> On Oct 24, 2014, at 12:13 PM, Tudor Girba <[hidden email]> wrote:
>
> Awesome. Where is the code?
>
> Doru
>
> On Fri, Oct 24, 2014 at 5:11 PM, Pierre CHANSON <[hidden email]> wrote:
> hello,
>
> just a small up,
>
> align Top: https://www.dropbox.com/s/7hlsmiklqefb7cn/screen1.png?dl=0
>
> align Bottom: https://www.dropbox.com/s/7kr3gy4e3gwvvgl/screen2.png?dl=0
>
> align Center: https://www.dropbox.com/s/nmgq8cg0f4p3m6u/screen3.png?dl=0
>
> cheers,
> Pierre
>
> 2014-10-23 16:37 GMT-03:00 Pierre CHANSON <[hidden email]>:
>
> hi Doru,
>
> haa yes I understand now ! Yes it should be the same complexity as we traverse
> each line twice =).
>
> Thanks !!
>
> Pierre
>
> 2014-10-23 16:04 GMT-03:00 Tudor Girba <[hidden email]>:
>
> Hi Pierre,
>
> You pretty much doing the same thing as I said only in the reverse order. My idea was to do a normal flow layout with top alignment and traverse again each line and shift the nodes to the bottom.
>
> But, your algorithm has about the same complexity, so it should be quite fine.
>
> Cheers,
> Doru
>
>
>
> On Thu, Oct 23, 2014 at 8:38 PM, Pierre CHANSON <[hidden email]> wrote:
> I am sorry Doru but in fact I did not well understood what you meant by "shift the smaller boxes",
>
> But I finally changed the solution, as another problem came with this first solution: as I put the last element at 0:0 position then the positions to the fist element are in negative x and y.
>
> So now I browse the elements in the normal order, I just pre-compute the next line to get the next line biggest element height before creating the line. Not a miracle solution but it works.
>
> thanks !!
>
> pierre
>
> 2014-10-23 15:32 GMT-03:00 Alexandre Bergel <[hidden email]>:
>
> Hi Pierre!
>
> I agree with Doru, the layout should remain the same. Maybe we could have a look at your algorithm next week, but it is doable.
>
> Alexandre
>
>
> > Le 23-10-2014 à 10:26, Pierre CHANSON <[hidden email]> a écrit :
> >
> > hello !
> >
> > thank you Doru, the thing is the max width is not based on number of elements but their size in pixel so we can't predict what will be the elements (and so the biggest element height) in the next line so, as a reversed align top, I put the elements from the bottom right corner to the top left. (Just put the elements in the reverse order) The last line is the fist one and less filled. But there is certainly a simple trick to fix this. What about the extra step to move at the end ?
> >
> > yes I will take a look at the center aligned version, I thought this one was already working but with a closer look, it's not :)
> >
> > Pierre
> >
> > _______________________________________________
> > Moose-dev mailing list
> > [hidden email]
> > https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>
>
>
>
> --
> www.tudorgirba.com
>
> "Every thing has its own flow"
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>
>
>
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>
>
>
>
> --
> www.tudorgirba.com
>
> "Every thing has its own flow"
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev

--
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel  http://www.bergel.eu
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.




_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev



--

"Every thing has its own flow"

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev