[kaffe] CVS kaffe (robilad): Resynced with GNU Classpath: whitespace diffs

Kaffe CVS cvs-commits at kaffe.org
Sat Dec 11 17:41:42 PST 2004


PatchSet 5615 
Date: 2004/12/12 01:35:06
Author: robilad
Branch: HEAD
Tag: (none) 
Log:
Resynced with GNU Classpath: whitespace diffs

Members: 
	ChangeLog:1.3160->1.3161 
	libraries/javalib/java/awt/CardLayout.java:1.12->1.13 
	libraries/javalib/java/awt/Menu.java:1.12->1.13 
	libraries/javalib/java/awt/MenuItem.java:1.15->1.16 
	libraries/javalib/java/awt/Panel.java:1.12->1.13 
	libraries/javalib/java/awt/Polygon.java:1.8->1.9 
	libraries/javalib/java/awt/PopupMenu.java:1.10->1.11 
	libraries/javalib/java/awt/TextArea.java:1.5->1.6 
	libraries/javalib/java/awt/TextComponent.java:1.3->1.4 
	libraries/javalib/java/awt/TextField.java:1.4->1.5 
	libraries/javalib/java/awt/dnd/peer/DropTargetContextPeer.java:1.5->1.6 
	libraries/javalib/java/awt/im/spi/InputMethodContext.java:1.1->1.2 
	libraries/javalib/java/awt/image/Raster.java:1.7->1.8 
	libraries/javalib/javax/swing/AbstractListModel.java:1.3->1.4 
	libraries/javalib/javax/swing/JPasswordField.java:1.4->1.5 
	libraries/javalib/javax/swing/JTree.java:1.8->1.9 
	libraries/javalib/javax/swing/plaf/basic/BasicTextUI.java:1.8->1.9 
	libraries/javalib/javax/swing/text/PlainDocument.java:1.4->1.5 

Index: kaffe/ChangeLog
diff -u kaffe/ChangeLog:1.3160 kaffe/ChangeLog:1.3161
--- kaffe/ChangeLog:1.3160	Sat Dec 11 23:08:35 2004
+++ kaffe/ChangeLog	Sun Dec 12 01:35:06 2004
@@ -1,5 +1,26 @@
 2004-12-11  Dalibor Topic  <robilad at kaffe.org>
 
+	* libraries/javalib/java/awt/CardLayout.java,
+	libraries/javalib/java/awt/Menu.java,
+	libraries/javalib/java/awt/MenuItem.java,
+	libraries/javalib/java/awt/Panel.java,
+	libraries/javalib/java/awt/Polygon.java,
+	libraries/javalib/java/awt/PopupMenu.java,
+	libraries/javalib/java/awt/TextArea.java,
+	libraries/javalib/java/awt/TextComponent.java,
+	libraries/javalib/java/awt/TextField.java,
+	libraries/javalib/java/awt/dnd/peer/DropTargetContextPeer.java,
+	libraries/javalib/java/awt/im/spi/InputMethodContext.java,
+	libraries/javalib/java/awt/image/Raster.java,
+	libraries/javalib/javax/swing/AbstractListModel.java,
+	libraries/javalib/javax/swing/JPasswordField.java,
+	libraries/javalib/javax/swing/JTree.java,
+	libraries/javalib/javax/swing/plaf/basic/BasicTextUI.java,
+	libraries/javalib/javax/swing/text/PlainDocument.java:
+	Resynced with GNU Classpath. White-space diffs.
+
+2004-12-11  Dalibor Topic  <robilad at kaffe.org>
+
 	* libraries/clib/awt/classpath-gtk/gtk-peer/gnu_java_awt_peer_gtk_GdkGraphics.c,
 	libraries/javalib/gnu/java/awt/peer/gtk/GdkGraphics.java,
 	libraries/javalib/gnu/java/awt/peer/gtk/GtkFramePeer.java,
