changeset 7876:18ce880b5fb4

Merge
author lana
date Tue, 13 Aug 2013 18:33:25 -0700
parents a4b0be7341ef e0f6039c0290
children f9cf6ecf596c
files makefiles/CompileNativeLibraries.gmk
diffstat 77 files changed, 1080 insertions(+), 307 deletions(-) [+]
line wrap: on
line diff
--- a/.hgtags	Tue Aug 13 19:10:54 2013 +0100
+++ b/.hgtags	Tue Aug 13 18:33:25 2013 -0700
@@ -223,3 +223,4 @@
 6a099a36589bd933957272ba63e5263bede29971 jdk8-b99
 5be9c5bfcfe9b2a40412b4fb364377d49de014eb jdk8-b100
 6901612328239fbd471d20823113c1cf3fdaebee jdk8-b101
+8ed8e2b4b90e0ac9aa5b3efef51cd576a9db96a9 jdk8-b102
--- a/makefiles/CompileNativeLibraries.gmk	Tue Aug 13 19:10:54 2013 +0100
+++ b/makefiles/CompileNativeLibraries.gmk	Tue Aug 13 18:33:25 2013 -0700
@@ -798,6 +798,16 @@
 	LIBAWT_XAWT_CFLAGS += -DFUNCPROTO=15
 endif
 
+ifeq ($(OPENJDK_TARGET_OS),linux)
+ifndef OPENJDK
+include $(JDK_TOPDIR)/make/closed/xawt.gmk
+endif
+
+ifeq ($(DISABLE_XRENDER),true)
+	LIBAWT_XAWT_CFLAGS += -DDISABLE_XRENDER_BY_DEFAULT=true
+endif
+endif
+
 ifeq ($(MILESTONE),internal)
 	LIBAWT_XAWT_CFLAGS += -DINTERNAL_BUILD
 endif
--- a/src/macosx/classes/com/apple/laf/AquaTabbedPaneCopyFromBasicUI.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/macosx/classes/com/apple/laf/AquaTabbedPaneCopyFromBasicUI.java	Tue Aug 13 18:33:25 2013 -0700
@@ -1856,7 +1856,10 @@
         // If we're not valid that means we will shortly be validated and
         // painted, which means we don't have to do anything here.
         if (!isRunsDirty && index >= 0 && index < tabPane.getTabCount()) {
-            tabPane.repaint(getTabBounds(tabPane, index));
+            Rectangle rect = getTabBounds(tabPane, index);
+            if (rect != null) {
+                tabPane.repaint(rect);
+            }
         }
     }
 
--- a/src/macosx/classes/com/apple/laf/AquaTabbedPaneUI.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/macosx/classes/com/apple/laf/AquaTabbedPaneUI.java	Tue Aug 13 18:33:25 2013 -0700
@@ -702,6 +702,20 @@
     }
 
     /**
+     * Returns the bounds of the specified tab index.  The bounds are
+     * with respect to the JTabbedPane's coordinate space.  If the tab at this
+     * index is not currently visible in the UI, then returns null.
+     */
+    @Override
+    public Rectangle getTabBounds(final JTabbedPane pane, final int i) {
+        if (visibleTabState.needsScrollTabs()
+                && (visibleTabState.isBefore(i) || visibleTabState.isAfter(i))) {
+            return null;
+        }
+        return super.getTabBounds(pane, i);
+    }
+
+    /**
      * Returns the tab index which intersects the specified point
      * in the JTabbedPane's coordinate space.
      */
--- a/src/macosx/classes/sun/lwawt/macosx/CPlatformWindow.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/macosx/classes/sun/lwawt/macosx/CPlatformWindow.java	Tue Aug 13 18:33:25 2013 -0700
@@ -830,18 +830,19 @@
     //                          UTILITY METHODS
     // ----------------------------------------------------------------------
 
-    /*
-     * Find image to install into Title or into Application icon.
-     * First try icons installed for toplevel. If there is no icon
-     * use default Duke image.
-     * This method shouldn't return null.
+    /**
+     * Find image to install into Title or into Application icon. First try
+     * icons installed for toplevel. Null is returned, if there is no icon and
+     * default Duke image should be used.
      */
     private CImage getImageForTarget() {
-        List<Image> icons = target.getIconImages();
-        if (icons == null || icons.size() == 0) {
-            return null;
+        CImage icon = null;
+        try {
+            icon = CImage.getCreator().createFromImages(target.getIconImages());
+        } catch (Exception ignored) {
+            // Perhaps the icon passed into Java is broken. Skipping this icon.
         }
-        return CImage.getCreator().createFromImages(icons);
+        return icon;
     }
 
     /*
--- a/src/share/classes/java/awt/event/ContainerListener.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/java/awt/event/ContainerListener.java	Tue Aug 13 18:33:25 2013 -0700
@@ -42,7 +42,7 @@
  * Container events are provided for notification purposes ONLY;
  * The AWT will automatically handle add and remove operations
  * internally so the program works properly regardless of
- * whether the program registers a <code>ComponentListener</code> or not.
+ * whether the program registers a {@code ContainerListener} or not.
  *
  * @see ContainerAdapter
  * @see ContainerEvent
--- a/src/share/classes/java/awt/image/BufferStrategy.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/java/awt/image/BufferStrategy.java	Tue Aug 13 18:33:25 2013 -0700
@@ -55,7 +55,7 @@
  * Alternatively, the contents of the back buffer can be copied, or
  * <i>blitted</i> forward in a chain instead of moving the video pointer.
  * <p>
- * <pre>
+ * <pre>{@code
  * Double buffering:
  *
  *                    ***********         ***********
@@ -72,7 +72,7 @@
  *          *         * <------ *         * <----- *         *
  *          ***********         ***********        ***********
  *
- * </pre>
+ * }</pre>
  * <p>
  * Here is an example of how buffer strategies can be created and used:
  * <pre><code>
--- a/src/share/classes/java/awt/image/BufferedImage.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/java/awt/image/BufferedImage.java	Tue Aug 13 18:33:25 2013 -0700
@@ -602,12 +602,12 @@
      *                  the raster has been premultiplied with alpha.
      * @param properties <code>Hashtable</code> of
      *                  <code>String</code>/<code>Object</code> pairs.
-     * @exception <code>RasterFormatException</code> if the number and
+     * @exception RasterFormatException if the number and
      * types of bands in the <code>SampleModel</code> of the
      * <code>Raster</code> do not match the number and types required by
      * the <code>ColorModel</code> to represent its color and alpha
      * components.
-     * @exception <code>IllegalArgumentException</code> if
+     * @exception IllegalArgumentException if
      *          <code>raster</code> is incompatible with <code>cm</code>
      * @see ColorModel
      * @see Raster
@@ -927,7 +927,7 @@
      * each color component in the returned data when
      * using this method.  With a specified coordinate (x,&nbsp;y) in the
      * image, the ARGB pixel can be accessed in this way:
-     * </p>
+     * <p>
      *
      * <pre>
      *    pixel   = rgbArray[offset + (y-startY)*scansize + (x-startX)]; </pre>
@@ -1131,7 +1131,7 @@
      * @return an {@link Object} that is the property referred to by the
      *          specified <code>name</code> or <code>null</code> if the
      *          properties of this image are not yet known.
-     * @throws <code>NullPointerException</code> if the property name is null.
+     * @throws NullPointerException if the property name is null.
      * @see ImageObserver
      * @see java.awt.Image#UndefinedProperty
      */
@@ -1144,7 +1144,7 @@
      * @param name the property name
      * @return an <code>Object</code> that is the property referred to by
      *          the specified <code>name</code>.
-     * @throws <code>NullPointerException</code> if the property name is null.
+     * @throws NullPointerException if the property name is null.
      */
     public Object getProperty(String name) {
         if (name == null) {
@@ -1196,7 +1196,7 @@
      * @param h the height of the specified rectangular region
      * @return a <code>BufferedImage</code> that is the subimage of this
      *          <code>BufferedImage</code>.
-     * @exception <code>RasterFormatException</code> if the specified
+     * @exception RasterFormatException if the specified
      * area is not contained within this <code>BufferedImage</code>.
      */
     public BufferedImage getSubimage (int x, int y, int w, int h) {
@@ -1388,7 +1388,7 @@
      * @param tileY the y index of the requested tile in the tile array
      * @return a <code>Raster</code> that is the tile defined by the
      *          arguments <code>tileX</code> and <code>tileY</code>.
-     * @exception <code>ArrayIndexOutOfBoundsException</code> if both
+     * @exception ArrayIndexOutOfBoundsException if both
      *          <code>tileX</code> and <code>tileY</code> are not
      *          equal to 0
      */
@@ -1558,7 +1558,7 @@
      * @return <code>true</code> if the tile specified by the specified
      *          indices is checked out for writing; <code>false</code>
      *          otherwise.
-     * @exception <code>ArrayIndexOutOfBoundsException</code> if both
+     * @exception ArrayIndexOutOfBoundsException if both
      *          <code>tileX</code> and <code>tileY</code> are not equal
      *          to 0
      */
--- a/src/share/classes/java/awt/image/ByteLookupTable.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/java/awt/image/ByteLookupTable.java	Tue Aug 13 18:33:25 2013 -0700
@@ -171,7 +171,7 @@
      * @exception ArrayIndexOutOfBoundsException if <code>src</code> is
      *            longer than <code>dst</code> or if for any element
      *            <code>i</code> of <code>src</code>,
-     *            <code>(src[i]&0xff)-offset</code> is either less than
+     *            {@code (src[i]&0xff)-offset} is either less than
      *            zero or greater than or equal to the length of the
      *            lookup table for any band.
      */
--- a/src/share/classes/java/awt/image/ColorModel.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/java/awt/image/ColorModel.java	Tue Aug 13 18:33:25 2013 -0700
@@ -692,12 +692,12 @@
      * <code>DataBuffer.TYPE_INT</code>.
      * @param inData an array of pixel values
      * @return the value of the green component of the specified pixel.
-     * @throws <code>ClassCastException</code> if <code>inData</code>
+     * @throws ClassCastException if <code>inData</code>
      *  is not a primitive array of type <code>transferType</code>
-     * @throws <code>ArrayIndexOutOfBoundsException</code> if
+     * @throws ArrayIndexOutOfBoundsException if
      *  <code>inData</code> is not large enough to hold a pixel value
      *  for this <code>ColorModel</code>
-     * @throws <code>UnsupportedOperationException</code> if this
+     * @throws UnsupportedOperationException if this
      *  <code>tranferType</code> is not supported by this
      *  <code>ColorModel</code>
      */
--- a/src/share/classes/java/awt/image/DirectColorModel.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/java/awt/image/DirectColorModel.java	Tue Aug 13 18:33:25 2013 -0700
@@ -642,12 +642,12 @@
      * @param inData the specified pixel
      * @return the alpha component of the specified pixel, scaled from
      *         0 to 255.
-     * @exception <code>ClassCastException</code> if <code>inData</code>
+     * @exception ClassCastException if <code>inData</code>
      *  is not a primitive array of type <code>transferType</code>
-     * @exception <code>ArrayIndexOutOfBoundsException</code> if
+     * @exception ArrayIndexOutOfBoundsException if
      *  <code>inData</code> is not large enough to hold a pixel value
      *  for this <code>ColorModel</code>
-     * @exception <code>UnsupportedOperationException</code> if this
+     * @exception UnsupportedOperationException if this
      *  <code>tranferType</code> is not supported by this
      *  <code>ColorModel</code>
      */
@@ -1055,7 +1055,7 @@
      * begin retrieving the color and alpha components
      * @return an <code>int</code> pixel value in this
      * <code>ColorModel</code> corresponding to the specified components.
-     * @exception <code>ArrayIndexOutOfBoundsException</code> if
+     * @exception ArrayIndexOutOfBoundsException if
      *  the <code>components</code> array is not large enough to
      *  hold all of the color and alpha components starting at
      *  <code>offset</code>
@@ -1097,9 +1097,9 @@
      * and alpha components
      * @return an <code>Object</code> representing an array of color and
      * alpha components.
-     * @exception <code>ClassCastException</code> if <code>obj</code>
+     * @exception ClassCastException if <code>obj</code>
      *  is not a primitive array of type <code>transferType</code>
-     * @exception <code>ArrayIndexOutOfBoundsException</code> if
+     * @exception ArrayIndexOutOfBoundsException if
      *  <code>obj</code> is not large enough to hold a pixel value
      *  for this <code>ColorModel</code> or the <code>components</code>
      *  array is not large enough to hold all of the color and alpha
--- a/src/share/classes/java/awt/image/ImageProducer.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/java/awt/image/ImageProducer.java	Tue Aug 13 18:33:25 2013 -0700
@@ -100,11 +100,11 @@
      * <code>ImageProducer</code> should respond by executing
      * the following minimum set of <code>ImageConsumer</code>
      * method calls:
-     * <pre>
+     * <pre>{@code
      *  ic.setHints(TOPDOWNLEFTRIGHT | < otherhints >);
      *  ic.setPixels(...);      // As many times as needed
      *  ic.imageComplete();
-     * </pre>
+     * }</pre>
      * @param ic the specified <code>ImageConsumer</code>
      * @see ImageConsumer#setHints
      */
--- a/src/share/classes/java/awt/image/IndexColorModel.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/java/awt/image/IndexColorModel.java	Tue Aug 13 18:33:25 2013 -0700
@@ -98,6 +98,7 @@
  * Index values greater than or equal to the map size, but less than
  * 2<sup><em>n</em></sup>, are undefined and return 0 for all color and
  * alpha components.
+ * </a>
  * <p>
  * For those methods that use a primitive array pixel representation of
  * type <code>transferType</code>, the array length is always one.
--- a/src/share/classes/java/awt/image/MemoryImageSource.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/java/awt/image/MemoryImageSource.java	Tue Aug 13 18:33:25 2013 -0700
@@ -37,7 +37,7 @@
  * uses an array to produce pixel values for an Image.  Here is an example
  * which calculates a 100x100 image representing a fade from black to blue
  * along the X axis and a fade from black to red along the Y axis:
- * <pre>
+ * <pre>{@code
  *
  *      int w = 100;
  *      int h = 100;
@@ -52,12 +52,12 @@
  *      }
  *      Image img = createImage(new MemoryImageSource(w, h, pix, 0, w));
  *
- * </pre>
+ * }</pre>
  * The MemoryImageSource is also capable of managing a memory image which
  * varies over time to allow animation or custom rendering.  Here is an
  * example showing how to set up the animation source and signal changes
  * in the data (adapted from the MemoryAnimationSourceDemo by Garth Dickie):
- * <pre>
+ * <pre>{@code
  *
  *      int pixels[];
  *      MemoryImageSource source;
@@ -96,7 +96,7 @@
  *          }
  *      }
  *
- * </pre>
+ * }</pre>
  *
  * @see ImageProducer
  *
--- a/src/share/classes/java/awt/image/MultiPixelPackedSampleModel.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/java/awt/image/MultiPixelPackedSampleModel.java	Tue Aug 13 18:33:25 2013 -0700
@@ -52,14 +52,14 @@
  * <code>x,&nbsp;y</code> from <code>DataBuffer</code> <code>data</code>
  * and storing the pixel data in data elements of type
  * <code>dataType</code>:
- * <pre>
+ * <pre>{@code
  *      int dataElementSize = DataBuffer.getDataTypeSize(dataType);
  *      int bitnum = dataBitOffset + x*pixelBitStride;
  *      int element = data.getElem(y*scanlineStride + bitnum/dataElementSize);
  *      int shift = dataElementSize - (bitnum & (dataElementSize-1))
  *                  - pixelBitStride;
  *      int pixel = (element >> shift) & ((1 << pixelBitStride) - 1);
- * </pre>
+ * }</pre>
  */
 
 public class MultiPixelPackedSampleModel extends SampleModel
--- a/src/share/classes/java/awt/image/PixelGrabber.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/java/awt/image/PixelGrabber.java	Tue Aug 13 18:33:25 2013 -0700
@@ -35,7 +35,7 @@
  * The PixelGrabber class implements an ImageConsumer which can be attached
  * to an Image or ImageProducer object to retrieve a subset of the pixels
  * in that image.  Here is an example:
- * <pre>
+ * <pre>{@code
  *
  * public void handlesinglepixel(int x, int y, int pixel) {
  *      int alpha = (pixel >> 24) & 0xff;
@@ -65,7 +65,7 @@
  *      }
  * }
  *
- * </pre>
+ * }</pre>
  *
  * @see ColorModel#getRGBdefault
  *
