Package igraph :: Package drawing :: Module shapes
[hide private]
[frames] | no frames]

Module shapes

source code

Shape drawing classes for igraph

Vertex shapes in igraph are usually referred to by short names like "rect" or "circle". This module contains the classes that implement the actual drawing routines for these shapes, and a resolver class that determines the appropriate shape drawer class given the short name.

Classes that are derived from ShapeDrawer in this module are automatically registered by ShapeDrawerDirectory. If you implement a custom shape drawer, you must register it in ShapeDrawerDirectory manually if you wish to refer to it by a name in the shape attribute of vertices.


License: Copyright (C) 2006-2012 Tamás Nepusz <ntamas@gmail.com> Pázmány Péter sétány 1/a, 1117 Budapest, Hungary This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA

Classes [hide private]
  ShapeDrawer
Static class, the ancestor of all vertex shape drawer classes.
  NullDrawer
Static drawer class which draws nothing.
  RectangleDrawer
Static class which draws rectangular vertices
  CircleDrawer
Static class which draws circular vertices
  UpTriangleDrawer
Static class which draws upright triangles
  DownTriangleDrawer
Static class which draws triangles pointing down
  DiamondDrawer
Static class which draws diamonds (i.e.
  PolygonDrawer
Class that is used to draw polygons.
  ShapeDrawerDirectory
Static class that resolves shape names to their corresponding shape drawer classes.
Variables [hide private]
  __package__ = 'igraph.drawing'

Imports: atan2, copysign, cos, pi, sin, sys, AbstractCairoDrawer, Point, consecutive_pairs