Index: kaffe/libraries/javalib/java/awt/CardLayout.java
diff -u kaffe/libraries/javalib/java/awt/CardLayout.java:1.12 kaffe/libraries/javalib/java/awt/CardLayout.java:1.13
--- kaffe/libraries/javalib/java/awt/CardLayout.java:1.12	Thu Dec  2 19:22:19 2004
+++ kaffe/libraries/javalib/java/awt/CardLayout.java	Sun Dec 12 01:35:08 2004
@@ -85,7 +85,7 @@
    *
    * @param comp The component to add
    * @param constraints The name by which the component can later be called
-   *
+   * 
    * @exception IllegalArgumentException If `constraints' is not a
    * <code>String</code>
    */
@@ -100,10 +100,10 @@
   /**
    * Add a new component to the layout.  The name can be used later
    * to refer to the component.
-   *
+   * 
    * @param name The name by which the component can later be called
    * @param comp The component to add
-   *
+   * 
    * @deprecated This method is deprecated in favor of
    * <code>addLayoutComponent(Component, Object)</code>.
    */
@@ -137,7 +137,7 @@
   /**
    * Return this layout manager's x alignment.  This method always
    * returns Component.CENTER_ALIGNMENT.
-   *
+   * 
    * @param parent Container using this layout manager instance
    *
    * @return the x-axis alignment
@@ -150,7 +150,7 @@
   /**
    * Returns this layout manager's y alignment.  This method always
    * returns Component.CENTER_ALIGNMENT.
-   *
+   * 
    * @param parent Container using this layout manager instance
    *
    * @return the y-axis alignment
@@ -180,7 +180,7 @@
 
   /**
    * Cause the last component in the container to be displayed.
-   *
+   * 
    * @param parent The parent container
    */
   public void last (Container parent)
@@ -218,7 +218,7 @@
 
   /**
    * Get the maximum layout size of the container.
-   *
+   * 
    * @param target The parent container
    *
    * @return the maximum layout size
@@ -232,7 +232,7 @@
 
   /**
    * Get the minimum layout size of the container.
-   *
+   * 
    * @param target The parent container
    *
    * @return the minimum layout size
@@ -246,7 +246,7 @@
    * Cause the next component in the container to be displayed.  If
    * this current card is the  last one in the deck, the first
    * component is displayed.
-   *
+   * 
    * @param parent The parent container
    */
   public void next (Container parent)
@@ -256,7 +256,7 @@
 
   /**
    * Get the preferred layout size of the container.
-   *
+   * 
    * @param parent The parent container
    *
    * @return the preferred layout size
@@ -270,7 +270,7 @@
    * Cause the previous component in the container to be displayed.
    * If this current card is the first one in the deck, the last
    * component is displayed.
-   *
+   * 
    * @param parent The parent container
    */
   public void previous (Container parent)
@@ -280,7 +280,7 @@
 
   /**
    * Remove the indicated component from this layout manager.
-   *
+   * 
    * @param comp The component to remove
    */
   public void removeLayoutComponent (Component comp)
@@ -301,7 +301,7 @@
 
   /**
    * Set this layout manager's horizontal gap.
-   *
+   * 
    * @param hgap The new gap
    */
   public void setHgap (int hgap)
@@ -311,7 +311,7 @@
 
   /**
    * Set this layout manager's vertical gap.
-   *
+   * 
    * @param vgap The new gap
    */
   public void setVgap (int vgap)
@@ -322,7 +322,7 @@
   /**
    * Cause the named component to be shown.  If the component name is
    * unknown, this method does nothing.
-   *
+   * 
    * @param parent The parent container
    * @param name The name of the component to show
    */
@@ -359,7 +359,7 @@
 
   /**
    * This implements first(), last(), next(), and previous().
-   *
+   * 
    * @param parent The parent container
    * @param what The type of goto: FIRST, LAST, NEXT or PREV
    */
Index: kaffe/libraries/javalib/java/awt/Menu.java
diff -u kaffe/libraries/javalib/java/awt/Menu.java:1.12 kaffe/libraries/javalib/java/awt/Menu.java:1.13
--- kaffe/libraries/javalib/java/awt/Menu.java:1.12	Fri Dec  3 01:56:21 2004
+++ kaffe/libraries/javalib/java/awt/Menu.java	Sun Dec 12 01:35:08 2004
@@ -444,7 +444,7 @@
     protected AccessibleAWTMenu()
     {
     }
-
+    
     public AccessibleRole getAccessibleRole()
     {
       return AccessibleRole.MENU;
Index: kaffe/libraries/javalib/java/awt/MenuItem.java
diff -u kaffe/libraries/javalib/java/awt/MenuItem.java:1.15 kaffe/libraries/javalib/java/awt/MenuItem.java:1.16
--- kaffe/libraries/javalib/java/awt/MenuItem.java:1.15	Fri Dec  3 01:56:22 2004
+++ kaffe/libraries/javalib/java/awt/MenuItem.java	Sun Dec 12 01:35:09 2004
@@ -109,24 +109,24 @@
     {
       super();
     }
-
-
-
+  
+  
+  
     public String getAccessibleName()
     {
       return label;
     }
-
+  
     public AccessibleAction getAccessibleAction()
     {
       return this;
     }
-
+  
     public AccessibleRole getAccessibleRole()
     {
       return AccessibleRole.MENU_ITEM;
     }
-
+  
     /* (non-Javadoc)
      * @see javax.accessibility.AccessibleAction#getAccessibleActionCount()
      */
@@ -141,9 +141,9 @@
     public String getAccessibleActionDescription(int i)
     {
       if (i == 0)
-       return label;
+	return label;
       else
-       return null;
+	return null;
     }
 
     /* (non-Javadoc)
@@ -152,7 +152,7 @@
     public boolean doAccessibleAction(int i)
     {
       if (i != 0)
-       return false;
+	return false;
       processActionEvent(new ActionEvent(this, ActionEvent.ACTION_PERFORMED, actionCommand));
       return true;
     }
@@ -161,7 +161,7 @@
     {
       return this;
     }
-
+  
     /* (non-Javadoc)
      * @see javax.accessibility.AccessibleValue#getCurrentAccessibleValue()
      */
@@ -176,11 +176,11 @@
     public boolean setCurrentAccessibleValue(Number number)
     {
       if (number.intValue() == 0)
-       {
-         setEnabled(false);
-         return false;
-       }
-
+	{
+	  setEnabled(false);
+	  return false;
+	}
+    
       setEnabled(true);
       return true;
     }
@@ -200,7 +200,7 @@
     {
       return new Integer(0);
     }
-
+  
   }
 
 
Index: kaffe/libraries/javalib/java/awt/Panel.java
diff -u kaffe/libraries/javalib/java/awt/Panel.java:1.12 kaffe/libraries/javalib/java/awt/Panel.java:1.13
--- kaffe/libraries/javalib/java/awt/Panel.java:1.12	Mon Oct  4 09:01:30 2004
+++ kaffe/libraries/javalib/java/awt/Panel.java	Sun Dec 12 01:35:09 2004
@@ -73,7 +73,7 @@
   /*
    * The number used to generate the name returned by getName.
    */
-  private static transient long next_panel_number = 0;
+  private static transient long next_panel_number;
 
   /**
    * Initializes a new instance of <code>Panel</code> that has a default
Index: kaffe/libraries/javalib/java/awt/Polygon.java
diff -u kaffe/libraries/javalib/java/awt/Polygon.java:1.8 kaffe/libraries/javalib/java/awt/Polygon.java:1.9
--- kaffe/libraries/javalib/java/awt/Polygon.java:1.8	Mon Nov 15 00:32:07 2004
+++ kaffe/libraries/javalib/java/awt/Polygon.java	Sun Dec 12 01:35:10 2004
@@ -175,13 +175,13 @@
     int i = npoints;
     while (--i >= 0)
       {
-       xpoints[i] += dx;
-       ypoints[i] += dy;
+	xpoints[i] += dx;
+	ypoints[i] += dy;
       }
     if (bounds != null)
       {
-       bounds.x += dx;
-       bounds.y += dy;
+	bounds.x += dx;
+	bounds.y += dy;
       }
   }
 
@@ -196,43 +196,43 @@
   {
     if (npoints + 1 > xpoints.length)
       {
-       int[] newx = new int[npoints + 1];
-       System.arraycopy(xpoints, 0, newx, 0, npoints);
-       xpoints = newx;
+	int[] newx = new int[npoints + 1];
+	System.arraycopy(xpoints, 0, newx, 0, npoints);
+	xpoints = newx;
       }
     if (npoints + 1 > ypoints.length)
       {
-       int[] newy = new int[npoints + 1];
-       System.arraycopy(ypoints, 0, newy, 0, npoints);
-       ypoints = newy;
+	int[] newy = new int[npoints + 1];
+	System.arraycopy(ypoints, 0, newy, 0, npoints);
+	ypoints = newy;
       }
     xpoints[npoints] = x;
     ypoints[npoints] = y;
     npoints++;
     if (bounds != null)
       {
-       if (npoints == 1)
-         {
-           bounds.x = x;
-           bounds.y = y;
-         }
-       else
-         {
-           if (x < bounds.x)
-             {
-               bounds.width += bounds.x - x;
-               bounds.x = x;
-             }
-           else if (x > bounds.x + bounds.width)
-             bounds.width = x - bounds.x;
-           if (y < bounds.y)
-             {
-               bounds.height += bounds.y - y;
-               bounds.y = y;
-             }
-           else if (y > bounds.y + bounds.height)
-             bounds.height = y - bounds.y;
-         }
+	if (npoints == 1)
+	  {
+	    bounds.x = x;
+	    bounds.y = y;
+	  }
+	else
+	  {
+	    if (x < bounds.x)
+	      {
+		bounds.width += bounds.x - x;
+		bounds.x = x;
+	      }
+	    else if (x > bounds.x + bounds.width)
+	      bounds.width = x - bounds.x;
+	    if (y < bounds.y)
+	      {
+		bounds.height += bounds.y - y;
+		bounds.y = y;
+	      }
+	    else if (y > bounds.y + bounds.height)
+	      bounds.height = y - bounds.y;
+	  }
       }
   }
 
@@ -263,27 +263,27 @@
   {
     if (bounds == null)
       {
-       if (npoints == 0)
-         return bounds = new Rectangle();
-       int i = npoints - 1;
-       int minx = xpoints[i];
-       int maxx = minx;
-       int miny = ypoints[i];
-       int maxy = miny;
-       while (--i >= 0)
-         {
-           int x = xpoints[i];
-           int y = ypoints[i];
-           if (x < minx)
-             minx = x;
-           else if (x > maxx)
-             maxx = x;
-           if (y < miny)
-             miny = y;
-           else if (y > maxy)
-             maxy = y;
-         }
-       bounds = new Rectangle(minx, miny, maxx - minx, maxy - miny);
+	if (npoints == 0)
+	  return bounds = new Rectangle();
+	int i = npoints - 1;
+	int minx = xpoints[i];
+	int maxx = minx;
+	int miny = ypoints[i];
+	int maxy = miny;
+	while (--i >= 0)
+	  {
+	    int x = xpoints[i];
+	    int y = ypoints[i];
+	    if (x < minx)
+	      minx = x;
+	    else if (x > maxx)
+	      maxx = x;
+	    if (y < miny)
+	      miny = y;
+	    else if (y > maxy)
+	      maxy = y;
+	  }
+	bounds = new Rectangle(minx, miny, maxx - minx, maxy - miny);
       }
     return bounds;
   }
@@ -476,45 +476,45 @@
   {
     return new PathIterator()
       {
-       /** The current vertex of iteration. */
-       private int vertex;
+	/** The current vertex of iteration. */
+	private int vertex;
 
-       public int getWindingRule()
-       {
-         return WIND_EVEN_ODD;
-       }
-
-       public boolean isDone()
-       {
-         return vertex > npoints;
-       }
-
-       public void next()
-       {
-         vertex++;
-       }
-
-       public int currentSegment(float[] coords)
-       {
-         if (vertex >= npoints)
-           return SEG_CLOSE;
-         coords[0] = xpoints[vertex];
-         coords[1] = ypoints[vertex];
-         if (transform != null)
-           transform.transform(coords, 0, coords, 0, 1);
-         return vertex == 0 ? SEG_MOVETO : SEG_LINETO;
-       }
-
-       public int currentSegment(double[] coords)
-       {
-         if (vertex >= npoints)
-           return SEG_CLOSE;
-         coords[0] = xpoints[vertex];
-         coords[1] = ypoints[vertex];
-         if (transform != null)
-           transform.transform(coords, 0, coords, 0, 1);
-         return vertex == 0 ? SEG_MOVETO : SEG_LINETO;
-       }
+	public int getWindingRule()
+	{
+	  return WIND_EVEN_ODD;
+	}
+
+	public boolean isDone()
+	{
+	  return vertex > npoints;
+	}
+
+	public void next()
+	{
+	  vertex++;
+	}
+
+	public int currentSegment(float[] coords)
+	{
+	  if (vertex >= npoints)
+	    return SEG_CLOSE;
+	  coords[0] = xpoints[vertex];
+	  coords[1] = ypoints[vertex];
+	  if (transform != null)
+	    transform.transform(coords, 0, coords, 0, 1);
+	  return vertex == 0 ? SEG_MOVETO : SEG_LINETO;
+	}
+
+	public int currentSegment(double[] coords)
+	{
+	  if (vertex >= npoints)
+	    return SEG_CLOSE;
+	  coords[0] = xpoints[vertex];
+	  coords[1] = ypoints[vertex];
+	  if (transform != null)
+	    transform.transform(coords, 0, coords, 0, 1);
+	  return vertex == 0 ? SEG_MOVETO : SEG_LINETO;
+	}
       };
   }
 
@@ -561,17 +561,17 @@
 
     if (useYaxis)
       {
-       xp = ypoints;
-       yp = xpoints;
-       double swap;
-       swap = y;
-       y = x;
-       x = swap;
+	xp = ypoints;
+	yp = xpoints;
+	double swap;
+	swap = y;
+	y = x;
+	x = swap;
       }
     else
       {
-       xp = xpoints;
-       yp = ypoints;
+	xp = xpoints;
+	yp = ypoints;
       }
 
     /* Get a value which is small but not insignificant relative the path. */
@@ -581,19 +581,19 @@
     y0 = yp[0] - y;
     for (int i = 1; i < npoints; i++)
       {
-       x1 = xp[i] - x;
-       y1 = yp[i] - y;
+	x1 = xp[i] - x;
+	y1 = yp[i] - y;
 
-       if (y0 == 0.0)
-         y0 -= epsilon;
-       if (y1 == 0.0)
-         y1 -= epsilon;
-       if (y0 * y1 < 0)
-         if (Line2D.linesIntersect(x0, y0, x1, y1, epsilon, 0.0, distance, 0.0))
-           ++crossings;
+	if (y0 == 0.0)
+	  y0 -= epsilon;
+	if (y1 == 0.0)
+	  y1 -= epsilon;
+	if (y0 * y1 < 0)
+	  if (Line2D.linesIntersect(x0, y0, x1, y1, epsilon, 0.0, distance, 0.0))
+	    ++crossings;
 
-       x0 = xp[i] - x;
-       y0 = yp[i] - y;
+	x0 = xp[i] - x;
+	y0 = yp[i] - y;
       }
 
     // end segment
@@ -605,7 +605,7 @@
       y1 -= epsilon;
     if (y0 * y1 < 0)
       if (Line2D.linesIntersect(x0, y0, x1, y1, epsilon, 0.0, distance, 0.0))
-       ++crossings;
+	++crossings;
 
     return crossings;
   }
Index: kaffe/libraries/javalib/java/awt/PopupMenu.java
diff -u kaffe/libraries/javalib/java/awt/PopupMenu.java:1.10 kaffe/libraries/javalib/java/awt/PopupMenu.java:1.11
--- kaffe/libraries/javalib/java/awt/PopupMenu.java:1.10	Fri Dec  3 01:56:22 2004
+++ kaffe/libraries/javalib/java/awt/PopupMenu.java	Sun Dec 12 01:35:10 2004
@@ -143,14 +143,14 @@
     protected AccessibleAWTPopupMenu()
     {
     }
-
+    
     public AccessibleRole getAccessibleRole()
     {
       return AccessibleRole.POPUP_MENU;
     }
-
+    
   }
-
+  
   public AccessibleContext getAccessibleContext()
   {
     return new AccessibleAWTPopupMenu();
Index: kaffe/libraries/javalib/java/awt/TextArea.java
diff -u kaffe/libraries/javalib/java/awt/TextArea.java:1.5 kaffe/libraries/javalib/java/awt/TextArea.java:1.6
--- kaffe/libraries/javalib/java/awt/TextArea.java:1.5	Fri Dec  3 01:56:22 2004
+++ kaffe/libraries/javalib/java/awt/TextArea.java	Sun Dec 12 01:35:11 2004
@@ -600,19 +600,19 @@
   {
     return next_text_number++;
   }
-
+  
   protected class AccessibleAWTTextArea extends AccessibleAWTTextComponent
   {
     protected AccessibleAWTTextArea()
     {
     }
-
+    
     public AccessibleStateSet getAccessibleStateSet()
     {
       return super.getAccessibleStateSet();
     }
   }
-
+  
   public AccessibleContext getAccessibleContext()
   {
     return new AccessibleAWTTextArea();
Index: kaffe/libraries/javalib/java/awt/TextComponent.java
diff -u kaffe/libraries/javalib/java/awt/TextComponent.java:1.3 kaffe/libraries/javalib/java/awt/TextComponent.java:1.4
--- kaffe/libraries/javalib/java/awt/TextComponent.java:1.3	Fri Dec  3 01:56:22 2004
+++ kaffe/libraries/javalib/java/awt/TextComponent.java	Sun Dec 12 01:35:11 2004
@@ -108,12 +108,12 @@
     {
       TextComponent.this.addTextListener(this);
     }
-
+    
     public AccessibleRole getAccessibleRole()
     {
       return AccessibleRole.TEXT;
     }
-
+    
     public AccessibleStateSet getAccessibleStateSet()
     {
       // TODO: Docs say PropertyChangeEvent will fire if this state changes.
@@ -123,12 +123,12 @@
         ss.add(AccessibleState.EDITABLE);
       return ss;
     }
-
+    
     public AccessibleText getAccessibleText()
     {
       return this;
     }
-
+    
     /* (non-Javadoc)
      * @see javax.accessibility.AccessibleText#getIndexAtPoint(java.awt.Point)
      */
@@ -171,26 +171,26 @@
       BreakIterator it = null;
       switch (part)
       {
-       case CHARACTER:
-         return text.substring(index, index + 1);
-       case WORD:
-         it = BreakIterator.getWordInstance();
-         break;
-       case SENTENCE:
-         it = BreakIterator.getSentenceInstance();
-         break;
-       default:
-         return null;
+      	case CHARACTER:
+      	  return text.substring(index, index + 1);
+      	case WORD:
+      	  it = BreakIterator.getWordInstance();
+      	  break;
+      	case SENTENCE:
+      	  it = BreakIterator.getSentenceInstance();
+      	  break;
+      	default:
+      	  return null;
       }
-         it.setText(text);
-         int start = index;
-         if (!it.isBoundary(index))
-           start = it.preceding(index);
-         int end = it.following(index);
-         if (end == -1)
-           return text.substring(index);
-         else
-           return text.substring(index, end);
+  	  it.setText(text);
+  	  int start = index;
+  	  if (!it.isBoundary(index))
+  	    start = it.preceding(index); 
+  	  int end = it.following(index);
+  	  if (end == -1)
+  	    return text.substring(index);
+  	  else
+  	    return text.substring(index, end);
     }
 
     /* (non-Javadoc)
@@ -202,30 +202,30 @@
       BreakIterator it = null;
       switch (part)
       {
-       case CHARACTER:
-         return text.substring(index, index + 1);
-       case WORD:
-         it = BreakIterator.getWordInstance();
-         break;
-       case SENTENCE:
-         it = BreakIterator.getSentenceInstance();
-         break;
-       default:
-         return null;
+      	case CHARACTER:
+      	  return text.substring(index, index + 1);
+      	case WORD:
+      	  it = BreakIterator.getWordInstance();
+      	  break;
+      	case SENTENCE:
+      	  it = BreakIterator.getSentenceInstance();
+      	  break;
+      	default:
+      	  return null;
       }
-         it.setText(text);
-         int start = index;
-         if (!it.isBoundary(index))
-           start = it.following(index);
-         // Make sure there was a complete unit.  I.e. if index is in the middle
-         // of a word, return null if there is no word after the that one.
-         if (start == -1)
-           return null;
-         int end = it.following(start);
-         if (end == -1)
-           return text.substring(index);
-         else
-           return text.substring(index, end);
+  	  it.setText(text);
+  	  int start = index;
+  	  if (!it.isBoundary(index))
+  	    start = it.following(index);
+  	  // Make sure there was a complete unit.  I.e. if index is in the middle
+  	  // of a word, return null if there is no word after the that one.
+  	  if (start == -1)
+  	    return null;
+  	  int end = it.following(start);
+  	  if (end == -1)
+  	    return text.substring(index);
+  	  else
+  	    return text.substring(index, end);
     }
 
     /* (non-Javadoc)
@@ -238,30 +238,30 @@
       BreakIterator it = null;
       switch (part)
       {
-       case CHARACTER:
-         return text.substring(index - 1, index);
-       case WORD:
-         it = BreakIterator.getWordInstance();
-         break;
-       case SENTENCE:
-         it = BreakIterator.getSentenceInstance();
-         break;
-       default:
-         return null;
+      	case CHARACTER:
+      	  return text.substring(index - 1, index);
+      	case WORD:
+      	  it = BreakIterator.getWordInstance();
+      	  break;
+      	case SENTENCE:
+      	  it = BreakIterator.getSentenceInstance();
+      	  break;
+      	default:
+      	  return null;
       }
-         it.setText(text);
-         int end = index;
-         if (!it.isBoundary(index))
-           end = it.preceding(index);
-         // Make sure there was a complete unit.  I.e. if index is in the middle
-         // of a word, return null if there is no word before that one.
-         if (end == -1)
-           return null;
-         int start = it.preceding(end);
-         if (start == -1)
-           return text.substring(0, end);
-         else
-           return text.substring(start, end);
+  	  it.setText(text);
+  	  int end = index;
+  	  if (!it.isBoundary(index))
+  	    end = it.preceding(index); 
+  	  // Make sure there was a complete unit.  I.e. if index is in the middle
+  	  // of a word, return null if there is no word before that one.
+  	  if (end == -1)
+  	    return null;
+  	  int start = it.preceding(end);
+  	  if (start == -1)
+  	    return text.substring(0, end);
+  	  else
+  	    return text.substring(start, end);
     }
 
     /* (non-Javadoc)
@@ -306,9 +306,9 @@
     public void textValueChanged(TextEvent event)
     {
       // TODO Auto-generated method stub
-
+      
     }
-
+    
   }
 
 /*************************************************************************/
@@ -701,7 +701,7 @@
       return tcp.getIndexAtPoint(p.x, p.y);
     return -1;
   }
-
+  
   private synchronized Rectangle
   getCharacterBounds(int i)
   {
@@ -710,8 +710,8 @@
       return tcp.getCharacterBounds(i);
     return null;
   }
-
-
+  
+  
 
 
 } // class TextComponent
Index: kaffe/libraries/javalib/java/awt/TextField.java
diff -u kaffe/libraries/javalib/java/awt/TextField.java:1.4 kaffe/libraries/javalib/java/awt/TextField.java:1.5
--- kaffe/libraries/javalib/java/awt/TextField.java:1.4	Fri Dec  3 01:56:22 2004
+++ kaffe/libraries/javalib/java/awt/TextField.java	Sun Dec 12 01:35:11 2004
@@ -526,13 +526,13 @@
     protected AccessibleAWTTextField()
     {
     }
-
+    
     public AccessibleStateSet getAccessibleStateSet()
     {
       return super.getAccessibleStateSet();
     }
   }
-
+  
   public AccessibleContext getAccessibleContext()
   {
     return new AccessibleAWTTextField();
Index: kaffe/libraries/javalib/java/awt/dnd/peer/DropTargetContextPeer.java
diff -u kaffe/libraries/javalib/java/awt/dnd/peer/DropTargetContextPeer.java:1.5 kaffe/libraries/javalib/java/awt/dnd/peer/DropTargetContextPeer.java:1.6
--- kaffe/libraries/javalib/java/awt/dnd/peer/DropTargetContextPeer.java:1.5	Thu Jul 22 19:37:07 2004
+++ kaffe/libraries/javalib/java/awt/dnd/peer/DropTargetContextPeer.java	Sun Dec 12 01:35:11 2004
@@ -1,5 +1,5 @@
 /* DropTargetContextPeer.java -- interface for drag-and-drop peers
-   Copyright (C) 2002 Free Software Foundation, Inc.
+   Copyright (C) 2002, 2004  Free Software Foundation, Inc.
 
 This file is part of GNU Classpath.
 
@@ -35,11 +35,12 @@
 obligated to do so.  If you do not wish to do so, delete this
 exception statement from your version. */
 
+
 package java.awt.dnd.peer;
 
-import java.awt.dnd.DropTarget;
 import java.awt.datatransfer.DataFlavor;
 import java.awt.datatransfer.Transferable;
+import java.awt.dnd.DropTarget;
 import java.awt.dnd.InvalidDnDOperationException;
 
 
Index: kaffe/libraries/javalib/java/awt/im/spi/InputMethodContext.java
diff -u kaffe/libraries/javalib/java/awt/im/spi/InputMethodContext.java:1.1 kaffe/libraries/javalib/java/awt/im/spi/InputMethodContext.java:1.2
--- kaffe/libraries/javalib/java/awt/im/spi/InputMethodContext.java:1.1	Thu Jul 22 19:37:11 2004
+++ kaffe/libraries/javalib/java/awt/im/spi/InputMethodContext.java	Sun Dec 12 01:35:12 2004
@@ -1,5 +1,5 @@
 /* InputMethodContext.java -- communication between an input method and client
-   Copyright (C) 2002 Free Software Foundation, Inc.
+   Copyright (C) 2002, 2004  Free Software Foundation, Inc.
 
 This file is part of GNU Classpath.
 
@@ -35,13 +35,14 @@
 obligated to do so.  If you do not wish to do so, delete this
 exception statement from your version. */
 
+
 package java.awt.im.spi;
 
-import java.awt.HeadlessException;
 import java.awt.Window;
 import java.awt.font.TextHitInfo;
 import java.awt.im.InputMethodRequests;
 import java.text.AttributedCharacterIterator;
+
 import javax.swing.JFrame;
 
 /**
@@ -49,7 +50,7 @@
  * and the client component. This should be passed to
  * {@link InputMethod#setInputMethodContext(InputMethodContext)}.
  *
- * @author Eric Blake <ebb9 at email.byu.edu>
+ * @author Eric Blake (ebb9 at email.byu.edu)
  * @since 1.3
  * @status updated to 1.4
  */
Index: kaffe/libraries/javalib/java/awt/image/Raster.java
diff -u kaffe/libraries/javalib/java/awt/image/Raster.java:1.7 kaffe/libraries/javalib/java/awt/image/Raster.java:1.8
--- kaffe/libraries/javalib/java/awt/image/Raster.java:1.7	Sun Nov 14 20:52:02 2004
+++ kaffe/libraries/javalib/java/awt/image/Raster.java	Sun Dec 12 01:35:12 2004
@@ -225,24 +225,24 @@
 				       bandMasks);
     return createWritableRaster(sm, dataBuffer, location);
   }
-    
-  public static Raster createRaster(SampleModel sm, DataBuffer db,
-				    Point location)
-  {
-    return new Raster(sm, db, location);
-  }
-
+  
   public static WritableRaster
   createPackedRaster(DataBuffer dataBuffer,
-                    int w, int h,
-                    int bitsPerPixel,
-                    Point location)
+		     int w, int h,
+		     int bitsPerPixel,
+		     Point location)
   {
     SampleModel sm =
       new MultiPixelPackedSampleModel(dataBuffer.getDataType(),
-                                      w, h,
-                                      bitsPerPixel);
+				       w, h,
+				       bitsPerPixel);
     return createWritableRaster(sm, dataBuffer, location);
+  }
+    
+  public static Raster createRaster(SampleModel sm, DataBuffer db,
+				    Point location)
+  {
+    return new Raster(sm, db, location);

*** Patch too long, truncated ***




More information about the kaffe mailing list