8025218: [javadoc] some errors in java/awt classes
authoryan
Thu, 26 Sep 2013 16:10:36 +0400
changeset 20172 f48935a247ec
parent 20171 099045062d79
child 20173 7d2dbee4296a
child 20428 929cd48fca8a
8025218: [javadoc] some errors in java/awt classes Reviewed-by: yan Contributed-by: Dmitry Zinkevich <dmitry.zinkevich@oracle.com>
jdk/src/share/classes/java/awt/AWTKeyStroke.java
jdk/src/share/classes/java/awt/Component.java
jdk/src/share/classes/java/awt/DefaultKeyboardFocusManager.java
jdk/src/share/classes/java/awt/Dialog.java
jdk/src/share/classes/java/awt/Event.java
jdk/src/share/classes/java/awt/Frame.java
jdk/src/share/classes/java/awt/GridBagConstraints.java
jdk/src/share/classes/java/awt/GridBagLayout.java
jdk/src/share/classes/java/awt/GridLayout.java
jdk/src/share/classes/java/awt/KeyboardFocusManager.java
jdk/src/share/classes/java/awt/MenuBar.java
jdk/src/share/classes/java/awt/ScrollPane.java
jdk/src/share/classes/java/awt/ScrollPaneAdjustable.java
jdk/src/share/classes/java/awt/SystemTray.java
jdk/src/share/classes/java/awt/TextComponent.java
jdk/src/share/classes/java/awt/TextField.java
jdk/src/share/classes/java/awt/Window.java
jdk/src/share/classes/java/awt/datatransfer/DataFlavor.java
jdk/src/share/classes/java/awt/event/MouseMotionListener.java
--- a/jdk/src/share/classes/java/awt/AWTKeyStroke.java	Thu Sep 26 10:48:56 2013 +0200
+++ b/jdk/src/share/classes/java/awt/AWTKeyStroke.java	Thu Sep 26 16:10:36 2013 +0400
@@ -485,11 +485,11 @@
      * If typed, pressed or released is not specified, pressed is assumed. Here
      * are some examples:
      * <pre>
-     *     "INSERT" => getAWTKeyStroke(KeyEvent.VK_INSERT, 0);
-     *     "control DELETE" => getAWTKeyStroke(KeyEvent.VK_DELETE, InputEvent.CTRL_MASK);
-     *     "alt shift X" => getAWTKeyStroke(KeyEvent.VK_X, InputEvent.ALT_MASK | InputEvent.SHIFT_MASK);
-     *     "alt shift released X" => getAWTKeyStroke(KeyEvent.VK_X, InputEvent.ALT_MASK | InputEvent.SHIFT_MASK, true);
-     *     "typed a" => getAWTKeyStroke('a');
+     *     "INSERT" =&gt; getAWTKeyStroke(KeyEvent.VK_INSERT, 0);
+     *     "control DELETE" =&gt; getAWTKeyStroke(KeyEvent.VK_DELETE, InputEvent.CTRL_MASK);
+     *     "alt shift X" =&gt; getAWTKeyStroke(KeyEvent.VK_X, InputEvent.ALT_MASK | InputEvent.SHIFT_MASK);
+     *     "alt shift released X" =&gt; getAWTKeyStroke(KeyEvent.VK_X, InputEvent.ALT_MASK | InputEvent.SHIFT_MASK, true);
+     *     "typed a" =&gt; getAWTKeyStroke('a');
      * </pre>
      *
      * @param s a String formatted as described above
--- a/jdk/src/share/classes/java/awt/Component.java	Thu Sep 26 10:48:56 2013 +0200
+++ b/jdk/src/share/classes/java/awt/Component.java	Thu Sep 26 16:10:36 2013 +0400
@@ -2026,7 +2026,7 @@
      * @return an instance of <code>Point</code> representing
      *          the top-left corner of the component's bounds in the
      *          coordinate space of the screen
-     * @throws <code>IllegalComponentStateException</code> if the
+     * @throws IllegalComponentStateException if the
      *          component is not showing on the screen
      * @see #setLocation
      * @see #getLocation
--- a/jdk/src/share/classes/java/awt/DefaultKeyboardFocusManager.java	Thu Sep 26 10:48:56 2013 +0200
+++ b/jdk/src/share/classes/java/awt/DefaultKeyboardFocusManager.java	Thu Sep 26 16:10:36 2013 +0400
@@ -1246,7 +1246,7 @@
      * any) should be cancelled.
      *
      * @param after the timestamp specified in the call to
