#BUGFIX by stefan
authorStefan Vogel <sv@exept.de>
Wed, 26 Feb 2020 18:06:12 +0100
changeset 4456 e059fcc5f0b3
parent 4455 93ed941728ff
child 4457 8c328436fba9
#BUGFIX by stefan class: WindowBuilder changed: #openAt:withExtent:andType: fix position with vertical multi-monitors
WindowBuilder.st
--- a/WindowBuilder.st	Wed Feb 26 17:18:29 2020 +0100
+++ b/WindowBuilder.st	Wed Feb 26 18:06:12 2020 +0100
@@ -1514,8 +1514,9 @@
                 newOrigin := newOrigin x @ y.
             ].
             usableHeight := windowsDevice usableHeightAt:newOrigin+window extent.
-            (newOrigin y + window height) > usableHeight ifTrue:[
-                y := usableHeight - window height - 20.
+            (newOrigin y + window height) > (monitorBounds top + usableHeight) ifTrue:[
+                "if window doesn't fit, place it at (or near) the top of the monitor"
+                y := monitorBounds top + usableHeight - window height - 20.
                 newOrigin := newOrigin x @ y.
             ].
         ].