MCPcopy Index your code
hub / github.com/matplotlib/matplotlib / __init__

Method __init__

lib/matplotlib/table.py:58–106  ·  view source on GitHub ↗

Parameters ---------- xy : 2-tuple The position of the bottom left corner of the cell. width : float The cell width. height : float The cell height. edgecolor : :mpltype:`color`, default: 'k' The color o

(self, xy, width, height, *,
                 edgecolor='k', facecolor='w',
                 fill=True,
                 text='',
                 loc='right',
                 fontproperties=None,
                 visible_edges='closed',
                 )

Source from the content-addressed store, hash-verified

56 }
57
58 def __init__(self, xy, width, height, *,
59 edgecolor='k', facecolor='w',
60 fill=True,
61 text='',
62 loc='right',
63 fontproperties=None,
64 visible_edges='closed',
65 ):
66 """
67 Parameters
68 ----------
69 xy : 2-tuple
70 The position of the bottom left corner of the cell.
71 width : float
72 The cell width.
73 height : float
74 The cell height.
75 edgecolor : :mpltype:`color`, default: 'k'
76 The color of the cell border.
77 facecolor : :mpltype:`color`, default: 'w'
78 The cell facecolor.
79 fill : bool, default: True
80 Whether the cell background is filled.
81 text : str, optional
82 The cell text.
83 loc : {'right', 'center', 'left'}
84 The alignment of the text within the cell.
85 fontproperties : dict, optional
86 A dict defining the font properties of the text. Supported keys and
87 values are the keyword arguments accepted by `.FontProperties`.
88 visible_edges : {'closed', 'open', 'horizontal', 'vertical'} or \
89substring of 'BRTL'
90 The cell edges to be drawn with a line: a substring of 'BRTL'
91 (bottom, right, top, left), or one of 'open' (no edges drawn),
92 'closed' (all edges drawn), 'horizontal' (bottom and top),
93 'vertical' (right and left).
94 """
95
96 # Call base
97 super().__init__(xy, width=width, height=height, fill=fill,
98 edgecolor=edgecolor, facecolor=facecolor)
99 self.set_clip_on(False)
100 self.visible_edges = visible_edges
101
102 # Create text object
103 self._loc = loc
104 self._text = Text(x=xy[0], y=xy[1], clip_on=False,
105 text=text, fontproperties=fontproperties,
106 horizontalalignment=loc, verticalalignment='center')
107
108 def set_transform(self, t):
109 super().set_transform(t)

Callers 1

__init__Method · 0.45

Calls 2

TextClass · 0.70
set_clip_onMethod · 0.45

Tested by

no test coverage detected