-     *        <code>enqueueKeyEvents</code>, or any value < 0
+     *        <code>enqueueKeyEvents</code>, or any value &lt; 0
      * @param untilFocused the Component specified in the call to
      *        <code>enqueueKeyEvents</code>
      * @see #enqueueKeyEvents
--- a/jdk/src/share/classes/java/awt/Dialog.java	Thu Sep 26 10:48:56 2013 +0200
+++ b/jdk/src/share/classes/java/awt/Dialog.java	Thu Sep 26 16:10:36 2013 +0400
@@ -61,7 +61,7 @@
  * <p>
  * The default layout for a dialog is <code>BorderLayout</code>.
  * <p>
- * A dialog may have its native decorations (i.e. Frame & Titlebar) turned off
+ * A dialog may have its native decorations (i.e. Frame &amp; Titlebar) turned off
  * with <code>setUndecorated</code>.  This can only be done while the dialog
  * is not {@link Component#isDisplayable() displayable}.
  * <p>
--- a/jdk/src/share/classes/java/awt/Event.java	Thu Sep 26 10:48:56 2013 +0200
+++ b/jdk/src/share/classes/java/awt/Event.java	Thu Sep 26 16:10:36 2013 +0400
@@ -524,7 +524,7 @@
      * This field has been replaced by MouseEvent.getClickCount().
      *
      * @serial
-     * @see java.awt.event.MouseEvent#getClickCount().
+     * @see java.awt.event.MouseEvent#getClickCount()
      */
     public int clickCount;
 
--- a/jdk/src/share/classes/java/awt/Frame.java	Thu Sep 26 10:48:56 2013 +0200
+++ b/jdk/src/share/classes/java/awt/Frame.java	Thu Sep 26 16:10:36 2013 +0400
@@ -265,12 +265,12 @@
      *
      * <p>Note that the correct test for frame being fully maximized is
      * <pre>
-     *     (state & Frame.MAXIMIZED_BOTH) == Frame.MAXIMIZED_BOTH
+     *     (state &amp; Frame.MAXIMIZED_BOTH) == Frame.MAXIMIZED_BOTH
      * </pre>
      *
      * <p>To test is frame is maximized in <em>some</em> direction use
      * <pre>
-     *     (state & Frame.MAXIMIZED_BOTH) != 0
+     *     (state &amp; Frame.MAXIMIZED_BOTH) != 0
      * </pre>
      *
      * @see #setExtendedState(int)
--- a/jdk/src/share/classes/java/awt/GridBagConstraints.java	Thu Sep 26 10:48:56 2013 +0200
+++ b/jdk/src/share/classes/java/awt/GridBagConstraints.java	Thu Sep 26 16:10:36 2013 +0400
@@ -30,7 +30,7 @@
  * <code>GridBagLayout</code> class.
  *
  * @author Doug Stein
- * @author Bill Spitzak (orignial NeWS & OLIT implementation)
+ * @author Bill Spitzak (orignial NeWS &amp; OLIT implementation)
  * @see java.awt.GridBagLayout
  * @since JDK1.0
  */
--- a/jdk/src/share/classes/java/awt/GridBagLayout.java	Thu Sep 26 10:48:56 2013 +0200
+++ b/jdk/src/share/classes/java/awt/GridBagLayout.java	Thu Sep 26 16:10:36 2013 +0400
@@ -120,9 +120,9 @@
  * Orientation relative values are interpreted relative to the container's
  * <code>ComponentOrientation</code> property while absolute values
  * are not.  Baseline relative values are calculated relative to the
- * baseline.  Valid values are:</dd>
+ * baseline.  Valid values are:
  * <p>
- * <center><table BORDER=0 COLS=3 WIDTH=800
+ * <center><table BORDER=0 WIDTH=800
  *        SUMMARY="absolute, relative and baseline values as described above">
  * <tr>
  * <th><P ALIGN="LEFT">Absolute Values</th>
@@ -131,6 +131,7 @@
  * </tr>
  * <tr>
  * <td>
+ * <ul style="list-style-type:none">
  * <li><code>GridBagConstraints.NORTH</code></li>
  * <li><code>GridBagConstraints.SOUTH</code></li>
  * <li><code>GridBagConstraints.WEST</code></li>
@@ -140,8 +141,10 @@
  * <li><code>GridBagConstraints.SOUTHWEST</code></li>
  * <li><code>GridBagConstraints.SOUTHEAST</code></li>
  * <li><code>GridBagConstraints.CENTER</code> (the default)</li>
+ * </ul>
  * </td>
  * <td>
+ * <ul style="list-style-type:none">
  * <li><code>GridBagConstraints.PAGE_START</code></li>
  * <li><code>GridBagConstraints.PAGE_END</code></li>
  * <li><code>GridBagConstraints.LINE_START</code></li>
@@ -150,8 +153,10 @@
  * <li><code>GridBagConstraints.FIRST_LINE_END</code></li>
  * <li><code>GridBagConstraints.LAST_LINE_START</code></li>
  * <li><code>GridBagConstraints.LAST_LINE_END</code></li>
+ * </ul>
  * </td>
  * <td>
+ * <ul style="list-style-type:none">
  * <li><code>GridBagConstraints.BASELINE</code></li>
  * <li><code>GridBagConstraints.BASELINE_LEADING</code></li>
  * <li><code>GridBagConstraints.BASELINE_TRAILING</code></li>
@@ -161,9 +166,10 @@
  * <li><code>GridBagConstraints.BELOW_BASELINE</code></li>
  * <li><code>GridBagConstraints.BELOW_BASELINE_LEADING</code></li>
  * <li><code>GridBagConstraints.BELOW_BASELINE_TRAILING</code></li>
+ * </ul>
  * </td>
  * </tr>
- * </table></center><p>
+ * </table></center>
  * <dt>{@link GridBagConstraints#weightx},
  * {@link GridBagConstraints#weighty}
  * <dd>Used to determine how to distribute space, which is
@@ -246,7 +252,7 @@
  * left-to-right container and Figure 3 shows the layout for a horizontal,
  * right-to-left container.
  * <p>
- * <center><table COLS=2 WIDTH=600 summary="layout">
+ * <center><table WIDTH=600 summary="layout">
  * <tr ALIGN=CENTER>
  * <td>
  * <img src="doc-files/GridBagLayout-1.gif" alt="The preceeding text describes this graphic (Figure 1)." ALIGN=center HSPACE=10 VSPACE=7>
@@ -349,7 +355,7 @@
  * </pre></blockquote><hr>
  * <p>
  * @author Doug Stein
- * @author Bill Spitzak (orignial NeWS & OLIT implementation)
+ * @author Bill Spitzak (orignial NeWS &amp; OLIT implementation)
  * @see       java.awt.GridBagConstraints
  * @see       java.awt.GridBagLayoutInfo
  * @see       java.awt.ComponentOrientation
--- a/jdk/src/share/classes/java/awt/GridLayout.java	Thu Sep 26 10:48:56 2013 +0200
+++ b/jdk/src/share/classes/java/awt/GridLayout.java	Thu Sep 26 16:10:36 2013 +0400
@@ -55,7 +55,7 @@
  * If the container's <code>ComponentOrientation</code> property is horizontal
  * and right-to-left, the example produces the output shown in Figure 2.
  * <p>
- * <center><table COLS=2 WIDTH=600 summary="layout">
+ * <center><table WIDTH=600 summary="layout">
  * <tr ALIGN=CENTER>
  * <td><img SRC="doc-files/GridLayout-1.gif"
  *      alt="Shows 6 buttons in rows of 2. Row 1 shows buttons 1 then 2.
--- a/jdk/src/share/classes/java/awt/KeyboardFocusManager.java	Thu Sep 26 10:48:56 2013 +0200
+++ b/jdk/src/share/classes/java/awt/KeyboardFocusManager.java	Thu Sep 26 16:10:36 2013 +0400
@@ -2034,7 +2034,7 @@
      * oldest</b> timestamp (if any) should be cancelled.
      *
      * @param after the timestamp specified in the call to
-     *        <code>enqueueKeyEvents</code>, or any value < 0
+     *        <code>enqueueKeyEvents</code>, or any value &lt; 0
      * @param untilFocused the Component specified in the call to
      *        <code>enqueueKeyEvents</code>
      * @see #enqueueKeyEvents
--- a/jdk/src/share/classes/java/awt/MenuBar.java	Thu Sep 26 10:48:56 2013 +0200
+++ b/jdk/src/share/classes/java/awt/MenuBar.java	Thu Sep 26 16:10:36 2013 +0400
@@ -43,7 +43,7 @@
  * This is what a menu bar might look like:
  * <p>
  * <img src="doc-files/MenuBar-1.gif"
- * <alt="Diagram of MenuBar containing 2 menus: Examples and Options.
+ * alt="Diagram of MenuBar containing 2 menus: Examples and Options.
  * Examples menu is expanded showing items: Basic, Simple, Check, and More Examples."
  * ALIGN=center HSPACE=10 VSPACE=7>
  * <p>
--- a/jdk/src/share/classes/java/awt/ScrollPane.java	Thu Sep 26 10:48:56 2013 +0200
+++ b/jdk/src/share/classes/java/awt/ScrollPane.java	Thu Sep 26 16:10:36 2013 +0400
@@ -247,7 +247,7 @@
      * component is removed and the new one is added.
      * @param comp the component to be added
      * @param constraints  not applicable
-     * @param index position of child component (must be <= 0)
+     * @param index position of child component (must be &lt;= 0)
      */
     protected final void addImpl(Component comp, Object constraints, int index) {
         synchronized (getTreeLock()) {
--- a/jdk/src/share/classes/java/awt/ScrollPaneAdjustable.java	Thu Sep 26 10:48:56 2013 +0200
+++ b/jdk/src/share/classes/java/awt/ScrollPaneAdjustable.java	Thu Sep 26 16:10:36 2013 +0400
@@ -220,7 +220,7 @@
      * This method is public for this class to properly implement
      * <code>Adjustable</code> interface.
      *
-     * @throws <code>AWTError</code>  Always throws an error when called.
+     * @throws AWTError Always throws an error when called.
      */
     public void setMinimum(int min) {
         throw new AWTError(SCROLLPANE_ONLY);
@@ -237,7 +237,7 @@
      * This method is public for this class to properly implement
      * <code>Adjustable</code> interface.
      *
-     * @throws <code>AWTError</code>  Always throws an error when called.
+     * @throws AWTError Always throws an error when called.
      */
     public void setMaximum(int max) {
         throw new AWTError(SCROLLPANE_ONLY);
@@ -274,7 +274,7 @@
      * This method is public for this class to properly implement
      * <code>Adjustable</code> interface.
      *
-     * @throws <code>AWTError</code>  Always throws an error when called.
+     * @throws AWTError Always throws an error when called.
      */
     public void setVisibleAmount(int v) {
         throw new AWTError(SCROLLPANE_ONLY);
--- a/jdk/src/share/classes/java/awt/SystemTray.java	Thu Sep 26 10:48:56 2013 +0200
+++ b/jdk/src/share/classes/java/awt/SystemTray.java	Thu Sep 26 16:10:36 2013 +0400
@@ -63,8 +63,8 @@
  *
  * <p>The following code snippet demonstrates how to access
  * and customize the system tray:
+ * <pre>
  * <code>
- * <pre>
  *     {@link TrayIcon} trayIcon = null;
  *     if (SystemTray.isSupported()) {
  *         // get the SystemTray instance
@@ -109,8 +109,8 @@
  *         trayIcon.{@link TrayIcon#setImage(java.awt.Image) setImage}(updatedImage);
  *     }
  *     // ...
+ * </code>
  * </pre>
- * </code>
  *
  * @since 1.6
  * @see TrayIcon
--- a/jdk/src/share/classes/java/awt/TextComponent.java	Thu Sep 26 10:48:56 2013 +0200
+++ b/jdk/src/share/classes/java/awt/TextComponent.java	Thu Sep 26 16:10:36 2013 +0400
@@ -972,7 +972,7 @@
          * coordinates.  If the index is invalid a null rectangle
          * is returned.
          *
-         * @param i the index into the String >= 0
+         * @param i the index into the String &gt;= 0
          * @return the screen coordinates of the character's bounding box
          */
         public Rectangle getCharacterBounds(int i) {
@@ -982,7 +982,7 @@
         /**
          * Returns the number of characters (valid indicies)
          *
-         * @return the number of characters >= 0
+         * @return the number of characters &gt;= 0
          */
         public int getCharCount() {
             return TextComponent.this.getText().length();
@@ -1018,7 +1018,7 @@
          * Return 0 if the text is empty, or the caret position
          * if no selection.
          *
-         * @return the index into the text of the start of the selection >= 0
+         * @return the index into the text of the start of the selection &gt;= 0
          */
         public int getSelectionStart() {
             return TextComponent.this.getSelectionStart();
@@ -1031,7 +1031,7 @@
          * Return 0 if the text is empty, or the caret position
          * if no selection.
          *
-         * @return the index into teh text of the end of the selection >= 0
+         * @return the index into teh text of the end of the selection &gt;= 0
          */
         public int getSelectionEnd() {
             return TextComponent.this.getSelectionEnd();
@@ -1056,7 +1056,7 @@
          *
          * @param part the AccessibleText.CHARACTER, AccessibleText.WORD,
          * or AccessibleText.SENTENCE to retrieve
-         * @param index an index within the text >= 0
+         * @param index an index within the text &gt;= 0
          * @return the letter, word, or sentence,
          *   null for an invalid index or part
          */
@@ -1122,7 +1122,7 @@
          *
          * @param part the AccessibleText.CHARACTER, AccessibleText.WORD,
          * or AccessibleText.SENTENCE to retrieve
-         * @param index an index within the text >= 0
+         * @param index an index within the text &gt;= 0
          * @return the letter, word, or sentence, null for an invalid
          *  index or part
          */
@@ -1175,7 +1175,7 @@
          *
          * @param part the AccessibleText.CHARACTER, AccessibleText.WORD,
          *   or AccessibleText.SENTENCE to retrieve
-         * @param index an index within the text >= 0
+         * @param index an index within the text &gt;= 0
          * @return the letter, word, or sentence, null for an invalid index
          *  or part
          */
--- a/jdk/src/share/classes/java/awt/TextField.java	Thu Sep 26 10:48:56 2013 +0200
+++ b/jdk/src/share/classes/java/awt/TextField.java	Thu Sep 26 16:10:36 2013 +0400
@@ -503,7 +503,7 @@
      *
      * @see #addActionListener
      * @see #removeActionListener
-     * @see     java.awt.event#ActionListener
+     * @see java.awt.event.ActionListener
      * @since 1.4
      */
     public synchronized ActionListener[] getActionListeners() {
--- a/jdk/src/share/classes/java/awt/Window.java	Thu Sep 26 10:48:56 2013 +0200
+++ b/jdk/src/share/classes/java/awt/Window.java	Thu Sep 26 16:10:36 2013 +0400
@@ -1075,7 +1075,6 @@
      * Hide this Window, its subcomponents, and all of its owned children.
      * The Window and its subcomponents can be made visible again
      * with a call to {@code show}.
-     * </p>
      * @see #show
      * @see #dispose
      * @deprecated As of JDK version 1.5, replaced by
@@ -3373,27 +3372,27 @@
      * this property of the Window.
      * <p>
      * For example, after the following code is executed:
-     * <pre><blockquote>
+     * <pre>
      * setLocationByPlatform(true);
      * setVisible(true);
      * boolean flag = isLocationByPlatform();
-     * </blockquote></pre>
+     * </pre>
      * The window will be shown at platform's default location and
      * {@code flag} will be {@code false}.
      * <p>
      * In the following sample:
-     * <pre><blockquote>
+     * <pre>
      * setLocationByPlatform(true);
      * setLocation(10, 10);
      * boolean flag = isLocationByPlatform();
      * setVisible(true);
-     * </blockquote></pre>
+     * </pre>
      * The window will be shown at (10, 10) and {@code flag} will be
      * {@code false}.
      *
      * @param locationByPlatform {@code true} if this Window should appear
      *        at the default location, {@code false} if at the current location
-     * @throws {@code IllegalComponentStateException} if the window
+     * @throws IllegalComponentStateException if the window
      *         is showing on screen and locationByPlatform is {@code true}.
      * @see #setLocation
      * @see #isShowing
--- a/jdk/src/share/classes/java/awt/datatransfer/DataFlavor.java	Thu Sep 26 10:48:56 2013 +0200
+++ b/jdk/src/share/classes/java/awt/datatransfer/DataFlavor.java	Thu Sep 26 16:10:36 2013 +0400
@@ -454,7 +454,7 @@
 
     /**
      * Constructs a <code>DataFlavor</code> from a <code>mimeType</code> string.
-     * The string can specify a "class=<fully specified Java class name>"
+     * The string can specify a "class=&lt;fully specified Java class name&gt;"
      * parameter to create a <code>DataFlavor</code> with the desired
      * representation class. If the string does not contain "class=" parameter,
      * <code>java.io.InputStream</code> is used as default.
--- a/jdk/src/share/classes/java/awt/event/MouseMotionListener.java	Thu Sep 26 10:48:56 2013 +0200
+++ b/jdk/src/share/classes/java/awt/event/MouseMotionListener.java	Thu Sep 26 16:10:36 2013 +0400
@@ -60,9 +60,9 @@
      * mouse button is released (regardless of whether the mouse position
      * is within the bounds of the component).
      * <p>
-     * Due to platform-dependent Drag&Drop implementations,
+     * Due to platform-dependent Drag&amp;Drop implementations,
      * <code>MOUSE_DRAGGED</code> events may not be delivered during a native
-     * Drag&Drop operation.
+     * Drag&amp;Drop operation.
      */
     public void mouseDragged(MouseEvent e);