| 1166 | |
| 1167 | @image_comparison(['check_radio_grid_buttons.png'], style='mpl20', remove_text=True) |
| 1168 | def test_radio_grid_buttons(): |
| 1169 | fig = plt.figure() |
| 1170 | rb_horizontal = widgets.RadioButtons( |
| 1171 | fig.add_axes((0.1, 0.05, 0.65, 0.05)), |
| 1172 | ["tea", "coffee", "chocolate milk", "water", "soda", "coke"], |
| 1173 | layout='horizontal', |
| 1174 | active=4, |
| 1175 | ) |
| 1176 | cb_grid = widgets.CheckButtons( |
| 1177 | fig.add_axes((0.1, 0.15, 0.25, 0.05*3)), |
| 1178 | ["Chicken", "Salad", "Rice", "Sushi", "Pizza", "Fries"], |
| 1179 | layout=(3, 2), |
| 1180 | actives=[True, True, False, False, False, True], |
| 1181 | ) |
| 1182 | rb_vertical = widgets.RadioButtons( |
| 1183 | fig.add_axes((0.1, 0.35, 0.2, 0.05*4)), |
| 1184 | ["Trinity Cream", "Cake", "Ice Cream", "Muhallebi"], |
| 1185 | layout='vertical', |
| 1186 | active=3, |
| 1187 | ) |
| 1188 | |
| 1189 | |
| 1190 | def test_radio_button_active_conflict(ax): |