Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8094194

[Mac, Retina] SubScene contents are blurry

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P3 P3
    • 8u40
    • 8u20
    • javafx
    • None
    • 2014 Macbook Pro (retina display), OS X 10.9.5, java.runtime.version=1.8.0_20-b26

      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";
      }

        1. BlurrySubscene2.java
          4 kB
        2. SubScene.png
          SubScene.png
          179 kB
        3. SubsceneTextWithFix.PNG
          SubsceneTextWithFix.PNG
          29 kB
        4. SubsceneTextWithOutFix.PNG
          SubsceneTextWithOutFix.PNG
          13 kB
        5. BlurrySubscene3.java
          2 kB

            flar Jim Graham
            josmithjfx John Smith (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported: