Index: /trunk/src/com/kitfox/svg/Tspan.java
===================================================================
--- /trunk/src/com/kitfox/svg/Tspan.java	(revision 14360)
+++ /trunk/src/com/kitfox/svg/Tspan.java	(revision 14361)
@@ -4,14 +4,14 @@
  * All rights reserved.
  *
- * Redistribution and use in source and binary forms, with or 
+ * Redistribution and use in source and binary forms, with or
  * without modification, are permitted provided that the following
  * conditions are met:
  *
- *   - Redistributions of source code must retain the above 
+ *   - Redistributions of source code must retain the above
  *     copyright notice, this list of conditions and the following
  *     disclaimer.
  *   - Redistributions in binary form must reproduce the above
  *     copyright notice, this list of conditions and the following
- *     disclaimer in the documentation and/or other materials 
+ *     disclaimer in the documentation and/or other materials
  *     provided with the distribution.
  *
@@ -27,6 +27,6 @@
  * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
- * OF THE POSSIBILITY OF SUCH DAMAGE. 
- * 
+ * OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
  * Mark McKay can be contacted at mark@kitfox.com.  Salamander and other
  * projects can be found at http://www.kitfox.com
@@ -36,6 +36,4 @@
 package com.kitfox.svg;
 
-import com.kitfox.svg.util.FontSystem;
-import com.kitfox.svg.xml.StyleAttribute;
 import java.awt.Graphics2D;
 import java.awt.Shape;
@@ -45,4 +43,7 @@
 import java.awt.geom.Point2D;
 import java.awt.geom.Rectangle2D;
+
+import com.kitfox.svg.util.FontSystem;
+import com.kitfox.svg.xml.StyleAttribute;
 
 /**
@@ -229,5 +230,5 @@
         //Get font
         Font font = diagram.getUniverse().getFont(fontFamily);
-        if (font == null)
+        if (font == null && fontFamily != null)
         {
             font = FontSystem.createFont(fontFamily, fontStyle, fontWeight, (int)fontSize);
@@ -243,5 +244,5 @@
         float cursorX = (float)cursor.getX();
         float cursorY = (float)cursor.getY();
-    
+
         String drawText = this.text;
         drawText = drawText.trim();
@@ -255,5 +256,5 @@
                 cursorX += dx[i];
             }
-            
+
             if (y != null && i < y.length)
             {
@@ -263,5 +264,5 @@
                 cursorY += dy[i];
             }
-            
+
             xform.setToIdentity();
             xform.setToTranslation(cursorX, cursorY);
@@ -322,5 +323,5 @@
 //            }
 ////            i++;
-//            
+//
 //            xform.setToIdentity();
 //            xform.setToTranslation(cursorX, cursorY);
@@ -342,5 +343,5 @@
 //            cursorX += glyphMetrics.getAdvance() + letterSpacing;
 //        }
-//        
+//
 //        cursor.setLocation(cursorX, cursorY);
 //    }
@@ -351,5 +352,5 @@
         float cursorX = 0;
         float cursorY = 0;
-    
+
         if (x != null)
         {
@@ -439,5 +440,5 @@
         float cursorX = 0;
         float cursorY = 0;
-    
+
         FontRenderContext frc = g.getFontRenderContext();
 
