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

Wrong scrollbar position on touch enabled devices

    XMLWordPrintable

Details

    • Bug
    • Status: Resolved
    • P4
    • Resolution: Fixed
    • jfx15
    • jfx15
    • javafx
    • None

    Description

      On touch enabled devices (desktop, embedded, iOS, Android), the scrollbar controls of a ListView are misplaced: it is a narrower control (default is 8 px) than the same regular control (for non-touch enabled devices, default 20 px), and instead of being aligned to the right (vertical) or bottom (horizontal), there is a visible inset of 8 pixels.

      As a simple workaround, with CSS the issue can be fixed:

      .scroll-bar:vertical {
          -fx-translate-x: 8;
      }

      .scroll-bar:horizontal {
          -fx-translate-y: 8;
      }

      The issue can be easily reproduced (with any JDK and JavaFX version) on desktop without a touch enabled device, just by using: -Dcom.sun.javafx.touch=true

      Attachments

        Issue Links

          Activity

            People

              jpereda Jose Pereda
              jpereda Jose Pereda
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: