src/main/java/org/geotools/renderer/style/SVGGraphicFactory.java
private double parseDouble(String value) {
try {
return java.lang.Double.parseDouble(value);
} catch (NumberFormatException arg2) {
+ if(value.endsWith("mm")){
+ int trail = value.endsWith("mm") ? 2 : value.endsWith(" mm") ? 3 : 0;
+ value = value.substring(0, value.length()-trail);
+ java.lang.Integer ScreenResolution = java.awt.Toolkit.getDefaultToolkit().getScreenResolution();
+ java.lang.Double valueDouble = java.lang.Double.parseDouble(value);
+ java.lang.Double valueInpx = valueDouble*ScreenResolution/25.4;
+ return valueInpx;
+ }else{
return java.lang.Double.parseDouble(value.replaceAll("\\D*$", ""));
+ }
}
}