]> source.dussan.org Git - xmlgraphics-fop.git/commitdiff
extra style options for the lines
authorKeiron Liddle <keiron@apache.org>
Wed, 12 Jul 2000 01:48:33 +0000 (01:48 +0000)
committerKeiron Liddle <keiron@apache.org>
Wed, 12 Jul 2000 01:48:33 +0000 (01:48 +0000)
none, miterlimit, linecap, line join

git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@193489 13f79535-47bb-0310-9956-ffa450edef68

src/org/apache/fop/datatypes/StyleData.java

index dc620d0cdc840ec5f8315b699affd78d8846d4af..0fde4bbbfcb8aae0e5983456708b3ef905fc0e56 100644 (file)
@@ -89,7 +89,9 @@ public class StyleData {
                                        if(value.startsWith("url(")) {
                                                table.put(type, new String(value));
                                        } else if(!value.equals("none")) {
-                                                       table.put(type, new ColorType(value));
+                                               table.put(type, new ColorType(value));
+                                       } else if(value.equals("none")) {
+                                               table.put(type, value);
                                        }
                                } else if(type.equals("color")) {
 //                                     if(!value.equals("none"))
@@ -100,15 +102,19 @@ public class StyleData {
                                } else if(type.equals("stroke-linejoin")) {
                                        table.put(type, value);
                                } else if(type.equals("stroke-miterlimit")) {
+                                       table.put(type, new SVGLengthImpl(value));
                                } else if(type.equals("stroke-dasharray")) {
                                        // array of space or comma separated numbers
-                                       Vector list = new Vector();
-                                       StringTokenizer array = new StringTokenizer(value, " ,");
-                                       while(array.hasMoreTokens()) {
-                                               String intstr = array.nextToken();
-                                               list.addElement(new Integer(Integer.parseInt(intstr)));
+                                       if(!value.equals("none")) {
+                                               Vector list = new Vector();
+                                               StringTokenizer array = new StringTokenizer(value, " ,");
+                                               while(array.hasMoreTokens()) {
+                                                       String intstr = array.nextToken();
+                                                       list.addElement(new Integer(Integer.parseInt(intstr)));
+                                               }
+                                               table.put(type, list);
                                        }
-                                       table.put(type, list);
+                                       // else leave ??
                                } else if(type.equals("stroke-dashoffset")) {
                                        table.put(type, new SVGLengthImpl(value));
                                } else if(type.equals("stroke-opacity")) {
@@ -117,11 +123,12 @@ public class StyleData {
                                                table.put(type, new String(value));
                                        } else if(!value.equals("none")) {
                                                table.put(type, new ColorType(value));
+                                       } else {
+                                               table.put(type, value);
                                        }
-//                                     else
-//                                             table.put(type, null);
                                } else if(type.equals("fill-rule")) {
                                        // nonzero
+                                       table.put(type, value);
                                } else if(type.equals("font")) {
                                        table.put(type, value);
                                } else if(type.equals("font-size")) {