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

SplitPane divider should support an absolute position

    XMLWordPrintable

Details

    Description

      Today, the SplitPane dividers have a relative (percentage) position (between 0 and 1).
      It is fine e.g. when one have a single divider at the middle of a window. When the window is resized, the divider is still at the middle.

      But with several dividers, we may need an absolute position mode.
      For instance, in SB, we have 2 panels (left and right) and a stage view at the middle (see attached test case).
      Right and left panels have a min/max sizes, and one can grow/shrink the panels, following the min/max sizes. Fine.
      But if one grow the window, we don't want the right and left panels to be resized. We need a way to enable an "absolute position mode" instead of a relative one.
      Moreover, we need to be able to have an absolute positioning from either the left or right (vertical divider), top or bottom (horizontal divider).

      SplitPane could have a setPositionMode() which can be ABSOLUTE_XXX/RELATIVE enum, and the get/setPosition() would return either a relative position (0..1) or an absolute one.
      ABSOLUTE_XXX could be : ABSOLUTE_LEFT, ABSOLUTE_RIGHT, ABSOLUTE_TOP, ABSOLUTE_BOTTOM

      Attachments

        Issue Links

          Activity

            People

              kwwong Kinsley Wong (Inactive)
              jcambon Jerome Cambon
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                Imported: