Gluon GraalVM console - graalvm-native-image

When compiling to native image and running it now days runs in "javaw" mode.
I would like that the console window to be shown also like when running a Java UI application with "java" command.
How to create a native image so that console window is shown in the background of UI when running it?
Thanks,

Related

create a desktop application passing code from my android application

I have created an android application, but I wanted to know if it can be transformed to a desktop application and what should I do? a small example will suffice
I use koltin as background code any suggestions

How to correctly configure Qt app to launch on wayland platform?

Currently trying to launch a Qt application on a wayland platform, without success. I succeeded to launch other basic apps such as a calculator or a paint sample. But my app get the following error :
QSocketNotifier: Can only be used with threads started with QThread
I can't find the cause of this error. Tried to launch the app with the env variable "qt.qpa.plugin" using the following values :
wayland-egl, wayland, wayland-xcomposite-egl
getting always the same error.
What kind of behavior triggers this error ?

Newbie cannot properly run or debug fresh project using Gluon multi-view with FXML in IntelliJ

I created a brand new Gluon mobile multi view with FXML project in IntelliJ CE 2018.2.1 using the Gluon plugin version 2.7.0 and Gradle 4.10.1
I open the Gradle tool window, Pick Project(root), Tasks, Application, run and I do see the generated application run properly, I believe, though it defaults to a mobile device sized window.
I get this error message:
SEVERE: javafx.platform is not defined. Desktop will be assumed by default.
What I'd like to do is debug a single JavaFX program in IntelliJ for all of the supported platforms (except embedded) in Windows and see more or less the right screen sizes before I start plugging in my iPad/iPhone/Android phone/Android tablet/Mac just to get the code logic right.
Is there some setting that would let me switch between simulating different devices as a first stage?
When I double click "debug" I get the following message and the window hangs.
Listening for transport dt_socket at address: 5005
Is this related? Are we trying to debug an actual device by accident?
As for the app size, when you run on desktop it defaults to a phone form factor of 335x600. This comes from the Display service:
#Override
public Dimension2D getDefaultDimensions() {
return isTablet() ? new Dimension2D(900, 600) : new Dimension2D(335, 600);
}
You can change to a tablet format of 900 x 600 if you set the charm-desktop-form system property to tablet.
Or you can simply override these settings, and set your desired size:
#Override
public void postInit(Scene scene) {
Swatch.BLUE.assignTo(scene);
if (Platform.isDesktop()) {
((Stage) scene.getWindow()).setWidth(400);
((Stage) scene.getWindow()).setHeight(800);
}
}
When you deploy your app to a mobile device, it will just adjust to the size of its screen.
Related to the message javafx.platform is not defined running on desktop, that system property is not defined, so it is a warning message that informs that desktop is selected. When you run on mobile, the proper Android or iOS value will be set for the platform.
Finally, about debugging, when you run on desktop you initially can debug only the desktop application, but you can modify the size of the application as mentioned above.
To debug the mobile application, you have to run either the iOS simulator or the Android emulator.
This question shows how to debug on Android from IntelliJ, but you have to actually deploy the application to a mobile device.
On iOS, providing you have a Mac, you can use the launchIPhoneSimulator task to launch the iOS simulator, where you can choose any of the possible iPhone or iPad devices with their different screens resolutions. In this case you don't need a device.
Solution to part 2: Debug the Desktop version from inside IntelliJ.
In IntelliJ, make a new Run configuration of type Gradle and use "run" not "debug" as the "task". Then choose "backpack [run]" from the toolbar and use the "debug" icon on the toolbar. IntelliJ will run the app with the JDWP options enabled and connect the debugger to it.

Why in WEBVIEW Context the xpath generated by Appium isn't working using iOS simulator?

I want to know why in WEBVIEW Context the xpath generated by Appium isn't working using iOS simulator with java to write our scripts?
Other question is there a way to make the code generated by appium recorder working in our java classes, because for now while we are in WEBVIEW there is no chance with appium we have to take a look into html code to create code.
PS : I have already tried to change the context to NATIVE then turn
back to WEBVIEW_1 but no changes.

Cannot set application icon for a GTK# application in Monodevelop 3.1.1

I set the icon as described in https://stackoverflow.com/a/12491626/67824 but it still shows as a generic app icon (grey screen with green "exec" text) in the dock and in the ⌘+tab application switcher (both when I run it from MonoDevelop and when I run it using mono foo.exe). I know it can be done, because when I run a mono-compliant version of LINQPad I'm seeing the LINQPad application icon.
I also use the SetIconFromFile method in the main window's class. Example below where my icon is copied to an Images folder at the root of my application:
this.SetIconFromFile(string.Format("{0}{1}Images{2}Logo.ico",
System.IO.Path.GetDirectoryName(Assembly.GetEntryAssembly().Location),
System.IO.Path.DirectorySeparatorChar,
System.IO.Path.DirectorySeparatorChar));