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

API Doc for BasicBorders.ButtonBorder.getBorderInsets() is incorrect

XMLWordPrintable

      Name: apR10229 Date: 11/05/2003


      Filed By : SPB JCK team (###@###.###)
      JDK : java full version "1.5.0-beta-b26"
      JCK : 1.5
      Platform[s] : Solaris
      switch/Mode :
      JCK test owner : http://javaweb.eng/jct/sqe/JCK-tck/usr/owners.jto
      Failing Test [s] : N/A


      Specification excerpt:
      ======================
      --------- J2SE API spec v.1.5 ---------
      ...
      getBorderInsets

      public Insets getBorderInsets(Component c)

          Description copied from class: AbstractBorderThis default implementation returns a new Insets instance where the top, left, bottom, and right fields are set to 0.

      Specified by:
      getBorderInsets in interface BorderOverrides:
      getBorderInsets in class AbstractBorder

      Parameters:
      c - the component for which this border insets value applies
      Returns:
      the new Insets object initialized to 0
      ...
      ---------- end-of-excerpt ---------------

      Problem description
      ===================
      API Doc for javax.swing.plaf.basic.BasicBorders.ButtonBorder.getBorderInsets() is
      ambiguous. It is incorrect to copy description for this method from AbstractButton.
      All copied assertions are incorrect and useless in this class context.
      For example return tag. Why real button implementation should return zero insets?
      For example Tiger RI return 3,2,3,3.

      JCK test source location:
      ==========================
      /java/re/jck/1.5/promoted/latest/JCK-runtime-15/tests

      ======================================================================

            Unassigned Unassigned
            pavsunw Pav Pav (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: