iMac display problem
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
iMac display problem
One of my standalone applications shows the following behaviour on an iMac:
The iMac's screen resolution is set to 1440 x 900 and the
substack size is 1200 x 855. I center it in preOpenStack. It shows up too close to the screen top so that a few pixels are UNDER the system caption bar at the top.
When I grab it and move it down a few pixels, its upper border aligns flush with the bottom of the caption bar and displays nicely in full.
I am wondering if maybe the shadow (turned on for this stack) may be the culprit. Is it included in the stack height the object inspector displays or does it get added on?
If that's not it - how can I overcome the demons that screw up the positioning?
TIA,
Kai
The iMac's screen resolution is set to 1440 x 900 and the
substack size is 1200 x 855. I center it in preOpenStack. It shows up too close to the screen top so that a few pixels are UNDER the system caption bar at the top.
When I grab it and move it down a few pixels, its upper border aligns flush with the bottom of the caption bar and displays nicely in full.
I am wondering if maybe the shadow (turned on for this stack) may be the culprit. Is it included in the stack height the object inspector displays or does it get added on?
If that's not it - how can I overcome the demons that screw up the positioning?
TIA,
Kai
I put my window titlebar under the mac Menu, I think the menu bar has some influence on the top of a stack, can't remember. But you can see in the code below I get the window bounds from revs windowboundingrect.
This reads by default on an iMac at my res: 0,50,1436,900
So to get your titlebar under the mac menu, make sure your window top is greater than 50...
There is a gotcha however, when opening a stack by opening rev at the same time Revs tools palette screws up the bounding rect.
So be sure and open rev, then open your stack.
This reads by default on an iMac at my res: 0,50,1436,900
So to get your titlebar under the mac menu, make sure your window top is greater than 50...
There is a gotcha however, when opening a stack by opening rev at the same time Revs tools palette screws up the bounding rect.
So be sure and open rev, then open your stack.
Code: Select all
function windowBound
if systemVersion() contains "Windows" then put "2,2,1280,92" into cRec
else put "2,22,1280,72" into cRec
put the windowboundingrect into WBR
put item 3 of WBR into item 3 of cRec
put item 1 of WBR into item 1 of cRec
set the cardRecMemory of stack (the mainStack of this stack) to cRec
return cRec
end windowBound
Kai,
How are you centering the stack? Can you post your script? Do you have a menubar defined in your substack? Is the situation in a standalone different from the situation in the IDE?
Best,
Mark
How are you centering the stack? Can you post your script? Do you have a menubar defined in your substack? Is the situation in a standalone different from the situation in the IDE?
Best,
Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode
Mark ~
can't tell you about differences between ID and standalone since I am developing on a MacMini and a 21 inch with 1600 x 1200 but deploying on an iMac with 1400 x 900 (among others).
No menubars.
Simple "set the loc of this stack to the screenloc"...
Kai
can't tell you about differences between ID and standalone since I am developing on a MacMini and a 21 inch with 1600 x 1200 but deploying on an iMac with 1400 x 900 (among others).
No menubars.
Simple "set the loc of this stack to the screenloc"...
Kai
Last edited by kpeters on Sat Jul 28, 2007 2:24 am, edited 1 time in total.
Kai,
I noticed smilar behaviour, lately. To fix this problem, adjust the value of the screenloc before setting the loc of the stack.
Best,
Mark
I noticed smilar behaviour, lately. To fix this problem, adjust the value of the screenloc before setting the loc of the stack.
Code: Select all
on centerStack
put the screenLoc into myLoc
if the platform is "MacOS" then
add 20 to item 4 of myLoc
end if
set the loc of stack "blabla" to myLoc
end centerStack
Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode