Negative coordinates do not work on Linux(Gnome), but on Windows

Dirk Lemmermann dlemmermann at gmail.com
Thu Oct 13 10:11:04 UTC 2022


Should someone want to look into this issue then I can recommend using the ScreensView in the GemsFX project for debugging purposes. You can see it here: https://www.youtube.com/watch?v=Kv7jo9fF9tc <https://www.youtube.com/watch?v=Kv7jo9fF9tc>

Dirk

> On 11 Oct 2022, at 23:21, Tom Schindl <tom.schindl at bestsolution.at> wrote:
> 
> As I have implemented something like this for Windows I can confirm that there you also need to use native win32 APIs for the move because only then you eg get docking and snapping correct which does not work if you use the FX-Stage APIs!
> 
> For OS-X I‘d have to look up the code because I can not member it.
> 
> Tom
> 
> Von meinem iPhone gesendet
> 
>> Am 11.10.2022 um 22:23 schrieb Thiago Milczarek Sayão <thiago.sayao at gmail.com>:
>> 
>> 
>> Hi,
>> 
>> The correct way to implement this on Linux would be:
>> 
>> https://specifications.freedesktop.org/wm-spec/wm-spec-1.4.html <https://specifications.freedesktop.org/wm-spec/wm-spec-1.4.html>
>> _NET_WM_MOVERESIZE
>> 
>> We would need to implement a specific API to do this.
>> 
>> This specification is to tell the Window Manager: Start a window move operation.
>> 
>> -- Thiago.
>> 
>> Em ter., 11 de out. de 2022 às 13:52, Thiago Milczarek Sayão <thiago.sayao at gmail.com <mailto:thiago.sayao at gmail.com>> escreveu:
>> Hi Dirk,
>> 
>> I have tried your example, it seems the window manager is denying the application from being moved into negative coordinates, unless using the window manager itself.
>> 
>> It might be due to security reasons, but that's just me wondering.
>> 
>> It might have a different behaviour on other window managers (modern gnome uses mutter).
>> 
>> 
>> 
>> Em ter., 11 de out. de 2022 às 12:37, Dirk Lemmermann <dlemmermann at gmail.com <mailto:dlemmermann at gmail.com>> escreveu:
>> I just ran into this issue: https://bugs.openjdk.org/browse/JDK-8222794 <https://bugs.openjdk.org/browse/JDK-8222794>
>> 
>> The ticket is closed and marked as “not an issue”. Unfortunately there is no description why this is not an issue.
>> 
>> In our app we removed the window decorations of our main stage and use a custom design. For this to work we also have to reimplement the moving / dragging around of the window but with the limitation expressed by the ticket this seems to be impossible.
>> 
>> I don’t really see a good reason why programmatically setting the x- or y-coordinate should not result in the window being shown on a different screen. However, I am open for being told why that is :-)
>> 
>> Dirk
>> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/openjfx-dev/attachments/20221013/f1440ca9/attachment.htm>


More information about the openjfx-dev mailing list