<div dir="ltr">Hi,<br><div><br></div><div>JavaFX allows setting the stage's width, height, and position (X, Y) when it is maximized or in fullscreen mode, without ignoring the values or throwing an exception.</div><div>  </div><div>The current documentation states the following regarding X, Y, Width, Height, and sizeToScene:</div><div><div class="gmail-text-base gmail-my-auto gmail-mx-auto gmail-py-5 gmail-px-6"><div class="gmail-mx-auto gmail-flex gmail-flex-1 gmail-text-base gmail-gap-4 gmail-md:gap-5 gmail-lg:gap-6 gmail-md:max-w-3xl gmail-lg:max-w-[40rem] gmail-xl:max-w-[48rem] gmail-group/turn-messages gmail-focus-visible:outline-hidden" tabindex="-1"><div class="gmail-group/conversation-turn gmail-relative gmail-flex gmail-w-full gmail-min-w-0 gmail-flex-col gmail-agent-turn gmail-@xs/thread:px-0 gmail-@sm/thread:px-1.5 gmail-@md/thread:px-4"><div class="gmail-relative gmail-flex-col gmail-gap-1 gmail-md:gap-3"><div class="gmail-flex gmail-max-w-full gmail-flex-col gmail-grow"><div dir="auto" class="gmail-min-h-8 gmail-text-message gmail-relative gmail-flex gmail-w-full gmail-flex-col gmail-items-end gmail-gap-2 gmail-text-start gmail-break-words gmail-whitespace-normal gmail-[.text-message+&]:mt-5"><div class="gmail-flex gmail-w-full gmail-flex-col gmail-gap-1 empty:hidden gmail-first:pt-[3px]"><div class="gmail-markdown gmail-prose gmail-dark:prose-invert gmail-w-full gmail-break-words gmail-dark"><p class="gmail-"><span style="color:rgb(71,71,71);font-family:"DejaVu Serif",Georgia,"Times New Roman",Times,serif;font-size:14px">Changing this attribute will not visually affect a </span><code style="font-family:"DejaVu Sans Mono",monospace;font-size:14px;padding-top:4px;margin-top:8px;line-height:1.4em;color:rgb(71,71,71)">Stage</code><span style="color:rgb(71,71,71);font-family:"DejaVu Serif",Georgia,"Times New Roman",Times,serif;font-size:14px"> while </span><code style="font-family:"DejaVu Sans Mono",monospace;font-size:14px;padding-top:4px;margin-top:8px;line-height:1.4em;color:rgb(71,71,71)">fullScreen</code><span style="color:rgb(71,71,71);font-family:"DejaVu Serif",Georgia,"Times New Roman",Times,serif;font-size:14px"> is true, but will be honored by the </span><code style="font-family:"DejaVu Sans Mono",monospace;font-size:14px;padding-top:4px;margin-top:8px;line-height:1.4em;color:rgb(71,71,71)">Stage</code><span style="color:rgb(71,71,71);font-family:"DejaVu Serif",Georgia,"Times New Roman",Times,serif;font-size:14px"> once </span><code style="font-family:"DejaVu Sans Mono",monospace;font-size:14px;padding-top:4px;margin-top:8px;line-height:1.4em;color:rgb(71,71,71)">fullScreen</code><span style="color:rgb(71,71,71);font-family:"DejaVu Serif",Georgia,"Times New Roman",Times,serif;font-size:14px"> becomes false. This value includes any and all decorations which may be added by the Operating System such as resizable frame handles. Typical applications will set the </span><a href="https://docs.oracle.com/javase/8/javafx/api/javafx/scene/Scene.html" title="class in javafx.scene" style="text-decoration-line:none;color:rgb(74,103,130);font-family:"DejaVu Serif",Georgia,"Times New Roman",Times,serif;font-size:14px"><code style="font-family:"DejaVu Sans Mono",monospace;padding-top:4px;margin-top:8px;line-height:1.4em">Scene</code></a><span style="color:rgb(71,71,71);font-family:"DejaVu Serif",Georgia,"Times New Roman",Times,serif;font-size:14px"> width instead.</span></p></div></div></div></div></div></div></div></div></div><div>It doesn’t mention anything about the maximized state, which I believe is a similar case.</div><div><div>  </div></div><div>Martin did some tests on Mac and Windows when resizing while Maximized, and it seems inconsistent between platforms.</div><div><br></div><div><a href="https://github.com/openjdk/jfx/pull/1748#issuecomment-2764224914">https://github.com/openjdk/jfx/pull/1748#issuecomment-2764224914</a></div><div><br></div><div>

On Linux, when setting the width or height while in fullscreen mode, GTK simply ignores the request and maintains the size the window had before entering fullscreen.

</div><div>I tried to work around this to align with the documentation, but it’s harder than it looks due to the asynchronous nature of X11. </div><div><br></div><div>Depending on how different platforms behave, it might be worth revisiting the documentation and aligning behaviors where possible to ensure consistency.  </div><div><br></div><div>-- Thiago.</div></div>