freetype curve extraction in Font.java and readback in Box.java
[org.ibex.core.git] / src / org / ibex / graphics / Path.java
index 7c0fd40..7557209 100644 (file)
@@ -37,6 +37,12 @@ public class Path {
     static final byte TYPE_QUADRADIC = 4;
 
     public static Path parse(String s) { return Tokenizer.parse(s); }
+
+    // FIXME: hack
+    private String toString;
+    private Path(String s) { this.toString = s; }
+    public String toString() { return toString; }
+
     public static class Tokenizer {
         // FIXME: check array bounds exception for improperly terminated string
         String s;
@@ -47,7 +53,7 @@ public class Path {
         public static Path parse(String s) {
             if (s == null) return null;
             Tokenizer t = new Tokenizer(s);
-            Path ret = new Path();
+            Path ret = new Path(s);
             char last_command = 'M';
             boolean first = true;
             while(t.hasMoreTokens()) {