@@ -165,8 +165,8 @@
      * accumulated in the default RGB ColorModel.  If the forceRGB
      * parameter is true, then the pixels will be accumulated in the
      * default RGB ColorModel anyway.  A buffer is allocated by the
-     * PixelGrabber to hold the pixels in either case.  If (w < 0) or
-     * (h < 0), then they will default to the remaining width and
+     * PixelGrabber to hold the pixels in either case.  If {@code (w < 0)} or
+     * {@code (h < 0)}, then they will default to the remaining width and
      * height of the source data when that information is delivered.
      * @param img the image to retrieve the image data from
      * @param x the x coordinate of the upper left corner of the rectangle
@@ -233,10 +233,10 @@
      * behaves in the following ways, depending on the value of
      * <code>ms</code>:
      * <ul>
-     * <li> If <code>ms</code> == 0, waits until all pixels are delivered
-     * <li> If <code>ms</code> > 0, waits until all pixels are delivered
+     * <li> If {@code ms == 0}, waits until all pixels are delivered
+     * <li> If {@code ms > 0}, waits until all pixels are delivered
      * as timeout expires.
-     * <li> If <code>ms</code> < 0, returns <code>true</code> if all pixels
+     * <li> If {@code ms < 0}, returns <code>true</code> if all pixels
      * are grabbed, <code>false</code> otherwise and does not wait.
      * </ul>
      * @param ms the number of milliseconds to wait for the image pixels
--- a/src/share/classes/java/awt/image/RGBImageFilter.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/java/awt/image/RGBImageFilter.java	Tue Aug 13 18:33:25 2013 -0700
@@ -39,7 +39,7 @@
  * The only method which needs to be defined to create a useable image
  * filter is the filterRGB method.  Here is an example of a definition
  * of a filter which swaps the red and blue components of an image:
- * <pre>
+ * <pre>{@code
  *
  *      class RedBlueSwapFilter extends RGBImageFilter {
  *          public RedBlueSwapFilter() {
@@ -56,7 +56,7 @@
  *          }
  *      }
  *
- * </pre>
+ * }</pre>
  *
  * @see FilteredImageSource
  * @see ImageFilter
--- a/src/share/classes/java/awt/image/ShortLookupTable.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/java/awt/image/ShortLookupTable.java	Tue Aug 13 18:33:25 2013 -0700
@@ -114,7 +114,7 @@
      * @exception ArrayIndexOutOfBoundsException if <code>src</code> is
      *            longer than <code>dst</code> or if for any element
      *            <code>i</code> of <code>src</code>,
-     *            <code>(src[i]&0xffff)-offset</code> is either less than
+     *            {@code (src[i]&0xffff)-offset} is either less than
      *            zero or greater than or equal to the length of the
      *            lookup table for any band.
      */
@@ -165,7 +165,7 @@
      * @exception ArrayIndexOutOfBoundsException if <code>src</code> is
      *            longer than <code>dst</code> or if for any element
      *            <code>i</code> of <code>src</code>,
-     *            <code>(src[i]&0xffff)-offset</code> is either less than
+     *            {@code (src[i]&0xffff)-offset} is either less than
      *            zero or greater than or equal to the length of the
      *            lookup table for any band.
      */
--- a/src/share/classes/java/awt/image/SinglePixelPackedSampleModel.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/java/awt/image/SinglePixelPackedSampleModel.java	Tue Aug 13 18:33:25 2013 -0700
@@ -57,10 +57,10 @@
  * The following code illustrates extracting the bits of the sample
  * representing band <code>b</code> for pixel <code>x,y</code>
  * from DataBuffer <code>data</code>:
- * <pre>
+ * <pre>{@code
  *      int sample = data.getElem(y * scanlineStride + x);
  *      sample = (sample & bitMasks[b]) >>> bitOffsets[b];
- * </pre>
+ * }</pre>
  */
 
 public class SinglePixelPackedSampleModel extends SampleModel
--- a/src/share/classes/java/awt/image/WritableRaster.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/java/awt/image/WritableRaster.java	Tue Aug 13 18:33:25 2013 -0700
@@ -372,13 +372,13 @@
      * integral type and less than or equal to 32 bits in size, then calling
      * this method is equivalent to executing the following code for all
      * <code>x,y</code> addresses valid in both Rasters.
-     * <pre>
+     * <pre>{@code
      *       Raster srcRaster;
      *       WritableRaster dstRaster;
      *       for (int b = 0; b < srcRaster.getNumBands(); b++) {
      *           dstRaster.setSample(x, y, b, srcRaster.getSample(x, y, b));
      *       }
-     * </pre>
+     * }</pre>
      * Thus, when copying an integral type source to an integral type
      * destination, if the source sample size is greater than the destination
      * sample size for a particular band, the high order bits of the source
--- a/src/share/classes/javax/imageio/ImageIO.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/imageio/ImageIO.java	Tue Aug 13 18:33:25 2013 -0700
@@ -228,7 +228,7 @@
      * be used when creating <code>ImageInputStream</code>s and
      * <code>ImageOutputStream</code>s.
      *
-     * <p> When reading from a standard <code>InputStream</code>>, it
+     * <p> When reading from a standard <code>InputStream</code>, it
      * may be necessary to save previously read information in a cache
      * since the underlying stream does not allow data to be re-read.
      * Similarly, when writing to a standard
--- a/src/share/classes/javax/imageio/ImageReadParam.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/imageio/ImageReadParam.java	Tue Aug 13 18:33:25 2013 -0700
@@ -80,7 +80,7 @@
  *
  * <p> The resulting region is then subsampled according to the
  * factors given in {@link IIOParam#setSourceSubsampling
- * <code>IIOParam.setSourceSubsampling</code>}.  The first pixel,
+ * IIOParam.setSourceSubsampling}.  The first pixel,
  * the number of pixels per row, and the number of rows all depend
  * on the subsampling settings.
  * Call the minimum X and Y coordinates of the resulting rectangle
--- a/src/share/classes/javax/imageio/ImageReader.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/imageio/ImageReader.java	Tue Aug 13 18:33:25 2013 -0700
@@ -230,8 +230,8 @@
      * increased as each image (or thumbnail, or image metadata) is
      * read.  If <code>seekForwardOnly</code> is true, then a call to
      * <code>read(index)</code> will throw an
-     * <code>IndexOutOfBoundsException</code> if <code>index &lt
-     * this.minIndex</code>; otherwise, the value of
+     * <code>IndexOutOfBoundsException</code> if {@code index < this.minIndex};
+     * otherwise, the value of
      * <code>minIndex</code> will be set to <code>index</code>.  If
      * <code>seekForwardOnly</code> is <code>false</code>, the value of
      * <code>minIndex</code> will remain 0 regardless of any read
@@ -328,8 +328,8 @@
      * increased as each image (or thumbnail, or image metadata) is
      * read.  If <code>seekForwardOnly</code> is true, then a call to
      * <code>read(index)</code> will throw an
-     * <code>IndexOutOfBoundsException</code> if <code>index &lt
-     * this.minIndex</code>; otherwise, the value of
+     * <code>IndexOutOfBoundsException</code> if {@code index < this.minIndex};
+     * otherwise, the value of
      * <code>minIndex</code> will be set to <code>index</code>.  If
      * <code>seekForwardOnly</code> is <code>false</code>, the value of
      * <code>minIndex</code> will remain 0 regardless of any read
@@ -600,8 +600,7 @@
      * <p> Note that formats that return <code>false</code> from
      * this method may nonetheless allow tiling (<i>e.g.</i> Restart
      * Markers in JPEG), and random access will likely be reasonably
