MCPcopy Index your code
hub / github.com/python/cpython / heading

Method heading

Lib/tkinter/ttk.py:1255–1284  ·  view source on GitHub ↗

Query or modify the heading options for the specified column. If kw is not given, returns a dict of the heading option values. If option is specified then the value for that option is returned. Otherwise, sets the options to the corresponding values. Valid options/v

(self, column, option=None, **kw)

Source from the content-addressed store, hash-verified

1253
1254
1255 def heading(self, column, option=None, **kw):
1256 """Query or modify the heading options for the specified column.
1257
1258 If kw is not given, returns a dict of the heading option values. If
1259 option is specified then the value for that option is returned.
1260 Otherwise, sets the options to the corresponding values.
1261
1262 Valid options/values are:
1263 text: text
1264 The text to display in the column heading
1265 image: image_name
1266 Specifies an image to display to the right of the column
1267 heading
1268 anchor: anchor
1269 Specifies how the heading text should be aligned. One of
1270 the standard Tk anchor values
1271 command: callback
1272 A callback to be invoked when the heading label is
1273 pressed.
1274
1275 To configure the tree column heading, call this with column = "#0" """
1276 cmd = kw.get('command')
1277 if cmd and not isinstance(cmd, str):
1278 # callback not registered yet, do it now
1279 kw['command'] = self.master.register(cmd, self._substitute)
1280
1281 if option is not None:
1282 kw[option] = None
1283
1284 return _val_or_dict(self.tk, kw, self._w, 'heading', column)
1285
1286
1287 def identify(self, component, x, y):

Callers 9

test_headingMethod · 0.45
test_setheadingMethod · 0.45
test_homeMethod · 0.45
test_headingMethod · 0.45
test_heading_callbackMethod · 0.45
docserverMethod · 0.45
tripieceMethod · 0.45
pentpieceMethod · 0.45

Calls 3

_val_or_dictFunction · 0.85
getMethod · 0.45
registerMethod · 0.45

Tested by 6

test_headingMethod · 0.36
test_setheadingMethod · 0.36
test_homeMethod · 0.36
test_headingMethod · 0.36
test_heading_callbackMethod · 0.36