Computes a bounding box in user-space coordinates covering the
points on the current path. If the current path is empty, returns
an empty rectangle ((0,0), (0,0)). Stroke parameters, fill rule,
surface dimensions and clipping are not taken into account.
Computes a bounding box in user-space coordinates covering the points on the current path. If the current path is empty, returns an empty rectangle ((0,0), (0,0)). Stroke parameters, fill rule, surface dimensions and clipping are not taken into account.
Contrast with cairo.context.Context.fillExtents and cairo.context.Context.strokeExtents which return the extents of only the area that would be "inked" by the corresponding drawing operations.
The result of cairo.context.Context.pathExtents is defined as equivalent to the limit of cairo.context.Context.strokeExtents with cairo.types.LineCap.Round as the line width approaches 0.0, (but never reaching the empty-rectangle returned by cairo.context.Context.strokeExtents for a line width of 0.0).
Specifically, this means that zero-area sub-paths such as cairo.context.Context.moveTo;cairo.context.Context.lineTo segments, (even degenerate cases where the coordinates to both calls are identical), will be considered as contributing to the extents. However, a lone cairo.context.Context.moveTo will not contribute to the results of cairo.context.Context.pathExtents.