Window rect

Ben Rubinstein benr_mc at
Tue Jul 2 08:54:01 CDT 2002

on 2/7/02 1:30 am, Sarah at sarahr at wrote:

> I haven't looked into this much, but if I understand you correctly, the
> rect of the stack (or window) only gives you the rect of the section
> INSIDE all the window decorations.  If this is not enough, can you just
> work out what the border & window title sizes are (presumably they vary
> between platforms) and apply them to the window rect yourself. It isn't
> an elegant solution but it should work.

Remembering unfortunately that these can change on a single platform - eg on
Windows a user can adjust the titlebar height to a nominal value anywhere in
the range 15-100 pixels (on the fly, while your stack is running).  Of
course the vast majority of users never adjust these settings - but if you
really need to get it right, you'll have to some way to find these values,
you can't hardwire them.

Does anyone know if they're stored in the registry?  Otherwise, presumably
an external could take a Rev window id and return the actual rect it
  Ben Rubinstein               |  Email: benr_mc at
  Cognitive Applications Ltd   |  Phone: +44 (0)1273-821600        |  Fax  : +44 (0)1273-728866

More information about the use-livecode mailing list