-     * efficient on tiles.  See {@link #isImageTiled
-     * <code>isImageTiled</code>}.
+     * efficient on tiles.  See {@link #isImageTiled isImageTiled}.
      *
      * <p> A reader for which all images are guaranteed to support
      * easy random access, or are guaranteed not to support easy
@@ -1212,11 +1211,10 @@
 
     /**
      * Returns <code>true</code> if this plug-in supports reading
-     * just a {@link java.awt.image.Raster <code>Raster</code>} of pixel data.
+     * just a {@link java.awt.image.Raster Raster} of pixel data.
      * If this method returns <code>false</code>, calls to
-     * {@link #readRaster <code>readRaster</code>} or {@link #readTileRaster
-     * <code>readTileRaster</code>} will throw an
-     * <code>UnsupportedOperationException</code>.
+     * {@link #readRaster readRaster} or {@link #readTileRaster readTileRaster}
+     * will throw an <code>UnsupportedOperationException</code>.
      *
      * <p> The default implementation returns <code>false</code>.
      *
@@ -1236,7 +1234,7 @@
      * application must determine how to interpret the pixel data by other
      * means.  Any destination or image-type parameters in the supplied
      * <code>ImageReadParam</code> object are ignored, but all other
-     * parameters are used exactly as in the {@link #read <code>read</code>}
+     * parameters are used exactly as in the {@link #read read}
      * method, except that any destination offset is used as a logical rather
      * than a physical offset.  The size of the returned <code>Raster</code>
      * will always be that of the source region clipped to the actual image.
@@ -1249,10 +1247,9 @@
      *
      * <p> Any registered <code>readUpdateListener</code>s are ignored, as
      * there is no <code>BufferedImage</code>, but all other listeners are
-     * called exactly as they are for the {@link #read <code>read</code>}
-     * method.
+     * called exactly as they are for the {@link #read read} method.
      *
-     * <p> If {@link #canReadRaster <code>canReadRaster()</code>} returns
+     * <p> If {@link #canReadRaster canReadRaster()} returns
      * <code>false</code>, this method throws an
      * <code>UnsupportedOperationException</code>.
      *
@@ -1481,13 +1478,13 @@
      * The application must determine how to interpret the pixel data by other
      * means.
      *
-     * <p> If {@link #canReadRaster <code>canReadRaster()</code>} returns
+     * <p> If {@link #canReadRaster canReadRaster()} returns
      * <code>false</code>, this method throws an
      * <code>UnsupportedOperationException</code>.
      *
      * <p> The default implementation checks if reading
      * <code>Raster</code>s is supported, and if so calls {@link
-     * #readRaster <code>readRaster(imageIndex, null)</code>} if
+     * #readRaster readRaster(imageIndex, null)} if
      * <code>tileX</code> and <code>tileY</code> are 0, or throws an
      * <code>IllegalArgumentException</code> otherwise.
      *
@@ -1548,8 +1545,8 @@
      * source render size or any format-specific settings), they will
      * be ignored.
      *
-     * <p> The default implementation just calls {@link #read
-     * <code>read(imageIndex, param)</code>}.
+     * <p> The default implementation just calls
+     * {@link #read read(imageIndex, param)}.
      *
      * @param imageIndex the index of the image to be retrieved.
      * @param param an <code>ImageReadParam</code> used to control
@@ -2544,9 +2541,8 @@
      * the supplied <code>ImageReadParam</code>.  The actual
      * subsampling factors, destination size, and destination offset
      * are <em>not</em> taken into consideration, thus further
-     * clipping must take place.  The {@link #computeRegions
-     * <code>computeRegions</code>} method performs all necessary
-     * clipping.
+     * clipping must take place.  The {@link #computeRegions computeRegions}
+     * method performs all necessary clipping.
      *
      * @param param the <code>ImageReadParam</code> being used, or
      * <code>null</code>.
@@ -2601,7 +2597,7 @@
      * width or height of 0, an <code>IllegalArgumentException</code>
      * is thrown.
      *
-     * <p> The {@link #getSourceRegion <code>getSourceRegion</code>}
+     * <p> The {@link #getSourceRegion getSourceRegion>}
      * method may be used if only source clipping is desired.
      *
      * @param param an <code>ImageReadParam</code>, or <code>null</code>.
--- a/src/share/classes/javax/imageio/ImageTypeSpecifier.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/imageio/ImageTypeSpecifier.java	Tue Aug 13 18:33:25 2013 -0700
@@ -840,7 +840,7 @@
      * not one of 1, 2, 4, 8, or 16.
      * @exception IllegalArgumentException if the
      * non-<code>null</code> LUT parameters do not have lengths of
-     * exactly <code>1 << bits</code>.
+     * exactly {@code 1 << bits}.
      * @exception IllegalArgumentException if <code>dataType</code> is
      * not one of <code>DataBuffer.TYPE_BYTE</code>,
      * <code>DataBuffer.TYPE_SHORT</code>,
--- a/src/share/classes/javax/imageio/ImageWriteParam.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/imageio/ImageWriteParam.java	Tue Aug 13 18:33:25 2013 -0700
@@ -49,7 +49,7 @@
  * and include additional pixels within the intersected bounds
  * according to the horizontal and vertical subsampling factors
  * specified by {@link IIOParam#setSourceSubsampling
- * <code>IIOParam.setSourceSubsampling</code>}.
+ * IIOParam.setSourceSubsampling}.
  *
  * <p> Individual features such as tiling, progressive encoding, and
  * compression may be set in one of four modes.
@@ -462,9 +462,8 @@
      * <code>IllegalStateException</code>.
      *
      * <li><code>MODE_EXPLICIT</code> - The image will be tiled
-     * according to parameters given in the {@link #setTiling
-     * <code>setTiling</code>} method.  Any previously set tiling
-     * parameters are discarded.
+     * according to parameters given in the {@link #setTiling setTiling}
+     * method.  Any previously set tiling parameters are discarded.
      *
      * <li><code>MODE_COPY_FROM_METADATA</code> - The image will
      * conform to the metadata object passed in to a write.
@@ -1421,7 +1420,7 @@
      * with <code>getCompressionQualityDescriptions</code> as part of a user
      * interface for setting or displaying the compression quality
      * level.  See {@link #getCompressionQualityDescriptions
-     * <code>getCompressionQualityDescriptions</code>} for more information.
+     * getCompressionQualityDescriptions} for more information.
      *
      * <p> If no descriptions are available, <code>null</code> is
      * returned.  If <code>null</code> is returned from
--- a/src/share/classes/javax/imageio/ImageWriter.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/imageio/ImageWriter.java	Tue Aug 13 18:33:25 2013 -0700
@@ -692,7 +692,7 @@
      * output prior to the current seek position may be flushed, and
      * need not be readable or writable, unless the plug-in needs to
      * be able to patch up the header information when
-     * <code>endWriteSequence</code> is called (<italic>e.g.</italic> TIFF).
+     * <code>endWriteSequence</code> is called (<i>e.g.</i> TIFF).
      *
      * <p> If <code>canWriteSequence</code> returns <code>false</code>,
      * this method will throw an
--- a/src/share/classes/javax/imageio/metadata/IIOMetadataFormatImpl.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/imageio/metadata/IIOMetadataFormatImpl.java	Tue Aug 13 18:33:25 2013 -0700
@@ -729,6 +729,7 @@
      * @param required <code>true</code> if an object value must be present.
      * @param defaultValue the default value for the
      * <code>Object</code> reference, or <code>null</code>.
+     * @param <T> the type of the object.
      *
      * @exception IllegalArgumentException if <code>elementName</code>
      * is <code>null</code>, or is not a legal element name for this format.
@@ -765,6 +766,7 @@
      * @param enumeratedValues a <code>List</code> of
      * <code>Object</code>s containing the legal values for the
      * object reference.
+     * @param <T> the type of the object.
      *
      * @exception IllegalArgumentException if <code>elementName</code>
      * is <code>null</code>, or is not a legal element name for this format.
@@ -836,6 +838,7 @@
      * is inclusive.
      * @param maxInclusive <code>true</code> if <code>maxValue</code>
      * is inclusive.
+     * @param <T> the type of the object.
      *
      * @exception IllegalArgumentException if <code>elementName</code>
      * is <code>null</code>, or is not a legal element name for this
--- a/src/share/classes/javax/imageio/plugins/bmp/BMPImageWriteParam.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/imageio/plugins/bmp/BMPImageWriteParam.java	Tue Aug 13 18:33:25 2013 -0700
@@ -56,9 +56,9 @@
  * <p><table border=1>
  * <caption><b>Compression Types</b></caption>
  * <tr><th>Type String</th> <th>Description</th>  <th>Image Types</th></tr>
- * <tr><td>BI_RGB</td>  <td>Uncompressed RLE</td> <td><= 8-bits/sample</td></tr>
- * <tr><td>BI_RLE8</td> <td>8-bit Run Length Encoding</td> <td><= 8-bits/sample</td></tr>
- * <tr><td>BI_RLE4</td> <td>4-bit Run Length Encoding</td> <td><= 4-bits/sample</td></tr>
+ * <tr><td>BI_RGB</td>  <td>Uncompressed RLE</td> <td>{@literal <= } 8-bits/sample</td></tr>
+ * <tr><td>BI_RLE8</td> <td>8-bit Run Length Encoding</td> <td>{@literal <=} 8-bits/sample</td></tr>
+ * <tr><td>BI_RLE4</td> <td>4-bit Run Length Encoding</td> <td>{@literal <=} 4-bits/sample</td></tr>
  * <tr><td>BI_BITFIELDS</td> <td>Packed data</td> <td> 16 or 32 bits/sample</td></tr>
  * </table>
  */
--- a/src/share/classes/javax/imageio/plugins/jpeg/JPEGImageReadParam.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/imageio/plugins/jpeg/JPEGImageReadParam.java	Tue Aug 13 18:33:25 2013 -0700
@@ -46,16 +46,15 @@
  * This class allows the tables to be specified directly from client
  * code.  If no tables are specified either in the stream or in a
  * <code>JPEGImageReadParam</code>, then the stream is presumed to use
- * the "standard" visually lossless tables.  See {@link JPEGQTable
- * <code>JPEGQTable</code>} and {@link JPEGHuffmanTable
- * <code>JPEGHuffmanTable</code>} for more information on the default
- * tables.
+ * the "standard" visually lossless tables.  See {@link JPEGQTable JPEGQTable}
+ * and {@link JPEGHuffmanTable JPEGHuffmanTable} for more information
+ *  on the default tables.
  *
  * <p> The default <code>JPEGImageReadParam</code> returned by the
  * <code>getDefaultReadParam</code> method of the builtin JPEG reader
  * contains no tables.  Default tables may be obtained from the table
- * classes {@link JPEGQTable <code>JPEGQTable</code>} and {@link
- * JPEGHuffmanTable <code>JPEGHuffmanTable</code>}.
+ * classes {@link JPEGQTable JPEGQTable} and
+ * {@link JPEGHuffmanTable JPEGHuffmanTable}.
  *
  * <p> If a stream does contain tables, the tables given in a
  * <code>JPEGImageReadParam</code> are ignored.  Furthermore, if the
@@ -64,13 +63,12 @@
  * abbreviated images.  Once tables have been read from a stream, they
  * can be overridden only by tables subsequently read from the same
  * stream.  In order to specify new tables, the {@link
- * javax.imageio.ImageReader#setInput <code>setInput</code>} method of
+ * javax.imageio.ImageReader#setInput setInput} method of
  * the reader must be called to change the stream.
  *
  * <p> Note that this class does not provide a means for obtaining the
  * tables found in a stream.  These may be extracted from a stream by
- * consulting the <code>IIOMetadata</code> object returned by the
- * reader.
+ * consulting the IIOMetadata object returned by the reader.
  *
  * <p>
  * For more information about the operation of the built-in JPEG plug-ins,
--- a/src/share/classes/javax/imageio/plugins/jpeg/JPEGImageWriteParam.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/imageio/plugins/jpeg/JPEGImageWriteParam.java	Tue Aug 13 18:33:25 2013 -0700
@@ -66,8 +66,8 @@
  * when an abbreviated stream must be written without writing any tables
  * to a stream first.  In order to use this class, the metadata object
  * passed into the writer must contain no tables, and no stream metadata
- * must be provided.  See {@link JPEGQTable <code>JPEGQTable</code>} and
- * {@link JPEGHuffmanTable <code>JPEGHuffmanTable</code>} for more
+ * must be provided.  See {@link JPEGQTable JPEGQTable} and
+ * {@link JPEGHuffmanTable JPEGHuffmanTable} for more
  * information on the default tables.
  *
  * <p> The default <code>JPEGImageWriteParam</code> returned by the
@@ -80,7 +80,7 @@
  * set of tables has been written, only tables in the metadata can
  * override them for subsequent writes, whether to the same stream or
  * a different one.  In order to specify new tables using this class,
- * the {@link javax.imageio.ImageWriter#reset <code>reset</code>}
+ * the {@link javax.imageio.ImageWriter#reset reset}
  * method of the writer must be called.
  *
  * <p>
--- a/src/share/classes/javax/imageio/spi/ImageReaderSpi.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/imageio/spi/ImageReaderSpi.java	Tue Aug 13 18:33:25 2013 -0700
@@ -78,7 +78,7 @@
      * <code>ImageInputStream.class</code>, to be returned from
      * <code>getInputTypes</code>.
      * @deprecated Instead of using this field, directly create
-     * the equivalent array <code>{ ImageInputStream.class }<code>.
+     * the equivalent array <code>{ ImageInputStream.class }</code>.
      */
     @Deprecated
     public static final Class[] STANDARD_INPUT_TYPE =
--- a/src/share/classes/javax/imageio/spi/ImageWriterSpi.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/imageio/spi/ImageWriterSpi.java	Tue Aug 13 18:33:25 2013 -0700
@@ -80,7 +80,7 @@
      * <code>ImageOutputStream.class</code>, to be returned from
      * <code>getOutputTypes</code>.
      * @deprecated Instead of using this field, directly create
-     * the equivalent array <code>{ ImageOutputStream.class }<code>.
+     * the equivalent array <code>{ ImageOutputStream.class }</code>.
      */
     @Deprecated
     public static final Class[] STANDARD_OUTPUT_TYPE =
--- a/src/share/classes/javax/imageio/spi/ServiceRegistry.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/imageio/spi/ServiceRegistry.java	Tue Aug 13 18:33:25 2013 -0700
@@ -157,6 +157,8 @@
      * or <code>null</code> if the system class loader (or, failing that
      * the bootstrap class loader) is to be used.
      *
+     * @param <T> the type of the providerClass.
+     *
      * @return An <code>Iterator</code> that yields provider objects
      * for the given service, in some arbitrary order.  The iterator
      * will throw an <code>Error</code> if a provider-configuration
@@ -188,6 +190,8 @@
      * @param providerClass a <code>Class</code>object indicating the
      * class or interface of the service providers being detected.
      *
+     * @param <T> the type of the providerClass.
+     *
      * @return An <code>Iterator</code> that yields provider objects
      * for the given service, in some arbitrary order.  The iterator
      * will throw an <code>Error</code> if a provider-configuration
@@ -247,6 +251,7 @@
      * @param provider the service provide object to be registered.
      * @param category the category under which to register the
      * provider.
+     * @param <T> the type of the provider.
      *
      * @return true if no provider of the same class was previously
      * registered in the same category category.
@@ -348,6 +353,7 @@
      * @param provider the service provider object to be deregistered.
      * @param category the category from which to deregister the
      * provider.
+     * @param <T> the type of the provider.
      *
      * @return <code>true</code> if the provider was previously
      * registered in the same category category,
@@ -435,6 +441,7 @@
      * @param category the category to be retrieved from.
      * @param useOrdering <code>true</code> if pairwise orderings
      * should be taken account in ordering the returned objects.
+     * @param <T> the type of the category.
      *
      * @return an <code>Iterator</code> containing service provider
      * objects from the given category, possibly in order.
@@ -490,6 +497,7 @@
      * whose <code>filter</code> method will be invoked.
      * @param useOrdering <code>true</code> if pairwise orderings
      * should be taken account in ordering the returned objects.
+     * @param <T> the type of the category.
      *
      * @return an <code>Iterator</code> containing service provider
      * objects from the given category, possibly in order.
@@ -517,6 +525,7 @@
      *
      * @param providerClass the <code>Class</code> of the desired
      * service provider object.
+     * @param <T> the type of the provider.
      *
      * @return a currently registered service provider object with the
      * desired <code>Class</code>type, or <code>null</code> is none is
@@ -561,6 +570,7 @@
      * @param firstProvider the preferred provider.
      * @param secondProvider the provider to which
      * <code>firstProvider</code> is preferred.
+     * @param <T> the type of the category.
      *
      * @return <code>true</code> if a previously unset ordering
      * was established.
@@ -606,6 +616,7 @@
      * @param firstProvider the formerly preferred provider.
      * @param secondProvider the provider to which
      * <code>firstProvider</code> was formerly preferred.
+     * @param <T> the type of the category.
      *
      * @return <code>true</code> if a previously set ordering was
      * disestablished.
--- a/src/share/classes/javax/imageio/stream/ImageInputStream.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/imageio/stream/ImageInputStream.java	Tue Aug 13 18:33:25 2013 -0700
@@ -183,7 +183,7 @@
      *
      * @return a boolean value from the stream.
      *
-     * @exception EOFException if the end of the stream is reached.
+     * @exception java.io.EOFException if the end of the stream is reached.
      * @exception IOException if an I/O error occurs.
      */
     boolean readBoolean() throws IOException;
@@ -201,7 +201,7 @@
      *
      * @return a signed byte value from the stream.
      *
-     * @exception EOFException if the end of the stream is reached.
+     * @exception java.io.EOFException if the end of the stream is reached.
      * @exception IOException if an I/O error occurs.
      */
     byte readByte() throws IOException;
@@ -225,7 +225,7 @@
      *
      * @return an unsigned byte value from the stream.
      *
-     * @exception EOFException if the end of the stream is reached.
+     * @exception java.io.EOFException if the end of the stream is reached.
      * @exception IOException if an I/O error occurs.
      */
     int readUnsignedByte() throws IOException;
@@ -240,7 +240,7 @@
      *
      * @return a signed short value from the stream.
      *
-     * @exception EOFException if the stream reaches the end before
+     * @exception java.io.EOFException if the stream reaches the end before
      * reading all the bytes.
      * @exception IOException if an I/O error occurs.
      *
@@ -261,7 +261,7 @@
      *
      * @return an unsigned short value from the stream, as an int.
      *
-     * @exception EOFException if the stream reaches the end before
+     * @exception java.io.EOFException if the stream reaches the end before
      * reading all the bytes.
      * @exception IOException if an I/O error occurs.
      *
@@ -278,7 +278,7 @@
      *
      * @return an unsigned char value from the stream.
      *
-     * @exception EOFException if the stream reaches the end before
+     * @exception java.io.EOFException if the stream reaches the end before
      * reading all the bytes.
      * @exception IOException if an I/O error occurs.
      *
@@ -296,7 +296,7 @@
      *
      * @return a signed int value from the stream.
      *
-     * @exception EOFException if the stream reaches the end before
+     * @exception java.io.EOFException if the stream reaches the end before
      * reading all the bytes.
      * @exception IOException if an I/O error occurs.
      *
@@ -316,7 +316,7 @@
      *
      * @return an unsigned int value from the stream, as a long.
      *
-     * @exception EOFException if the stream reaches the end before
+     * @exception java.io.EOFException if the stream reaches the end before
      * reading all the bytes.
      * @exception IOException if an I/O error occurs.
      *
@@ -334,7 +334,7 @@
      *
      * @return a signed long value from the stream.
      *
-     * @exception EOFException if the stream reaches the end before
+     * @exception java.io.EOFException if the stream reaches the end before
      * reading all the bytes.
      * @exception IOException if an I/O error occurs.
      *
@@ -352,7 +352,7 @@
      *
      * @return a float value from the stream.
      *
-     * @exception EOFException if the stream reaches the end before
+     * @exception java.io.EOFException if the stream reaches the end before
      * reading all the bytes.
      * @exception IOException if an I/O error occurs.
      *
@@ -370,7 +370,7 @@
      *
      * @return a double value from the stream.
      *
-     * @exception EOFException if the stream reaches the end before
+     * @exception java.io.EOFException if the stream reaches the end before
      * reading all the bytes.
      * @exception IOException if an I/O error occurs.
      *
@@ -469,7 +469,7 @@
      * then a <code>UTFDataFormatException</code> is thrown.
      *
      * <p> If end of file is encountered at any time during this
-     * entire process, then an <code>EOFException</code> is thrown.
+     * entire process, then an <code>java.io.EOFException</code> is thrown.
      *
      * <p> After every group has been converted to a character by this
      * process, the characters are gathered, in the same order in
@@ -488,10 +488,10 @@
      *
      * @return a String read from the stream.
      *
-     * @exception  EOFException  if this stream reaches the end
+     * @exception  java.io.EOFException  if this stream reaches the end
      * before reading all the bytes.
-     * @exception  UTFDataFormatException if the bytes do not represent a
-     * valid modified UTF-8 encoding of a string.
+     * @exception  java.io.UTFDataFormatException if the bytes do not represent
+     * a valid modified UTF-8 encoding of a string.
      * @exception IOException if an I/O error occurs.
      */
     String readUTF() throws IOException;
@@ -499,7 +499,7 @@
     /**
      * Reads <code>len</code> bytes from the stream, and stores them
      * into <code>b</code> starting at index <code>off</code>.
-     * If the end of the stream is reached, an <code>EOFException</code>
+     * If the end of the stream is reached, an <code>java.io.EOFException</code>
      * will be thrown.
      *
      * <p> The bit offset within the stream is reset to zero before
@@ -514,7 +514,7 @@
      * len</code> is greater than <code>b.length</code>.
      * @exception NullPointerException if <code>b</code> is
      * <code>null</code>.
-     * @exception EOFException if the stream reaches the end before
+     * @exception java.io.EOFException if the stream reaches the end before
      * reading all the bytes.
      * @exception IOException if an I/O error occurs.
      */
@@ -523,7 +523,7 @@
     /**
      * Reads <code>b.length</code> bytes from the stream, and stores them
      * into <code>b</code> starting at index <code>0</code>.
-     * If the end of the stream is reached, an <code>EOFException</code>
+     * If the end of the stream is reached, an <code>java.io.EOFException</code>
      * will be thrown.
      *
      * <p> The bit offset within the stream is reset to zero before
@@ -533,7 +533,7 @@
      *
      * @exception NullPointerException if <code>b</code> is
      * <code>null</code>.
-     * @exception EOFException if the stream reaches the end before
+     * @exception java.io.EOFException if the stream reaches the end before
      * reading all the bytes.
      * @exception IOException if an I/O error occurs.
      */
@@ -544,7 +544,7 @@
      * stream according to the current byte order, and
      * stores them into <code>s</code> starting at index
      * <code>off</code>.  If the end of the stream is reached, an
-     * <code>EOFException</code> will be thrown.
+     * <code>java.io.EOFException</code> will be thrown.
      *
      * <p> The bit offset within the stream is reset to zero before
      * the read occurs.
@@ -558,7 +558,7 @@
      * len</code> is greater than <code>s.length</code>.
      * @exception NullPointerException if <code>s</code> is
      * <code>null</code>.
-     * @exception EOFException if the stream reaches the end before
+     * @exception java.io.EOFException if the stream reaches the end before
      * reading all the bytes.
      * @exception IOException if an I/O error occurs.
      */
@@ -569,7 +569,7 @@
      * stream according to the current byte order, and
      * stores them into <code>c</code> starting at index
      * <code>off</code>.  If the end of the stream is reached, an
-     * <code>EOFException</code> will be thrown.
+     * <code>java.io.EOFException</code> will be thrown.
      *
      * <p> The bit offset within the stream is reset to zero before
      * the read occurs.
@@ -583,7 +583,7 @@
      * len</code> is greater than <code>c.length</code>.
      * @exception NullPointerException if <code>c</code> is
      * <code>null</code>.
-     * @exception EOFException if the stream reaches the end before
+     * @exception java.io.EOFException if the stream reaches the end before
      * reading all the bytes.
      * @exception IOException if an I/O error occurs.
      */
@@ -594,7 +594,7 @@
      * stream according to the current byte order, and
      * stores them into <code>i</code> starting at index
      * <code>off</code>.  If the end of the stream is reached, an
-     * <code>EOFException</code> will be thrown.
+     * <code>java.io.EOFException</code> will be thrown.
      *
      * <p> The bit offset within the stream is reset to zero before
      * the read occurs.
@@ -608,7 +608,7 @@
      * len</code> is greater than <code>i.length</code>.
      * @exception NullPointerException if <code>i</code> is
      * <code>null</code>.
-     * @exception EOFException if the stream reaches the end before
+     * @exception java.io.EOFException if the stream reaches the end before
      * reading all the bytes.
      * @exception IOException if an I/O error occurs.
      */
@@ -619,7 +619,7 @@
      * stream according to the current byte order, and
      * stores them into <code>l</code> starting at index
      * <code>off</code>.  If the end of the stream is reached, an
-     * <code>EOFException</code> will be thrown.
+     * <code>java.io.EOFException</code> will be thrown.
      *
      * <p> The bit offset within the stream is reset to zero before
      * the read occurs.
@@ -633,7 +633,7 @@
      * len</code> is greater than <code>l.length</code>.
      * @exception NullPointerException if <code>l</code> is
      * <code>null</code>.
-     * @exception EOFException if the stream reaches the end before
+     * @exception java.io.EOFException if the stream reaches the end before
      * reading all the bytes.
      * @exception IOException if an I/O error occurs.
      */
@@ -644,7 +644,7 @@
      * floats) from the stream according to the current byte order,
      * and stores them into <code>f</code> starting at
      * index <code>off</code>.  If the end of the stream is reached,
-     * an <code>EOFException</code> will be thrown.
+     * an <code>java.io.EOFException</code> will be thrown.
      *
      * <p> The bit offset within the stream is reset to zero before
      * the read occurs.
@@ -658,7 +658,7 @@
      * len</code> is greater than <code>f.length</code>.
      * @exception NullPointerException if <code>f</code> is
      * <code>null</code>.
-     * @exception EOFException if the stream reaches the end before
+     * @exception java.io.EOFException if the stream reaches the end before
      * reading all the bytes.
      * @exception IOException if an I/O error occurs.
      */
@@ -669,7 +669,7 @@
      * floats) from the stream according to the current byte order,
      * and stores them into <code>d</code> starting at
      * index <code>off</code>.  If the end of the stream is reached,
-     * an <code>EOFException</code> will be thrown.
+     * an <code>java.io.EOFException</code> will be thrown.
      *
      * <p> The bit offset within the stream is reset to zero before
      * the read occurs.
@@ -683,7 +683,7 @@
      * len</code> is greater than <code>d.length</code>.
      * @exception NullPointerException if <code>d</code> is
      * <code>null</code>.
-     * @exception EOFException if the stream reaches the end before
+     * @exception java.io.EOFException if the stream reaches the end before
      * reading all the bytes.
      * @exception IOException if an I/O error occurs.
      */
@@ -748,7 +748,7 @@
      * @return an <code>int</code> containing the value <code>0</code>
      * or <code>1</code>.
      *
-     * @exception EOFException if the stream reaches the end before
+     * @exception java.io.EOFException if the stream reaches the end before
      * reading all the bits.
      * @exception IOException if an I/O error occurs.
      */
@@ -768,13 +768,13 @@
      * the right side of the return value, as shown by the following
      * pseudo-code:
      *
-     * <pre>
+     * <pre>{@code
      * long accum = 0L;
      * for (int i = 0; i < numBits; i++) {
      *   accum <<= 1; // Shift left one bit to make room
      *   accum |= readBit();
      * }
-     * </pre>
+     * }</pre>
      *
      * Note that the result of <code>readBits(32)</code> may thus not
      * be equal to that of <code>readInt()</code> if a reverse network
@@ -782,7 +782,7 @@
      * false</code>).
      *
      * <p> If the end of the stream is encountered before all the bits
-     * have been read, an <code>EOFException</code> is thrown.
+     * have been read, an <code>java.io.EOFException</code> is thrown.
      *
      * @param numBits the number of bits to read, as an <code>int</code>
      * between 0 and 64, inclusive.
@@ -791,7 +791,7 @@
      *
      * @exception IllegalArgumentException if <code>numBits</code>
      * is not between 0 and 64, inclusive.
-     * @exception EOFException if the stream reaches the end before
+     * @exception java.io.EOFException if the stream reaches the end before
      * reading all the bits.
      * @exception IOException if an I/O error occurs.
      */
@@ -850,7 +850,7 @@
      * returned by <code>getflushedPosition</code>).
      *
      * <p> It is legal to seek past the end of the file; an
