|
Post by Walt Decker on Dec 18, 2020 13:42:40 GMT -5
So far I have found two problems with compiler parsing. The first is with STYLEBITS.
This problem concerns the built-in globals "Window...".
Consider:
WindowLeftX = 100 WindowLeftY = 100 WindowWidth = 300 WindowHeight = 300
OPEN "Win Test" FOR WINDOW AS #WIN
WindowLeftX = 150 WindowLeftY = 150 WindowWidth = 300 WindowHeight = 300
OPEN "WIN TEST2" FOR WINDOW AS #WIN2
WAIT END
"WIN TEST2" is placed exactly on top of "Win Test."
|
|
|
Post by tsh73 on Dec 18, 2020 14:02:19 GMT -5
There are no
WindowLeftX WindowLeftY
They are
UpperLeftX UpperLeftY
|
|
|
Post by Rod on Dec 18, 2020 14:03:41 GMT -5
UpperLeftX,UpperLeftY are the Liberty variables.
|
|
|
Post by Walt Decker on Dec 18, 2020 14:11:21 GMT -5
My bad. However, the windows should not be located centered on the desktop but should be at 0, 0 of the desk top. That would immediately tell the coder that something is wrong with his placement or the variables he is using.
|
|
|
Post by tsh73 on Dec 18, 2020 14:44:11 GMT -5
This is BASIC. If you do not set variable, it does sensible default. For me putting window about middle of screen if position is not set is sensible. Your opinion is as good as mine.
|
|
|
Post by Walt Decker on Dec 18, 2020 16:23:05 GMT -5
I suggest you delve into the API a bit, CreateWindow() comes to mind.
|
|
|
Post by Carl Gundel on Dec 20, 2020 13:48:29 GMT -5
My bad. However, the windows should not be located centered on the desktop but should be at 0, 0 of the desk top. That would immediately tell the coder that something is wrong with his placement or the variables he is using. I certainly understand the logic of your suggestion, but most programming systems I have seen do not behave this way. Not specifying the window position usually results in a reasonable default location for opening of a window.
|
|