Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Logical coordinates returned by JAB API are different from physical coordinates when DPI changes #62

Open
discovery-131794 opened this issue Aug 13, 2022 · 1 comment
Labels
bug Something isn't working

Comments

@discovery-131794
Copy link

discovery-131794 commented Aug 13, 2022

Hi @gaozhao1989 ,
Sometimes when display DPI changes, the logical coordinates returned by JAB API are different from physical coordinates. And the reason is that the java application is not "PROCESS_PER_MONITOR_DPI_AWARE".
When using simulate click, we need physical coordinates to locate the element, So I think we need to convert logical coordinates to physical coordinates by calling win32 function "LogicalToPhysicalPointForPerMonitorDPI".

@gaozhao1989
Copy link
Owner

Hi @discovery-131794 ,

Thanks for your feedback on this. Let met check and if this can be work

@gaozhao1989 gaozhao1989 added the bug Something isn't working label Sep 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants