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

toFront()/toBack() do not work in some situations

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Not an Issue
    • Icon: P4 P4
    • None
    • 8u77
    • javafx
    • x86
    • other

      A DESCRIPTION OF THE REQUEST :
      toFront() and toBack() do not work to reorder a tab in a tab pane. In the Qt Framework the equivalent functions are raise() and lower() respectively. The toFront() in JavaFX either brings a stage to the front, or a control in to the top in the z-order of a layout. In Qt it can be used to also change the collection/layout order of the children. If raise() is called on QDockWidget or a QTab in Qt they will be brought to the top. In JavaFX, calling toFront() on a Tab has no effect.

      http://doc.qt.io/qt-5/qwidget.html#raise

      JUSTIFICATION :
      toFront() already brings Node's to the front with layouts such as BorderPane, but not with other containers like TabPane.

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      toFront() called on a tab should bring it to the front of the TabPane() and make it the selected tab.

      CUSTOMER SUBMITTED WORKAROUND :
      The work around is to get the parent of the tab and then ask its selection model to the select the tab.

            jgiles Jonathan Giles
            webbuggrp Webbug Group
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: