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

Function test_radio_buttons_props

lib/matplotlib/tests/test_widgets.py:1153–1164  ·  view source on GitHub ↗
(fig_test, fig_ref)

Source from the content-addressed store, hash-verified

1151
1152@check_figures_equal()
1153def test_radio_buttons_props(fig_test, fig_ref):
1154 label_props = {'color': ['red'], 'fontsize': [24]}
1155 radio_props = {'facecolor': 'green', 'edgecolor': 'blue', 'linewidth': 2}
1156
1157 widgets.RadioButtons(fig_ref.subplots(), ['tea', 'coffee'],
1158 label_props=label_props, radio_props=radio_props)
1159
1160 cb = widgets.RadioButtons(fig_test.subplots(), ['tea', 'coffee'])
1161 cb.set_label_props(label_props)
1162 # Setting the label size automatically increases default marker size, so we
1163 # need to do that here as well.
1164 cb.set_radio_props({**radio_props, 's': (24 / 2)**2})
1165
1166
1167@image_comparison(['check_radio_grid_buttons.png'], style='mpl20', remove_text=True)

Callers

nothing calls this directly

Calls 3

set_radio_propsMethod · 0.95
set_label_propsMethod · 0.80
subplotsMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…