Just wondering if anyone has attempted to do math on coordinate pairs to achieve right-aligning of windows.
Currently, I'm working on my maintained spells window to make a right-side of the screen version, which requires two windows to share the same top-right corner.
I'm having some luck with:
Code:
MathIsHard.Size=Parent.MaintainedCompact.Size
MathIsHard.RightBarbie.Size=Location
MathIsHard.RightBarbie.PackSize=A,A
MathIsHard.Size=Size
Which basically takes the location of the maintained window, adds it's size and then subtracts the size of the small maintained window. (The result ends up in MathIsHard.RightBarbie.Size. The calculation isn't instant.) Currently, I'm using an effector to read the value back an instant later but am open for other ideas.
Was just wondering if anyone had tried something similar in the past and had any warnings/tips...
Or, if no one had tried it before, perhaps it'll work as inspiration to some of the geniuses writing interfaces...