Index: trunk/src/org/openstreetmap/josm/gui/mappaint/mapcss/Instruction.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/mappaint/mapcss/Instruction.java	(revision 7381)
+++ trunk/src/org/openstreetmap/josm/gui/mappaint/mapcss/Instruction.java	(revision 7382)
@@ -36,13 +36,13 @@
             this.key = key;
             this.isSetInstruction = isSetInstruction;
-            if (val instanceof Keyword) {
-                if ("none".equals(((Keyword) val).val)) {
-                    this.val = null;
-                } else {
-                    this.val = val;
-                }
-            } else if (val instanceof LiteralExpression) {
+            if (val instanceof LiteralExpression) {
                 Object litValue = ((LiteralExpression) val).evaluate(null);
-                if (key.equals(TEXT)) {
+                if (litValue instanceof Keyword) {
+                    if ("none".equals(((Keyword) litValue).val)) {
+                        this.val = null;
+                    } else {
+                        this.val = val;
+                    }
+                } else if (key.equals(TEXT)) {
                     /* Special case for declaration 'text: ...'
                      *
