You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by hi...@apache.org on 2006/10/31 15:25:57 UTC

svn commit: r469497 [1/2] - in /incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt: ./ datatransfer/ gl/ gl/color/ gl/font/ gl/image/ gl/opengl/ gl/render/ im/ internal/nls/ nativebridge/ text/ theme/ wtk/

Author: hindessm
Date: Tue Oct 31 06:25:53 2006
New Revision: 469497

URL: http://svn.apache.org/viewvc?view=rev&rev=469497
Log:
Applied patch #2 from "[#HARMONY-1313] [classlib][internationalization]
Internationalization of the awt module".

Modified:
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/AWTPermissionCollection.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ButtonStateController.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ByteVector.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ClipRegion.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ContextStorage.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ReadOnlyIterator.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/RelativeTimer.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ScrollbarStateController.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DTK.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DataProvider.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DataProxy.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DataSource.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DataTransferThread.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/TextFlavor.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/CommonGraphics2D.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/ICompositeContext.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/ImageSurface.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/MultiRectArea.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/Surface.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/color/NativeCMM.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/color/NativeImageFormat.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/CaretManager.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/CommonGlyphVector.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/CompositeFont.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/FontManager.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/FontMetricsImpl.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/FontPeerImpl.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/LineMetricsImpl.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/TextMetricsCalculator.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/TextRunBreaker.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/TextRunSegmentImpl.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/image/GifDecoder.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/image/JpegDecoder.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/image/OffscreenImage.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/image/PngDecoder.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/opengl/GL.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/render/JavaBlitter.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/render/JavaShapeRasterizer.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/im/IMJFrame.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/im/IMManager.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/im/IMWindow.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/internal/nls/messages.properties
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/nativebridge/ByteBase.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/nativebridge/Int16Pointer.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/nativebridge/PointerPointer.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/text/AWTHighlighter.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/text/ActionNames.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/text/ActionSet.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/text/InputMethodRequestsImpl.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/text/PropertyNames.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/text/TextFactory.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/text/TextUtils.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/theme/DefaultFileDialog.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/theme/DefaultMenu.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/wtk/NativeEventThread.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/wtk/NativeIM.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/wtk/ShutdownThread.java
    incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/wtk/Synchronizer.java

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/AWTPermissionCollection.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/AWTPermissionCollection.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/AWTPermissionCollection.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/AWTPermissionCollection.java Tue Oct 31 06:25:53 2006
@@ -27,35 +27,35 @@
 public interface AWTPermissionCollection {
 
     AWTPermission ACCESS_CLIPBOARD_PERMISSION = new AWTPermission(
-        "accessClipboard");
+        "accessClipboard"); //$NON-NLS-1$
 
     AWTPermission ACCESS_EVENT_QUEUE_PERMISSION = new AWTPermission(
-        "accessEventQueue");
+        "accessEventQueue"); //$NON-NLS-1$
 
-    AWTPermission CREATE_ROBOT_PERMISSION = new AWTPermission("createRobot");
+    AWTPermission CREATE_ROBOT_PERMISSION = new AWTPermission("createRobot"); //$NON-NLS-1$
 
     AWTPermission FULL_SCREEN_EXCLUSIVE_PERMISSION = new AWTPermission(
-        "fullScreenExclusive");
+        "fullScreenExclusive"); //$NON-NLS-1$
 
     AWTPermission LISTEN_TO_ALL_AWTEVENTS_PERMISSION = new AWTPermission(
-        "listenToAllAWTEvents");
+        "listenToAllAWTEvents"); //$NON-NLS-1$
 
     AWTPermission READ_DISPLAY_PIXELS_PERMISSION = new AWTPermission(
-        "readDisplayPixels");
+        "readDisplayPixels"); //$NON-NLS-1$
 
     AWTPermission REPLACE_KEYBOARD_FOCUS_MANAGER_PERMISSION = new AWTPermission(
-        "replaceKeyboardFocusManager");
+        "replaceKeyboardFocusManager"); //$NON-NLS-1$
 
     AWTPermission SET_APPLET_STUB_PERMISSION = new AWTPermission(
-        "setAppletStub");
+        "setAppletStub"); //$NON-NLS-1$
 
     AWTPermission SET_WINDOW_ALWAYS_ON_TOP_PERMISSION = new AWTPermission(
-        "setWindowAlwaysOnTop");
+        "setWindowAlwaysOnTop"); //$NON-NLS-1$
 
     AWTPermission SHOW_WINDOW_WITHOUT_WARNING_BANNER_PERMISSION = new AWTPermission(
-        "showWindowWithoutWarningBanner");
+        "showWindowWithoutWarningBanner"); //$NON-NLS-1$
 
     AWTPermission WATCH_MAOUSE_POINTER_PERMISSION = new AWTPermission(
-        "watchMousePointer");
+        "watchMousePointer"); //$NON-NLS-1$
 }
 

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ButtonStateController.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ButtonStateController.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ButtonStateController.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ButtonStateController.java Tue Oct 31 06:25:53 2006
@@ -28,6 +28,8 @@
 import java.awt.event.MouseEvent;
 import java.awt.event.MouseListener;
 
+import org.apache.harmony.awt.internal.nls.Messages;
+
 /**
  * ButtonStateController.
  * Changes Component state and fires [action] events in response to
@@ -96,7 +98,8 @@
     }
 
     public void keyPressed(KeyEvent ke) {
-        assert focused == true : "Key event for unfocused component";
+        // awt.54=Key event for unfocused component
+        assert focused == true : Messages.getString("awt.54"); //$NON-NLS-1$
 
         if (mousePressed || keyPressed || (ke.getKeyCode() != KeyEvent.VK_SPACE)) {
             return;
@@ -107,7 +110,8 @@
     }
 
     public void keyReleased(KeyEvent ke) {
-        assert focused == true : "Key event for unfocused component";
+        // awt.54=Key event for unfocused component
+        assert focused == true : Messages.getString("awt.54"); //$NON-NLS-1$
 
         if (!keyPressed || (ke.getKeyCode() != KeyEvent.VK_SPACE)) {
             return;
@@ -121,24 +125,28 @@
     }
 
     public void mouseEntered(MouseEvent me) {
-        assert mouseInside == false : "Double mouse enter event for component";
+        // awt.55=Double mouse enter event for component
+        assert mouseInside == false : Messages.getString("awt.55"); //$NON-NLS-1$
         mouseCrossed(true);
     }
 
     public void mouseExited(MouseEvent me) {
-        assert mouseInside == true : "Double mouse exit event for component";
+        // awt.56=Double mouse exit event for component
+        assert mouseInside == true : Messages.getString("awt.56"); //$NON-NLS-1$
         mouseCrossed(false);
     }
 
     public void focusGained(FocusEvent fe) {
-        assert focused == false : "Double focus gained event for component";
+        // awt.57=Double focus gained event for component
+        assert focused == false : Messages.getString("awt.57"); //$NON-NLS-1$
 
         focused = true;
         component.repaint();
     }
 
     public void focusLost(FocusEvent fe) {
-        assert focused == true : "Double focus lost event for component";
+        // awt.58=Double focus lost event for component
+        assert focused == true : Messages.getString("awt.58"); //$NON-NLS-1$
 
         focused = false;
         keyPressed = false;

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ByteVector.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ByteVector.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ByteVector.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ByteVector.java Tue Oct 31 06:25:53 2006
@@ -20,6 +20,8 @@
  */
 package org.apache.harmony.awt;
 
+import org.apache.harmony.awt.internal.nls.Messages;
+
 /**
  * Analog of StringBuffer but works with bytes.
  */
@@ -116,7 +118,8 @@
      */
     public byte get(int index) {
         if ((index < 0) || (index >= count)) {
-            throw new RuntimeException("Index out of range.");
+            // awt.33=index is out of range
+            throw new RuntimeException(Messages.getString("awt.33")); //$NON-NLS-1$
         }
 
         return value[index];

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ClipRegion.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ClipRegion.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ClipRegion.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ClipRegion.java Tue Oct 31 06:25:53 2006
@@ -24,6 +24,7 @@
 import java.awt.Rectangle;
 
 import org.apache.harmony.awt.gl.MultiRectArea;
+import org.apache.harmony.awt.internal.nls.Messages;
 
 public class ClipRegion extends Rectangle {
     private final MultiRectArea clip;
@@ -72,7 +73,8 @@
             y += c.getY();
         }
         if (c == null) {
-            throw new IllegalArgumentException("Component expected to be a parent");
+            // awt.51=Component expected to be a parent
+            throw new IllegalArgumentException(Messages.getString("awt.51")); //$NON-NLS-1$
         }
         region.translate(x, y);
     }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ContextStorage.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ContextStorage.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ContextStorage.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ContextStorage.java Tue Oct 31 06:25:53 2006
@@ -23,6 +23,7 @@
 import java.awt.*;
 
 import org.apache.harmony.awt.datatransfer.*;
+import org.apache.harmony.awt.internal.nls.Messages;
 import org.apache.harmony.awt.wtk.*;
 
 
@@ -122,7 +123,8 @@
             }
             group = group.getParent();
         }
-        throw new RuntimeException("Application has run out of context thread group");
+        // awt.59=Application has run out of context thread group
+        throw new RuntimeException(Messages.getString("awt.59")); //$NON-NLS-1$
     }
 
     public static boolean shutdownPending() {

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ReadOnlyIterator.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ReadOnlyIterator.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ReadOnlyIterator.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ReadOnlyIterator.java Tue Oct 31 06:25:53 2006
@@ -22,6 +22,8 @@
 
 import java.util.Iterator;
 
+import org.apache.harmony.awt.internal.nls.Messages;
+
 /**
  * ReadOnlyIterator
  */
@@ -37,7 +39,8 @@
     }
 
     public void remove() {
-        throw new UnsupportedOperationException("Iterator is read-only");
+        // awt.50=Iterator is read-only
+        throw new UnsupportedOperationException(Messages.getString("awt.50")); //$NON-NLS-1$
     }
 
     public boolean hasNext() {

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/RelativeTimer.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/RelativeTimer.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/RelativeTimer.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/RelativeTimer.java Tue Oct 31 06:25:53 2006
@@ -23,6 +23,8 @@
 import java.util.Iterator;
 import java.util.LinkedList;
 
+import org.apache.harmony.awt.internal.nls.Messages;
+
 /**
  * Relative timer class. Basic class for PeriodicTimer and SingleShotTimer.
  * "Relative" means that there is no binding with absolute time.
@@ -40,10 +42,12 @@
 
     RelativeTimer(long interval, Runnable handler) {
         if (interval <= 0) {
-            throw new IllegalArgumentException("Time interval can't be <= 0");
+            // awt.52=Time interval can't be <= 0
+            throw new IllegalArgumentException(Messages.getString("awt.52")); //$NON-NLS-1$
         }
         if (handler == null) {
-            throw new IllegalArgumentException("Handler can't be null");
+            // awt.53=Handler can't be null
+            throw new IllegalArgumentException(Messages.getString("awt.53")); //$NON-NLS-1$
         }
 
         this.interval = interval;
@@ -141,7 +145,7 @@
                 time = Long.MAX_VALUE;
                 insert(entry, false);
                 thread = new DeltaThread();
-                thread.setName("Relative Timer");
+                thread.setName("Relative Timer"); //$NON-NLS-1$
                 thread.setDaemon(true);
                 thread.start();
             } else {

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ScrollbarStateController.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ScrollbarStateController.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ScrollbarStateController.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/ScrollbarStateController.java Tue Oct 31 06:25:53 2006
@@ -36,6 +36,7 @@
 import java.awt.event.MouseListener;
 import java.awt.event.MouseMotionListener;
 
+import org.apache.harmony.awt.internal.nls.Messages;
 import org.apache.harmony.awt.state.ScrollbarState;
 
 
@@ -434,7 +435,8 @@
     }
 
     public void keyPressed(KeyEvent e) {
-        assert focused : "Key event for unfocused component";
+        // awt.54=Key event for unfocused component
+        assert focused : Messages.getString("awt.54"); //$NON-NLS-1$
         int keyCode = e.getKeyCode();
         switch (keyCode) {
         case KeyEvent.VK_UP:

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DTK.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DTK.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DTK.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DTK.java Tue Oct 31 06:25:53 2006
@@ -29,6 +29,7 @@
 import java.nio.charset.Charset;
 
 import org.apache.harmony.awt.ContextStorage;
+import org.apache.harmony.awt.internal.nls.Messages;
 import org.apache.harmony.misc.SystemUtils;
 
 /**
@@ -130,13 +131,14 @@
         String name;
         switch (SystemUtils.getOS()) {
         case SystemUtils.OS_WINDOWS:
-            name = "org.apache.harmony.awt.datatransfer.windows.WinDTK";
+            name = "org.apache.harmony.awt.datatransfer.windows.WinDTK"; //$NON-NLS-1$
             break;
         case SystemUtils.OS_LINUX:
-            name = "org.apache.harmony.awt.datatransfer.linux.LinuxDTK";
+            name = "org.apache.harmony.awt.datatransfer.linux.LinuxDTK"; //$NON-NLS-1$
             break;
         default:
-            throw new RuntimeException("Unknown native platform.");
+            // awt.4E=Unknown native platform.
+            throw new RuntimeException(Messages.getString("awt.4E")); //$NON-NLS-1$
         }
         try {
             DTK dtk = (DTK) Class.forName(name).newInstance();
@@ -147,12 +149,12 @@
     }
     
     public String getDefaultCharset() {
-        return "unicode";
+        return "unicode"; //$NON-NLS-1$
     }
 
     protected String[] getCharsets() {
         return new String[] { 
-                "UTF-16", "UTF-8", "unicode", "ISO-8859-1", "US-ASCII" };
+                "UTF-16", "UTF-8", "unicode", "ISO-8859-1", "US-ASCII" }; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
     }
 
     public void initSystemFlavorMap(SystemFlavorMap fm) {
@@ -162,18 +164,18 @@
                 DataFlavor.stringFlavor, 
                 DataProvider.FORMAT_TEXT);
         appendSystemFlavorMap(fm,
-                charsets, "plain",
+                charsets, "plain", //$NON-NLS-1$
                 DataProvider.FORMAT_TEXT);
 
         appendSystemFlavorMap(fm,
-                charsets, "html",
+                charsets, "html", //$NON-NLS-1$
                 DataProvider.FORMAT_HTML);
         
         appendSystemFlavorMap(fm,
                 DataProvider.urlFlavor, 
                 DataProvider.FORMAT_URL);
         appendSystemFlavorMap(fm,
-                charsets, "uri-list",
+                charsets, "uri-list", //$NON-NLS-1$
                 DataProvider.FORMAT_URL);
         
         appendSystemFlavorMap(fm,

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DataProvider.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DataProvider.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DataProvider.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DataProvider.java Tue Oct 31 06:25:53 2006
@@ -34,28 +34,28 @@
      * http://java.sun.com/j2se/1.5.0/docs/guide/dragndrop/spec/dnd1.html
      */
     
-    public static final String FORMAT_TEXT = "text/plain";
-    public static final String FORMAT_FILE_LIST = "application/x-java-file-list";
-    public static final String FORMAT_URL = "application/x-java-url";
-    public static final String FORMAT_HTML = "text/html";
-    public static final String FORMAT_IMAGE = "image/x-java-image";
+    public static final String FORMAT_TEXT = "text/plain"; //$NON-NLS-1$
+    public static final String FORMAT_FILE_LIST = "application/x-java-file-list"; //$NON-NLS-1$
+    public static final String FORMAT_URL = "application/x-java-url"; //$NON-NLS-1$
+    public static final String FORMAT_HTML = "text/html"; //$NON-NLS-1$
+    public static final String FORMAT_IMAGE = "image/x-java-image"; //$NON-NLS-1$
 
-    public static final String TYPE_IMAGE = "image/x-java-image";
+    public static final String TYPE_IMAGE = "image/x-java-image"; //$NON-NLS-1$
     public static final String TYPE_SERIALIZED = 
-                                    "application/x-java-serialized-object";
-    public static final String TYPE_PLAINTEXT = "text/plain";
-    public static final String TYPE_HTML = "text/html";
-    public static final String TYPE_URL = "application/x-java-url";
+                                    "application/x-java-serialized-object"; //$NON-NLS-1$
+    public static final String TYPE_PLAINTEXT = "text/plain"; //$NON-NLS-1$
+    public static final String TYPE_HTML = "text/html"; //$NON-NLS-1$
+    public static final String TYPE_URL = "application/x-java-url"; //$NON-NLS-1$
     public static final String TYPE_TEXTENCODING = 
-                                    "application/x-java-text-encoding";
-    public static final String TYPE_FILELIST = "application/x-java-file-list";
-    public static final String TYPE_URILIST = "text/uri-list";
+                                    "application/x-java-text-encoding"; //$NON-NLS-1$
+    public static final String TYPE_FILELIST = "application/x-java-file-list"; //$NON-NLS-1$
+    public static final String TYPE_URILIST = "text/uri-list"; //$NON-NLS-1$
 
     public static final DataFlavor urlFlavor = 
-        new DataFlavor("application/x-java-url;class=java.net.URL", "URL");
+        new DataFlavor("application/x-java-url;class=java.net.URL", "URL"); //$NON-NLS-1$ //$NON-NLS-2$
     
     public static final DataFlavor uriFlavor = 
-        new DataFlavor("text/uri-list", "URI");
+        new DataFlavor("text/uri-list", "URI"); //$NON-NLS-1$ //$NON-NLS-2$
 
     
     public String[] getNativeFormats();

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DataProxy.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DataProxy.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DataProxy.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DataProxy.java Tue Oct 31 06:25:53 2006
@@ -51,6 +51,8 @@
 import java.util.Iterator;
 import java.util.List;
 
+import org.apache.harmony.awt.internal.nls.Messages;
+
 /**
  * Wrapper for native data
  */
@@ -76,7 +78,7 @@
     public Object getTransferData(DataFlavor flavor)
             throws UnsupportedFlavorException, IOException {
         
-        String mimeType = flavor.getPrimaryType() + "/" + flavor.getSubType();
+        String mimeType = flavor.getPrimaryType() + "/" + flavor.getSubType(); //$NON-NLS-1$
         if (flavor.isFlavorTextType()) {
             if (mimeType.equalsIgnoreCase(DataProvider.TYPE_HTML)) {
                 return getHTML(flavor);
@@ -136,7 +138,8 @@
         }
         String str = data.getText();
         if (str == null) {
-            throw new IOException("Data is not available");
+            // awt.4F=Data is not available
+            throw new IOException(Messages.getString("awt.4F")); //$NON-NLS-1$
         }
         return getTextRepresentation(str, f);
     }
@@ -148,7 +151,8 @@
         }
         String[] files = data.getFileList();
         if (files == null) {
-            throw new IOException("Data is not available");
+            // awt.4F=Data is not available
+            throw new IOException(Messages.getString("awt.4F")); //$NON-NLS-1$
         }
         return Arrays.asList(files);
     }
@@ -160,7 +164,8 @@
         }
         String str = data.getHTML();
         if (str == null) {
-            throw new IOException("Data is not available");
+            // awt.4F=Data is not available
+            throw new IOException(Messages.getString("awt.4F")); //$NON-NLS-1$
         }
         return getTextRepresentation(str, f);
     }
@@ -172,7 +177,8 @@
         }
         String str = data.getURL();
         if (str == null) {
-            throw new IOException("Data is not available");
+            // awt.4F=Data is not available
+            throw new IOException(Messages.getString("awt.4F")); //$NON-NLS-1$
         }
         URL url = new URL(str);
         if (f.getRepresentationClass().isAssignableFrom(URL.class)) {
@@ -193,7 +199,8 @@
         }
         byte bytes[] = data.getSerializedObject(f.getRepresentationClass());
         if (bytes == null) {
-            throw new IOException("Data is not available");
+            // awt.4F=Data is not available
+            throw new IOException(Messages.getString("awt.4F")); //$NON-NLS-1$
         }
         ByteArrayInputStream str = new ByteArrayInputStream(bytes);
         try {
@@ -204,7 +211,7 @@
     }
     
     private String getCharset(DataFlavor f) {
-        return f.getParameter("charset");
+        return f.getParameter("charset"); //$NON-NLS-1$
     }
 
     private Object getTextRepresentation(String text, DataFlavor f)
@@ -246,7 +253,8 @@
         }
         RawBitmap bitmap = data.getRawBitmap();
         if (bitmap == null) {
-            throw new IOException("Data is not available");
+            // awt.4F=Data is not available
+            throw new IOException(Messages.getString("awt.4F")); //$NON-NLS-1$
         }
         return createBufferedImage(bitmap);
     }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DataSource.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DataSource.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DataSource.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DataSource.java Tue Oct 31 06:25:53 2006
@@ -54,7 +54,7 @@
     }
 
     private boolean isHtmlFlavor(DataFlavor f) {
-        return "html".equalsIgnoreCase(f.getSubType());
+        return "html".equalsIgnoreCase(f.getSubType()); //$NON-NLS-1$
     }
     
     protected DataFlavor[] getDataFlavors() {

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DataTransferThread.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DataTransferThread.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DataTransferThread.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/DataTransferThread.java Tue Oct 31 06:25:53 2006
@@ -28,7 +28,7 @@
     private final DTK dtk;
 
     public DataTransferThread(DTK dtk) {
-        super("AWT-DataTransferThread");
+        super("AWT-DataTransferThread"); //$NON-NLS-1$
         setDaemon(true);
         this.dtk = dtk;
     }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/TextFlavor.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/TextFlavor.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/TextFlavor.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/datatransfer/TextFlavor.java Tue Oct 31 06:25:53 2006
@@ -42,9 +42,9 @@
                                          String nat,
                                          String subType) {
         for (int i = 0; i < unicodeTextClasses.length; i++) {
-            String type = "text/" + subType;
-            String params = ";class=\"" + 
-                    unicodeTextClasses[i].getName() + "\"";
+            String type = "text/" + subType; //$NON-NLS-1$
+            String params = ";class=\"" +  //$NON-NLS-1$
+                    unicodeTextClasses[i].getName() + "\""; //$NON-NLS-1$
             DataFlavor f = new DataFlavor(type + params, type);
             fm.addFlavorForUnencodedNative(nat, f);
             fm.addUnencodedNativeForFlavor(f, nat);
@@ -56,10 +56,10 @@
                                          String subType, 
                                          String charset) {
         for (int i = 0; i < charsetTextClasses.length; i++) {
-            String type = "text/" + subType;
-            String params = ";class=\"" + 
-                    charsetTextClasses[i].getName() + "\"" + 
-                    ";charset=\"" + charset + "\"";
+            String type = "text/" + subType; //$NON-NLS-1$
+            String params = ";class=\"" +  //$NON-NLS-1$
+                    charsetTextClasses[i].getName() + "\"" +  //$NON-NLS-1$
+                    ";charset=\"" + charset + "\""; //$NON-NLS-1$ //$NON-NLS-2$
             DataFlavor f = new DataFlavor(type + params, type);
             fm.addFlavorForUnencodedNative(nat, f);
             fm.addUnencodedNativeForFlavor(f, nat);

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/CommonGraphics2D.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/CommonGraphics2D.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/CommonGraphics2D.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/CommonGraphics2D.java Tue Oct 31 06:25:53 2006
@@ -143,7 +143,7 @@
 
     protected JavaShapeRasterizer jsr = new JavaShapeRasterizer();
 
-    protected Font font = new Font("Dialog", Font.PLAIN, 12);;
+    protected Font font = new Font("Dialog", Font.PLAIN, 12);; //$NON-NLS-1$
 
     protected TextRenderer jtr = JavaTextRenderer.inst;
 
@@ -157,7 +157,7 @@
 
 
     // Print debug output or not
-    protected static final boolean debugOutput = "1".equals(System.getProperty("g2d.debug"));
+    protected static final boolean debugOutput = "1".equals(System.getProperty("g2d.debug")); //$NON-NLS-1$ //$NON-NLS-2$
 
     // Constructors
     protected CommonGraphics2D() {
@@ -189,7 +189,7 @@
         setColor(c);
         setPaint(p);
         if (debugOutput) {
-            System.err.println("CommonGraphics2D.clearRect("+x+", "+y+", "+width+", "+height+")");
+            System.err.println("CommonGraphics2D.clearRect("+x+", "+y+", "+width+", "+height+")"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
         }
     }
 
@@ -520,7 +520,7 @@
     @Override
     public void drawLine(int x1, int y1, int x2, int y2) {
         if (debugOutput) {
-            System.err.println("CommonGraphics2D.drawLine("+x1+", "+y1+", "+x2+", "+y2+")");
+            System.err.println("CommonGraphics2D.drawLine("+x1+", "+y1+", "+x2+", "+y2+")"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
         }
 
         if (stroke instanceof BasicStroke && ((BasicStroke)stroke).getLineWidth() <= 1) {
@@ -608,7 +608,7 @@
     @Override
     public void drawRoundRect(int x, int y, int width, int height, int arcWidth, int arcHeight) {
         if (debugOutput) {
-            System.err.println("CommonGraphics2D.drawRoundRect("+x+", "+y+", "+width+", "+height+","+arcWidth+", "+arcHeight+")");
+            System.err.println("CommonGraphics2D.drawRoundRect("+x+", "+y+", "+width+", "+height+","+arcWidth+", "+arcHeight+")"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$ //$NON-NLS-6$ //$NON-NLS-7$
         }
 
         draw(new RoundRectangle2D.Float(x, y, width, height, arcWidth, arcHeight));
@@ -643,7 +643,7 @@
     @Override
     public void drawString(String str, float x, float y) {
         if (debugOutput) {
-            System.err.println("CommonGraphics2D.drawString("+str+", "+x+", "+y+")");
+            System.err.println("CommonGraphics2D.drawString("+str+", "+x+", "+y+")"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$
         }
 
         AffineTransform at = (AffineTransform)this.getTransform().clone();
@@ -747,7 +747,7 @@
     @Override
     public void fillRect(int x, int y, int width, int height) {
         if (debugOutput) {
-            System.err.println("CommonGraphics2D.fillRect("+x+", "+y+", "+width+", "+height+")");
+            System.err.println("CommonGraphics2D.fillRect("+x+", "+y+", "+width+", "+height+")"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
         }
 
         fill(new Rectangle(x, y, width, height));
@@ -756,7 +756,7 @@
     @Override
     public void fillRoundRect(int x, int y, int width, int height, int arcWidth, int arcHeight) {
         if (debugOutput) {
-            System.err.println("CommonGraphics2D.fillRoundRect("+x+", "+y+", "+width+", "+height+","+arcWidth+", "+arcHeight+")");
+            System.err.println("CommonGraphics2D.fillRoundRect("+x+", "+y+", "+width+", "+height+","+arcWidth+", "+arcHeight+")"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$ //$NON-NLS-6$ //$NON-NLS-7$
         }
 
         fill(new RoundRectangle2D.Float(x, y, width, height, arcWidth, arcHeight));
@@ -897,7 +897,7 @@
     @Override
     public void translate(double tx, double ty) {
         if (debugOutput) {
-            System.err.println("CommonGraphics2D.translate("+tx+", "+ty+")");
+            System.err.println("CommonGraphics2D.translate("+tx+", "+ty+")"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
         }
 
         transform.translate(tx, ty);
@@ -907,7 +907,7 @@
     @Override
     public void translate(int tx, int ty) {
         if (debugOutput) {
-            System.err.println("CommonGraphics2D.translate("+tx+", "+ty+")");
+            System.err.println("CommonGraphics2D.translate("+tx+", "+ty+")"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
         }
 
         transform.translate(tx, ty);
@@ -938,13 +938,13 @@
         if (s == null) {
             setTransformedClip(null);
             if (debugOutput) {
-                System.err.println("CommonGraphics2D.setClip(null)");
+                System.err.println("CommonGraphics2D.setClip(null)"); //$NON-NLS-1$
             }
             return;
         }
 
         if (debugOutput) {
-            System.err.println("CommonGraphics2D.setClip("+s.getBounds()+")");
+            System.err.println("CommonGraphics2D.setClip("+s.getBounds()+")"); //$NON-NLS-1$ //$NON-NLS-2$
         }
 
         if (s instanceof MultiRectArea) {
@@ -1037,7 +1037,7 @@
         }
 
         if (debugOutput) {
-            System.err.println("CommonGraphics2D.fillMultiRectArea("+mra+")");
+            System.err.println("CommonGraphics2D.fillMultiRectArea("+mra+")"); //$NON-NLS-1$ //$NON-NLS-2$
         }
 
         if (paint instanceof Color){

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/ICompositeContext.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/ICompositeContext.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/ICompositeContext.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/ICompositeContext.java Tue Oct 31 06:25:53 2006
@@ -28,6 +28,7 @@
 
 import org.apache.harmony.awt.gl.ImageSurface;
 import org.apache.harmony.awt.gl.render.NativeImageBlitter;
+import org.apache.harmony.awt.internal.nls.Messages;
 
 
 /**
@@ -52,19 +53,19 @@
     public void compose(Raster srcIn, Raster dstIn, WritableRaster dstOut) {
 
         if(!srcCM.isCompatibleRaster(srcIn)) {
-            throw new IllegalArgumentException("The srcIn raster is " +
-                    "incompatible with src ColorModel");
+            // awt.48=The srcIn raster is incompatible with src ColorModel
+            throw new IllegalArgumentException(Messages.getString("awt.48")); //$NON-NLS-1$
         }
 
         if(!dstCM.isCompatibleRaster(dstIn)) {
-            throw new IllegalArgumentException("The dstIn raster is " +
-                    "incompatible with dst ColorModel");
+            // awt.49=The dstIn raster is incompatible with dst ColorModel
+            throw new IllegalArgumentException(Messages.getString("awt.49")); //$NON-NLS-1$
         }
 
         if(dstIn != dstOut){
             if(!dstCM.isCompatibleRaster(dstOut)) {
-                throw new IllegalArgumentException("The dstOut raster is " +
-                        "incompatible with dst ColorModel");
+                // awt.4A=The dstOut raster is incompatible with dst ColorModel
+                throw new IllegalArgumentException(Messages.getString("awt.4A")); //$NON-NLS-1$
             }
             dstOut.setDataElements(0, 0, dstIn);
         }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/ImageSurface.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/ImageSurface.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/ImageSurface.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/ImageSurface.java Tue Oct 31 06:25:53 2006
@@ -38,6 +38,7 @@
 
 import org.apache.harmony.awt.gl.color.LUTColorConverter;
 import org.apache.harmony.awt.gl.image.DataBufferListener;
+import org.apache.harmony.awt.internal.nls.Messages;
 
 
 /**
@@ -65,8 +66,8 @@
 
     public ImageSurface(ColorModel cm, WritableRaster raster, int type){
         if (!cm.isCompatibleRaster(raster)) {
-            throw new IllegalArgumentException("The raster is" +
-                    " incompatible with this ColorModel");
+            // awt.4D=The raster is incompatible with this ColorModel
+            throw new IllegalArgumentException(Messages.getString("awt.4D")); //$NON-NLS-1$
         }
         this.cm = cm;
         this.raster = raster;
@@ -183,8 +184,8 @@
                     (ComponentSampleModel) sm;
                 scanlineStride = csm.getScanlineStride();
             }else{
-                throw new IllegalArgumentException("The raster is" +
-                " incompatible with this ColorModel");
+                // awt.4D=The raster is incompatible with this ColorModel
+                throw new IllegalArgumentException(Messages.getString("awt.4D")); //$NON-NLS-1$
             }
 
         }else if(cm instanceof ComponentColorModel){
@@ -202,8 +203,8 @@
                     smType = CSM;
                 }
             }else{
-                throw new IllegalArgumentException("The raster is" +
-                " incompatible with this ColorModel");
+                // awt.4D=The raster is incompatible with this ColorModel
+                throw new IllegalArgumentException(Messages.getString("awt.4D")); //$NON-NLS-1$
             }
 
         }else{

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/MultiRectArea.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/MultiRectArea.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/MultiRectArea.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/MultiRectArea.java Tue Oct 31 06:25:53 2006
@@ -29,6 +29,8 @@
 import java.util.ArrayList;
 import java.util.NoSuchElementException;
 
+import org.apache.harmony.awt.internal.nls.Messages;
+
 public class MultiRectArea implements Shape {
 
     /**
@@ -270,7 +272,8 @@
 
         public int currentSegment(double[] coords) {
             if (isDone()) {
-                throw new NoSuchElementException("Iiterator out of bounds");
+                // awt.4B=Iiterator out of bounds
+                throw new NoSuchElementException(Messages.getString("awt.4B")); //$NON-NLS-1$
             }
             int type = 0;
 
@@ -308,7 +311,8 @@
 
         public int currentSegment(float[] coords) {
             if (isDone()) {
-                throw new NoSuchElementException("Iiterator out of bounds");
+                // awt.4B=Iiterator out of bounds
+                throw new NoSuchElementException(Messages.getString("awt.4B")); //$NON-NLS-1$
             }
             int type = 0;
 
@@ -367,7 +371,7 @@
         } else {
             rect = new int[mra.rect.length];
             System.arraycopy(mra.rect, 0, rect, 0, mra.rect.length);
-            check(this, "MultiRectArea(MRA)");
+            check(this, "MultiRectArea(MRA)"); //$NON-NLS-1$
         }
     }
 
@@ -383,7 +387,7 @@
             rect[3] = r.x + r.width - 1;
             rect[4] = r.y + r.height - 1;
         }
-        check(this, "MultiRectArea(Rectangle)");
+        check(this, "MultiRectArea(Rectangle)"); //$NON-NLS-1$
     }
 
     /**
@@ -398,7 +402,7 @@
             rect[3] = x1;
             rect[4] = y1;
         }
-        check(this, "MultiRectArea(Rectangle)");
+        check(this, "MultiRectArea(Rectangle)"); //$NON-NLS-1$
     }
 
     /**
@@ -474,7 +478,8 @@
     static MultiRectArea check(MultiRectArea mra, String msg) {
         if (CHECK && mra != null) {
             if (MultiRectArea.checkValidation(mra.getRectangles(), mra.sorted) != -1) {
-                new RuntimeException("Invalid MultiRectArea in method " + msg);
+                // awt.4C=Invalid MultiRectArea in method {0}
+                new RuntimeException(Messages.getString("awt.4C", msg)); //$NON-NLS-1$
             }
         }
         return mra;
@@ -582,7 +587,7 @@
      * Union two MutliRectareArea objects
      */
     public static MultiRectArea intersect(MultiRectArea src1, MultiRectArea src2) {
-        MultiRectArea res = check(MultiRectAreaOp.Intersection.getResult(src1, src2), "intersect(MRA,MRA)");
+        MultiRectArea res = check(MultiRectAreaOp.Intersection.getResult(src1, src2), "intersect(MRA,MRA)"); //$NON-NLS-1$
         return res;
     }
 
@@ -590,7 +595,7 @@
      * Intersect two MultiRectArea objects
      */
     public static MultiRectArea union(MultiRectArea src1, MultiRectArea src2) {
-        MultiRectArea res = check(new MultiRectAreaOp.Union().getResult(src1, src2), "union(MRA,MRA)");
+        MultiRectArea res = check(new MultiRectAreaOp.Union().getResult(src1, src2), "union(MRA,MRA)"); //$NON-NLS-1$
         return res;
     }
 
@@ -598,7 +603,7 @@
      * Subtract two MultiRectArea objects
      */
     public static MultiRectArea subtract(MultiRectArea src1, MultiRectArea src2) {
-        MultiRectArea res = check(MultiRectAreaOp.Subtraction.getResult(src1, src2), "subtract(MRA,MRA)");
+        MultiRectArea res = check(MultiRectAreaOp.Subtraction.getResult(src1, src2), "subtract(MRA,MRA)"); //$NON-NLS-1$
         return res;
     }
 
@@ -607,15 +612,15 @@
      */
     public static void print(MultiRectArea mra, String msg) {
         if (mra == null) {
-            System.out.println(msg + "=null");
+            System.out.println(msg + "=null"); //$NON-NLS-1$
         } else {
             Rectangle[] rects = mra.getRectangles();
-            System.out.println(msg + "(" + rects.length + ")");
+            System.out.println(msg + "(" + rects.length + ")"); //$NON-NLS-1$ //$NON-NLS-2$
             for (Rectangle element : rects) {
                 System.out.println(
-                        element.x + "," +
-                        element.y + "," +
-                        (element.x + element.width - 1) + "," +
+                        element.x + "," + //$NON-NLS-1$
+                        element.y + "," + //$NON-NLS-1$
+                        (element.x + element.width - 1) + "," + //$NON-NLS-1$
                         (element.y + element.height - 1));
             }
         }
@@ -763,14 +768,14 @@
      * Tests does rectangle lie inside MultiRectArea object
      */
     public boolean contains(double x, double y, double w, double h) {
-        throw new RuntimeException("Not implemented");
+        throw new RuntimeException("Not implemented"); //$NON-NLS-1$
     }
 
     /**
      * Tests does Rectangle2D lie inside MultiRectArea object
      */
     public boolean contains(Rectangle2D r) {
-        throw new RuntimeException("Not implemented");
+        throw new RuntimeException("Not implemented"); //$NON-NLS-1$
     }
 
     /**
@@ -818,13 +823,13 @@
     public String toString() {
         int cnt = getRectCount();
         StringBuffer sb = new StringBuffer((cnt << 5) + 128);
-        sb.append(getClass().getName()).append(" [");
+        sb.append(getClass().getName()).append(" ["); //$NON-NLS-1$
         for(int i = 1; i < rect[0]; i += 4) {
-            sb.append(i > 1 ? ", [" : "[").append(rect[i]).append(", ").append(rect[i + 1]).
-            append(", ").append(rect[i + 2] - rect[i] + 1).append(", ").
-            append(rect[i + 3] - rect[i + 1] + 1).append("]");
+            sb.append(i > 1 ? ", [" : "[").append(rect[i]).append(", ").append(rect[i + 1]). //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+            append(", ").append(rect[i + 2] - rect[i] + 1).append(", "). //$NON-NLS-1$ //$NON-NLS-2$
+            append(rect[i + 3] - rect[i + 1] + 1).append("]"); //$NON-NLS-1$
         }
-        return sb.append("]").toString();
+        return sb.append("]").toString(); //$NON-NLS-1$
     }
 
 }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/Surface.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/Surface.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/Surface.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/Surface.java Tue Oct 31 06:25:53 2006
@@ -81,7 +81,7 @@
     private static final int BLUE_555_MASK = 0x001f;
 
     static{
-        System.loadLibrary("gl");
+        System.loadLibrary("gl"); //$NON-NLS-1$
         initIDs();
     }
 

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/color/NativeCMM.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/color/NativeCMM.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/color/NativeCMM.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/color/NativeCMM.java Tue Oct 31 06:25:53 2006
@@ -77,7 +77,7 @@
             AccessController.doPrivileged(
                   new PrivilegedAction<Void>() {
                     public Void run() {
-                        System.loadLibrary("lcmm");
+                        System.loadLibrary("lcmm"); //$NON-NLS-1$
                         return null;
                     }
             } );

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/color/NativeImageFormat.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/color/NativeImageFormat.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/color/NativeImageFormat.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/color/NativeImageFormat.java Tue Oct 31 06:25:53 2006
@@ -30,6 +30,7 @@
 import java.util.ArrayList;
 
 import org.apache.harmony.awt.gl.AwtImageBackdoorAccessor;
+import org.apache.harmony.awt.internal.nls.Messages;
 
 
 /**
@@ -204,8 +205,8 @@
             cmmFormat |= bytesSh(1);
         }
         else
-            throw new IllegalArgumentException(
-                    "First argument should be byte or short array");
+            // awt.47=First argument should be byte or short array
+            throw new IllegalArgumentException(Messages.getString("awt.47")); //$NON-NLS-1$
 
         cmmFormat |= channelsSh(nChannels);
 

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/CaretManager.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/CaretManager.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/CaretManager.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/CaretManager.java Tue Oct 31 06:25:53 2006
@@ -30,6 +30,8 @@
 import java.awt.geom.Line2D;
 import java.awt.*;
 
+import org.apache.harmony.awt.internal.nls.Messages;
+
 /**
  * This class provides functionality for creating caret and highlight shapes
  * (bidirectional text is also supported, but, unfortunately, not tested yet).
@@ -50,7 +52,8 @@
         int idx = info.getInsertionIndex();
 
         if (idx < 0 || idx > breaker.getCharCount()) {
-            throw new IllegalArgumentException("TextHitInfo out of range");
+            // awt.42=TextHitInfo out of range
+            throw new IllegalArgumentException(Messages.getString("awt.42")); //$NON-NLS-1$
         }
     }
 

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/CommonGlyphVector.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/CommonGlyphVector.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/CommonGlyphVector.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/CommonGlyphVector.java Tue Oct 31 06:25:53 2006
@@ -32,6 +32,8 @@
 import java.awt.geom.Point2D;
 import java.awt.geom.Rectangle2D;
 
+import org.apache.harmony.awt.internal.nls.Messages;
+
 /**
  * GlyphVector implementation
  */
@@ -313,8 +315,8 @@
     @Override
     public void setGlyphPosition(int glyphIndex, Point2D newPos) {
         if ((glyphIndex > vector.length) || (glyphIndex < 0)) {
-            throw new IndexOutOfBoundsException(
-                    "glyphIndex is out of vector's limits");
+            // awt.43=glyphIndex is out of vector's limits
+            throw new IndexOutOfBoundsException(Messages.getString("awt.43")); //$NON-NLS-1$
         }
         float x = (float)newPos.getX();
         float y = (float)newPos.getY();
@@ -336,8 +338,8 @@
     @Override
     public Point2D getGlyphPosition(int glyphIndex) {
         if ((glyphIndex > vector.length) || (glyphIndex < 0)) {
-            throw new IndexOutOfBoundsException(
-                    "glyphIndex is out of vector's limits");
+            // awt.43=glyphIndex is out of vector's limits
+            throw new IndexOutOfBoundsException(Messages.getString("awt.43")); //$NON-NLS-1$
         }
         int index = glyphIndex << 1;
         Point2D pos = new Point2D.Float(visualPositions[index], visualPositions[index+1]);
@@ -366,8 +368,8 @@
     @Override
     public void setGlyphTransform(int glyphIndex, AffineTransform trans) {
         if ((glyphIndex >= vector.length) || (glyphIndex < 0)) {
-            throw new IndexOutOfBoundsException(
-                    "glyphIndex is out of vector's limits");
+            // awt.43=glyphIndex is out of vector's limits
+            throw new IndexOutOfBoundsException(Messages.getString("awt.43")); //$NON-NLS-1$
         }
 
         if ((trans == null) || (trans.isIdentity())) {
@@ -387,8 +389,8 @@
     @Override
     public AffineTransform getGlyphTransform(int glyphIndex) {
         if ((glyphIndex >= this.vector.length) || (glyphIndex < 0)) {
-            throw new IndexOutOfBoundsException(
-                    "glyphIndex is out of vector's limits");
+            // awt.43=glyphIndex is out of vector's limits
+            throw new IndexOutOfBoundsException(Messages.getString("awt.43")); //$NON-NLS-1$
         }
         return this.glsTransforms[glyphIndex];
     }
@@ -402,8 +404,8 @@
     public GlyphMetrics getGlyphMetrics(int glyphIndex) {
 
         if ((glyphIndex < 0) || ((glyphIndex) >= this.getNumGlyphs())) {
-            throw new IndexOutOfBoundsException(
-                    "glyphIndex is out of vector's range");
+            // awt.43=glyphIndex is out of vector's limits
+            throw new IndexOutOfBoundsException(Messages.getString("awt.43")); //$NON-NLS-1$
         }
         // TODO: is there a sence in GlyphMetrics
         // if certain glyph or Font has a transform??
@@ -422,7 +424,7 @@
     public GlyphJustificationInfo getGlyphJustificationInfo(int glyphIndex) {
         // TODO : Find out the source of Justification info
         if (true) {
-            throw new RuntimeException("Method is not implemented");
+            throw new RuntimeException("Method is not implemented"); //$NON-NLS-1$
         }
         return null;
     }
@@ -443,8 +445,8 @@
     @Override
     public Shape getGlyphVisualBounds(int glyphIndex) {
         if ((glyphIndex < 0) || (glyphIndex >= this.getNumGlyphs())) {
-            throw new IndexOutOfBoundsException(
-                    "glyphIndex is out of vector's range");
+            // awt.43=glyphIndex is out of vector's limits
+            throw new IndexOutOfBoundsException(Messages.getString("awt.43")); //$NON-NLS-1$
         }
 
         int idx  = glyphIndex << 1;
@@ -486,8 +488,8 @@
             float x, float y) {
         // TODO : need to be implemented with FontRenderContext
         if ((glyphIndex < 0) || (glyphIndex >= this.getNumGlyphs())) {
-            throw new IndexOutOfBoundsException(
-                    "glyphIndex is out of vector's range");
+            // awt.43=glyphIndex is out of vector's limits
+            throw new IndexOutOfBoundsException(Messages.getString("awt.43")); //$NON-NLS-1$
         }
 
         int idx  = glyphIndex << 1;
@@ -522,8 +524,8 @@
     @Override
     public Shape getGlyphOutline(int glyphIndex) {
         if ((glyphIndex < 0) || (glyphIndex >= this.getNumGlyphs())) {
-            throw new IndexOutOfBoundsException(
-                    "glyphIndex is out of vector's range");
+            // awt.43=glyphIndex is out of vector's limits
+            throw new IndexOutOfBoundsException(Messages.getString("awt.43")); //$NON-NLS-1$
         }
 
         if (gvShapes[glyphIndex] == null) {
@@ -595,13 +597,13 @@
             int[] codeReturn) {
 
         if ((beginGlyphIndex < 0) || ((numEntries + beginGlyphIndex) > this.getNumGlyphs())) {
-            throw new IndexOutOfBoundsException(
-                    "beginGlyphIndex is out of vector's range");
+            // awt.44=beginGlyphIndex is out of vector's range
+            throw new IndexOutOfBoundsException(Messages.getString("awt.44")); //$NON-NLS-1$
         }
 
         if (numEntries < 0) {
-            throw new IllegalArgumentException(
-                    "numEntries is out of vector's range");
+            // awt.45=numEntries is out of vector's range
+            throw new IllegalArgumentException(Messages.getString("awt.45")); //$NON-NLS-1$
         }
 
         if (codeReturn == null) {
@@ -627,14 +629,14 @@
     public int[] getGlyphCharIndices(int beginGlyphIndex, int numEntries,
             int[] codeReturn) {
         if ((beginGlyphIndex < 0) || (beginGlyphIndex >= this.getNumGlyphs())) {
-            throw new IllegalArgumentException(
-                    "beginGlyphIndex is out of vector range");
+            // awt.44=beginGlyphIndex is out of vector's range
+            throw new IllegalArgumentException(Messages.getString("awt.44")); //$NON-NLS-1$
         }
 
         if ((numEntries < 0)
                 || ((numEntries + beginGlyphIndex) > this.getNumGlyphs())) {
-            throw new IllegalArgumentException(
-                    "numEntries is out of vector range");
+            // awt.45=numEntries is out of vector's range
+            throw new IllegalArgumentException(Messages.getString("awt.45")); //$NON-NLS-1$
         }
 
         if (codeReturn == null) {
@@ -665,13 +667,13 @@
         numEntries *= 2;
 
         if ((beginGlyphIndex < 0) || ((numEntries + beginGlyphIndex) > len)) {
-            throw new IndexOutOfBoundsException(
-                    "beginGlyphIndex is out of vector's range");
+            // awt.44=beginGlyphIndex is out of vector's range
+            throw new IndexOutOfBoundsException(Messages.getString("awt.44")); //$NON-NLS-1$
         }
 
         if (numEntries < 0) {
-            throw new IllegalArgumentException(
-                    "numEntries is out of vector's range");
+            // awt.45=numEntries is out of vector's range
+            throw new IllegalArgumentException(Messages.getString("awt.45")); //$NON-NLS-1$
         }
 
         if (positionReturn == null) {
@@ -699,13 +701,13 @@
         numEntries *= 2;
 
         if ((beginGlyphIndex < 0) || ((numEntries + beginGlyphIndex) > len)) {
-            throw new IndexOutOfBoundsException(
-                    "beginGlyphIndex is out of vector's range");
+            // awt.44=beginGlyphIndex is out of vector's range
+            throw new IndexOutOfBoundsException(Messages.getString("awt.44")); //$NON-NLS-1$
         }
 
         if (numEntries < 0) {
-            throw new IllegalArgumentException(
-                    "numEntries is out of vector's range");
+            // awt.45=numEntries is out of vector's range
+            throw new IllegalArgumentException(Messages.getString("awt.45")); //$NON-NLS-1$
         }
 
         System.arraycopy(setPositions, 0, visualPositions, beginGlyphIndex, numEntries);
@@ -722,8 +724,8 @@
 
         int len = (this.getNumGlyphs()+1) << 1;
         if (len != setPositions.length){
-            throw new IllegalArgumentException(
-                    "length of setPositions array differs from the length of positions array");
+            // awt.46=length of setPositions array differs from the length of positions array
+            throw new IllegalArgumentException(Messages.getString("awt.46")); //$NON-NLS-1$
         }
 
         System.arraycopy(setPositions, 0, visualPositions, 0, len);
@@ -740,8 +742,8 @@
     @Override
     public int getGlyphCode(int glyphIndex) {
         if (glyphIndex >= this.vector.length || glyphIndex < 0) {
-            throw new IndexOutOfBoundsException(
-                    "glyphIndex is out of vector's range");
+            // awt.43=glyphIndex is out of vector's limits
+            throw new IndexOutOfBoundsException(Messages.getString("awt.43")); //$NON-NLS-1$
         }
         return this.vector[glyphIndex].getGlyphCode();
     }
@@ -755,8 +757,8 @@
     public int getGlyphCharIndex(int glyphIndex) {
 
         if ((glyphIndex < 0) || (glyphIndex >= this.getNumGlyphs())) {
-            throw new IllegalArgumentException(
-                    "glyphIndex is out of vector's range");
+            // awt.43=glyphIndex is out of vector's limits
+            throw new IllegalArgumentException(Messages.getString("awt.43")); //$NON-NLS-1$
         }
 
         if ((this.layoutFlags & Font.LAYOUT_RIGHT_TO_LEFT) != 0) {
@@ -774,8 +776,8 @@
     public char getGlyphChar(int glyphIndex) {
 
         if ((glyphIndex < 0) || (glyphIndex >= this.getNumGlyphs())) {
-            throw new IllegalArgumentException(
-                    "glyphIndex is out of vector's range");
+            // awt.43=glyphIndex is out of vector's limits
+            throw new IllegalArgumentException(Messages.getString("awt.43")); //$NON-NLS-1$
         }
         return this.charVector[glyphIndex];
     }
@@ -906,7 +908,8 @@
     @Override
     public Shape getGlyphLogicalBounds(int glyphIndex){
         if ((glyphIndex < 0) || (glyphIndex >= this.getNumGlyphs())){
-            throw new IndexOutOfBoundsException("glyphIndex is out of vector's range");
+            // awt.43=glyphIndex is out of vector's limits
+            throw new IndexOutOfBoundsException(Messages.getString("awt.43")); //$NON-NLS-1$
         }
         Glyph glyph = this.vector[glyphIndex];
 

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/CompositeFont.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/CompositeFont.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/CompositeFont.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/CompositeFont.java Tue Oct 31 06:25:53 2006
@@ -84,7 +84,7 @@
         this.fontProperties = fProperties;// !! Supposed that fProperties parameter != null
         fPhysicalFonts = physFonts;
         numFonts = fPhysicalFonts.length; 
-        setDefaultLineMetrics("", null);
+        setDefaultLineMetrics("", null); //$NON-NLS-1$
         this.uniformLM = false;
     }
 
@@ -180,7 +180,7 @@
     @Override
     public LineMetrics getLineMetrics(){
         if (nlm == null){
-            setDefaultLineMetrics("", null);
+            setDefaultLineMetrics("", null); //$NON-NLS-1$
         }
 
         return this.nlm;
@@ -451,9 +451,9 @@
     @Override
     public String toString(){
     return new String(this.getClass().getName() +
-            "[name=" + this.name +
-            ",style="+ this.style +
-            ",fps=" + this.fontProperties + "]");
+            "[name=" + this.name + //$NON-NLS-1$
+            ",style="+ this.style + //$NON-NLS-1$
+            ",fps=" + this.fontProperties + "]"); //$NON-NLS-1$ //$NON-NLS-2$
     }
 
     /**

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/FontManager.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/FontManager.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/FontManager.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/FontManager.java Tue Oct 31 06:25:53 2006
@@ -43,8 +43,8 @@
      */
     public String[] allFamilies;
 
-    public static final String DEFAULT_NAME = "Default"; /* Default font name */
-    public static final String DIALOG_NAME = "Dialog";  /* Dialog font name */
+    public static final String DEFAULT_NAME = "Default"; /* Default font name */ //$NON-NLS-1$
+    public static final String DIALOG_NAME = "Dialog";  /* Dialog font name */ //$NON-NLS-1$
 
     /**
      * Set of constants applicable to the TrueType 'name' table.
@@ -73,48 +73,48 @@
      * FontProperty related constants. 
      */
 
-    public static final String PLATFORM_FONT_NAME = "PlatformFontName";
-    public static final String LOGICAL_FONT_NAME = "LogicalFontName";
-    public static final String COMPONENT_INDEX = "ComponentIndex";
-    public static final String STYLE_INDEX = "StyleIndex";
+    public static final String PLATFORM_FONT_NAME = "PlatformFontName"; //$NON-NLS-1$
+    public static final String LOGICAL_FONT_NAME = "LogicalFontName"; //$NON-NLS-1$
+    public static final String COMPONENT_INDEX = "ComponentIndex"; //$NON-NLS-1$
+    public static final String STYLE_INDEX = "StyleIndex"; //$NON-NLS-1$
 
     public static final String[] FONT_MAPPING_KEYS = {
-            "LogicalFontName.StyleName.ComponentIndex", "LogicalFontName.ComponentIndex"
+            "LogicalFontName.StyleName.ComponentIndex", "LogicalFontName.ComponentIndex" //$NON-NLS-1$ //$NON-NLS-2$
     };
 
-    public static final String FONT_CHARACTER_ENCODING = "fontcharset.LogicalFontName.ComponentIndex";
+    public static final String FONT_CHARACTER_ENCODING = "fontcharset.LogicalFontName.ComponentIndex"; //$NON-NLS-1$
 
-    public static final String EXCLUSION_RANGES = "exclusion.LogicalFontName.ComponentIndex";
+    public static final String EXCLUSION_RANGES = "exclusion.LogicalFontName.ComponentIndex"; //$NON-NLS-1$
 
-    public static final String FONT_FILE_NAME = "filename.PlatformFontName";
+    public static final String FONT_FILE_NAME = "filename.PlatformFontName"; //$NON-NLS-1$
 
     /**
      * Available logical font families names.
      */
     public static final String[] LOGICAL_FONT_FAMILIES = {
-            "Serif", "SansSerif", "Monospaced", "Dialog", "DialogInput"
+            "Serif", "SansSerif", "Monospaced", "Dialog", "DialogInput" //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
     };
 
     /**
      * Available logical font names.
      */
     public static final String[] LOGICAL_FONT_NAMES = {
-            "serif", "serif.plain", "serif.bold", "serif.italic", "serif.bolditalic",
-            "sansserif", "sansserif.plain", "sansserif.bold", "sansserif.italic", "sansserif.bolditalic",
-            "monospaced", "monospaced.plain", "monospaced.bold", "monospaced.italic", "monospaced.bolditalic",
-            "dialog", "dialog.plain", "dialog.bold", "dialog.italic", "dialog.bolditalic",
-            "dialoginput", "dialoginput.plain", "dialoginput.bold", "dialoginput.italic", "dialoginput.bolditalic"
+            "serif", "serif.plain", "serif.bold", "serif.italic", "serif.bolditalic", //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
+            "sansserif", "sansserif.plain", "sansserif.bold", "sansserif.italic", "sansserif.bolditalic", //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
+            "monospaced", "monospaced.plain", "monospaced.bold", "monospaced.italic", "monospaced.bolditalic", //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
+            "dialog", "dialog.plain", "dialog.bold", "dialog.italic", "dialog.bolditalic", //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
+            "dialoginput", "dialoginput.plain", "dialoginput.bold", "dialoginput.italic", "dialoginput.bolditalic" //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
     };
 
     /**
      * Available logical font face names.
      */
     public static final String[] LOGICAL_FONT_FACES = {
-            "Serif", "Serif.plain", "Serif.bold", "Serif.italic", "Serif.bolditalic",
-            "Sansserif", "Sansserif.plain", "Sansserif.bold", "Sansserif.italic", "Sansserif.bolditalic",
-            "Monospaced", "Monospaced.plain", "Monospaced.bold", "Monospaced.italic", "Monospaced.bolditalic",
-            "Dialog", "Dialog.plain", "Dialog.bold", "Dialog.italic", "Dialog.bolditalic",
-            "Dialoginput", "Dialoginput.plain", "Dialoginput.bold", "Dialoginput.italic", "Dialoginput.bolditalic"
+            "Serif", "Serif.plain", "Serif.bold", "Serif.italic", "Serif.bolditalic", //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
+            "Sansserif", "Sansserif.plain", "Sansserif.bold", "Sansserif.italic", "Sansserif.bolditalic", //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
+            "Monospaced", "Monospaced.plain", "Monospaced.bold", "Monospaced.italic", "Monospaced.bolditalic", //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
+            "Dialog", "Dialog.plain", "Dialog.bold", "Dialog.italic", "Dialog.bolditalic", //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
+            "Dialoginput", "Dialoginput.plain", "Dialoginput.bold", "Dialoginput.italic", "Dialoginput.bolditalic" //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
     };
 
     /**
@@ -122,7 +122,7 @@
      * Font.getStyle() corresponds to indexes in STYLE_NAMES array.
      */
     public static final String[] STYLE_NAMES = {
-            "plain", "bold", "italic", "bolditalic"
+            "plain", "bold", "italic", "bolditalic" //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$
     };
 
     /**
@@ -154,8 +154,8 @@
      * Set of possible "os" property values.
      */
     public static final String[] OS_VALUES = {
-            "NT", "98", "2000", "Me", "XP", // For Windows
-            "Redhat", "Turbo", "SuSE"       // For Linux
+            "NT", "98", "2000", "Me", "XP", // For Windows //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
+            "Redhat", "Turbo", "SuSE"       // For Linux //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
     };
 
     /**
@@ -164,30 +164,30 @@
      * the values from current configuration.
      */
     public static final String[] FP_FILE_NAMES = {
-            "/lib/font.properties.Language_Country_Encoding.OSVersion",
-            "/lib/font.properties.Language_Country_Encoding.OS",
-            "/lib/font.properties.Language_Country_Encoding.Version",
-            "/lib/font.properties.Language_Country_Encoding",
-            "/lib/font.properties.Language_Country.OSVersion",
-            "/lib/font.properties.Language_Country.OS",
-            "/lib/font.properties.Language_Country.Version",
-            "/lib/font.properties.Language_Country",
-            "/lib/font.properties.Language_Encoding.OSVersion",
-            "/lib/font.properties.Language_Encoding.OS",
-            "/lib/font.properties.Language_Encoding.Version",
-            "/lib/font.properties.Language_Encoding",
-            "/lib/font.properties.Language.OSVersion",
-            "/lib/font.properties.Language.OS",
-            "/lib/font.properties.Language.Version",
-            "/lib/font.properties.Language",
-            "/lib/font.properties.Encoding.OSVersion",
-            "/lib/font.properties.Encoding.OS",
-            "/lib/font.properties.Encoding.Version",
-            "/lib/font.properties.Encoding",
-            "/lib/font.properties.OSVersion",
-            "/lib/font.properties.OS",
-            "/lib/font.properties.Version",
-            "/lib/font.properties"
+            "/lib/font.properties.Language_Country_Encoding.OSVersion", //$NON-NLS-1$
+            "/lib/font.properties.Language_Country_Encoding.OS", //$NON-NLS-1$
+            "/lib/font.properties.Language_Country_Encoding.Version", //$NON-NLS-1$
+            "/lib/font.properties.Language_Country_Encoding", //$NON-NLS-1$
+            "/lib/font.properties.Language_Country.OSVersion", //$NON-NLS-1$
+            "/lib/font.properties.Language_Country.OS", //$NON-NLS-1$
+            "/lib/font.properties.Language_Country.Version", //$NON-NLS-1$
+            "/lib/font.properties.Language_Country", //$NON-NLS-1$
+            "/lib/font.properties.Language_Encoding.OSVersion", //$NON-NLS-1$
+            "/lib/font.properties.Language_Encoding.OS", //$NON-NLS-1$
+            "/lib/font.properties.Language_Encoding.Version", //$NON-NLS-1$
+            "/lib/font.properties.Language_Encoding", //$NON-NLS-1$
+            "/lib/font.properties.Language.OSVersion", //$NON-NLS-1$
+            "/lib/font.properties.Language.OS", //$NON-NLS-1$
+            "/lib/font.properties.Language.Version", //$NON-NLS-1$
+            "/lib/font.properties.Language", //$NON-NLS-1$
+            "/lib/font.properties.Encoding.OSVersion", //$NON-NLS-1$
+            "/lib/font.properties.Encoding.OS", //$NON-NLS-1$
+            "/lib/font.properties.Encoding.Version", //$NON-NLS-1$
+            "/lib/font.properties.Encoding", //$NON-NLS-1$
+            "/lib/font.properties.OSVersion", //$NON-NLS-1$
+            "/lib/font.properties.OS", //$NON-NLS-1$
+            "/lib/font.properties.Version", //$NON-NLS-1$
+            "/lib/font.properties" //$NON-NLS-1$
     };
 
     /**
@@ -322,7 +322,7 @@
      * @param faceName logical font face name
      */
     public String getFamilyFromLogicalFace(String faceName){
-        int pos = faceName.indexOf(".");
+        int pos = faceName.indexOf("."); //$NON-NLS-1$
         if (pos == -1){
             return faceName;
         }
@@ -341,7 +341,7 @@
      */
     private FontPeer createLogicalFontPeer(String faceName, int style, int size){
         String family = getFamilyFromLogicalFace(faceName);
-        FontProperty[] fps = getFontProperties(family.toLowerCase() + "." + style);
+        FontProperty[] fps = getFontProperties(family.toLowerCase() + "." + style); //$NON-NLS-1$
         if (fps != null){
             int numFonts = fps.length;
             FontPeerImpl[] physicalFonts = new FontPeerImpl[numFonts];
@@ -443,7 +443,7 @@
     public String getLogicalFaceFromFont(int fontStyle, int logicalIndex){
         int style = 0;
         String name = LOGICAL_FONT_FACES[logicalIndex];
-        int pos = name.indexOf(".");
+        int pos = name.indexOf("."); //$NON-NLS-1$
         
         if (pos == -1){
             return createLogicalFace(name, fontStyle);
@@ -466,7 +466,7 @@
      */
     public int getStyleFromLogicalFace(String name){
         int style;
-        int pos = name.indexOf(".");
+        int pos = name.indexOf("."); //$NON-NLS-1$
         
         if (pos == -1){
             return Font.PLAIN;
@@ -487,7 +487,7 @@
      * @param styleIndex index of the style name from the STYLE_NAMES array 
      */
     public String createLogicalFace(String family, int styleIndex){
-        return family + "." + STYLE_NAMES[styleIndex];
+        return family + "." + STYLE_NAMES[styleIndex]; //$NON-NLS-1$
     }
     
     /**
@@ -548,7 +548,7 @@
      */
     public File getTempFontFile()throws IOException{
 
-        File fontFile = File.createTempFile("jFont", ".ttf");
+        File fontFile = File.createTempFile("jFont", ".ttf"); //$NON-NLS-1$ //$NON-NLS-2$
         fontFile.deleteOnExit();
 
         return fontFile;
@@ -562,13 +562,13 @@
     public static File getFontPropertyFile(){
         File file = null;
 
-        String javaHome = System.getProperty("java.home");
+        String javaHome = System.getProperty("java.home"); //$NON-NLS-1$
         Locale l = Locale.getDefault();
         String language = l.getLanguage();
         String country = l.getCountry();
-        String fileEncoding = System.getProperty("file.encoding");
+        String fileEncoding = System.getProperty("file.encoding"); //$NON-NLS-1$
 
-        String os = System.getProperty("os.name");
+        String os = System.getProperty("os.name"); //$NON-NLS-1$
 
         int i = 0;
 
@@ -585,21 +585,21 @@
             os = null;
         }
 
-        String version = System.getProperty("os.version");
+        String version = System.getProperty("os.version"); //$NON-NLS-1$
         String pathname;
 
         for (i = 0; i < FP_FILE_NAMES.length; i++){
             pathname = FP_FILE_NAMES[i];
             if (os != null){
-                pathname = pathname.replaceFirst("OS", os);
+                pathname = pathname.replaceFirst("OS", os); //$NON-NLS-1$
             }
 
             pathname = javaHome + pathname;
 
-            pathname = pathname.replaceAll("Language", language).
-                                replaceAll("Country", country).
-                                replaceAll("Encoding", fileEncoding).
-                                replaceAll("Version", version);
+            pathname = pathname.replaceAll("Language", language). //$NON-NLS-1$
+                                replaceAll("Country", country). //$NON-NLS-1$
+                                replaceAll("Encoding", fileEncoding). //$NON-NLS-1$
+                                replaceAll("Version", version); //$NON-NLS-1$
 
             file = new File(pathname);
 
@@ -634,14 +634,14 @@
             return null;
         }
 
-        String[] intervals = exclusionString.split(",");
+        String[] intervals = exclusionString.split(","); //$NON-NLS-1$
 
         if (intervals != null){
             int num = intervals.length;
             if (num > 0){
                 results = new int[intervals.length << 1];
                 for (int i = 0; i < intervals.length; i++){
-                    String ranges[] = intervals[i].split("-");
+                    String ranges[] = intervals[i].split("-"); //$NON-NLS-1$
                     results[i*2] = Integer.parseInt(ranges[0], 16);
                     results[i*2+1] = Integer.parseInt(ranges[1], 16);
 

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/FontMetricsImpl.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/FontMetricsImpl.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/FontMetricsImpl.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/FontMetricsImpl.java Tue Oct 31 06:25:53 2006
@@ -76,7 +76,7 @@
             // scaleY = (float)at.getScaleY();
         }
 
-        LineMetricsImpl lm = (LineMetricsImpl)peer.getLineMetrics("", null, at);
+        LineMetricsImpl lm = (LineMetricsImpl)peer.getLineMetrics("", null, at); //$NON-NLS-1$
         
         this.ascent = lm.getLogicalAscent();
         this.descent = lm.getLogicalDescent();

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/FontPeerImpl.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/FontPeerImpl.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/FontPeerImpl.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/FontPeerImpl.java Tue Oct 31 06:25:53 2006
@@ -30,6 +30,8 @@
 import java.util.ArrayList;
 import java.util.Locale;
 
+import org.apache.harmony.awt.internal.nls.Messages;
+
 /**
  * Abstract class for platform dependent peer implementation of the Font class.
  */
@@ -268,8 +270,8 @@
         ArrayList<Glyph> lst = new ArrayList<Glyph>(len);
 
         if (size < 0) {
-            throw new IllegalArgumentException(
-                    "min range bound value is grater than max range bound");
+            // awt.09=min range bound value is greater than max range bound
+            throw new IllegalArgumentException(Messages.getString("awt.09")); //$NON-NLS-1$
         }
 
         while (i < uLast) {

Modified: incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/LineMetricsImpl.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/LineMetricsImpl.java?view=diff&rev=469497&r1=469496&r2=469497
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/LineMetricsImpl.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/font/LineMetricsImpl.java Tue Oct 31 06:25:53 2006
@@ -22,6 +22,8 @@
 
 import java.awt.font.LineMetrics;
 
+import org.apache.harmony.awt.internal.nls.Messages;
+
 /**
  *
  * LineMetrics implementation class.
@@ -126,7 +128,8 @@
      */
     public LineMetricsImpl(int len, float[] metrics, float[] _baselineData){
         if (metrics.length < 16){
-            throw new IllegalArgumentException("Wrong number of metrics!");
+            // awt.40=Wrong number of metrics\!
+            throw new IllegalArgumentException(Messages.getString("awt.40")); //$NON-NLS-1$
         }
         numChars = len;