RoboFab RContour

Usage

# robofab manual
# Contour object
#    usage examples

# take a glyph (one with outlines obviously)
c = CurrentGlyph()
# get to contours by index:
print c[0]
➔ Download this.
< RContour for Mailer-Regular.a[0] >

Description

RContour is an object for, well, contours. A contour is a single path of any number of points and shape. A glyph usually consists of a couple fo contours, and this the object that represents each one. The RContour object offers access to the outline matter in various ways. The parent of RContour is usually RGlyph.

Understanding Contours and outlines

The way outline data is organised in RoboFab, and how the various objects relate is described here: understanding contours.

If you want to add new contours to a glyph it's easier to draw them with a pen than to construct the shapes from segments.

Attributes

Attribute examples

Examples with contours and points here.

Methods for segments

For regular drawing in glyphs: please use Pens. If you want to mess with segments on a lower level, be our guest:

Methods for points

Other methods

Method examples

# robofab manual
#     Contour object
#    method examples

#method examples
➔ Download this.