8211999: Window positioning bugs due to overlapping GraphicsDevice bounds (Windows/HiDPI) #375
Old review request:
(Note: the fix use API available since Windows 8.1: WM_DPICHANGED, but it should be fine for
This formula makes the next configuration completely broken:
Since the screens are overlapped we cannot be sure how to translate the user's space
The proposed solution for this bug is to change the formulas to these:
In other words, we should not transform the X and Y coordinates of the screen(the top/left corner). This will
Before the fix:
After the fix(only the part appeared on this screen should be scaled)
Note that these new formulas are applicable only for the coordinates on the screen such as X and Y.
The main changes for the problem above are:
But it does not work well if the smaller part of the top-level window is located on one screen1(DPI=100) but
As a fix, all HW components will try to use the scale factor of the top-level window, see AwtComponent::GetScreenImOn:
Probably there are some other bugs and possibility to cleanups, but I would like to do that in separate issues.
The mach5 is also green.
PS: hope I did not forget some important information, will send it later if any.
The text was updated successfully, but these errors were encountered:
@mrserb The following labels will be automatically applied to this pull request:
When this pull request is ready to be reviewed, an RFR email will be sent to the corresponding mailing lists. If you would like to change these labels, use the
You found this bug https://bugs.openjdk.java.net/browse/JDK-8249164 the case when the window is split across two screens with different DPI are not properly supported before and after the fix, in both cases, there are values which break it. But I need to confirm that, please provide exact display resolution/java pipeline/and scales.
@mrserb This change now passes all automated pre-integration checks.
After integration, the commit message for the final commit will be:
At the time when this comment was updated there had been 3 new commits pushed to the
Please see this link for an up-to-date comparison between the source branch of this pull request and the
@mrserb Since your change was applied there have been 4 commits pushed to the
Your commit was automatically rebased without conflicts.
Pushed as commit be63525.
…unds (Windows/HiDPI) Reviewed-by: kizune, aivanov