-     * <code>EOFException</code> will be thrown only if a read is
+     * <code>java.io.EOFException</code> will be thrown only if a read is
      * performed.
      *
      * @param pos a <code>long</code> containing the desired file
--- a/src/share/classes/javax/imageio/stream/ImageInputStreamImpl.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/imageio/stream/ImageInputStreamImpl.java	Tue Aug 13 18:33:25 2013 -0700
@@ -88,7 +88,7 @@
     /**
      * The position prior to which data may be discarded.  Seeking
      * to a smaller position is not allowed.  <code>flushedPos</code>
-     * will always be >= 0.
+     * will always be {@literal >= 0}.
      */
     protected long flushedPos = 0;
 
--- a/src/share/classes/javax/imageio/stream/ImageOutputStream.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/imageio/stream/ImageOutputStream.java	Tue Aug 13 18:33:25 2013 -0700
@@ -59,9 +59,9 @@
      * remainder of the current byte is padded with 0s
      * and written out first.  The bit offset will be 0 after the
      * write.  Implementers can use the
-     * {@link ImageOutputStreamImpl#flushBits <code>flushBits</code>}
-     * method of {@link ImageOutputStreamImpl
-     * <code>ImageOutputStreamImpl</code>} to guarantee this.
+     * {@link ImageOutputStreamImpl#flushBits flushBits}
+     * method of {@link ImageOutputStreamImpl ImageOutputStreamImpl}
+     * to guarantee this.
      *
      * @param b an <code>int</code> whose lower 8 bits are to be
      * written.
@@ -99,9 +99,9 @@
      * remainder of the current byte is padded with 0s
      * and written out first.  The bit offset will be 0 after the
      * write.  Implementers can use the
-     * {@link ImageOutputStreamImpl#flushBits <code>flushBits</code>}
-     * method of {@link ImageOutputStreamImpl
-     * <code>ImageOutputStreamImpl</code>} to guarantee this.
+     * {@link ImageOutputStreamImpl#flushBits flushBits}
+     * method of {@link ImageOutputStreamImpl ImageOutputStreamImpl}
+     * to guarantee this.
      *
      * @param b an array of <code>byte</code>s to be written.
      * @param off the start offset in the data.
@@ -182,8 +182,7 @@
     void writeShort(int v) throws IOException;
 
     /**
-     * This method is a synonym for
-     * {@link #writeShort <code>writeShort</code>}.
+     * This method is a synonym for {@link #writeShort writeShort}.
      *
      * @param v an <code>int</code> containing the char (unsigned
      * short) value to be written.
@@ -430,7 +429,7 @@
      *
      * @exception NullPointerException if <code>s</code> is
      * <code>null</code>.
-     * @exception UTFDataFormatException if the modified UTF-8
+     * @exception java.io.UTFDataFormatException if the modified UTF-8
      * representation of <code>s</code> requires more than 65536 bytes.
      * @exception IOException if an I/O error occurs.
      */
--- a/src/share/classes/javax/print/DocFlavor.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/DocFlavor.java	Tue Aug 13 18:33:25 2013 -0700
@@ -286,7 +286,7 @@
  * "autosensing" works is implementation dependent. In general, preformatted
  * autosense print data is provided in a byte oriented representation class
  * (byte array, InputStream, URL).
- *
+ * </UL>
  * <P>
  * <HR>
  * <H3>Service Formatted Print Data</H3>
@@ -545,7 +545,7 @@
      * the match.
      * @return String representing a mime parameter, or
      * null if that parameter is not in the mime type string.
-     * @exception throws NullPointerException if paramName is null.
+     * @exception NullPointerException if paramName is null.
      */
     public String getParameter(String paramName) {
         return
--- a/src/share/classes/javax/print/MultiDocPrintJob.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/MultiDocPrintJob.java	Tue Aug 13 18:33:25 2013 -0700
@@ -47,7 +47,7 @@
      * PrintJobListener.
      *
      * @param multiDoc The documents to be printed. ALL must be a flavor
-     *                          supported by the PrintJob & PrintService.
+     *        supported by the PrintJob {@literal &} PrintService.
      *
      * @param attributes The job attributes to be applied to this print job.
      *        If this parameter is null then the default attributes are used.
--- a/src/share/classes/javax/print/PrintService.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/PrintService.java	Tue Aug 13 18:33:25 2013 -0700
@@ -40,7 +40,7 @@
  * a printer's supported attributes.
  * <P>
  * Example:
- *   <PRE>
+ *   <PRE>{@code
  *   DocFlavor flavor = DocFlavor.INPUT_STREAM.POSTSCRIPT;
  *   PrintRequestAttributeSet aset = new HashPrintRequestAttributeSet();
  *   aset.add(MediaSizeName.ISO_A4);
@@ -56,7 +56,7 @@
  *        } catch (PrintException e) {
  *        }
  *   }
- *   </PRE>
+ *   }</PRE>
  */
 public interface PrintService {
 
--- a/src/share/classes/javax/print/ServiceUI.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/ServiceUI.java	Tue Aug 13 18:33:25 2013 -0700
@@ -118,7 +118,7 @@
      * any changes made by the user.
      *
      * A typical basic usage of this method may be :
-     * <pre>
+     * <pre>{@code
      * PrintService[] services = PrintServiceLookup.lookupPrintServices(
      *                            DocFlavor.INPUT_STREAM.JPEG, null);
      * PrintRequestAttributeSet attributes = new HashPrintRequestAttributeSet();
@@ -131,7 +131,7 @@
      *     ... print ...
      *    }
      * }
-     * </pre>
+     * }</pre>
      * <p>
 
      * @param gc used to select screen. null means primary or default screen.
--- a/src/share/classes/javax/print/ServiceUIFactory.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/ServiceUIFactory.java	Tue Aug 13 18:33:25 2013 -0700
@@ -39,8 +39,8 @@
  * initialize services only when needed without any API dependencies
  * except in an environment in which they are used.
  * <p>
- * Swing UIs are preferred as they provide a more consistent L&F and
- * can support accessibility APIs.
+ * Swing UIs are preferred as they provide a more consistent {@literal L&F}
+ * and can support accessibility APIs.
  * <p>
  * Example usage:
  * <pre>
--- a/src/share/classes/javax/print/attribute/AttributeSet.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/attribute/AttributeSet.java	Tue Aug 13 18:33:25 2013 -0700
@@ -42,7 +42,7 @@
  * class rather than the attribute object's class itself. An attribute
  * object's
  * category is determined by calling the {@link Attribute#getCategory()
- * <CODE>getCategory()</CODE>} method defined in interface {@link Attribute
+ * getCategory()} method defined in interface {@link Attribute
  * Attribute}.
  * <P>
  * The interfaces of an AttributeSet resemble those of the Java Collections
@@ -217,7 +217,7 @@
     /**
      * Adds all of the elements in the specified set to this attribute.
      * The outcome is the same as if the =
-     * {@link #add(Attribute) <CODE>add(Attribute)</CODE>}
+     * {@link #add(Attribute) add(Attribute)}
      * operation had been applied to this attribute set successively with each
      * element from the specified set.
      * The behavior of the <CODE>addAll(AttributeSet)</CODE>
@@ -301,7 +301,7 @@
      * This ensures that <tt>t1.equals(t2)</tt> implies that
      * <tt>t1.hashCode()==t2.hashCode()</tt> for any two attribute sets
      * <tt>t1</tt> and <tt>t2</tt>, as required by the general contract of
-     * {@link java.lang.Object#hashCode() <CODE>Object.hashCode()</CODE>}.
+     * {@link java.lang.Object#hashCode() Object.hashCode()}.
      *
      * @return  The hash code value for this attribute set.
      */
--- a/src/share/classes/javax/print/attribute/DateTimeSyntax.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/attribute/DateTimeSyntax.java	Tue Aug 13 18:33:25 2013 -0700
@@ -36,9 +36,9 @@
  * <P>
  * Under the hood, a date-time attribute is stored as a value of class <code>
  * java.util.Date</code>. You can get a date-time attribute's Date value by
- * calling {@link #getValue() <CODE>getValue()</CODE>}. A date-time attribute's
+ * calling {@link #getValue() getValue()}. A date-time attribute's
  * Date value is established when it is constructed (see {@link
- * #DateTimeSyntax(Date) <CODE>DateTimeSyntax(Date)</CODE>}). Once
+ * #DateTimeSyntax(Date) DateTimeSyntax(Date)}). Once
  * constructed, a date-time attribute's value is immutable.
  * <P>
  * To construct a date-time attribute from separate values of the year, month,
--- a/src/share/classes/javax/print/attribute/DocAttributeSet.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/attribute/DocAttributeSet.java	Tue Aug 13 18:33:25 2013 -0700
@@ -37,8 +37,8 @@
  * constructors and mutating operations guarantee an additional invariant,
  * namely that all attribute values in the DocAttributeSet must be instances
  * of interface {@link DocAttribute DocAttribute}.
- * The {@link #add(Attribute) <CODE>add(Attribute)</CODE>}, and
- * {@link #addAll(AttributeSet) <CODE>addAll(AttributeSet)</CODE>} operations
+ * The {@link #add(Attribute) add(Attribute)}, and
+ * {@link #addAll(AttributeSet) addAll(AttributeSet)} operations
  * are respecified below to guarantee this additional invariant.
  * <P>
  *
@@ -74,7 +74,7 @@
     /**
      * Adds all of the elements in the specified set to this attribute.
      * The outcome is  the same as if the
-     * {@link #add(Attribute) <CODE>add(Attribute)</CODE>}
+     * {@link #add(Attribute) add(Attribute)}
      * operation had been applied to this attribute set successively with
      * each element from the specified set. If none of the categories in the
      * specified set  are the same as any categories in this attribute set,
--- a/src/share/classes/javax/print/attribute/EnumSyntax.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/attribute/EnumSyntax.java	Tue Aug 13 18:33:25 2013 -0700
@@ -81,15 +81,15 @@
  * for identical objects (<CODE>==</CODE>).
  * <P>
  * You can convert an enumeration value to a string by calling {@link
- * #toString() <CODE>toString()</CODE>}. The string is obtained from a table
+ * #toString() toString()}. The string is obtained from a table
  * supplied by the enumeration class.
  * <P>
  * Under the hood, an enumeration value is just an integer, a different integer
  * for each enumeration value within an enumeration class. You can get an
  * enumeration value's integer value by calling {@link #getValue()
- * <CODE>getValue()</CODE>}. An enumeration value's integer value is established
+ * getValue()}. An enumeration value's integer value is established
  * when it is constructed (see {@link #EnumSyntax(int)
- * <CODE>EnumSyntax(int)</CODE>}). Since the constructor is protected, the only
+ * EnumSyntax(int)}). Since the constructor is protected, the only
  * possible enumeration values are the singleton objects declared in the
  * enumeration class; additional enumeration values cannot be created at run
  * time.
@@ -170,10 +170,10 @@
      *
      * @return  The enumeration singleton value stored at index
      *          <I>i</I>-<I>L</I> in the enumeration value table returned by
-     *          {@link #getEnumValueTable() <CODE>getEnumValueTable()</CODE>},
+     *          {@link #getEnumValueTable() getEnumValueTable()},
      *          where <I>i</I> is this enumeration value's integer value and
      *          <I>L</I> is the value returned by {@link #getOffset()
-     *          <CODE>getOffset()</CODE>}.
+     *          getOffset()}.
      *
      * @throws ObjectStreamException if the stream can't be deserialised
      * @throws  InvalidObjectException
@@ -220,18 +220,18 @@
      * Returns the string table for this enumeration value's enumeration class.
      * The enumeration class's integer values are assumed to lie in the range
      * <I>L</I>..<I>L</I>+<I>N</I>-1, where <I>L</I> is the value returned by
-     * {@link #getOffset() <CODE>getOffset()</CODE>} and <I>N</I> is the length
+     * {@link #getOffset() getOffset()} and <I>N</I> is the length
      * of the string table. The element in the string table at index
      * <I>i</I>-<I>L</I> is the value returned by {@link #toString()
-     * <CODE>toString()</CODE>} for the enumeration value whose integer value
+     * toString()} for the enumeration value whose integer value
      * is <I>i</I>. If an integer within the above range is not used by any
      * enumeration value, leave the corresponding table element null.
      * <P>
      * The default implementation returns null. If the enumeration class (a
      * subclass of class EnumSyntax) does not override this method to return a
      * non-null string table, and the subclass does not override the {@link
-     * #toString() <CODE>toString()</CODE>} method, the base class {@link
-     * #toString() <CODE>toString()</CODE>} method will return just a string
+     * #toString() toString()} method, the base class {@link
+     * #toString() toString()} method will return just a string
      * representation of this enumeration value's integer value.
      * @return the string table
      */
@@ -243,11 +243,11 @@
      * Returns the enumeration value table for this enumeration value's
      * enumeration class. The enumeration class's integer values are assumed to
      * lie in the range <I>L</I>..<I>L</I>+<I>N</I>-1, where <I>L</I> is the
-     * value returned by {@link #getOffset() <CODE>getOffset()</CODE>} and
+     * value returned by {@link #getOffset() getOffset()} and
      * <I>N</I> is the length of the enumeration value table. The element in the
      * enumeration value table at index <I>i</I>-<I>L</I> is the enumeration
      * value object whose integer value is <I>i</I>; the {@link #readResolve()
-     * <CODE>readResolve()</CODE>} method needs this to preserve singleton
+     * readResolve()} method needs this to preserve singleton
      * semantics during deserialization of an enumeration instance. If an
      * integer within the above range is not used by any enumeration value,
      * leave the corresponding table element null.
@@ -255,8 +255,8 @@
      * The default implementation returns null. If the enumeration class (a
      * subclass of class EnumSyntax) does not override this method to return
      * a non-null enumeration value table, and the subclass does not override
-     * the {@link #readResolve() <CODE>readResolve()</CODE>} method, the base
-     * class {@link #readResolve() <CODE>readResolve()</CODE>} method will throw
+     * the {@link #readResolve() readResolve()} method, the base
+     * class {@link #readResolve() readResolve()} method will throw
      * an exception whenever an enumeration instance is deserialized from an
      * object input stream.
      * @return the value table
--- a/src/share/classes/javax/print/attribute/HashAttributeSet.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/attribute/HashAttributeSet.java	Tue Aug 13 18:33:25 2013 -0700
@@ -388,7 +388,7 @@
     /**
      * Adds all of the elements in the specified set to this attribute.
      * The outcome is the same as if the
-     * {@link #add(Attribute) <CODE>add(Attribute)</CODE>}
+     * {@link #add(Attribute) add(Attribute)}
      * operation had been applied to this attribute set successively with
      * each element from the specified set.
      * The behavior of the <CODE>addAll(AttributeSet)</CODE>
@@ -512,7 +512,7 @@
      * This ensures that <tt>t1.equals(t2)</tt> implies that
      * <tt>t1.hashCode()==t2.hashCode()</tt> for any two attribute sets
      * <tt>t1</tt> and <tt>t2</tt>, as required by the general contract of
-     * {@link java.lang.Object#hashCode() <CODE>Object.hashCode()</CODE>}.
+     * {@link java.lang.Object#hashCode() Object.hashCode()}.
      *
      * @return  The hash code value for this attribute set.
      */
--- a/src/share/classes/javax/print/attribute/IntegerSyntax.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/attribute/IntegerSyntax.java	Tue Aug 13 18:33:25 2013 -0700
@@ -33,9 +33,9 @@
  * <P>
  * Under the hood, an integer attribute is just an integer. You can get an
  * integer attribute's integer value by calling {@link #getValue()
- * <CODE>getValue()</CODE>}. An integer attribute's integer value is
+ * getValue()}. An integer attribute's integer value is
  * established when it is constructed (see {@link #IntegerSyntax(int)
- * <CODE>IntegerSyntax(int)</CODE>}). Once constructed, an integer attribute's
+ * IntegerSyntax(int)}). Once constructed, an integer attribute's
  * value is immutable.
  * <P>
  *
--- a/src/share/classes/javax/print/attribute/PrintJobAttributeSet.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/attribute/PrintJobAttributeSet.java	Tue Aug 13 18:33:25 2013 -0700
@@ -36,8 +36,8 @@
  * constructors and mutating operations guarantee an additional invariant,
  * namely that all attribute values in the PrintJobAttributeSet must be
  * instances of interface {@link PrintJobAttribute PrintJobAttribute}.
- * The {@link #add(Attribute) <CODE>add(Attribute)</CODE>}, and
- * {@link #addAll(AttributeSet) <CODE>addAll(AttributeSet)</CODE>} operations
+ * The {@link #add(Attribute) add(Attribute)}, and
+ * {@link #addAll(AttributeSet) >addAll(AttributeSet)} operations
  * are respecified below to guarantee this additional invariant.
  * <P>
  *
@@ -72,7 +72,7 @@
     /**
      * Adds all of the elements in the specified set to this attribute.
      * The outcome is  the same as if the
-     * {@link #add(Attribute) <CODE>add(Attribute)</CODE>}
+     * {@link #add(Attribute) add(Attribute)}
      * operation had been applied to this attribute set successively with
      * each element from the specified set. If none of the categories in the
      * specified set  are the same as any categories in this attribute set,
--- a/src/share/classes/javax/print/attribute/PrintRequestAttributeSet.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/attribute/PrintRequestAttributeSet.java	Tue Aug 13 18:33:25 2013 -0700
@@ -37,8 +37,8 @@
  * constructors and mutating operations guarantee an additional invariant,
  * namely that all attribute values in the PrintRequestAttributeSet must be
  * instances of interface {@link PrintRequestAttribute PrintRequestAttribute}.
- * The {@link #add(Attribute) <CODE>add(Attribute)</CODE>}, and
- * {@link #addAll(AttributeSet) <CODE>addAll(AttributeSet)</CODE>} operations
+ * The {@link #add(Attribute) add(Attribute)}, and
+ * {@link #addAll(AttributeSet) addAll(AttributeSet)} operations
  * are respecified below to guarantee this additional invariant.
  * <P>
  *
@@ -73,7 +73,7 @@
     /**
      * Adds all of the elements in the specified set to this attribute.
      * The outcome is  the same as if the
-     * {@link #add(Attribute) <CODE>add(Attribute)</CODE>}
+     * {@link #add(Attribute) add(Attribute)}
      * operation had been applied to this attribute set successively with
      * each element from the specified set. If none of the categories in the
      * specified set  are the same as any categories in this attribute set,
--- a/src/share/classes/javax/print/attribute/PrintServiceAttributeSet.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/attribute/PrintServiceAttributeSet.java	Tue Aug 13 18:33:25 2013 -0700
@@ -39,8 +39,8 @@
  * invariant,
  * namely that all attribute values in the PrintServiceAttributeSet must be
  * instances of interface {@link PrintServiceAttribute PrintServiceAttribute}.
- * The {@link #add(Attribute) <CODE>add(Attribute)</CODE>}, and
- * {@link #addAll(AttributeSet) <CODE>addAll(AttributeSet)</CODE>} operations
+ * The {@link #add(Attribute) add(Attribute)}, and
+ * {@link #addAll(AttributeSet) addAll(AttributeSet)} operations
  * are respecified below to guarantee this additional invariant.
  * <P>
  *
@@ -77,7 +77,7 @@
     /**
      * Adds all of the elements in the specified set to this attribute.
      * The outcome is  the same as if the
-     * {@link #add(Attribute) <CODE>add(Attribute)</CODE>}
+     * {@link #add(Attribute) add(Attribute)}
      * operation had been applied to this attribute set successively with
      * each element from the specified set. If none of the categories in the
      * specified set  are the same as any categories in this attribute set,
--- a/src/share/classes/javax/print/attribute/ResolutionSyntax.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/attribute/ResolutionSyntax.java	Tue Aug 13 18:33:25 2013 -0700
@@ -39,7 +39,7 @@
  * resolution attribute's values, indicating the units in which the values are
  * to be returned. The two most common resolution units are dots per inch (dpi)
  * and dots per centimeter (dpcm), and exported constants {@link #DPI
- * <CODE>DPI</CODE>} and {@link #DPCM <CODE>DPCM</CODE>} are provided for
+ * DPI} and {@link #DPCM DPCM} are provided for
  * indicating those units.
  * <P>
  * Once constructed, a resolution attribute's value is immutable.
@@ -68,9 +68,9 @@
  * done, which would not be guaranteed if a floating point representation were
  * used.
  * <P>
- * The exported constant {@link #DPI <CODE>DPI</CODE>} is actually the
+ * The exported constant {@link #DPI DPI} is actually the
  * conversion factor by which to multiply a value in dpi to get the value in
- * dphi. Likewise, the exported constant {@link #DPCM <CODE>DPCM</CODE>} is the
+ * dphi. Likewise, the exported constant {@link #DPCM DPCM} is the
  * conversion factor by which to multiply a value in dpcm to get the value in
  * dphi. A client can specify a resolution value in units other than dpi or dpcm
  * by supplying its own conversion factor. However, since the internal units of
@@ -120,12 +120,12 @@
      * @param  feedResolution
      *     Feed direction resolution.
      * @param units
-     *     Unit conversion factor, e.g. {@link #DPI <CODE>DPI</CODE>} or
-     * {@link    #DPCM <CODE>DPCM</CODE>}.
+     *     Unit conversion factor, e.g. {@link #DPI DPI} or
+     * {@link    #DPCM DPCM}.
      *
      * @exception  IllegalArgumentException
-     *     (unchecked exception) Thrown if <CODE>crossFeedResolution</CODE> <
-     *     1 or <CODE>feedResolution</CODE> < 1 or <CODE>units</CODE> < 1.
+     *     (unchecked exception) Thrown if {@code crossFeedResolution < 1}
+     *     or {@code feedResolution < 1} or {@code units < 1}.
      */
     public ResolutionSyntax(int crossFeedResolution, int feedResolution,
                             int units) {
@@ -172,14 +172,14 @@
      * The values are rounded to the nearest integer.
      *
      * @param  units
-     *     Unit conversion factor, e.g. {@link #DPI <CODE>DPI</CODE>} or
-     * {@link   #DPCM <CODE>DPCM</CODE>}.
+     *     Unit conversion factor, e.g. {@link #DPI DPI} or
+     * {@link   #DPCM DPCM}.
      *
      * @return  A two-element array with the cross feed direction resolution
      *          at index 0 and the feed direction resolution at index 1.
      *
      * @exception  IllegalArgumentException
-     *     (unchecked exception) Thrown if <CODE>units</CODE> < 1.
+     *     (unchecked exception) Thrown if {@code units < 1}.
      */
     public int[] getResolution(int units) {
         return new int[] { getCrossFeedResolution(units),
@@ -192,13 +192,13 @@
      * the given units. The value is rounded to the nearest integer.
      *
      * @param  units
-     *     Unit conversion factor, e.g. {@link #DPI <CODE>DPI</CODE>} or
-     * {@link  #DPCM <CODE>DPCM</CODE>}.
+     *     Unit conversion factor, e.g. {@link #DPI DPI} or
+     * {@link  #DPCM DPCM}.
      *
      * @return  Cross feed direction resolution.
      *
      * @exception  IllegalArgumentException
-     *     (unchecked exception) Thrown if <CODE>units</CODE> < 1.
+     *     (unchecked exception) Thrown if {@code units < 1}.
      */
     public int getCrossFeedResolution(int units) {
         return convertFromDphi (crossFeedResolution, units);
@@ -209,13 +209,13 @@
      * given units. The value is rounded to the nearest integer.
      *
      * @param  units
-     *     Unit conversion factor, e.g. {@link #DPI <CODE>DPI</CODE>} or {@link
-     *     #DPCM <CODE>DPCM</CODE>}.
+     *     Unit conversion factor, e.g. {@link #DPI DPI} or {@link
+     *     #DPCM DPCM}.
      *
      * @return  Feed direction resolution.
      *
      * @exception  IllegalArgumentException
-     *     (unchecked exception) Thrown if <CODE>units</CODE> < 1.
+     *     (unchecked exception) Thrown if {@code units < 1}.
      */
     public int getFeedResolution(int units) {
         return convertFromDphi (feedResolution, units);
@@ -229,8 +229,8 @@
      * rounded to the nearest integer.
      *
      * @param  units
-     *     Unit conversion factor, e.g. {@link #DPI <CODE>DPI</CODE>} or {@link
-     *     #DPCM <CODE>DPCM</CODE>}.
+     *     Unit conversion factor, e.g. {@link #DPI CODE>DPI} or {@link
+     *     #DPCM DPCM}.
      * @param  unitsName
      *     Units name string, e.g. <CODE>"dpi"</CODE> or <CODE>"dpcm"</CODE>. If
      *     null, no units name is appended to the result.
@@ -238,7 +238,7 @@
      * @return  String version of this resolution attribute.
      *
      * @exception  IllegalArgumentException
-     *     (unchecked exception) Thrown if <CODE>units</CODE> < 1.
+     *     (unchecked exception) Thrown if {@code units < 1}.
      */
     public String toString(int units, String unitsName) {
         StringBuffer result = new StringBuffer();
--- a/src/share/classes/javax/print/attribute/Size2DSyntax.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/attribute/Size2DSyntax.java	Tue Aug 13 18:33:25 2013 -0700
@@ -38,8 +38,8 @@
  * values are measured. Methods are provided to return a two-dimensional size
  * attribute's values, indicating the units in which the values are to be
  * returned. The two most common size units are inches (in) and millimeters
- * (mm), and exported constants {@link #INCH <CODE>INCH</CODE>} and {@link #MM
- * <CODE>MM</CODE>} are provided for indicating those units.
+ * (mm), and exported constants {@link #INCH INCH} and {@link #MM
+ * MM} are provided for indicating those units.
  * <P>
  * Once constructed, a two-dimensional size attribute's value is immutable.
  * <P>
@@ -66,9 +66,9 @@
  * units, you have to search for a media size of 215.9 x 279.4 mm; rounding off
  * to an integral 216 x 279 mm will not match.
  * <P>
- * The exported constant {@link #INCH <CODE>INCH</CODE>} is actually the
+ * The exported constant {@link #INCH INCH} is actually the
  * conversion factor by which to multiply a value in inches to get the value in
- * &#181;m. Likewise, the exported constant {@link #MM <CODE>MM</CODE>} is the
+ * &#181;m. Likewise, the exported constant {@link #MM MM} is the
  * conversion factor by which to multiply a value in mm to get the value in
  * &#181;m. A client can specify a resolution value in units other than inches
  * or mm by supplying its own conversion factor. However, since the internal
@@ -117,12 +117,12 @@
      * @param  x  X dimension.
      * @param  y  Y dimension.
      * @param  units
-     *     Unit conversion factor, e.g. {@link #INCH <CODE>INCH</CODE>} or
-     *     {@link #MM <CODE>MM</CODE>}.
+     *     Unit conversion factor, e.g. {@link #INCH INCH} or
+     *     {@link #MM MM}.
      *
      * @exception  IllegalArgumentException
-     *     (Unchecked exception) Thrown if <CODE>x</CODE> < 0 or <CODE>y</CODE>
-     *     < 0 or <CODE>units</CODE> < 1.
+     *     (Unchecked exception) Thrown if {@code x < 0} or {@code y < 0} or
+     *     {@code units < 1}.
      */
     protected Size2DSyntax(float x, float y, int units) {
         if (x < 0.0f) {
@@ -145,12 +145,12 @@
      * @param  x  X dimension.
      * @param  y  Y dimension.
      * @param  units
-     *     Unit conversion factor, e.g. {@link #INCH <CODE>INCH</CODE>} or
-     *     {@link #MM <CODE>MM</CODE>}.
+     *     Unit conversion factor, e.g. {@link #INCH INCH} or
+     *     {@link #MM MM}.
      *
      * @exception  IllegalArgumentException
-     *   (Unchecked exception) Thrown if <CODE>x</CODE> < 0 or <CODE>y</CODE>
-     *    < 0 or <CODE>units</CODE> < 1.
+     *   (Unchecked exception) Thrown if {@code x < 0} or {@code y < 0}
+     *    or {@code units < 1}.
      */
     protected Size2DSyntax(int x, int y, int units) {
         if (x < 0) {
@@ -193,14 +193,13 @@
      * as floating-point values.
      *
      * @param  units
-     *     Unit conversion factor, e.g. {@link #INCH <CODE>INCH</CODE>} or
-     *     {@link #MM <CODE>MM</CODE>}.
+     *     Unit conversion factor, e.g. {@link #INCH INCH} or {@link #MM MM}.
      *
      * @return  A two-element array with the X dimension at index 0 and the Y
      *          dimension at index 1.
      *
      * @exception  IllegalArgumentException
-     *     (unchecked exception) Thrown if <CODE>units</CODE> < 1.
+     *     (unchecked exception) Thrown if {@code units < 1}.
      */
     public float[] getSize(int units) {
         return new float[] {getX(units), getY(units)};
@@ -211,13 +210,12 @@
      * units as a floating-point value.
      *
      * @param  units
-     *     Unit conversion factor, e.g. {@link #INCH <CODE>INCH</CODE>} or
-     *     {@link #MM <CODE>MM</CODE>}.
+     *     Unit conversion factor, e.g. {@link #INCH INCH} or {@link #MM MM}.
      *
      * @return  X dimension.
      *
      * @exception  IllegalArgumentException
-     *     (unchecked exception) Thrown if <CODE>units</CODE> < 1.
+     *     (unchecked exception) Thrown if {@code units < 1}.
      */
     public float getX(int units) {
         return convertFromMicrometers(x, units);
@@ -228,13 +226,12 @@
      * units as a floating-point value.
      *
      * @param  units
-     *     Unit conversion factor, e.g. {@link #INCH <CODE>INCH</CODE>} or
-     *     {@link #MM <CODE>MM</CODE>}.
+     *     Unit conversion factor, e.g. {@link #INCH INCH} or {@link #MM MM}.
      *
      * @return  Y dimension.
      *
      * @exception  IllegalArgumentException
-     *     (unchecked exception) Thrown if <CODE>units</CODE> < 1.
+     *     (unchecked exception) Thrown if {@code units < 1}.
      */
     public float getY(int units) {
         return convertFromMicrometers(y, units);
@@ -248,16 +245,16 @@
      * floating point.
      *
      * @param  units
-     *     Unit conversion factor, e.g. {@link #INCH <CODE>INCH</CODE>} or
-     *     {@link #MM <CODE>MM</CODE>}.
+     *     Unit conversion factor, e.g. {@link #INCH INCH} or {@link #MM MM}.
+     *
      * @param  unitsName
-     *     Units name string, e.g. <CODE>"in"</CODE> or <CODE>"mm"</CODE>. If
+     *     Units name string, e.g. {@code in} or {@code mm}. If
      *     null, no units name is appended to the result.
      *
      * @return  String version of this two-dimensional size attribute.
      *
      * @exception  IllegalArgumentException
-     *     (unchecked exception) Thrown if <CODE>units</CODE> < 1.
+     *     (unchecked exception) Thrown if {@code units < 1}.
      */
     public String toString(int units, String unitsName) {
         StringBuffer result = new StringBuffer();
--- a/src/share/classes/javax/print/attribute/standard/Chromaticity.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/attribute/standard/Chromaticity.java	Tue Aug 13 18:33:25 2013 -0700
@@ -40,11 +40,11 @@
  * can be verified to support color printing.
  * <P>
  * The table below shows the effects of specifying a Chromaticity attribute of
- * {@link #MONOCHROME <CODE>MONOCHROME</CODE>} or {@link #COLOR
- * <CODE>COLOR</CODE>} for a monochrome or color document.
+ * {@link #MONOCHROME MONOCHROME} or {@link #COLOR COLOR}
+ * for a monochrome or color document.
  * <P>
  * <TABLE BORDER=1 CELLPADDING=2 CELLSPACING=1 SUMMARY="Shows effects of specifying MONOCHROME or COLOR Chromaticity attributes">
- * <TR BGCOLOR="#E5E5E5">
+ * <TR>
  * <TH>
  * Chromaticity<BR>Attribute
  * </TH>
@@ -57,7 +57,7 @@
  * </TR>
  * <TR>
  * <TD>
- * {@link #MONOCHROME <CODE>MONOCHROME</CODE>}
+ * {@link #MONOCHROME MONOCHROME}
  * </TD>
  * <TD>
  * Printed as is, in monochrome
@@ -68,7 +68,7 @@
  * </TR>
  * <TR>
  * <TD>
- * {@link #COLOR <CODE>COLOR</CODE>}
+ * {@link #COLOR COLOR}
  * </TD>
  * <TD>
  * Printed as is, in monochrome
--- a/src/share/classes/javax/print/attribute/standard/Compression.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/attribute/standard/Compression.java	Tue Aug 13 18:33:25 2013 -0700
@@ -34,7 +34,7 @@
  * print data (the doc), not of the Print Job. If a Compression attribute is not
  * specified for a doc, the printer assumes the doc's print data is uncompressed
  * (i.e., the default Compression value is always {@link #NONE
- * <CODE>NONE</CODE>}).
+ * NONE}).
  * <P>
  * <B>IPP Compatibility:</B> The category name returned by
  * <CODE>getName()</CODE> is the IPP attribute name.  The enumeration's
--- a/src/share/classes/javax/print/attribute/standard/Finishings.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/attribute/standard/Finishings.java	Tue Aug 13 18:33:25 2013 -0700
@@ -46,13 +46,13 @@
  * &nbsp;
  * </TD>
  * <TD WIDTH=27%>
- * {@link #NONE <CODE>NONE</CODE>}
+ * {@link #NONE NONE}
  * </TD>
  * <TD WIDTH=27%>
- * {@link #STAPLE <CODE>STAPLE</CODE>}
+ * {@link #STAPLE STAPLE}
  * </TD>
  * <TD WIDTH=36%>
- * {@link #EDGE_STITCH <CODE>EDGE_STITCH</CODE>}
+ * {@link #EDGE_STITCH EDGE_STITCH}
  * </TD>
  * </TR>
  * <TR>
@@ -60,13 +60,13 @@
  * &nbsp;
  * </TD>
  * <TD>
- * {@link #BIND <CODE>BIND</CODE>}
+ * {@link #BIND BIND}
  * </TD>
  * <TD>
- * {@link #SADDLE_STITCH <CODE>SADDLE_STITCH</CODE>}
+ * {@link #SADDLE_STITCH SADDLE_STITCH}
  * </TD>
  * <TD>
- * {@link #COVER <CODE>COVER</CODE>}
+ * {@link #COVER COVER}
  * </TD>
  * <TD>
  * &nbsp;
@@ -82,13 +82,13 @@
  * &nbsp;
  * </TD>
  * <TD WIDTH=27%>
- * {@link #STAPLE_TOP_LEFT <CODE>STAPLE_TOP_LEFT</CODE>}
+ * {@link #STAPLE_TOP_LEFT STAPLE_TOP_LEFT}
  * </TD>
  * <TD WIDTH=27%>
- * {@link #EDGE_STITCH_LEFT <CODE>EDGE_STITCH_LEFT</CODE>}
+ * {@link #EDGE_STITCH_LEFT EDGE_STITCH_LEFT}
  * </TD>
  * <TD WIDTH=27%>
- * {@link #STAPLE_DUAL_LEFT <CODE>STAPLE_DUAL_LEFT</CODE>}
+ * {@link #STAPLE_DUAL_LEFT STAPLE_DUAL_LEFT}
  * </TD>
  * <TD WIDTH=9%>
  * &nbsp;
@@ -99,13 +99,13 @@
  * &nbsp;
  * </TD>
  * <TD WIDTH=27%>
- * {@link #STAPLE_BOTTOM_LEFT <CODE>STAPLE_BOTTOM_LEFT</CODE>}
+ * {@link #STAPLE_BOTTOM_LEFT STAPLE_BOTTOM_LEFT}
  * </TD>
  * <TD WIDTH=27%>
- * {@link #EDGE_STITCH_TOP <CODE>EDGE_STITCH_TOP</CODE>}
+ * {@link #EDGE_STITCH_TOP EDGE_STITCH_TOP}
  * </TD>
  * <TD WIDTH=27%>
- * {@link #STAPLE_DUAL_TOP <CODE>STAPLE_DUAL_TOP</CODE>}
+ * {@link #STAPLE_DUAL_TOP STAPLE_DUAL_TOP}
  * </TD>
  * <TD WIDTH=9%>
  * &nbsp;
@@ -116,13 +116,13 @@
  * &nbsp;
  * </TD>
  * <TD WIDTH=27%>
- * {@link #STAPLE_TOP_RIGHT <CODE>STAPLE_TOP_RIGHT</CODE>}
+ * {@link #STAPLE_TOP_RIGHT STAPLE_TOP_RIGHT}
  * </TD>
  * <TD WIDTH=27%>
- * {@link #EDGE_STITCH_RIGHT <CODE>EDGE_STITCH_RIGHT</CODE>}
+ * {@link #EDGE_STITCH_RIGHT EDGE_STITCH_RIGHT}
  * </TD>
  * <TD WIDTH=27%>
- * {@link #STAPLE_DUAL_RIGHT <CODE>STAPLE_DUAL_RIGHT</CODE>}
+ * {@link #STAPLE_DUAL_RIGHT STAPLE_DUAL_RIGHT}
  * </TD>
  * <TD WIDTH=9%>
  * &nbsp;
@@ -133,13 +133,13 @@
  * &nbsp;
  * </TD>
  * <TD WIDTH=27%>
- * {@link #STAPLE_BOTTOM_RIGHT <CODE>STAPLE_BOTTOM_RIGHT</CODE>}
+ * {@link #STAPLE_BOTTOM_RIGHT STAPLE_BOTTOM_RIGHT}
  * </TD>
  * <TD WIDTH=27%>
- * {@link #EDGE_STITCH_BOTTOM <CODE>EDGE_STITCH_BOTTOM</CODE>}
+ * {@link #EDGE_STITCH_BOTTOM EDGE_STITCH_BOTTOM}
  * </TD>
  * <TD WIDTH=27%>
- * {@link #STAPLE_DUAL_BOTTOM <CODE>STAPLE_DUAL_BOTTOM</CODE>}
+ * {@link #STAPLE_DUAL_BOTTOM STAPLE_DUAL_BOTTOM}
  * </TD>
  * <TD WIDTH=9%>
  * &nbsp;
@@ -147,16 +147,16 @@
  * </TR>
  * </TABLE>
  * <P>
- * The <CODE>STAPLE_<I>XXX</I></CODE> values are specified with respect to the
+ * The STAPLE_<I>XXX</I> values are specified with respect to the
  * document as if the document were a portrait document. If the document is
  * actually a landscape or a reverse-landscape document, the client supplies the
  * appropriate transformed value. For example, to position a staple in the upper
  * left hand corner of a landscape document when held for reading, the client
- * supplies the <CODE>STAPLE_BOTTOM_LEFT</CODE> value (since landscape is
+ * supplies the STAPLE_BOTTOM_LEFT value (since landscape is
  * defined as a +90 degree rotation from portrait, i.e., anti-clockwise). On the
  * other hand, to position a staple in the upper left hand corner of a
  * reverse-landscape document when held for reading, the client supplies the
- * <CODE>STAPLE_TOP_RIGHT</CODE> value (since reverse-landscape is defined as a
+ * STAPLE_TOP_RIGHT value (since reverse-landscape is defined as a
  * -90 degree rotation from portrait, i.e., clockwise).
  * <P>
  * The angle (vertical, horizontal, angled) of each staple with respect to the
--- a/src/share/classes/javax/print/attribute/standard/JobKOctets.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/attribute/standard/JobKOctets.java	Tue Aug 13 18:33:25 2013 -0700
@@ -67,7 +67,7 @@
  * shown in the table below.
  * <P>
  * <TABLE BORDER=1 CELLPADDING=2 CELLSPACING=1 SUMMARY="Table showing computation of doc sizes">
- * <TR BGCOLOR="#E5E5E5">
+ * <TR>
  * <TH>Representation Class</TH>
  * <TH>Document Size</TH>
  * </TR>
--- a/src/share/classes/javax/print/attribute/standard/MediaPrintableArea.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/attribute/standard/MediaPrintableArea.java	Tue Aug 13 18:33:25 2013 -0700
@@ -62,7 +62,7 @@
  * The (x,y) origin is positioned at the top-left of the paper in portrait
  * mode regardless of the orientation specified in the requesting context.
  * For example a printable area for A4 paper in portrait or landscape
- * orientation will have height > width.
+ * orientation will have height {@literal >} width.
  * <p>
  * A printable area attribute's values are stored
  * internally as integers in units of micrometers (&#181;m), where 1 micrometer
@@ -107,9 +107,9 @@
       * @param units  in which the values are expressed.
       *
       * @exception  IllegalArgumentException
-      *     Thrown if <CODE>x</CODE> < 0 or <CODE>y</CODE> < 0
-      *     or <CODE>w</CODE> <= 0 or <CODE>h</CODE> <= 0 or
-      *     <CODE>units</CODE> < 1.
+      *     Thrown if {@code x < 0} or {@code y < 0}
+      *     or {@code w <= 0} or {@code h <= 0} or
+      *     {@code units < 1}.
       */
     public MediaPrintableArea(float x, float y, float w, float h, int units) {
         if ((x < 0.0) || (y < 0.0) || (w <= 0.0) || (h <= 0.0) ||
@@ -133,9 +133,9 @@
       * @param units  in which the values are expressed.
       *
       * @exception  IllegalArgumentException
-      *     Thrown if <CODE>x</CODE> < 0 or <CODE>y</CODE> < 0
-      *     or <CODE>w</CODE> <= 0 or <CODE>h</CODE> <= 0 or
-      *     <CODE>units</CODE> < 1.
+      *     Thrown if {@code x < 0} or {@code y < 0}
+      *     or {@code w <= 0} or {@code h <= 0} or
+      *     {@code units < 1}.
       */
     public MediaPrintableArea(int x, int y, int w, int h, int units) {
         if ((x < 0) || (y < 0) || (w <= 0) || (h <= 0) ||
@@ -159,7 +159,7 @@
      * @return printable area as array of x, y, w, h in the specified units.
      *
      * @exception  IllegalArgumentException
-     *     (unchecked exception) Thrown if <CODE>units</CODE> < 1.
+     *     (unchecked exception) Thrown if {@code units < 1}.
      */
     public float[] getPrintableArea(int units) {
         return new float[] { getX(units), getY(units),
@@ -177,7 +177,7 @@
      * specified units.
      *
      * @exception  IllegalArgumentException
-     *     (unchecked exception) Thrown if <CODE>units</CODE> < 1.
+     *     (unchecked exception) Thrown if {@code units < 1}.
      */
      public float getX(int units) {
         return convertFromMicrometers(x, units);
@@ -194,7 +194,7 @@
      * specified units.
      *
      * @exception  IllegalArgumentException
-     *     (unchecked exception) Thrown if <CODE>units</CODE> < 1.
+     *     (unchecked exception) Thrown if {@code units < 1}.
      */
      public float getY(int units) {
         return convertFromMicrometers(y, units);
@@ -209,7 +209,7 @@
      * @return  width of the printable area in the specified units.
      *
      * @exception  IllegalArgumentException
-     *     (unchecked exception) Thrown if <CODE>units</CODE> < 1.
+     *     (unchecked exception) Thrown if {@code units < 1}.
      */
      public float getWidth(int units) {
         return convertFromMicrometers(w, units);
@@ -224,7 +224,7 @@
      * @return  height of the printable area in the specified units.
      *
      * @exception  IllegalArgumentException
-     *     (unchecked exception) Thrown if <CODE>units</CODE> < 1.
+     *     (unchecked exception) Thrown if {@code units < 1}.
      */
      public float getHeight(int units) {
         return convertFromMicrometers(h, units);
@@ -301,7 +301,7 @@
      * @return  String version of this two-dimensional size attribute.
      *
      * @exception  IllegalArgumentException
-     *     (unchecked exception) Thrown if <CODE>units</CODE> < 1.
+     *     (unchecked exception) Thrown if {@code units < 1}.
      */
     public String toString(int units, String unitsName) {
         if (unitsName == null) {
--- a/src/share/classes/javax/print/attribute/standard/MediaSize.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/attribute/standard/MediaSize.java	Tue Aug 13 18:33:25 2013 -0700
@@ -45,7 +45,7 @@
  * <code>MediaSize.getMediaSizeForName(MediaSizeName)</code>
  * to find the physical dimensions of the MediaSizeName instances
  * enumerated in this API. This is useful for clients which need this
- * information to format & paginate printing.
+ * information to format {@literal &} paginate printing.
  * <P>
  *
  * @author  Phil Race, Alan Kaminsky
@@ -71,8 +71,8 @@
      *     <CODE>Size2DSyntax.MM</CODE>.
      *
      * @exception  IllegalArgumentException
-     *   (Unchecked exception) Thrown if <CODE>x</CODE> < 0 or <CODE>y</CODE>
-     *     < 0 or <CODE>units</CODE> < 1 or <CODE>x</CODE> > <CODE>y</CODE>.
+     *   (Unchecked exception) Thrown if {@code x < 0} or {@code y < 0} or
+     *   {@code units < 1} or {@code x > y}.
      */
     public MediaSize(float x, float y,int units) {
         super (x, y, units);
@@ -92,8 +92,8 @@
      *     <CODE>Size2DSyntax.MM</CODE>.
      *
      * @exception  IllegalArgumentException
-     *   (Unchecked exception) Thrown if <CODE>x</CODE> < 0 or <CODE>y</CODE>
-     *     < 0 or <CODE>units</CODE> < 1 or <CODE>x</CODE> > <CODE>y</CODE>.
+     *   (Unchecked exception) Thrown if {@code x < 0} or {@code y < 0} or
+     *   {@code units < 1} or {@code x > y}.
      */
     public MediaSize(int x, int y,int units) {
         super (x, y, units);
@@ -115,8 +115,8 @@
      * @param media a media name to associate with this MediaSize
      *
      * @exception  IllegalArgumentException
-     *   (Unchecked exception) Thrown if <CODE>x</CODE> < 0 or <CODE>y</CODE>
-     *     < 0 or <CODE>units</CODE> < 1 or <CODE>x</CODE> > <CODE>y</CODE>.
+     *   (Unchecked exception) Thrown if {@code x < 0} or {@code y < 0} or
+     *   {@code units < 1} or {@code x > y}.
      */
     public MediaSize(float x, float y,int units, MediaSizeName media) {
         super (x, y, units);
@@ -141,8 +141,8 @@
      * @param media a media name to associate with this MediaSize
      *
      * @exception  IllegalArgumentException
-     *   (Unchecked exception) Thrown if <CODE>x</CODE> < 0 or <CODE>y</CODE>
-     *     < 0 or <CODE>units</CODE> < 1 or <CODE>x</CODE> > <CODE>y</CODE>.
+     *   (Unchecked exception) Thrown if {@code x < 0} or {@code y < 0} or
+     *   {@code units < 1} or {@code x > y}.
      */
     public MediaSize(int x, int y,int units, MediaSizeName media) {
         super (x, y, units);
@@ -194,7 +194,8 @@
      *     Unit conversion factor, e.g. <CODE>Size2DSyntax.INCH</CODE> or
      *     <CODE>Size2DSyntax.MM</CODE>
      * @return MediaSizeName matching these dimensions, or null.
-     * @exception IllegalArgumentException if x <= 0, y <= 0, or units < 1
+     * @exception IllegalArgumentException if {@code x <= 0},
+     *      {@code y <= 0}, or {@code units < 1}.
      *
      */
     public static MediaSizeName findMedia(float x, float y, int units) {
--- a/src/share/classes/javax/print/attribute/standard/PresentationDirection.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/attribute/standard/PresentationDirection.java	Tue Aug 13 18:33:25 2013 -0700
@@ -56,56 +56,56 @@
 
     /**
      * Pages are laid out in columns starting at the top left,
-     * proceeeding towards the bottom & right.
+     * proceeeding towards the bottom {@literal &} right.
      */
     public static final PresentationDirection TOBOTTOM_TORIGHT =
         new PresentationDirection(0);
 
     /**
      * Pages are laid out in columns starting at the top right,
-     * proceeeding towards the bottom & left.
+     * proceeeding towards the bottom {@literal &} left.
      */
     public static final PresentationDirection TOBOTTOM_TOLEFT =
         new PresentationDirection(1);
 
     /**
      * Pages are laid out in columns starting at the bottom left,
-     * proceeeding towards the top & right.
+     * proceeeding towards the top {@literal &} right.
      */
     public static final PresentationDirection TOTOP_TORIGHT =
         new PresentationDirection(2);
 
     /**
      * Pages are laid out in columns starting at the bottom right,
-     * proceeeding towards the top & left.
+     * proceeeding towards the top {@literal &} left.
      */
     public static final PresentationDirection TOTOP_TOLEFT =
         new PresentationDirection(3);
 
     /**
      * Pages are laid out in rows starting at the top left,
-     * proceeeding towards the right & bottom.
+     * proceeeding towards the right {@literal &} bottom.
      */
     public static final PresentationDirection TORIGHT_TOBOTTOM =
         new PresentationDirection(4);
 
     /**
      * Pages are laid out in rows starting at the bottom left,
-     * proceeeding towards the right & top.
+     * proceeeding towards the right {@literal &} top.
      */
     public static final PresentationDirection TORIGHT_TOTOP =
         new PresentationDirection(5);
 
     /**
      * Pages are laid out in rows starting at the top right,
-     * proceeeding towards the left & bottom.
+     * proceeeding towards the left {@literal &} bottom.
      */
     public static final PresentationDirection TOLEFT_TOBOTTOM =
         new PresentationDirection(6);
 
     /**
      * Pages are laid out in rows starting at the bottom right,
-     * proceeeding towards the left & top.
+     * proceeeding towards the left {@literal &} top.
      */
     public static final PresentationDirection TOLEFT_TOTOP =
         new PresentationDirection(7);
--- a/src/share/classes/javax/print/attribute/standard/PrinterMoreInfoManufacturer.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/attribute/standard/PrinterMoreInfoManufacturer.java	Tue Aug 13 18:33:25 2013 -0700
@@ -40,7 +40,7 @@
  * details on color support). The information is intended to be germane to
  * this kind of printer without regard to site specific modifications or
  * services.
- * <P
+ * <P>
  * In contrast, the {@link PrinterMoreInfo PrinterMoreInfo} attribute is used
  * to find out more information about this specific printer rather than this
  * general kind of printer.
--- a/src/share/classes/javax/print/attribute/standard/PrinterResolution.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/print/attribute/standard/PrinterResolution.java	Tue Aug 13 18:33:25 2013 -0700
@@ -84,11 +84,11 @@
      *     Feed direction resolution.
      * @param  units
      *    Unit conversion factor, e.g. <code>ResolutionSyntax.DPI</CODE>
-     * or <code>ResolutionSyntax.>DPCM</CODE>.
+     * or <code>ResolutionSyntax.DPCM</CODE>.
      *
      * @exception  IllegalArgumentException
-     *     (unchecked exception) Thrown if <CODE>crossFeedResolution</CODE> <
-     *     1 or <CODE>feedResolution</CODE> < 1 or <CODE>units</CODE> < 1.
+     *     (unchecked exception) Thrown if {@code crossFeedResolution < 1} or
+     *     {@code feedResolution < 1} or {@code units < 1}.
      */
     public PrinterResolution(int crossFeedResolution, int feedResolution,
                              int units) {
--- a/src/share/classes/javax/swing/text/GlyphView.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/javax/swing/text/GlyphView.java	Tue Aug 13 18:33:25 2013 -0700
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1999, 2010, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -514,7 +514,7 @@
             int x1 = x0 + (int) painter.getSpan(this, p0, p1, getTabExpander(), x0);
 
             // calculate y coordinate
-            int y = alloc.y + alloc.height - (int) painter.getDescent(this);
+            int y = alloc.y + (int)(painter.getHeight(this) - painter.getDescent(this));
             if (underline) {
                 int yTmp = y + 1;
                 g.drawLine(x0, yTmp, x1, yTmp);
--- a/src/share/classes/sun/awt/AppContext.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/share/classes/sun/awt/AppContext.java	Tue Aug 13 18:33:25 2013 -0700
@@ -310,11 +310,13 @@
                     // and excludes applets because by the time applet starts
                     // a number of contexts have already been created by the plugin.
                     if (numAppContexts.get() == 0) {
-                        // This check is not necessary, its purpose is to help
-                        // Plugin devs to catch all the cases of main AC creation.
                         if (System.getProperty("javaplugin.version") == null &&
                                 System.getProperty("javawebstart.version") == null) {
                             initMainAppContext();
+                        } else if (System.getProperty("javafx.version") != null &&
+                                threadGroup.getParent() != null) {
+                            // Swing inside JavaFX case
+                            SunToolkit.createNewAppContext();
                         }
                     }
 
--- a/src/solaris/classes/sun/print/UnixPrintJob.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/solaris/classes/sun/print/UnixPrintJob.java	Tue Aug 13 18:33:25 2013 -0700
@@ -334,6 +334,10 @@
             throw new PrintException("can't get print data: " + e.toString());
         }
 
+        if (data == null) {
+            throw new PrintException("Null print data.");
+        }
+
         if (flavor == null || (!service.isDocFlavorSupported(flavor))) {
             notifyEvent(PrintJobEvent.JOB_FAILED);
             throw new PrintJobFlavorException("invalid flavor", flavor);
--- a/src/solaris/native/sun/awt/gtk2_interface.c	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/solaris/native/sun/awt/gtk2_interface.c	Tue Aug 13 18:33:25 2013 -0700
@@ -794,6 +794,7 @@
             }
             putenv (new_env);
             free (new_env);
+            free (tmp_env);
         }
     }
 
--- a/src/solaris/native/sun/java2d/x11/XRBackendNative.c	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/solaris/native/sun/java2d/x11/XRBackendNative.c	Tue Aug 13 18:33:25 2013 -0700
@@ -269,6 +269,13 @@
     static jboolean firstTime = JNI_TRUE;
 
     if (firstTime) {
+#ifdef DISABLE_XRENDER_BY_DEFAULT
+        if (verbose == JNI_FALSE) {
+            xrenderAvailable = JNI_FALSE;
+            firstTime = JNI_FALSE;
+            return xrenderAvailable;
+        }
+#endif
         AWT_LOCK();
         xrenderAvailable = IsXRenderAvailable(verbose);
         AWT_UNLOCK();
--- a/src/windows/classes/sun/print/Win32PrintJob.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/windows/classes/sun/print/Win32PrintJob.java	Tue Aug 13 18:33:25 2013 -0700
@@ -340,6 +340,10 @@
             throw new PrintException("can't get print data: " + e.toString());
         }
 
+        if (data == null) {
+            throw new PrintException("Null print data.");
+        }
+
         if (flavor == null || (!service.isDocFlavorSupported(flavor))) {
             notifyEvent(PrintJobEvent.JOB_FAILED);
             throw new PrintJobFlavorException("invalid flavor", flavor);
--- a/src/windows/native/sun/windows/awt_Component.cpp	Tue Aug 13 19:10:54 2013 +0100
+++ b/src/windows/native/sun/windows/awt_Component.cpp	Tue Aug 13 18:33:25 2013 -0700
@@ -3528,8 +3528,12 @@
     if (ops == SAVE) {
         transTable.put(reinterpret_cast<void*>(static_cast<INT_PTR>(wkey)),
                        reinterpret_cast<void*>(static_cast<INT_PTR>(translation)));
-        deadKeyFlagTable.put(reinterpret_cast<void*>(static_cast<INT_PTR>(wkey)),
-                       reinterpret_cast<void*>(static_cast<INT_PTR>(deadKeyFlag)));
+        if (deadKeyFlag) {
+            deadKeyFlagTable.put(reinterpret_cast<void*>(static_cast<INT_PTR>(wkey)),
+                         reinterpret_cast<void*>(static_cast<INT_PTR>(deadKeyFlag)));
+        } else {
+            deadKeyFlagTable.remove(reinterpret_cast<void*>(static_cast<INT_PTR>(wkey)));
+        }
     }
 
     isDeadKey = deadKeyFlag;
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/com/apple/eawt/DefaultMenuBar/DefaultMenuBarTest.java	Tue Aug 13 18:33:25 2013 -0700
@@ -0,0 +1,108 @@
+/*
+ * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+/*
+ * @test
+ * @bug 8007267
+ * @summary [macosx] com.apple.eawt.Application.setDefaultMenuBar is not working
+ * @author leonid.romanov@oracle.com
+ * @run main DefaultMenuBarTest
+ */
+
+import java.awt.*;
+import java.awt.event.*;
+import javax.swing.*;
+import sun.awt.*;
+import java.lang.reflect.Method;
+
+
+public class DefaultMenuBarTest {
+    static KeyStroke ks = KeyStroke.getKeyStroke(KeyEvent.VK_O, InputEvent.META_MASK);
+
+    static volatile int listenerCallCounter = 0;
+    public static void main(String[] args) throws Exception {
+        if (sun.awt.OSInfo.getOSType() != sun.awt.OSInfo.OSType.MACOSX) {
+            System.out.println("This test is for MacOS only. Automatically passed on other platforms.");
+            return;
+        }
+
+        System.setProperty("apple.laf.useScreenMenuBar", "true");
+        SwingUtilities.invokeAndWait(new Runnable() {
+            public void run() {
+                createAndShowGUI();
+            }
+        });
+
+        SunToolkit toolkit = (SunToolkit) Toolkit.getDefaultToolkit();
+        Robot robot = new Robot();
+        robot.setAutoDelay(100);
+
+        robot.keyPress(KeyEvent.VK_META);
+        robot.keyPress(ks.getKeyCode());
+        robot.keyRelease(ks.getKeyCode());
+        robot.keyRelease(KeyEvent.VK_META);
+
+        toolkit.realSync();
+
+        if (listenerCallCounter != 1) {
+            throw new Exception("Test failed: ActionListener either wasn't called or was called more than once");
+        }
+    }
+
+    private static void createAndShowGUI() {
+        JMenu menu = new JMenu("File");
+        JMenuItem newItem = new JMenuItem("Open");
+
+        newItem.setAccelerator(ks);
+        newItem.addActionListener(
+            new ActionListener(){
+                public void actionPerformed(ActionEvent e) {
+                    listenerCallCounter++;
+                }
+            }
+        );
+        menu.add(newItem);
+
+        JMenuBar defaultMenu = new JMenuBar();
+        defaultMenu.add(menu);
+
+        // Application.getApplication().setDefaultMenuBar(defaultMenu);
+        try {
+            Class appClass = Class.forName("com.apple.eawt.Application");
+            if (appClass != null) {
+                Method method = appClass.getMethod("getApplication");
+                if (method != null) {
+                    Object app = method.invoke(null, new Object[]{});
+                    if (app != null) {
+                        method = appClass.getMethod("setDefaultMenuBar", new Class[]{JMenuBar.class});
+                        if (method != null) {
+                            method.invoke(app, new Object[]{defaultMenu});
+                        }
+                    }
+                }
+            }
+        } catch (Exception e) {
+            e.printStackTrace();
+        }
+    }
+}
--- a/test/java/awt/EventDispatchThread/LoopRobustness/LoopRobustness.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/test/java/awt/EventDispatchThread/LoopRobustness/LoopRobustness.java	Tue Aug 13 18:33:25 2013 -0700
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1998, 2010, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1998, 2013, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -49,6 +49,8 @@
     public static volatile boolean otherExceptionsCaught = false;
 
     public static void main(String [] args) throws Exception {
+        SunToolkit.createNewAppContext();
+
         ThreadGroup mainThreadGroup = Thread.currentThread().getThreadGroup();
 
         long at;
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/java/awt/event/KeyEvent/DeadKey/DeadKeySystemAssertionDialog.java	Tue Aug 13 18:33:25 2013 -0700
@@ -0,0 +1,65 @@
+/*
+ * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+import java.awt.Frame;
+import java.awt.Robot;
+import java.awt.TextField;
+import java.awt.Toolkit;
+import java.awt.event.KeyEvent;
+import sun.awt.SunToolkit;
+/*
+ * @test
+ * @bug 8013849
+ * @summary Awt assert on Hashtable.cpp:124
+ * @author alexandr.scherbatiy area=awt.event
+ * @run main/timeout=5 DeadKeySystemAssertionDialog
+ */
+
+public class DeadKeySystemAssertionDialog {
+
+    public static void main(String[] args) throws Exception {
+
+        SunToolkit toolkit = (SunToolkit) Toolkit.getDefaultToolkit();
+        Frame frame = new Frame();
+        frame.setSize(300, 200);
+
+        TextField textField = new TextField();
+        frame.add(textField);
+
+        frame.setVisible(true);
+        toolkit.realSync();
+
+        textField.requestFocus();
+        toolkit.realSync();
+
+        // Check that the system assertion dialog does not block Java
+        Robot robot = new Robot();
+        robot.setAutoDelay(50);
+        robot.keyPress(KeyEvent.VK_A);
+        robot.keyRelease(KeyEvent.VK_A);
+        toolkit.realSync();
+
+        frame.setVisible(false);
+        frame.dispose();
+    }
+}
--- a/test/javax/print/attribute/autosense/PrintAutoSenseData.java	Tue Aug 13 19:10:54 2013 +0100
+++ b/test/javax/print/attribute/autosense/PrintAutoSenseData.java	Tue Aug 13 18:33:25 2013 -0700
@@ -23,7 +23,7 @@
 
 /*
  * @test
- * @bug 4468109
+ * @bug 4468109 8021583
  * @summary Test for printing AUTOSENSE DocFlavor.  No exception should be thrown.
  * @run main PrintAutoSenseData
 */
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/javax/print/attribute/autosense/sample.txt	Tue Aug 13 18:33:25 2013 -0700
@@ -0,0 +1,1 @@
+This is a program for testing AutoSense data.
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/javax/swing/JTabbedPane/4361477/bug4361477.java	Tue Aug 13 18:33:25 2013 -0700
@@ -0,0 +1,100 @@
+/*
+ * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+import java.awt.*;
+import java.awt.event.*;
+import javax.swing.*;
+import javax.swing.event.*;
+import sun.awt.SunToolkit;
+
+/*
+ * @test
+ * @bug 4361477
+ * @summary JTabbedPane throws ArrayOutOfBoundsException
+ * @author Oleg Mokhovikov
+ * @run main bug4361477
+ */
+public class bug4361477 {
+
+    static JTabbedPane tabbedPane;
+    volatile static boolean bStateChanged = false;
+    volatile static Rectangle bounds;
+
+    public static void main(String args[]) throws Exception {
+
+        SunToolkit toolkit = (SunToolkit) Toolkit.getDefaultToolkit();
+        Robot robot = new Robot();
+        robot.setAutoDelay(50);
+
+        SwingUtilities.invokeAndWait(new Runnable() {
+
+            @Override
+            public void run() {
+                createAndShowUI();
+            }
+        });
+
+        toolkit.realSync();
+
+        SwingUtilities.invokeAndWait(new Runnable() {
+
+            @Override
+            public void run() {
+                bounds = tabbedPane.getUI().getTabBounds(tabbedPane, 0);
+            }
+        });
+
+        Point location = bounds.getLocation();
+        SwingUtilities.convertPointToScreen(location, tabbedPane);
+        robot.mouseMove(location.x + 1, location.y + 1);
+        robot.mousePress(InputEvent.BUTTON1_MASK);
+        robot.mouseRelease(InputEvent.BUTTON1_MASK);
+
+        if (!bStateChanged) {
+            throw new RuntimeException("Tabbed pane state is not changed");
+        }
+    }
+
+    static void createAndShowUI() {
+
+        final JFrame frame = new JFrame();
+        tabbedPane = new JTabbedPane();
+        tabbedPane.add("Tab0", new JPanel());
+        tabbedPane.add("Tab1", new JPanel());
+        tabbedPane.add("Tab2", new JPanel());
+        tabbedPane.setSelectedIndex(2);
+        tabbedPane.addChangeListener(new ChangeListener() {
+
+            public void stateChanged(final ChangeEvent pick) {
+                bStateChanged = true;
+                if (tabbedPane.getTabCount() == 3) {
+                    tabbedPane.remove(2);
+                }
+            }
+        });
+
+        frame.getContentPane().add(tabbedPane);
+        frame.setSize(300, 200);
+        frame.setVisible(true);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/javax/swing/JTabbedPane/6495408/bug6495408.java	Tue Aug 13 18:33:25 2013 -0700
@@ -0,0 +1,81 @@
+/*
+ * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+import javax.swing.*;
+import java.awt.*;
+import sun.awt.SunToolkit;
+/*
+ * @test
+ * @bug 6495408
+ * @summary REGRESSION: JTabbedPane throws ArrayIndexOutOfBoundsException
+ * @author Alexander Potochkin
+ * @run main bug6495408
+ */
+
+public class bug6495408 {
+
+    static JTabbedPane tabbedPane;
+
+    public static void main(String[] args) throws Exception {
+        SunToolkit toolkit = (SunToolkit) Toolkit.getDefaultToolkit();
+        final Robot robot = new Robot();
+        robot.setAutoDelay(50);
+
+        SwingUtilities.invokeAndWait(new Runnable() {
+
+            public void run() {
+                final JFrame frame = new JFrame();
+                frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+                tabbedPane = new JTabbedPane();
+                tabbedPane.setTabPlacement(JTabbedPane.LEFT);
+                tabbedPane.addTab("Hello", null);
+                frame.add(tabbedPane);
+                frame.setSize(400, 400);
+                frame.setLocationRelativeTo(null);
+                frame.setVisible(true);
+            }
+        });
+
+        toolkit.realSync();
+
+        final Rectangle d = new Rectangle();
+        final Point p = new Point();
+
+        for (int i = 0; i < 7; i++) {
+            SwingUtilities.invokeLater(new Runnable() {
+
+                public void run() {
+                    int tab = tabbedPane.getTabCount() - 1;
+                    Rectangle bounds = tabbedPane.getBoundsAt(tab);
+                    if (bounds != null) {
+                        d.setBounds(bounds);
+                        p.setLocation(d.x + d.width / 2, d.y + d.height / 2);
+                        SwingUtilities.convertPointToScreen(p, tabbedPane);
+                        robot.mouseMove(p.x, p.y + d.height);
+                        tabbedPane.addTab("Hello", null);
+                    }
+                }
+            });
+        }
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/javax/swing/JTabbedPane/7161568/bug7161568.java	Tue Aug 13 18:33:25 2013 -0700
@@ -0,0 +1,90 @@
+/*
+ * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+import java.awt.*;
+import javax.swing.*;
+import java.awt.event.*;
+import sun.awt.SunToolkit;
+
+/**
+ * @test
+ * @bug 7161568
+ * @author Alexander Scherbatiy
+ * @summary Tests that navigating tabs in the JTAbbedPane does not throw NPE
+ * @run main bug7161568
+ */
+public class bug7161568 {
+
+    private static final int N = 50;
+    private static JTabbedPane tabbedPane;
+
+    public static void main(String[] args) throws Exception {
+        UIManager.put("TabbedPane.selectionFollowsFocus", Boolean.FALSE);
+
+        SunToolkit toolkit = (SunToolkit) Toolkit.getDefaultToolkit();
+        Robot robot = new Robot();
+        robot.setAutoDelay(50);
+
+        SwingUtilities.invokeAndWait(new Runnable() {
+
+            @Override
+            public void run() {
+                createAndShowUI();
+            }
+        });
+
+        toolkit.realSync();
+
+        SwingUtilities.invokeAndWait(new Runnable() {
+
+            @Override
+            public void run() {
+                tabbedPane.requestFocus();
+            }
+        });
+
+        toolkit.realSync();
+
+        for (int i = 0; i < N; i++) {
+            robot.keyPress(KeyEvent.VK_LEFT);
+            robot.keyRelease(KeyEvent.VK_LEFT);
+            toolkit.realSync();
+        }
+    }
+
+    static void createAndShowUI() {
+        JFrame frame = new JFrame("Test");
+        frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+        frame.setSize(100, 100);
+
+        tabbedPane = new JTabbedPane();
+
+        for (int i = 0; i < N; i++) {
+            tabbedPane.addTab("Tab: " + i, new JLabel("Test"));
+        }
+
+        tabbedPane.setSelectedIndex(0);
+
+        frame.getContentPane().add(tabbedPane);
+        frame.setVisible(true);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/javax/swing/text/StyledEditorKit/8016833/bug8016833.java	Tue Aug 13 18:33:25 2013 -0700
@@ -0,0 +1,270 @@
+/*
+ * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+/* @test
+   @bug 8016833
+   @summary underlines and strikethroughs should be  painted at the correct
+            positions for different kind of text styles: normal, superscript and subscript
+   @author Anton Nashatyrev
+   @run main bug8016833
+*/
+import javax.swing.*;
+import javax.swing.text.BadLocationException;
+import javax.swing.text.Style;
+import javax.swing.text.StyleConstants;
+import javax.swing.text.StyledDocument;
+import java.awt.*;
+import java.awt.image.BufferedImage;
+import java.lang.reflect.InvocationTargetException;
+
+public class bug8016833 {
+
+    void drawText(final Graphics g, final boolean underline, final boolean strikethrough, final boolean background) {
+        drawText(g, "mama", underline, strikethrough, background);
+    }
+
+    void drawText(final Graphics g, final String text, final boolean underline, final boolean strikethrough, final boolean background) {
+        try {
+            SwingUtilities.invokeAndWait(new Runnable() {
+                @Override
+                public void run() {
+                    final JTextPane comp = new JTextPane();
+                    final StyledDocument doc = comp.getStyledDocument();
+
+                    Style style = comp.addStyle("superscript", null);
+                    setNormalStyle(style);
+
+                    if (underline) {
+                        StyleConstants.setUnderline(style, true);
+                    }
+                    if (strikethrough) {
+                        StyleConstants.setStrikeThrough(style, true);
+                    }
+                    if (background) {
+                        StyleConstants.setBackground(style, Color.BLUE);
+                    }
+                    try {
+                        doc.insertString(doc.getLength(), "mama", style);
+                    } catch (BadLocationException e) {
+                        throw new RuntimeException(e);
+                    }
+
+                    comp.setSize(200, 100);
+                    comp.paint(g);
+                }
+            });
+        } catch (InterruptedException e) {
+            throw new RuntimeException(e);
+        } catch (InvocationTargetException e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    void setNormalStyle(Style style) {
+        StyleConstants.setSuperscript(style, true);
+    }
+
+    int getEmptyPixel() {
+        return 0xFFFFFFFF;
+    }
+
+    boolean isPixelEmpty(int argb) {
+        return (argb & 0x00FFFFFF) == (getEmptyPixel() & 0x00FFFFFF);
+    }
+
+    boolean isLineEmpty(BufferedImage img, int coord, boolean isHorizontal) {
+        int len = isHorizontal ? img.getWidth() : img.getHeight();
+        for (int i = 0; i < len; i++) {
+            int pixel = isHorizontal ? img.getRGB(i, coord) : img.getRGB(coord, i);
+            if (!isPixelEmpty(pixel)) {
+                return false;
+            }
+        }
+        return true;
+    }
+
+    Rectangle getPixelsOutline(BufferedImage img) {
+        int x1 = 0;
+        while (x1 < img.getWidth() && isLineEmpty(img, x1, false)) {
+            x1++;
+        }
+        int x2 = img.getWidth() - 1;
+        while (x2 >= 0 && isLineEmpty(img, x2, false)) {
+            x2--;
+        }
+        int y1 = 0;
+        while (y1 < img.getHeight() && isLineEmpty(img, y1, true)) {
+            y1++;
+        }
+        int y2 = img.getHeight() - 1;
+        while (y2 >= 0 && isLineEmpty(img, y2, true)) {
+            y2--;
+        }
+
+        return new Rectangle(x1, y1, x2 - x1 + 1, y2 - y1 + 1);
+    }
+
+    BufferedImage createImage() {
+        final BufferedImage img = new BufferedImage(200, 100, BufferedImage.TYPE_INT_ARGB);
+        try {
+            SwingUtilities.invokeAndWait(new Runnable() {
+                @Override
+                public void run() {
+                    Graphics g = img.getGraphics();
+                    g.setColor(new Color(getEmptyPixel()));
+                    g.fillRect(0, 0, 10000, 10000);
+                }
+            });
+        } catch (InterruptedException e) {
+            throw new RuntimeException(e);
+        } catch (InvocationTargetException e) {
+            throw new RuntimeException(e);
+        }
+        return img;
+    }
+
+    int subPixels(int pix1, int pix2) {
+        if (pix1 == pix2) {
+            return getEmptyPixel();
+        }
+        return pix1;
+    }
+
+    /**
+     * Subtracts img2 from img1
+     */
+    BufferedImage subImages(BufferedImage img1, BufferedImage img2) {
+        if (img1.getHeight() != img2.getHeight() ||
+                img1.getWidth() != img2.getWidth()) {
+            throw new RuntimeException("Different sizes");
+        }
+        BufferedImage ret = new BufferedImage(img1.getWidth(), img1.getHeight(), img1.getType());
+
+        for (int x = 0; x < ret.getWidth(); x++) {
+            for (int y = 0; y < ret.getHeight(); y++) {
+                ret.setRGB(x, y, subPixels(img1.getRGB(x, y), img2.getRGB(x, y)));
+            }
+        }
+        return ret;
+    }
+
+    void testUnderline() {
+        System.out.println("  testUnderline()");
+
+        final BufferedImage img1 = createImage();
+        drawText(img1.getGraphics(), true, false, false);
+        final Rectangle out1 = getPixelsOutline(img1);
+        System.out.println("   Underlined: " + out1);
+
+        final BufferedImage img2 = createImage();
+        drawText(img2.getGraphics(), false, false, false);
+        final Rectangle out2 = getPixelsOutline(img2);
+        System.out.println("   Normal: " + out2);
+
+        final BufferedImage img3 = subImages(img1, img2);
+        final Rectangle out3 = getPixelsOutline(img3);
+        System.out.println("   Sub: " + out3);
+
+        // underline is not too thick
+        assertTrue(out3.getHeight() <= 2);
+        // not too wide
+        assertTrue(out3.getWidth() * 0.8 < out2.getWidth());
+        // not too low
+        assertTrue(out3.getY() - (out1.getY() + out2.getHeight()) < 3);
+        // not too high
+        assertTrue(out3.getY() - (out1.getY() + out2.getHeight()) > 0);
+    }
+
+    void testStrikthrough() {
+        System.out.println("  testStrikthrough()");
+
+        final BufferedImage img1 = createImage();
+        drawText(img1.getGraphics(), false, true, false);
+        final Rectangle out1 = getPixelsOutline(img1);
+        System.out.println("   Striked: " + out1);
+
+        final BufferedImage img2 = createImage();
+        drawText(img2.getGraphics(), false, false, false);
+        final Rectangle out2 = getPixelsOutline(img2);
+        System.out.println("   Normal: " + out2);
+
+        final BufferedImage img3 = subImages(img1, img2);
+        final Rectangle out3 = getPixelsOutline(img3);
+        System.out.println("   Sub: " + out3);
+
+        // strikethrough is not too thick
+        assertTrue(out3.getHeight() <= 2);
+        // not too wide
+        assertTrue(out3.getWidth() * 0.8 < out2.getWidth());
+        // not too low
+        assertTrue(out3.getY() - (out1.getY() + out2.getHeight()) < 0);
+        // not too high
+        assertTrue(out3.getY() - out1.getY() > 1);
+    }
+    void assertTrue(boolean b) {
+        if (!b) {
+            throw new RuntimeException("Assertion failed");
+        }
+    }
+
+    static void testSuperScript() {
+        System.out.println("testSuperScript()");
+        bug8016833 b = new bug8016833() {
+            @Override
+            void setNormalStyle(Style style) {
+                StyleConstants.setSuperscript(style, true);
+            }
+        };
+        b.testUnderline();
+        b.testStrikthrough();
+    }
+
+    static void testSubScript() {
+        System.out.println("testSubScript()");
+        bug8016833 b = new bug8016833() {
+            @Override
+            void setNormalStyle(Style style) {
+                StyleConstants.setSubscript(style, true);
+            }
+        };
+        b.testUnderline();
+        b.testStrikthrough();
+    }
+
+    static void testNormalScript() {
+        System.out.println("testNormalScript()");
+        bug8016833 b = new bug8016833() {
+            @Override
+            void setNormalStyle(Style style) {
+            }
+        };
+        b.testUnderline();
+        b.testStrikthrough();
+    }
+
+    public static void main(String[] args) {
+        testSubScript();
+        testSuperScript();
+        testNormalScript();
+    }
+}