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

Region's layoutInArea() and positionInArea() incorrectly attempt to snap non-resizables to pixel boundaries, often causing gaps in positioning

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P4
    • fx2.0
    • fx2.0
    • javafx

    Description

      the following code illustrates a problem in the way Region's layout code is always trying to snap positions, regardless of whether the node is resizable and can even be snapped:

                  StackPane stack = new StackPane();
                  stack.setAlignment(Pos.BOTTOM_RIGHT); // leaves a small gap on bottom-right of circle because of snap-to-pixel rounding
                  stack.setStyle("-fx-background-color: yellow;");
                  stack.getChildren().add(new Circle(20.12));

      Attachments

        Issue Links

          Activity

            People

              amfowler Anne Fowler (Inactive)
              amfowler Anne Fowler (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                Imported: