MCPcopy Create free account
hub / github.com/RT-Thread/env-windows / _options

Method _options

tools/python-3.11.9-amd64/Lib/tkinter/__init__.py:1543–1567  ·  view source on GitHub ↗

Internal function.

(self, cnf, kw = None)

Source from the content-addressed store, hash-verified

1541 return ws
1542
1543 def _options(self, cnf, kw = None):
1544 """Internal function."""
1545 if kw:
1546 cnf = _cnfmerge((cnf, kw))
1547 else:
1548 cnf = _cnfmerge(cnf)
1549 res = ()
1550 for k, v in cnf.items():
1551 if v is not None:
1552 if k[-1] == '_': k = k[:-1]
1553 if callable(v):
1554 v = self._register(v)
1555 elif isinstance(v, (tuple, list)):
1556 nv = []
1557 for item in v:
1558 if isinstance(item, int):
1559 nv.append(str(item))
1560 elif isinstance(item, str):
1561 nv.append(_stringify(item))
1562 else:
1563 break
1564 else:
1565 v = ' '.join(nv)
1566 res = res + ('-'+k, v)
1567 return res
1568
1569 def nametowidget(self, name):
1570 """Return the Tkinter instance of a widget identified by

Callers 15

clipboard_getMethod · 0.95
clipboard_clearMethod · 0.95
clipboard_appendMethod · 0.95
selection_clearMethod · 0.95
selection_getMethod · 0.95
selection_handleMethod · 0.95
selection_ownMethod · 0.95
selection_own_getMethod · 0.95
_configureMethod · 0.95
_grid_configureMethod · 0.95
pack_configureMethod · 0.45
place_configureMethod · 0.45

Calls 8

_registerMethod · 0.95
_cnfmergeFunction · 0.85
strFunction · 0.85
_stringifyFunction · 0.85
callableFunction · 0.50
itemsMethod · 0.45
appendMethod · 0.45
joinMethod · 0.45

Tested by

no test coverage detected