How to run an app headless?
Thiago Milczarek Sayão
thiago.sayao at gmail.com
Fri Jun 9 10:40:03 UTC 2023
Hi Johan,
I just wanted to replicate a simple test outside of the testing system to
see why the behavior change in focus is happening on
https://github.com/openjdk/jfx/pull/1110
So the solution Kevin replied to in this email was enough.
The fix for this PR seems to have focused the button that is used in
the MouseEventFirerTest.
testAnchorRight[0], so the
testing values are different (because of the focus decoration shadow).
Before the PR and the change made in
https://bugs.openjdk.org/browse/JDK-8296621 the button does get focused,
but when
the test runs, values are not updated yet.
It's weird because with the PR, focus does get a little bit delayed because
it happens after the window is shown
(makes sense to me to show and then focus).
-- Thiago
Em sex., 9 de jun. de 2023 às 04:29, Johan Vos <johan.vos at gluonhq.com>
escreveu:
> The monocle classes are not included in the default
> distributions/artifact. In our downloads on
> https://gluonhq.com/products/javafx/ we have specific SDK's that include
> the Monocle classes. Note that we currently don't have automated builds for
> Linux x86-64, since we use a devkit compiled from JDK-alike sources, see
> https://github.com/gluonhq/devtoolskit/ for more info. That devkit
> unfortunately doesn't yet compile some of the native classes in monocle.
>
> The usecase where Monocle is used because users want to run an app
> headless is something I see very often. And it works. However, Monocle
> isn't really created for this, as it is more a solution for embedded
> systems.
> I think there is real value in a separate, small, first-class Glass
> platform that works headless (at the same level as gtk/mac/win) and that is
> explicitly targeting running apps in headless mode.
>
> - Johan
>
>
>
>
> On Thu, Jun 8, 2023 at 8:07 PM Thiago Milczarek Sayão <
> thiago.sayao at gmail.com> wrote:
>
>> Hi,
>>
>> I'm building javafx with:
>> ./gradlew -PincludeMonocle build
>>
>> And trying to test with:
>> java @/home/tsayao/jfx/build/run.args -Dglass.platform=Monocle
>> -Dmonocle.platform=Headless -Dprism.order=sw WindowTest.java
>>
>> But it seems monocle was not included:
>> java.lang.ClassNotFoundException:
>> com.sun.glass.ui.monocle.MonoclePlatformFactory
>>
>> Any obvious mistake?
>>
>> -- Thiago
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/openjfx-dev/attachments/20230609/483628d4/attachment.htm>
More information about the openjfx-dev
mailing list