XWidgetSoft Forum
https://www.bbs.xwidget.com/

Align Ordering Problem
https://www.bbs.xwidget.com/viewtopic.php?f=8&t=3191
Page 1 of 1

Author:  Sooner266 [ June 4th, 2013, 8:22 pm ]
Post subject:  Align Ordering Problem

I'm making a widget with several sections, each grouped in a layer, that can be toggled on and off separately. I'm using the align section set to MostTop or Top to make them stay as far toward the top of the widget as possible. However, the order of the layers seems to change randomly. How does the alignment with MostTop and Top choose which layer will be above another? Is there any way to define an order that it will keep? I've tried different combinations of MostTop and Top without success.

In case I didn't explain that very well, I attached a little widget to demonstrate my problem. Press the buttons to toggle different layers on and off, and notice how sometimes it doesn't put them back in order.

Thanks.

Attachments:
AlignTest.XWidgetPkg [6.6 KiB]
Downloaded 211 times

Author:  qiancang [ June 4th, 2013, 9:00 pm ]
Post subject:  Re: Align Ordering Problem

Hi,this is a bug of XWidget's align function, components would be out of order sometimes.
I use slidepanel to achieve the same effect.

Attachments:
AlignTest.XWidgetPkg [6.67 KiB]
Downloaded 201 times

Author:  Sooner266 [ June 4th, 2013, 9:11 pm ]
Post subject:  Re: Align Ordering Problem

Thanks very much for the quick reply and example.
Ah, I see, interesting workaround. A little messy but it definitely works. I guess I'll use that until the bug is fixed.

Thanks again!

Author:  digigamer [ June 4th, 2013, 10:52 pm ]
Post subject:  Re: Align Ordering Problem

qiancang wrote:
Hi,this is a bug of XWidget's align function, components would be out of order sometimes.
I use slidepanel to achieve the same effect.


This is the bug of the designer, not xwidget.
Manually reorder the contents of the main.xul with a text editor. The last item is rendered first. Controls are placed in bottom to top order they are declared.

Author:  Sooner266 [ June 5th, 2013, 7:56 am ]
Post subject:  Re: Align Ordering Problem

XWDesigner already writes layers in the .xul file in reverse order, and it's showing the weird behavior. If I reverse it in the .xul file manually, it just starts in random order, and wants to put them in reverse order when you toggle them repeatedly, and still shows some random behavior. That sure sounds like a bug in XWidget itself to me.

Page 1 of 1 All times are UTC - 8 hours
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/