Window decorations and the effective rect issue

Paul Dupuis paul at researchware.com
Wed Sep 9 14:58:51 EDT 2015


On 9/9/2015 2:32 PM, Richard Gaskin wrote:
> Paul Dupuis wrote:
> > However, I have run into a puzzler. Under Windows 8 (and Win 7) when I
> > set the effective rect of a stack to 0,0,x,y or set the effective
> > topLeft of a stack to 0,0, that stack is NOT taking into account the
> > wider window borders of Windows 7 and 8 and is positioning the stack
> > with part of its borders off screen - it is like the stack thinks it's
> > window borders were the thinner ones back under Windows 2000 or XP!
> >
> > This only occur with old stacks in the application - i.e. stacks
> > originally migrated from HyperCard > SuperCard > Metacard >Revolution.
> > If I create a new "Untitled 1" substack in the old legacy mainstack
> > and set it's effective topLeft to 0,0, it renders exactly as expected.
>
> On Ubuntu difference there is a meaningless (though seemingly
> non-random) difference between a stack's "rect" and its "effective rect":
> <http://quality.runrev.com/show_bug.cgi?id=15097>
>
> Maybe whatever made "effective rect" broken on Linux is related to
> what you're seeing in Windows?
>
> Possibly not, though:  the Linux bug is evident with all stacks, old
> or new.
>
Richard,

Thanks for the tip on the bug entry. It led me to try the same message
box test. In this case 'put the effective rect of stack "hrMenubar" &&
the rect of stack "hrMenubar" returns numbers that are not nonsense:
0,0,1366,59 3,26,1363,56. It does illustrate that, even though it is
running under Windows 8, Livecode 6.7.6 thinks the border is only 3px!
For contrast, the same test in a new Untitled substack in same mainstack
as the "hrMenubar substack, produces 12,138,428,577 20,169,420,569 which
has the correct Windows 8 border width of 8px.

I think Mark is probably right, it may be some internal property set as
part of the imports of the stacks. I'll try to strip it down to just a
single substack to illustrate the issue and send it to LiveCode.

Thanks again,




More information about the use-livecode mailing list