[Lemon-commits] [lemon_svn] deba: r2031 - hugo/trunk/lemon

Lemon SVN svn at lemon.cs.elte.hu
Mon Nov 6 20:49:38 CET 2006


Author: deba
Date: Mon Jul  4 19:51:07 2005
New Revision: 2031

Modified:
   hugo/trunk/lemon/graph_to_eps.h

Log:
May it does not throw Warning with g++-4.0


Modified: hugo/trunk/lemon/graph_to_eps.h
==============================================================================
--- hugo/trunk/lemon/graph_to_eps.h	(original)
+++ hugo/trunk/lemon/graph_to_eps.h	Mon Jul  4 19:51:07 2005
@@ -707,13 +707,15 @@
     }
     BoundingBox<double> bb;
     ///\bug: Chech whether the graph is empty.
-    if(NodeIt(g)==INVALID) bb+=xy<double>(0,0);
     for(NodeIt n(g);n!=INVALID;++n) {
       double ns=_nodeSizes[n]*_nodeScale;
       xy<double> p(ns,ns);
       bb+=p+_coords[n];
       bb+=-p+_coords[n];
-      }
+    }
+    if (bb.empty()) {
+      bb = BoundingBox<double>(xy<double>(0,0));
+    }
     if(_scaleToA4)
       os <<"%%BoundingBox: 0 0 596 842\n%%DocumentPaperSizes: a4\n";
     else os << "%%BoundingBox: "



More information about the Lemon-commits mailing list