Duplicate :
|
|
Relates :
|
|
Relates :
|
Elements that placed inside a SubScene are blurry. Link to a preview of the sample application on my system: http://i.imgur.com/q5pudHP.png Sample application: import javafx.application.Application; import javafx.scene.*; import javafx.scene.layout.HBox; import javafx.scene.text.Text; import javafx.stage.Stage; public class BlurrySubscene extends Application { public static void main(String[] args) { launch(args); } @Override public void start(Stage stage) { final Text subsceneText = new Text("Subscene Text:\n\n" + TEXT); subsceneText.relocate(0, 0); double W = subsceneText.getBoundsInLocal().getWidth(); double H = subsceneText.getBoundsInLocal().getHeight(); SubScene subscene = new SubScene(new Group(subsceneText), W, H); Scene scene = new Scene( new HBox( subscene, new Text("Scene Text:\n\n" + TEXT) ) ); stage.setScene(scene); stage.show(); } private static final String TEXT = "O for a Muse of fire, that would ascend\n" + "The brightest heaven of invention,\n" + "A kingdom for a stage, princes to act\n" + "And monarchs to behold the swelling scene!\n" + "Then should the warlike Harry, like himself,\n" + "Assume the port of Mars; and at his heels,\n" + "Leash'd in like hounds, should famine, sword and fire\n" + "Crouch for employment"; }
|