ScrollPane doesn't take content size into account on USE_COMPUTED_SIZE

XMLWordPrintable

    • Type: Bug
    • Resolution: Fixed
    • Priority: P3
    • emb-8u6, 8u20
    • Affects Version/s: fx2.1, 7u6, 8
    • Component/s: javafx
    • Environment:

      javafx-sdk2.2.0-beta-b06, JavaFX 8 b118

      When I have some content in my ScrollPane and do the following:

      scrollPane.setPrefWidth(ScrollPane.USE_COMPUTED_SIZE);

      I can assume that the content size will be used to set the scrollPane width.

      However it doesn't work that way. Look at the attached code. It has two scrollPanes with identical content. First scrollPane has prefWidth set to USE_COMPUTED_SIZE, second has it set to 300. See the resulting screenshot.

        1. Bug.java
          3 kB
        2. RT-21495.patch
          1 kB
        3. screenshot-1.jpg
          screenshot-1.jpg
          14 kB

            Assignee:
            David Grieve
            Reporter:
            Alexander Kuznetcov (Inactive)
            Votes:
            1 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported: