src/java.desktop/share/classes/sun/font/Decoration.java

Print this page
rev 10520 : 8055723[client]: Replace concat String to append in StringBuilder parameters
Contributed-by: Otavio Santana <otaviojava@java.net>

@@ -429,16 +429,16 @@
 
         public String toString() {
             StringBuilder sb = new StringBuilder();
             sb.append(super.toString());
             sb.append("[");
-            if (fgPaint != null) sb.append("fgPaint: " + fgPaint);
-            if (bgPaint != null) sb.append(" bgPaint: " + bgPaint);
+            if (fgPaint != null) sb.append("fgPaint: ").append(fgPaint);
+            if (bgPaint != null) sb.append(" bgPaint: ").append(bgPaint);
             if (swapColors) sb.append(" swapColors: true");
             if (strikethrough) sb.append(" strikethrough: true");
-            if (stdUnderline != null) sb.append(" stdUnderline: " + stdUnderline);
-            if (imUnderline != null) sb.append(" imUnderline: " + imUnderline);
+            if (stdUnderline != null) sb.append(" stdUnderline: ").append(stdUnderline);
+            if (imUnderline != null) sb.append(" imUnderline: ").append(imUnderline);
             sb.append("]");
             return sb.toString();
         }
     }
 }