python-igraph API reference

List of all classes, functions and methods in python-igraph

class documentation

Abstract class that serves as a base class for anything that draws on a Cairo context within a given bounding box.

A subclass of AbstractCairoDrawer is guaranteed to have an attribute named context that represents the Cairo context to draw on, and an attribute named bbox for the BoundingBox of the drawing area.

Method __init__ Constructs the drawer and associates it to the given Cairo context and the given BoundingBox.
Instance Variable context Undocumented
Property bbox The bounding box of the drawing area where this drawer will draw.
Method bbox.setter Sets the bounding box of the drawing area where this drawer will draw.
Method draw Abstract method, must be implemented in derived classes.
Instance Variable _bbox Undocumented
Method _mark_point Marks the given point with a small circle on the canvas. Used primarily for debugging purposes.
def __init__(self, context, bbox):

Constructs the drawer and associates it to the given Cairo context and the given BoundingBox.

Parameterscontextthe context on which we will draw
bboxthe bounding box within which we will draw. Can be anything accepted by the constructor of BoundingBox (i.e., a 2-tuple, a 4-tuple or a BoundingBox object).
context =

Undocumented

_bbox =
@property
bbox =

The bounding box of the drawing area where this drawer will draw.

@bbox.setter
def bbox(self, bbox):

Sets the bounding box of the drawing area where this drawer will draw.

def _mark_point(self, x, y, color=0, size=4):

Marks the given point with a small circle on the canvas. Used primarily for debugging purposes.

Parametersxthe X coordinate of the point to mark
ythe Y coordinate of the point to mark
colorthe color of the marker. It can be a 3-tuple (RGB components, alpha=0.5), a 4-tuple (RGBA components) or an index where zero means red, 1 means green, 2 means blue and so on.
sizethe diameter of the marker.
API Documentation for igraph, generated by pydoctor 21.2.2.