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

[macosx] Enable a component UI to specify the result of isOptimizedDrawingEnabled()

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Unresolved
    • Icon: P4 P4
    • tbd
    • 8u60
    • client-libs

      A DESCRIPTION OF THE REQUEST :
      A component UI may install a layout manager that causes the child components to overlap. A specific example is a scroll pane UI that implements OS X style scroll bars that overlay the viewport. In such a case, the component UI must ensure that isOptimizedDrawingEnabled() on the component returns false.

      This is not possible currently, because almost all Swing components return the constant false (by inheriting the method from JComponent). The solution recommended for application developers is to define a component subclass that overrides this method. This solution is not useful for UI delegates, as they are intended to be orthogonal to the class hierarchy. It is not acceptable for a look and feel to require the application developer modify their class hierarchy.

      Thus, there is a need for the component UI to alter the behavior of isOptimizedDrawingEnabled() in existing Swing component classes.

      A simple solution would be to define a method JComponent.setOptimizedDrawingEnabled(boolean).


      JUSTIFICATION :
      See description.


            psadhukhan Prasanta Sadhukhan
            webbuggrp Webbug Group
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated: