Scale the node sizes and arc widths in a more sensible way
authorAlpar Juttner <alpar@cs.elte.hu>
Mon, 14 Apr 2008 11:23:56 +0100
changeset 13250ff949140fa
parent 131 3125084667a3
child 133 d76e2ff9c70d
Scale the node sizes and arc widths in a more sensible way
demo/graph_to_eps_demo.cc
lemon/graph_to_eps.h
     1.1 --- a/demo/graph_to_eps_demo.cc	Tue Apr 15 08:56:55 2008 +0100
     1.2 +++ b/demo/graph_to_eps_demo.cc	Mon Apr 14 11:23:56 2008 +0100
     1.3 @@ -199,7 +199,7 @@
     1.4      copyright("(C) 2003-2007 LEMON Project").
     1.5      coords(hcoords).
     1.6      absoluteNodeSizes().absoluteArcWidths().
     1.7 -    nodeScale(45).
     1.8 +    nodeScale(.45).
     1.9      distantColorNodeTexts().
    1.10      //    distantBWNodeTexts().
    1.11      nodeTexts(hcolors).nodeTextSize(.6).
     2.1 --- a/lemon/graph_to_eps.h	Tue Apr 15 08:56:55 2008 +0100
     2.2 +++ b/lemon/graph_to_eps.h	Mon Apr 14 11:23:56 2008 +0100
     2.3 @@ -150,10 +150,10 @@
     2.4    DefaultGraphToEpsTraits(const G &_g,std::ostream& _os=std::cout,
     2.5  			  bool _pros=false) :
     2.6      g(_g), os(_os),
     2.7 -    _coords(dim2::Point<double>(1,1)), _nodeSizes(.01), _nodeShapes(0),
     2.8 +    _coords(dim2::Point<double>(1,1)), _nodeSizes(1), _nodeShapes(0),
     2.9      _nodeColors(WHITE), _arcColors(BLACK),
    2.10      _arcWidths(1.0), _arcWidthScale(0.003),
    2.11 -    _nodeScale(1.0), _xBorder(10), _yBorder(10), _scale(1.0),
    2.12 +    _nodeScale(.01), _xBorder(10), _yBorder(10), _scale(1.0),
    2.13      _nodeBorderQuotient(.1),
    2.14      _drawArrows(false), _arrowLength(1), _arrowWidth(0.3),
    2.15      _showNodes(true), _showArcs(true),
    2.16 @@ -496,7 +496,7 @@
    2.17    /// equal to \c d.
    2.18    /// \sa nodeSizes()
    2.19    /// \sa autoNodeScale()
    2.20 -  GraphToEps<T> &nodeScale(double d) {_nodeScale=d;return *this;}
    2.21 +  GraphToEps<T> &nodeScale(double d=.01) {_nodeScale=d;return *this;}
    2.22    ///Turns on/off the automatic node width scaling.
    2.23  
    2.24    ///Turns on/off the automatic node width scaling.
    2.25 @@ -549,7 +549,7 @@
    2.26    /// If both arcWidths() and autoArcWidthScale() are used, then the
    2.27    /// arc withs will be scaled in such a way that the greatest width will be
    2.28    /// equal to \c d.
    2.29 -  GraphToEps<T> &arcWidthScale(double d) {_arcWidthScale=d;return *this;}
    2.30 +  GraphToEps<T> &arcWidthScale(double d=.003) {_arcWidthScale=d;return *this;}
    2.31    ///Turns on/off the automatic arc width scaling.
    2.32  
    2.33    ///Turns on/off the automatic arc width scaling.