diff options
Diffstat (limited to 'java/awt/font')
-rw-r--r-- | java/awt/font/FontRenderContext.java | 7 | ||||
-rw-r--r-- | java/awt/font/GlyphJustificationInfo.java | 4 | ||||
-rw-r--r-- | java/awt/font/GlyphMetrics.java | 6 | ||||
-rw-r--r-- | java/awt/font/GlyphVector.java | 20 | ||||
-rw-r--r-- | java/awt/font/GraphicAttribute.java | 18 | ||||
-rw-r--r-- | java/awt/font/ImageGraphicAttribute.java | 26 | ||||
-rw-r--r-- | java/awt/font/LineBreakMeasurer.java | 49 | ||||
-rw-r--r-- | java/awt/font/LineMetrics.java | 20 | ||||
-rw-r--r-- | java/awt/font/MultipleMaster.java | 10 | ||||
-rw-r--r-- | java/awt/font/OpenType.java | 14 | ||||
-rw-r--r-- | java/awt/font/ShapeGraphicAttribute.java | 28 | ||||
-rw-r--r-- | java/awt/font/TextAttribute.java | 124 | ||||
-rw-r--r-- | java/awt/font/TextHitInfo.java | 10 | ||||
-rw-r--r-- | java/awt/font/TextLayout.java | 244 | ||||
-rw-r--r-- | java/awt/font/TextMeasurer.java | 42 | ||||
-rw-r--r-- | java/awt/font/TransformAttribute.java | 24 |
16 files changed, 321 insertions, 325 deletions
diff --git a/java/awt/font/FontRenderContext.java b/java/awt/font/FontRenderContext.java index c25bae3ec..8d530ec5f 100644 --- a/java/awt/font/FontRenderContext.java +++ b/java/awt/font/FontRenderContext.java @@ -48,7 +48,7 @@ public class FontRenderContext private AffineTransform affineTransform; private boolean isAntiAliased; private boolean usesFractionalMetrics; - + /** * Construct a new <code>FontRenderContext</code>. */ @@ -56,7 +56,7 @@ public class FontRenderContext { // Do nothing here. } - + /** * Construct a new <code>FontRenderContext</code>. */ @@ -68,7 +68,7 @@ public class FontRenderContext { this.affineTransform = new AffineTransform (tx); } - + this.isAntiAliased = isAntiAliased; this.usesFractionalMetrics = usesFractionalMetrics; } @@ -135,4 +135,3 @@ public class FontRenderContext return usesFractionalMetrics; } } - diff --git a/java/awt/font/GlyphJustificationInfo.java b/java/awt/font/GlyphJustificationInfo.java index 5f45fd584..cfa64f05e 100644 --- a/java/awt/font/GlyphJustificationInfo.java +++ b/java/awt/font/GlyphJustificationInfo.java @@ -47,7 +47,7 @@ public final class GlyphJustificationInfo public static final int PRIORITY_WHITESPACE = 1; public static final int PRIORITY_INTERCHAR = 2; public static final int PRIORITY_NONE = 3; - + public final float weight; public final int growPriority; public final boolean growAbsorb; @@ -57,7 +57,7 @@ public final class GlyphJustificationInfo public final boolean shrinkAbsorb; public final float shrinkLeftLimit; public final float shrinkRightLimit; - + public GlyphJustificationInfo (float weight, boolean growAbsorb, int growPriority, float growLeftLimit, float growRightLimit, boolean shrinkAbsorb, diff --git a/java/awt/font/GlyphMetrics.java b/java/awt/font/GlyphMetrics.java index 0a78d3052..b41b7f45b 100644 --- a/java/awt/font/GlyphMetrics.java +++ b/java/awt/font/GlyphMetrics.java @@ -50,13 +50,13 @@ public final class GlyphMetrics public static final byte LIGATURE = 1; public static final byte STANDARD = 0; public static final byte WHITESPACE = 4; - + private boolean horizontal; private float advanceX; private float advanceY; private Rectangle2D bounds; private byte glyphType; - + public GlyphMetrics (boolean horizontal, float advanceX, float advanceY, Rectangle2D bounds, byte glyphType) { @@ -66,7 +66,7 @@ public final class GlyphMetrics this.bounds = bounds; this.glyphType = glyphType; } - + public GlyphMetrics (float advance, Rectangle2D bounds, byte glyphType) { this (true, advance, advance, bounds, glyphType); diff --git a/java/awt/font/GlyphVector.java b/java/awt/font/GlyphVector.java index f4cb01b95..4a87f4c62 100644 --- a/java/awt/font/GlyphVector.java +++ b/java/awt/font/GlyphVector.java @@ -69,12 +69,12 @@ public abstract class GlyphVector implements Cloneable public abstract Font getFont (); public abstract FontRenderContext getFontRenderContext (); - + public int getGlyphCharIndex (int glyphIndex) { return glyphIndex; } - + public int[] getGlyphCharIndices(int beginGlyphIndex, int numEntries, int[] codeReturn) { @@ -85,10 +85,10 @@ public abstract class GlyphVector implements Cloneable int j = beginGlyphIndex; while (j < numEntries) codeReturn[i++] = getGlyphCharIndex(j++); - + return codeReturn; } - + public abstract int getGlyphCode (int glyphIndex); public abstract int[] getGlyphCodes (int beginGlyphIndex, int numEntries, @@ -106,7 +106,7 @@ public abstract class GlyphVector implements Cloneable public Shape getGlyphOutline(int glyphIndex, float x, float y) { Shape s = getGlyphOutline(glyphIndex); - + // This is the only way to translate the origin of a shape AffineTransform at = AffineTransform.getTranslateInstance(x, y); return at.createTransformedShape(s); @@ -117,12 +117,12 @@ public abstract class GlyphVector implements Cloneable { Rectangle bounds = new Rectangle(); Rectangle2D rect = getGlyphVisualBounds(index).getBounds2D(); - + bounds.x = (int) (rect.getX() + x); bounds.y = (int) (rect.getY() + y); bounds.width = (int) rect.getMaxX() - bounds.x; bounds.height = (int) rect.getMaxY() - bounds.y; - + return bounds; } @@ -144,7 +144,7 @@ public abstract class GlyphVector implements Cloneable public abstract Rectangle2D getLogicalBounds (); public abstract int getNumGlyphs (); - + public abstract Shape getOutline (); public abstract Shape getOutline (float x, float y); @@ -154,12 +154,12 @@ public abstract class GlyphVector implements Cloneable { Rectangle bounds = new Rectangle(); Rectangle2D rect = getVisualBounds(); - + bounds.x = (int) (rect.getX() + x); bounds.y = (int) (rect.getY() + y); bounds.width = (int) rect.getMaxX() - bounds.x; bounds.height = (int) rect.getMaxY() - bounds.y; - + return bounds; } diff --git a/java/awt/font/GraphicAttribute.java b/java/awt/font/GraphicAttribute.java index 19f781bcc..edf0c204d 100644 --- a/java/awt/font/GraphicAttribute.java +++ b/java/awt/font/GraphicAttribute.java @@ -43,7 +43,7 @@ import java.awt.geom.Rectangle2D; /** * This class represents a graphic embedded in text. - * + * * @author Michael Koch * @author Lillian Angel (langel at redhat dot com) */ @@ -59,7 +59,7 @@ public abstract class GraphicAttribute /** * Constructor. - * + * * @param alignment - the alignment to use for the graphic */ protected GraphicAttribute(int alignment) @@ -71,7 +71,7 @@ public abstract class GraphicAttribute /** * Draws the graphic. - * + * * @param graphics - the graphics configuration to use * @param x - the x location * @param y - the y location @@ -81,7 +81,7 @@ public abstract class GraphicAttribute /** * Gets the distance from the origin of its graphic to the right side of the * bounds of its graphic. - * + * * @return the advance */ public abstract float getAdvance(); @@ -89,21 +89,21 @@ public abstract class GraphicAttribute /** * Gets the positive distance from the origin of its graphic to the top of * bounds. - * + * * @return the ascent */ public abstract float getAscent(); /** * Gets the distance from the origin of its graphic to the bottom of the bounds. - * + * * @return the descent */ public abstract float getDescent(); /** * Gets the alignment. - * + * * @return the alignment */ public final int getAlignment() @@ -114,7 +114,7 @@ public abstract class GraphicAttribute /** * Returns a Rectangle2D that encloses the rendered area. * Default bounds is the rectangle (0, -ascent, advance, ascent+descent). - * + * * @return the bounds of the rendered area */ public Rectangle2D getBounds() @@ -125,7 +125,7 @@ public abstract class GraphicAttribute /** * Returns the justification information for this object. - * + * * @return the justification information */ public GlyphJustificationInfo getJustificationInfo() diff --git a/java/awt/font/ImageGraphicAttribute.java b/java/awt/font/ImageGraphicAttribute.java index 3e4fdcf73..63fff4101 100644 --- a/java/awt/font/ImageGraphicAttribute.java +++ b/java/awt/font/ImageGraphicAttribute.java @@ -45,7 +45,7 @@ import java.awt.geom.Rectangle2D; /** * This is an implementation of GraphicAttribute which draws images in a * TextLayout. - * + * * @author Lillian Angel * @author Michael Koch */ @@ -58,7 +58,7 @@ public final class ImageGraphicAttribute /** * Constucts an instance from the specified Image. The origin is at (0, 0). - * + * * @param image - image to construct from. * @param alignment - the alignment */ @@ -70,7 +70,7 @@ public final class ImageGraphicAttribute /** * Constucts an instance from the specified Image. The origin is at (originX, * originY). - * + * * @param image - image to construct from * @param alignment - the alignment * @param originX - x point of origin @@ -88,10 +88,10 @@ public final class ImageGraphicAttribute /** * Draws the image at the specified location, relative to the * origin. - * + * * @param g - the graphics to use to render the image * @param x - the x location - * @param y - the y location + * @param y - the y location */ public void draw(Graphics2D g, float x, float y) { @@ -100,7 +100,7 @@ public final class ImageGraphicAttribute /** * Compares this to the specified Object - * + * * @param obj - the object to compare * @return true if the obj and this are equivalent */ @@ -115,7 +115,7 @@ public final class ImageGraphicAttribute /** * Compares this to the ImageGraphicAttribute given, by * comparing all fields and values. - * + * * @param rhs - the ImageGraphicAttribute to compare * @return true if the object given is equivalent to this */ @@ -128,13 +128,13 @@ public final class ImageGraphicAttribute && (this.getDescent() == rhs.getDescent()) && (this.hashCode() == rhs.hashCode()) && (this.image.equals(rhs.image)) - && (this.originX == rhs.originX) + && (this.originX == rhs.originX) && (this.originY == rhs.originY))); } /** * Returns distance from the origin to the right edge of the image of this. - * + * * @return the advance */ public float getAdvance() @@ -144,7 +144,7 @@ public final class ImageGraphicAttribute /** * Returns the the distance from the top of the image to the origin of this. - * + * * @return the ascent. */ public float getAscent() @@ -154,7 +154,7 @@ public final class ImageGraphicAttribute /** * Gets the bounds of the object rendered, relative to the position. - * + * * @return the bounds of the object rendered, relative to the position. */ public Rectangle2D getBounds() @@ -167,7 +167,7 @@ public final class ImageGraphicAttribute /** * Returns the distance from the origin to the bottom of the image. - * + * * @return the descent */ public float getDescent() @@ -177,7 +177,7 @@ public final class ImageGraphicAttribute /** * Gets the hash code for this image. - * + * * @return the hash code */ public int hashCode() diff --git a/java/awt/font/LineBreakMeasurer.java b/java/awt/font/LineBreakMeasurer.java index 278bc8476..d11f20d1f 100644 --- a/java/awt/font/LineBreakMeasurer.java +++ b/java/awt/font/LineBreakMeasurer.java @@ -45,17 +45,17 @@ public final class LineBreakMeasurer { private AttributedCharacterIterator text; private int position; - private TextMeasurer tm; + private TextMeasurer tm; private int numChars; - public LineBreakMeasurer(AttributedCharacterIterator text, - BreakIterator breakIter, FontRenderContext frc) + public LineBreakMeasurer(AttributedCharacterIterator text, + BreakIterator breakIter, FontRenderContext frc) { this( text, frc ); } - public LineBreakMeasurer(AttributedCharacterIterator text, - FontRenderContext frc) + public LineBreakMeasurer(AttributedCharacterIterator text, + FontRenderContext frc) { this.text = text; position = 0; @@ -63,15 +63,15 @@ public final class LineBreakMeasurer tm = new TextMeasurer( text, frc ); } - public void deleteChar(AttributedCharacterIterator newParagraph, - int deletePos) + public void deleteChar(AttributedCharacterIterator newParagraph, + int deletePos) { tm.deleteChar( newParagraph, deletePos ); position = 0; } - public void insertChar(AttributedCharacterIterator newParagraph, - int insertPos) + public void insertChar(AttributedCharacterIterator newParagraph, + int insertPos) { tm.insertChar( newParagraph, insertPos ); position = 0; @@ -82,8 +82,8 @@ public final class LineBreakMeasurer return nextLayout( wrappingWidth, numChars, false ); } - public TextLayout nextLayout(float wrappingWidth, int offsetLimit, - boolean requireNextWord) + public TextLayout nextLayout(float wrappingWidth, int offsetLimit, + boolean requireNextWord) { int next = nextOffset( wrappingWidth, offsetLimit, requireNextWord ); TextLayout tl = tm.getLayout( position, next ); @@ -96,8 +96,8 @@ public final class LineBreakMeasurer return nextOffset( wrappingWidth, numChars, false ); } - public int nextOffset(float wrappingWidth, int offsetLimit, - boolean requireNextWord) + public int nextOffset(float wrappingWidth, int offsetLimit, + boolean requireNextWord) { int guessOffset = tm.getLineBreakIndex(position, wrappingWidth); if( offsetLimit > numChars ) @@ -105,8 +105,8 @@ public final class LineBreakMeasurer if( guessOffset > offsetLimit ) { - text.setIndex( offsetLimit ); - return offsetLimit; + text.setIndex( offsetLimit ); + return offsetLimit; } text.setIndex( guessOffset ); @@ -117,18 +117,18 @@ public final class LineBreakMeasurer // Otherwise jump forward or backward to the last such char. if( !requireNextWord ) - while( !Character.isWhitespace( text.previous() ) && - guessOffset > position ) - guessOffset--; + while( !Character.isWhitespace( text.previous() ) && + guessOffset > position ) + guessOffset--; else - while( !Character.isWhitespace( text.next() ) && - guessOffset < offsetLimit ) - guessOffset++; - + while( !Character.isWhitespace( text.next() ) && + guessOffset < offsetLimit ) + guessOffset++; + if( guessOffset > offsetLimit ) { - text.setIndex( offsetLimit ); - return offsetLimit; + text.setIndex( offsetLimit ); + return offsetLimit; } text.setIndex( guessOffset ); @@ -146,4 +146,3 @@ public final class LineBreakMeasurer return position; } } - diff --git a/java/awt/font/LineMetrics.java b/java/awt/font/LineMetrics.java index 3c45ad19a..d43fd98bb 100644 --- a/java/awt/font/LineMetrics.java +++ b/java/awt/font/LineMetrics.java @@ -44,24 +44,24 @@ package java.awt.font; public abstract class LineMetrics { public abstract float getAscent(); - + public abstract int getBaselineIndex(); - + public abstract float[] getBaselineOffsets(); - + public abstract float getDescent(); - + public abstract float getHeight(); - + public abstract float getLeading(); - + public abstract int getNumChars(); - + public abstract float getStrikethroughOffset(); - + public abstract float getStrikethroughThickness(); - + public abstract float getUnderlineOffset(); - + public abstract float getUnderlineThickness(); } diff --git a/java/awt/font/MultipleMaster.java b/java/awt/font/MultipleMaster.java index 57417ea60..1be44bd75 100644 --- a/java/awt/font/MultipleMaster.java +++ b/java/awt/font/MultipleMaster.java @@ -46,16 +46,16 @@ import java.awt.Font; public interface MultipleMaster { Font deriveMMFont (float[] axes); - + Font deriveMMFont (float[] glyphWidths, float avgStemWidth, float typicalCapHeight, float typicalXHeight, float italicAngle); - + float[] getDesignAxisDefaults(); - + String[] getDesignAxisNames(); - + float[] getDesignAxisRanges(); - + int getNumDesignAxes(); } diff --git a/java/awt/font/OpenType.java b/java/awt/font/OpenType.java index ece3279cc..e992d0700 100644 --- a/java/awt/font/OpenType.java +++ b/java/awt/font/OpenType.java @@ -94,18 +94,18 @@ public interface OpenType int TAG_VDMX = 1447316824; int TAG_VHEA = 1986553185; int TAG_VMTX = 1986884728; - + byte[] getFontTable (int sfntTag); - + byte[] getFontTable (int sfntTag, int offset, int count); - + byte[] getFontTable (String strSfntTag); - + byte[] getFontTable (String strSfntTag, int offset, int count); - + int getFontTableSize (int sfntTag); - + int getFontTableSize (String strSfntTag); - + int getVersion (); } diff --git a/java/awt/font/ShapeGraphicAttribute.java b/java/awt/font/ShapeGraphicAttribute.java index 06814972b..8d6891632 100644 --- a/java/awt/font/ShapeGraphicAttribute.java +++ b/java/awt/font/ShapeGraphicAttribute.java @@ -44,24 +44,24 @@ import java.awt.geom.Rectangle2D; /** * This is an implementation of GraphicAttribute that draws shapes in a TextLayout. - * + * * @author Lillian Angel (langel at redhat dot com) */ public final class ShapeGraphicAttribute extends GraphicAttribute { /** True if the shape should be filled. */ public static final boolean FILL = false; - + /** True if the shape should be stroked with a 1-pixel wide stroke. */ public static final boolean STROKE = true; private Shape shape; private boolean stroke; private Rectangle2D bounds; - + /** * Constructor. - * + * * @param shape - the Shape to render. The Shape is rendered with its origin. * @param alignment - the alignment * @param stroke - true if the Shape should be stroked; false if the Shape @@ -77,7 +77,7 @@ public final class ShapeGraphicAttribute extends GraphicAttribute /** * Draws the graphic at the given location. - * + * * @param graphics - the graphics to use. * @param x - the x location to draw at. * @param y - the y location to draw at. @@ -94,7 +94,7 @@ public final class ShapeGraphicAttribute extends GraphicAttribute /** * Compares this ShapeGraphicAttribute to obj. - * + * * @param obj - the object to compare. */ public boolean equals(Object obj) @@ -107,7 +107,7 @@ public final class ShapeGraphicAttribute extends GraphicAttribute /** * Compares this ShapeGraphicAttribute to rhs. - * + * * @param rhs - the ShapeGraphicAttribute to compare. */ public boolean equals(ShapeGraphicAttribute rhs) @@ -118,14 +118,14 @@ public final class ShapeGraphicAttribute extends GraphicAttribute && getAdvance() == rhs.getAdvance() && getAscent() == rhs.getAscent() && getBounds().equals(rhs.getBounds()) - && getDescent() == rhs.getDescent() + && getDescent() == rhs.getDescent() && hashCode() == rhs.hashCode())); } /** * Gets the distance from the origin of its Shape to the right side of the * bounds of its Shape. - * + * * @return the advance */ public float getAdvance() @@ -136,7 +136,7 @@ public final class ShapeGraphicAttribute extends GraphicAttribute /** * Gets the positive distance from the origin of its Shape to the top of * bounds. - * + * * @return the ascent */ public float getAscent() @@ -146,7 +146,7 @@ public final class ShapeGraphicAttribute extends GraphicAttribute /** * Gets the distance from the origin of its Shape to the bottom of the bounds. - * + * * @return the descent */ public float getDescent() @@ -156,7 +156,7 @@ public final class ShapeGraphicAttribute extends GraphicAttribute /** * Returns a Rectangle2D that encloses all of the bits drawn by this shape. - * + * * @return the bounds of the shape. */ public Rectangle2D getBounds() @@ -169,13 +169,13 @@ public final class ShapeGraphicAttribute extends GraphicAttribute bounds.width++; bounds.height++; } - + return bounds; } /** * Gets the hash code. - * + * * @return the hash code. */ public int hashCode() diff --git a/java/awt/font/TextAttribute.java b/java/awt/font/TextAttribute.java index 6f5ed59f9..bfade21bb 100644 --- a/java/awt/font/TextAttribute.java +++ b/java/awt/font/TextAttribute.java @@ -48,197 +48,197 @@ import java.text.AttributedCharacterIterator; public final class TextAttribute extends AttributedCharacterIterator.Attribute { private static final long serialVersionUID = 7744112784117861702L; - + /** A key for the background paint attribute. */ public static final TextAttribute BACKGROUND = new TextAttribute("background"); - + /** A key for the BIDI_EMBEDDING attribute. */ public static final TextAttribute BIDI_EMBEDDING = new TextAttribute("bidi_embedding"); - + /** A key for the CHAR_REPLACEMENT attribute. */ public static final TextAttribute CHAR_REPLACEMENT = new TextAttribute("char_replacement"); - + /** A key for the FAMILY attribute. */ public static final TextAttribute FAMILY = new TextAttribute("family"); - + /** A key for the font attribute. */ public static final TextAttribute FONT = new TextAttribute("font"); - + /** A key for the foreground paint attribute. */ - public static final TextAttribute FOREGROUND = + public static final TextAttribute FOREGROUND = new TextAttribute("foreground"); - + /** A key for the INPUT_METHOD_HIGHLIGHT attribute. */ public static final TextAttribute INPUT_METHOD_HIGHLIGHT = new TextAttribute("input method highlight"); - + /** A key for the INPUT_METHOD_UNDERLINE attribute. */ public static final TextAttribute INPUT_METHOD_UNDERLINE = new TextAttribute("input method underline"); - + /** A key for the text justification attribute. */ public static final TextAttribute JUSTIFICATION = new TextAttribute("justification"); - - /** + + /** * A value that can be used with the {@link #JUSTIFICATION} attribute to - * indicate full justification of the text. + * indicate full justification of the text. */ public static final Float JUSTIFICATION_FULL = new Float(1.0); - - /** + + /** * A value that can be used with the {@link #JUSTIFICATION} attribute to - * indicate no justification of the text. + * indicate no justification of the text. */ public static final Float JUSTIFICATION_NONE = new Float(0.0); - + /** A key for the NUMERIC_SHAPING attribute. */ public static final TextAttribute NUMERIC_SHAPING = new TextAttribute("numeric_shaping"); - + /** A key for the POSTURE attribute. */ public static final TextAttribute POSTURE = new TextAttribute("posture"); - + /** A value that can be used with the {@link #POSTURE} attribute. */ public static final Float POSTURE_OBLIQUE = new Float(0.2); - + /** A value that can be used with the {@link #POSTURE} attribute. */ public static final Float POSTURE_REGULAR = new Float(0.0); - + /** A key for the RUN_DIRECTION attribute. */ public static final TextAttribute RUN_DIRECTION = new TextAttribute("run_direction"); - + /** A value that can be used with the {@link #RUN_DIRECTION} attribute. */ public static final Boolean RUN_DIRECTION_LTR = Boolean.FALSE; - + /** A value that can be used with the {@link #RUN_DIRECTION} attribute. */ public static final Boolean RUN_DIRECTION_RTL = Boolean.TRUE; - + /** A key for the text size attribute. */ public static final TextAttribute SIZE = new TextAttribute("size"); - + /** A key for the STRIKETHROUGH attribute. */ public static final TextAttribute STRIKETHROUGH = new TextAttribute("strikethrough"); - + /** A value that can be used with the {@link #STRIKETHROUGH} attribute. */ public static final Boolean STRIKETHROUGH_ON = Boolean.TRUE; - + /** A key for the SUPERSCRIPT attribute. */ public static final TextAttribute SUPERSCRIPT = new TextAttribute("superscript"); - + /** A value that can be used with the {@link #SUPERSCRIPT} attribute. */ public static final Integer SUPERSCRIPT_SUB = new Integer(-1); - + /** A value that can be used with the {@link #SUPERSCRIPT} attribute. */ public static final Integer SUPERSCRIPT_SUPER = new Integer(1); - + /** A key for the SWAP_COLORS attribute. */ public static final TextAttribute SWAP_COLORS = new TextAttribute("swap_colors"); - + /** A value that can be used with the {@link #SWAP_COLORS} attribute. */ public static final Boolean SWAP_COLORS_ON = Boolean.TRUE; - + /** A key for the TRANFORM attribute. */ public static final TextAttribute TRANSFORM = new TextAttribute("transform"); - + /** A key for the UNDERLINE attribute. */ public static final TextAttribute UNDERLINE = new TextAttribute("underline"); - + /** A value that can be used with the {@link #UNDERLINE} attribute. */ public static final Integer UNDERLINE_LOW_DASHED = new Integer(5); - + /** A value that can be used with the {@link #UNDERLINE} attribute. */ public static final Integer UNDERLINE_LOW_DOTTED = new Integer(3); - + /** A value that can be used with the {@link #UNDERLINE} attribute. */ public static final Integer UNDERLINE_LOW_GRAY = new Integer(4); - + /** A value that can be used with the {@link #UNDERLINE} attribute. */ public static final Integer UNDERLINE_LOW_ONE_PIXEL = new Integer(1); - + /** A value that can be used with the {@link #UNDERLINE} attribute. */ public static final Integer UNDERLINE_LOW_TWO_PIXEL = new Integer(2); - + /** A value that can be used with the {@link #UNDERLINE} attribute. */ public static final Integer UNDERLINE_ON = new Integer(0); - + /** A key for the WEIGHT attribute. */ public static final TextAttribute WEIGHT = new TextAttribute("weight"); - + /** A value that can be used with the {@link #WEIGHT} attribute. */ public static final Float WEIGHT_BOLD = new Float(2.0); - + /** A value that can be used with the {@link #WEIGHT} attribute. */ public static final Float WEIGHT_DEMIBOLD = new Float(1.75); - + /** A value that can be used with the {@link #WEIGHT} attribute. */ public static final Float WEIGHT_DEMILIGHT = new Float(0.875); - + /** A value that can be used with the {@link #WEIGHT} attribute. */ public static final Float WEIGHT_EXTRA_LIGHT = new Float(0.5); - + /** A value that can be used with the {@link #WEIGHT} attribute. */ public static final Float WEIGHT_EXTRABOLD = new Float(2.5); - + /** A value that can be used with the {@link #WEIGHT} attribute. */ public static final Float WEIGHT_HEAVY = new Float(2.25); - + /** A value that can be used with the {@link #WEIGHT} attribute. */ public static final Float WEIGHT_LIGHT = new Float(0.75); - + /** A value that can be used with the {@link #WEIGHT} attribute. */ public static final Float WEIGHT_MEDIUM = new Float(1.5); - + /** A value that can be used with the {@link #WEIGHT} attribute. */ public static final Float WEIGHT_REGULAR = new Float(1.0); - + /** A value that can be used with the {@link #WEIGHT} attribute. */ public static final Float WEIGHT_SEMIBOLD = new Float(1.25); - + /** A value that can be used with the {@link #WEIGHT} attribute. */ public static final Float WEIGHT_ULTRABOLD = new Float(2.75); - + /** A key for the WIDTH attribute. */ public static final TextAttribute WIDTH = new TextAttribute("width"); - + /** A value that can be used with the {@link #WIDTH} attribute. */ public static final Float WIDTH_CONDENSED = new Float(0.75); - + /** A value that can be used with the {@link #WIDTH} attribute. */ public static final Float WIDTH_EXTENDED = new Float(1.5); - + /** A value that can be used with the {@link #WIDTH} attribute. */ public static final Float WIDTH_REGULAR = new Float(1.0); - + /** A value that can be used with the {@link #WIDTH} attribute. */ public static final Float WIDTH_SEMI_CONDENSED = new Float(0.875); - + /** A value that can be used with the {@link #WIDTH} attribute. */ public static final Float WIDTH_SEMI_EXTENDED = new Float(1.25); - + /** * Creates a new attribute. - * + * * @param name the name. */ protected TextAttribute(String name) { super(name); } - + /** * After deserialization, this method ensures that only one instance of * each attribute is used. - * + * * @return The (single) attribute instance. - * + * * @throws InvalidObjectException if the attribute is not recognised. */ protected Object readResolve() diff --git a/java/awt/font/TextHitInfo.java b/java/awt/font/TextHitInfo.java index f6fee1add..17479b09e 100644 --- a/java/awt/font/TextHitInfo.java +++ b/java/awt/font/TextHitInfo.java @@ -1,4 +1,4 @@ -/* TextHitInfo.java -- +/* TextHitInfo.java -- Copyright (C) 2002, 2005 Free Software Foundation, Inc. This file is part of GNU Classpath. @@ -44,13 +44,13 @@ public final class TextHitInfo { private int charIndex; private boolean leadingEdge; - + TextHitInfo (int charIndex, boolean leadingEdge) { this.charIndex = charIndex; this.leadingEdge = leadingEdge; } - + public int getCharIndex() { return charIndex; @@ -75,7 +75,7 @@ public final class TextHitInfo { if(obj instanceof TextHitInfo) return this.equals((TextHitInfo) obj); - + return false; } @@ -83,7 +83,7 @@ public final class TextHitInfo { if (hitInfo == null) return false; - + return (charIndex == hitInfo.getCharIndex ()) && (leadingEdge == hitInfo.isLeadingEdge ()); } diff --git a/java/awt/font/TextLayout.java b/java/awt/font/TextLayout.java index 4346ab91d..c4f174245 100644 --- a/java/awt/font/TextLayout.java +++ b/java/awt/font/TextLayout.java @@ -134,7 +134,7 @@ public final class TextLayout implements Cloneable * performance. */ private float totalAdvance = -1F; - + /** * The cached natural bounds. */ @@ -188,7 +188,7 @@ public final class TextLayout implements Cloneable /** * Constructs a TextLayout. */ - public TextLayout (String str, Font font, FontRenderContext frc) + public TextLayout (String str, Font font, FontRenderContext frc) { this.frc = frc; string = str.toCharArray(); @@ -201,28 +201,28 @@ public final class TextLayout implements Cloneable if (Bidi.requiresBidi(string, offset, offset + length)) { - bidi = new Bidi(str, leftToRight ? Bidi.DIRECTION_LEFT_TO_RIGHT + bidi = new Bidi(str, leftToRight ? Bidi.DIRECTION_LEFT_TO_RIGHT : Bidi.DIRECTION_RIGHT_TO_LEFT ); - int rc = bidi.getRunCount(); - byte[] table = new byte[ rc ]; - for(int i = 0; i < table.length; i++) - table[i] = (byte)bidi.getRunLevel(i); + int rc = bidi.getRunCount(); + byte[] table = new byte[ rc ]; + for(int i = 0; i < table.length; i++) + table[i] = (byte)bidi.getRunLevel(i); runs = new Run[rc]; - for(int i = 0; i < rc; i++) - { - int start = bidi.getRunStart(i); - int end = bidi.getRunLimit(i); - if(start != end) // no empty runs. - { - GlyphVector gv = font.layoutGlyphVector(frc, + for(int i = 0; i < rc; i++) + { + int start = bidi.getRunStart(i); + int end = bidi.getRunLimit(i); + if(start != end) // no empty runs. + { + GlyphVector gv = font.layoutGlyphVector(frc, string, start, end, ((table[i] & 1) == 0) ? Font.LAYOUT_LEFT_TO_RIGHT : Font.LAYOUT_RIGHT_TO_LEFT ); runs[i] = new Run(gv, font, start, end); } - } - Bidi.reorderVisually( table, 0, runs, 0, runs.length ); + } + Bidi.reorderVisually( table, 0, runs, 0, runs.length ); // Clean up null runs. ArrayList cleaned = new ArrayList(rc); for (int i = 0; i < rc; i++) @@ -239,7 +239,7 @@ public final class TextLayout implements Cloneable leftToRight ? Font.LAYOUT_LEFT_TO_RIGHT : Font.LAYOUT_RIGHT_TO_LEFT ); Run run = new Run(gv, font, 0, length); - runs = new Run[]{ run }; + runs = new Run[]{ run }; } setCharIndices(); setupMappings(); @@ -247,8 +247,8 @@ public final class TextLayout implements Cloneable } public TextLayout (String string, - Map<? extends AttributedCharacterIterator.Attribute, ?> attributes, - FontRenderContext frc) + Map<? extends AttributedCharacterIterator.Attribute, ?> attributes, + FontRenderContext frc) { this( string, new Font( attributes ), frc ); } @@ -261,7 +261,7 @@ public final class TextLayout implements Cloneable /** * Package-private constructor to make a textlayout from an existing one. - * This is used by TextMeasurer for returning sub-layouts, and it + * This is used by TextMeasurer for returning sub-layouts, and it * saves a lot of time in not having to relayout the text. */ TextLayout(TextLayout t, int startIndex, int endIndex) @@ -284,14 +284,14 @@ public final class TextLayout implements Cloneable for( int i = 0; i < nRuns; i++ ) { Run run = t.runs[i + startingRun]; - GlyphVector gv = run.glyphVector; + GlyphVector gv = run.glyphVector; Font font = run.font; - // Copy only the relevant parts of the first and last runs. - int beginGlyphIndex = (i > 0) ? 0 : t.charIndices[startIndex][1]; - int numEntries = ( i < nRuns - 1) ? gv.getNumGlyphs() : - 1 + t.charIndices[endIndex - 1][1] - beginGlyphIndex; - - int[] codes = gv.getGlyphCodes(beginGlyphIndex, numEntries, null); + // Copy only the relevant parts of the first and last runs. + int beginGlyphIndex = (i > 0) ? 0 : t.charIndices[startIndex][1]; + int numEntries = ( i < nRuns - 1) ? gv.getNumGlyphs() : + 1 + t.charIndices[endIndex - 1][1] - beginGlyphIndex; + + int[] codes = gv.getGlyphCodes(beginGlyphIndex, numEntries, null); gv = font.createGlyphVector(frc, codes); runs[i] = new Run(gv, font, run.runStart - startIndex, run.runEnd - startIndex); @@ -311,7 +311,7 @@ public final class TextLayout implements Cloneable int currentChar = 0; for(int run = 0; run < runs.length; run++) { - currentChar = -1; + currentChar = -1; Run current = runs[run]; GlyphVector gv = current.glyphVector; for( int gi = 0; gi < gv.getNumGlyphs(); gi++) @@ -366,7 +366,7 @@ public final class TextLayout implements Cloneable { CPStringBuilder sb = new CPStringBuilder(); int idx = iter.getIndex(); - for(char c = iter.first(); c != CharacterIterator.DONE; c = iter.next()) + for(char c = iter.first(); c != CharacterIterator.DONE; c = iter.next()) sb.append(c); iter.setIndex( idx ); return sb.toString(); @@ -377,13 +377,13 @@ public final class TextLayout implements Cloneable Font f = (Font)iter.getAttribute(TextAttribute.FONT); if( f == null ) { - int size; - Float i = (Float)iter.getAttribute(TextAttribute.SIZE); - if( i != null ) - size = (int)i.floatValue(); - else - size = 14; - f = new Font("Dialog", Font.PLAIN, size ); + int size; + Float i = (Float)iter.getAttribute(TextAttribute.SIZE); + if( i != null ) + size = (int)i.floatValue(); + else + size = 14; + f = new Font("Dialog", Font.PLAIN, size ); } return f; } @@ -400,21 +400,21 @@ public final class TextLayout implements Cloneable leftToRight = true; while( i < endOffs && !gotDirection ) switch( Character.getDirectionality(string[i++]) ) - { - case Character.DIRECTIONALITY_LEFT_TO_RIGHT: - case Character.DIRECTIONALITY_LEFT_TO_RIGHT_EMBEDDING: - case Character.DIRECTIONALITY_LEFT_TO_RIGHT_OVERRIDE: - gotDirection = true; - break; - - case Character.DIRECTIONALITY_RIGHT_TO_LEFT: - case Character.DIRECTIONALITY_RIGHT_TO_LEFT_ARABIC: - case Character.DIRECTIONALITY_RIGHT_TO_LEFT_EMBEDDING: - case Character.DIRECTIONALITY_RIGHT_TO_LEFT_OVERRIDE: - leftToRight = false; - gotDirection = true; - break; - } + { + case Character.DIRECTIONALITY_LEFT_TO_RIGHT: + case Character.DIRECTIONALITY_LEFT_TO_RIGHT_EMBEDDING: + case Character.DIRECTIONALITY_LEFT_TO_RIGHT_OVERRIDE: + gotDirection = true; + break; + + case Character.DIRECTIONALITY_RIGHT_TO_LEFT: + case Character.DIRECTIONALITY_RIGHT_TO_LEFT_ARABIC: + case Character.DIRECTIONALITY_RIGHT_TO_LEFT_EMBEDDING: + case Character.DIRECTIONALITY_RIGHT_TO_LEFT_OVERRIDE: + leftToRight = false; + gotDirection = true; + break; + } determineWhiteSpace(); } @@ -422,14 +422,14 @@ public final class TextLayout implements Cloneable { // Determine if there's whitespace in the thing. // Ignore trailing chars. - int i = offset + length - 1; + int i = offset + length - 1; hasWhitespace = false; while( i >= offset && Character.isWhitespace( string[i] ) ) i--; // Check the remaining chars while( i >= offset ) if( Character.isWhitespace( string[i--] ) ) - hasWhitespace = true; + hasWhitespace = true; } protected Object clone () @@ -437,8 +437,8 @@ public final class TextLayout implements Cloneable return new TextLayout( this, 0, length); } - public void draw (Graphics2D g2, float x, float y) - { + public void draw (Graphics2D g2, float x, float y) + { for(int i = 0; i < runs.length; i++) { Run run = runs[i]; @@ -464,7 +464,7 @@ public final class TextLayout implements Cloneable // Compare all glyph vectors. for( int i = 0; i < runs.length; i++ ) if( !runs[i].equals( tl.runs[i] ) ) - return false; + return false; return true; } @@ -501,46 +501,46 @@ public final class TextLayout implements Cloneable public Shape getBlackBoxBounds (int firstEndpoint, int secondEndpoint) { if( secondEndpoint - firstEndpoint <= 0 ) - return new Rectangle2D.Float(); // Hmm? + return new Rectangle2D.Float(); // Hmm? if( firstEndpoint < 0 || secondEndpoint > getCharacterCount()) return new Rectangle2D.Float(); GeneralPath gp = new GeneralPath(); - + int ri = charIndices[ firstEndpoint ][0]; int gi = charIndices[ firstEndpoint ][1]; double advance = 0; - + for( int i = 0; i < ri; i++ ) { Run run = runs[i]; GlyphVector gv = run.glyphVector; advance += gv.getLogicalBounds().getWidth(); } - + for( int i = ri; i <= charIndices[ secondEndpoint - 1 ][0]; i++ ) { Run run = runs[i]; GlyphVector gv = run.glyphVector; - int dg; - if( i == charIndices[ secondEndpoint - 1 ][0] ) - dg = charIndices[ secondEndpoint - 1][1]; - else - dg = gv.getNumGlyphs() - 1; - - for( int j = 0; j <= dg; j++ ) - { - Rectangle2D r2 = (gv.getGlyphVisualBounds( j )). - getBounds2D(); - Point2D p = gv.getGlyphPosition( j ); - r2.setRect( advance + r2.getX(), r2.getY(), - r2.getWidth(), r2.getHeight() ); - gp.append(r2, false); - } - - advance += gv.getLogicalBounds().getWidth(); + int dg; + if( i == charIndices[ secondEndpoint - 1 ][0] ) + dg = charIndices[ secondEndpoint - 1][1]; + else + dg = gv.getNumGlyphs() - 1; + + for( int j = 0; j <= dg; j++ ) + { + Rectangle2D r2 = (gv.getGlyphVisualBounds( j )). + getBounds2D(); + Point2D p = gv.getGlyphPosition( j ); + r2.setRect( advance + r2.getX(), r2.getY(), + r2.getWidth(), r2.getHeight() ); + gp.append(r2, false); + } + + advance += gv.getLogicalBounds().getWidth(); } return gp; } @@ -564,7 +564,7 @@ public final class TextLayout implements Cloneable boolean leading = hit.isLeadingEdge(); // For the boundary cases we return the boundary runs. Run run; - + if (index >= length) { info[0] = getAdvance(); @@ -710,15 +710,15 @@ public final class TextLayout implements Cloneable public Shape getLogicalHighlightShape (int firstEndpoint, int secondEndpoint) { - return getLogicalHighlightShape( firstEndpoint, secondEndpoint, - getBounds() ); + return getLogicalHighlightShape( firstEndpoint, secondEndpoint, + getBounds() ); } public Shape getLogicalHighlightShape (int firstEndpoint, int secondEndpoint, Rectangle2D bounds) { if( secondEndpoint - firstEndpoint <= 0 ) - return new Rectangle2D.Float(); // Hmm? + return new Rectangle2D.Float(); // Hmm? if( firstEndpoint < 0 || secondEndpoint > getCharacterCount()) return new Rectangle2D.Float(); @@ -728,7 +728,7 @@ public final class TextLayout implements Cloneable int gi = charIndices[ firstEndpoint ][1]; double advance = 0; - + for( int i = 0; i < ri; i++ ) advance += runs[i].glyphVector.getLogicalBounds().getWidth(); @@ -736,24 +736,24 @@ public final class TextLayout implements Cloneable { Run run = runs[i]; GlyphVector gv = run.glyphVector; - int dg; // last index in this run to use. - if( i == charIndices[ secondEndpoint - 1 ][0] ) - dg = charIndices[ secondEndpoint - 1][1]; - else - dg = gv.getNumGlyphs() - 1; - - for(; gi <= dg; gi++ ) - { - Rectangle2D r2 = (gv.getGlyphLogicalBounds( gi )). - getBounds2D(); - if( r == null ) - r = r2; - else - r = r.createUnion(r2); - } - gi = 0; // reset glyph index into run for next run. - - advance += gv.getLogicalBounds().getWidth(); + int dg; // last index in this run to use. + if( i == charIndices[ secondEndpoint - 1 ][0] ) + dg = charIndices[ secondEndpoint - 1][1]; + else + dg = gv.getNumGlyphs() - 1; + + for(; gi <= dg; gi++ ) + { + Rectangle2D r2 = (gv.getGlyphLogicalBounds( gi )). + getBounds2D(); + if( r == null ) + r = r2; + else + r = r.createUnion(r2); + } + gi = 0; // reset glyph index into run for next run. + + advance += gv.getLogicalBounds().getWidth(); } return r; @@ -901,9 +901,9 @@ public final class TextLayout implements Cloneable for(int i = 0; i < runs.length; i++) { GlyphVector gv = runs[i].glyphVector; - gp.append( gv.getOutline( x, 0f ), false ); - Rectangle2D r = gv.getLogicalBounds(); - x += r.getWidth(); + gp.append( gv.getOutline( x, 0f ), false ); + Rectangle2D r = gv.getLogicalBounds(); + x += r.getWidth(); } if( tx != null ) gp.transform( tx ); @@ -935,22 +935,22 @@ public final class TextLayout implements Cloneable int lastNonWSChar = j - lastRun; j = 0; while( runs[ runs.length - 1 ].glyphVector.getGlyphCharIndex( j ) - <= lastNonWSChar ) + <= lastNonWSChar ) { - totalAdvance += runs[ runs.length - 1 ].glyphVector + totalAdvance += runs[ runs.length - 1 ].glyphVector .getGlyphLogicalBounds( j ) .getBounds2D().getWidth(); - j ++; + j ++; } - + return totalAdvance; } public Shape getVisualHighlightShape (TextHitInfo firstEndpoint, TextHitInfo secondEndpoint) { - return getVisualHighlightShape( firstEndpoint, secondEndpoint, - getBounds() ); + return getVisualHighlightShape( firstEndpoint, secondEndpoint, + getBounds() ); } public Shape getVisualHighlightShape (TextHitInfo firstEndpoint, @@ -1102,17 +1102,17 @@ public final class TextLayout implements Cloneable { Run current = runs[run]; for(int i = 0; i < current.glyphVector.getNumGlyphs(); i++ ) - { - int cindex = current.runStart + { + int cindex = current.runStart + current.glyphVector.getGlyphCharIndex( i ); - if( Character.isWhitespace( string[cindex] ) ) - // && cindex < lastNWS ) - { - wsglyphs[ nglyphs * 2 ] = run; - wsglyphs[ nglyphs * 2 + 1] = i; - nglyphs++; - } - } + if( Character.isWhitespace( string[cindex] ) ) + // && cindex < lastNWS ) + { + wsglyphs[ nglyphs * 2 ] = run; + wsglyphs[ nglyphs * 2 + 1] = i; + nglyphs++; + } + } } deltaW = deltaW / nglyphs; // Change in width per whitespace glyph double w = 0; @@ -1394,8 +1394,8 @@ public final class TextLayout implements Cloneable } public TextHitInfo getStrongCaret(TextHitInfo hit1, - TextHitInfo hit2, - TextLayout layout) + TextHitInfo hit2, + TextLayout layout) { byte l1 = layout.getCharacterLevel(hit1.getCharIndex()); byte l2 = layout.getCharacterLevel(hit2.getCharIndex()); @@ -1418,5 +1418,3 @@ public final class TextLayout implements Cloneable } } } - - diff --git a/java/awt/font/TextMeasurer.java b/java/awt/font/TextMeasurer.java index f4430bf6d..e443e8bc7 100644 --- a/java/awt/font/TextMeasurer.java +++ b/java/awt/font/TextMeasurer.java @@ -43,7 +43,7 @@ import java.awt.Shape; /** * TextMeasurer is a small utility class for measuring the length of laid-out - * text objects. + * text objects. * * @author Sven de Marothy * @since 1.3 @@ -57,9 +57,9 @@ public final class TextMeasurer implements Cloneable /** * Creates a TextMeasurer from a given text in the form of an - * <code>AttributedCharacterIterator</code> and a + * <code>AttributedCharacterIterator</code> and a * <code>FontRenderContext</code>. - */ + */ public TextMeasurer (AttributedCharacterIterator text, FontRenderContext frc) { this.text = text; @@ -139,22 +139,22 @@ public final class TextMeasurer implements Cloneable * * @param start - the starting index. * @param maxAdvance - the maximum advance allowed. - * @return the index of the first character beyond maxAdvance, or the + * @return the index of the first character beyond maxAdvance, or the * index of the last character + 1. */ public int getLineBreakIndex (int start, float maxAdvance) - { + { if( start < 0 ) throw new IllegalArgumentException("Start parameter must be > 0."); double remainingLength = getAdvanceBetween( start, numChars ); - + int guessOffset = (int)( ( (double)maxAdvance / (double)remainingLength) - * ( (double)numChars - (double)start ) ); + * ( (double)numChars - (double)start ) ); guessOffset += start; if( guessOffset > numChars ) guessOffset = numChars; - + double guessLength = getAdvanceBetween( start, guessOffset ); boolean makeSmaller = ( guessLength > maxAdvance ); int inc = makeSmaller ? -1 : 1; @@ -162,19 +162,19 @@ public final class TextMeasurer implements Cloneable do { - guessOffset = guessOffset + inc; - if( guessOffset <= start || guessOffset > numChars ) - { - keepGoing = false; - } - else - { - guessLength = getAdvanceBetween( start, guessOffset ); - if( makeSmaller && ( guessLength <= maxAdvance) ) - keepGoing = false; - if( !makeSmaller && ( guessLength >= maxAdvance) ) - keepGoing = false; - } + guessOffset = guessOffset + inc; + if( guessOffset <= start || guessOffset > numChars ) + { + keepGoing = false; + } + else + { + guessLength = getAdvanceBetween( start, guessOffset ); + if( makeSmaller && ( guessLength <= maxAdvance) ) + keepGoing = false; + if( !makeSmaller && ( guessLength >= maxAdvance) ) + keepGoing = false; + } } while( keepGoing ); diff --git a/java/awt/font/TransformAttribute.java b/java/awt/font/TransformAttribute.java index 977cafa03..56d15bb0b 100644 --- a/java/awt/font/TransformAttribute.java +++ b/java/awt/font/TransformAttribute.java @@ -43,12 +43,12 @@ import java.io.Serializable; /** * This class provides a mechanism for using an {@link AffineTransform} as - * an <i>immutable</i> attribute (for example, in the - * {@link java.text.AttributedString} class). Any transform passed to + * an <i>immutable</i> attribute (for example, in the + * {@link java.text.AttributedString} class). Any transform passed to * this class is copied before being stored, and any transform handed out - * by this class is a copy of the stored transform. In this way, it is + * by this class is a copy of the stored transform. In this way, it is * not possible to modify the stored transform. - * + * * @author Michael Koch */ public final class TransformAttribute implements Serializable @@ -56,16 +56,16 @@ public final class TransformAttribute implements Serializable private static final long serialVersionUID = 3356247357827709530L; private AffineTransform affineTransform; - + /** * Creates a new attribute that contains a copy of the given transform. - * + * * @param transform the transform (<code>null</code> not permitted). - * - * @throws IllegalArgumentException if <code>transform</code> is + * + * @throws IllegalArgumentException if <code>transform</code> is * <code>null</code>. */ - public TransformAttribute (AffineTransform transform) + public TransformAttribute (AffineTransform transform) { if (transform == null) { @@ -76,7 +76,7 @@ public final class TransformAttribute implements Serializable /** * Returns a copy of the transform contained by this attribute. - * + * * @return A copy of the transform. */ public AffineTransform getTransform () @@ -87,10 +87,10 @@ public final class TransformAttribute implements Serializable /** * Returns <code>true</code> if the transform contained by this attribute is * an identity transform, and <code>false</code> otherwise. - * + * * @return <code>true</code> if the transform contained by this attribute is * an identity transform, and <code>false</code> otherwise. - * + * * @since 1.4 */ public boolean isIdentity () |