diff src/java/de/intevation/mxd/reader/MarkerFillSymbolReader.java @ 135:a4ab239509f1

Updated the default values and reader error handling.
author Raimund Renkert <rrenkert@intevation.de>
date Wed, 22 Jun 2011 13:55:22 +0200
parents fb93f20478cc
children 0bde090506f9
line wrap: on
line diff
--- a/src/java/de/intevation/mxd/reader/MarkerFillSymbolReader.java	Wed Jun 22 12:01:28 2011 +0200
+++ b/src/java/de/intevation/mxd/reader/MarkerFillSymbolReader.java	Wed Jun 22 13:55:22 2011 +0200
@@ -83,8 +83,7 @@
                String.valueOf(symbol.getXOffset()));
         }
         catch(IOException ioe) {
-            logger.warn("Could not read x-offset. Setting x-offset to 0");
-            symbolElement.setAttribute("xoffset", "0");
+            logger.warn("Could not read x-offset.");
         }
 
         try {
@@ -93,8 +92,7 @@
                 String.valueOf(symbol.getYOffset()));
         }
         catch(IOException ioe) {
-            logger.warn("Could not read y-offset. Setting y-offset to 0.");
-            symbolElement.setAttribute("yoffset", "0");
+            logger.warn("Could not read y-offset.");
         }
 
         try {
@@ -103,10 +101,7 @@
                 String.valueOf(symbol.getXSeparation()));
         }
         catch(IOException ioe) {
-            logger.warn(
-                "Could not read x-separation." +
-                " Setting x-separation to 0.");
-            symbolElement.setAttribute("xseparation", "0");
+            logger.warn("Could not read x-separation.");
         }
 
         try {
@@ -116,9 +111,7 @@
         }
         catch(IOException ioe) {
             logger.warn(
-                "Could not read y-separation." + 
-                " Setting y-separation to 0.");
-            symbolElement.setAttribute("yseparation", "0");
+                "Could not read y-separation.");
         }
 
         int style;
@@ -126,7 +119,7 @@
             style = symbol.getStyle();
         }
         catch(IOException ioe) {
-            logger.warn("Could not read style. Setting style to \"empty\"");
+            logger.warn("Could not read style.");
             style = -1;
         }
         switch(style) {
@@ -145,7 +138,7 @@
             case esriSimpleFillStyle.esriSFSDiagonalCross:
                 symbolElement.setAttribute("fillstyle", "diagonalcross");
                 break;
-            default: symbolElement.setAttribute("fillstyle", "empty");
+            default: break;
         }
 
         try {
@@ -172,12 +165,7 @@
             }
         }
         catch(IOException ioe) {
-            logger.warn(
-                "Could not read color." +
-                " Setting color to black with no transparency.");
-            Color black = new Color (0, 0, 0);
-            symbolElement.setAttribute("color", String.valueOf(black.getRGB()));
-            symbolElement.setAttribute("transparency", "-1");
+            logger.warn("Could not read color.");
         }
 
         try {
@@ -195,7 +183,7 @@
             }
         }
         catch(Exception e) {
-            logger.warn("Could not read outline. No fallback defined.");
+            logger.warn("Could not read outline.");
         }
 
         try {
@@ -213,7 +201,7 @@
             }
         }
         catch(Exception e) {
-            logger.warn("Could not read marker symbol. No fallback defined.");
+            logger.warn("Could not read marker symbol.");
         }
         return parent;
     }
This site is hosted by Intevation GmbH (Datenschutzerklärung und Impressum | Privacy Policy and Imprint)