Zipped sample to demonstrate the problem is included.
A button is on a panel which is 80%x by 80%y.
If I place a button like this
Button1.right = 80%x
and run the script in debug mode, the button1.right is at 90%x as far as a rough measurement tells me, but visually you can see it's at 90% because the right edge of the button is against the right edge of the panel.
If I increase the panel width to 100%, then the button1.right shifts to 80%x where it should be.
I can fix my problem by having a full screen panel in the background and making that the parent of everything else, but can someone explain this to me?
Should I always have a layout which uses the full screen?
A button is on a panel which is 80%x by 80%y.
If I place a button like this
Button1.right = 80%x
and run the script in debug mode, the button1.right is at 90%x as far as a rough measurement tells me, but visually you can see it's at 90% because the right edge of the button is against the right edge of the panel.
If I increase the panel width to 100%, then the button1.right shifts to 80%x where it should be.
I can fix my problem by having a full screen panel in the background and making that the parent of everything else, but can someone explain this to me?
Should I always have a layout which uses the full screen?
Attachments
Last edited: