-
Bug
-
Resolution: Duplicate
-
P3
-
None
-
jfx21
-
generic
-
generic
A DESCRIPTION OF THE PROBLEM :
When you start a JavaFX-application with an JFXPanel on a screen with scaling of 100% and you move to this window to a screen with a scaling of 125% the content of the JFXPanel looks somehow distorted, i.e. like scaled in a bad quality.
REGRESSION : Last worked in version 8u421
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Execute the source code and move the JFX-window to screen scaled with 125%.
---------- BEGIN SOURCE ----------
package com.hexagon.applauncher.core;
import java.awt.BorderLayout;
import javax.swing.JButton;
import javax.swing.JFrame;
import javax.swing.JPanel;
import javax.swing.SwingUtilities;
import javafx.application.Platform;
import javafx.embed.swing.JFXPanel;
import javafx.scene.Scene;
import javafx.scene.web.WebView;
public class FXWebViewInSwing {
private JFXPanel jfxPanel ;
public void createAndShowWindow() {
JFrame frame = new JFrame();
JButton quit = new JButton("Quit");
quit.addActionListener(event -> System.exit(0));
jfxPanel = new JFXPanel();
Platform.runLater(this::createJFXContent);
JPanel buttonPanel = new JPanel();
buttonPanel.add(quit);
frame.add(BorderLayout.CENTER, jfxPanel);
frame.add(BorderLayout.SOUTH, buttonPanel);
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
frame.setSize(800, 800);
frame.setLocationRelativeTo(null);
frame.setVisible(true);
}
private void createJFXContent() {
WebView webView = new WebView();
webView.getEngine().load("https://openjfx.io");
Scene scene = new Scene(webView);
jfxPanel.setScene(scene);
}
public static void main(String[] args) {
FXWebViewInSwing swingApp = new FXWebViewInSwing();
SwingUtilities.invokeLater(swingApp::createAndShowWindow);
}
}
---------- END SOURCE ----------
FREQUENCY : always
When you start a JavaFX-application with an JFXPanel on a screen with scaling of 100% and you move to this window to a screen with a scaling of 125% the content of the JFXPanel looks somehow distorted, i.e. like scaled in a bad quality.
REGRESSION : Last worked in version 8u421
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Execute the source code and move the JFX-window to screen scaled with 125%.
---------- BEGIN SOURCE ----------
package com.hexagon.applauncher.core;
import java.awt.BorderLayout;
import javax.swing.JButton;
import javax.swing.JFrame;
import javax.swing.JPanel;
import javax.swing.SwingUtilities;
import javafx.application.Platform;
import javafx.embed.swing.JFXPanel;
import javafx.scene.Scene;
import javafx.scene.web.WebView;
public class FXWebViewInSwing {
private JFXPanel jfxPanel ;
public void createAndShowWindow() {
JFrame frame = new JFrame();
JButton quit = new JButton("Quit");
quit.addActionListener(event -> System.exit(0));
jfxPanel = new JFXPanel();
Platform.runLater(this::createJFXContent);
JPanel buttonPanel = new JPanel();
buttonPanel.add(quit);
frame.add(BorderLayout.CENTER, jfxPanel);
frame.add(BorderLayout.SOUTH, buttonPanel);
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
frame.setSize(800, 800);
frame.setLocationRelativeTo(null);
frame.setVisible(true);
}
private void createJFXContent() {
WebView webView = new WebView();
webView.getEngine().load("https://openjfx.io");
Scene scene = new Scene(webView);
jfxPanel.setScene(scene);
}
public static void main(String[] args) {
FXWebViewInSwing swingApp = new FXWebViewInSwing();
SwingUtilities.invokeLater(swingApp::createAndShowWindow);
}
}
---------- END SOURCE ----------
FREQUENCY : always
- duplicates
-
JDK-8222209 JavaFX is rendered blurry on systems with monitors in different configuration
- Resolved