MCPcopy
hub / github.com/matplotlib/matplotlib / unit_rectangle

Method unit_rectangle

lib/matplotlib/path.py:778–785  ·  view source on GitHub ↗

Return a `Path` instance of the unit rectangle from (0, 0) to (1, 1).

(cls)

Source from the content-addressed store, hash-verified

776
777 @classmethod
778 def unit_rectangle(cls):
779 """
780 Return a `Path` instance of the unit rectangle from (0, 0) to (1, 1).
781 """
782 if cls._unit_rectangle is None:
783 cls._unit_rectangle = cls([[0, 0], [1, 0], [1, 1], [0, 1], [0, 0]],
784 closed=True, readonly=True)
785 return cls._unit_rectangle
786
787 _unit_regular_polygons = WeakValueDictionary()
788

Callers 12

test_pathpatch_3dFunction · 0.80
_set_pixelMethod · 0.80
_set_squareMethod · 0.80
_set_diamondMethod · 0.80
get_pathMethod · 0.80
drawMethod · 0.80
plot_pathsFunction · 0.80
test_clippingFunction · 0.80

Calls

no outgoing calls