Am 13.04.2021 um 23:53 schrieb Rich Shepard:
> My applications use environmental data, each of which has to specify
> the
> units (e.g., cm, m, km, ft, yd, mi). With the widget sets I've used
> (wxPython and TKinter) I've always used a combobox with the acceptable
> choices in it. I'm now planning a new application using PyQt5 and it
> occured
> to me that a set of radio buttons would also work.
> 
> While a set of radiobuttons occupies more room on the parent widget
> than
> does a combobox are there any technical or user issues that would
> suggest
> using one over the other?
> 
> TIA,
> 
> Rich

I use radiobuttons if the list of choices is small and static, like
about 2 - 5 fixed entries. Comboboxes are better for larger lists,
or if the user can add own entries, or if there's a chance that the
program needs more entries later.

IME, radiobuttons cause more visual distraction while comboboxes can
be less obvious for less tech-savvy people. OTOH, comboboxes require
two clicks.

For your situation with units, I would probably go for radios if the
user needs to change the units often and combos if radios would make
the view more complex and less obvious.
-- 
https://mail.python.org/mailman/listinfo/python-list

Reply via email to