MCPcopy Index your code
hub / github.com/RustPython/RustPython / _format_optvalue

Function _format_optvalue

Lib/tkinter/ttk.py:32–40  ·  view source on GitHub ↗

Internal function.

(value, script=False)

Source from the content-addressed store, hash-verified

30
31
32def _format_optvalue(value, script=False):
33 """Internal function."""
34 if script:
35 # if caller passes a Tcl script to tk.call, all the values need to
36 # be grouped into words (arguments to a command in Tcl dialect)
37 value = _stringify(value)
38 elif isinstance(value, (list, tuple)):
39 value = _join(value)
40 return value
41
42def _format_optdict(optdict, script=False, ignore=None):
43 """Formats optdict to a tuple to pass it to tk.call.

Callers 3

_format_optdictFunction · 0.85
_format_mapdictFunction · 0.85
_format_elemcreateFunction · 0.85

Calls 3

_stringifyFunction · 0.90
_joinFunction · 0.90
isinstanceFunction · 0.85

Tested by

no test coverage detected