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

TableView with wrapped Text doesn't (always) scroll

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: P4 P4
    • tbd
    • 8u40
    • javafx
    • OSX 10.10.2
      java version "1.8.0_40"
      Java(TM) SE Runtime Environment (build 1.8.0_40-b27)
      Java HotSpot(TM) 64-Bit Server VM (build 25.40-b25, mixed mode)

      See minimal example here: https://gist.github.com/thelmstedt/2432b188aff575cff106

      - Given a TableColumn, with CellFactory for generating Cells with wrapped Text elements
      - Generate the UI, then add the data
      - Although the content is off screen, there is no scrollbar
      - Resize either the Column or the Whole screen: the scroll bar appears

      There are two caveats to this bug, unfortunately not something I can hack in to an app:
         1) make the content much larger than the table (eg increase the number of rows to 20)
         2) put a long sleep in between adding items

      I haven't dug down into the code but those two caveats make it seem that:
         1) wrapping isn't taken in to account for an initial table height, if the content was going to scroll initially (pre wrap) it still works. Problem seems to be when pre-wrap (no scroll) becomes post-wrap (scroll)
         2) wrapping might be happening a little late in the rendering process

            Unassigned Unassigned
            duke J. Duke
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Imported: