smart multi-select combo?



[pygtk-1.99.15, gtk-2.2.1, python 2.3a1]
I need something *like* a combo widget, but that allows multiple
and extended selects and for which the "entry" widget is read-only 
and shows a "summary" of the selections.  E.g.
----------------
        1
        2*
        3*
        4*
        5
        8*
----------------
      (2-4,8)
 [OK]   [Cancel]
----------------
where 2,3,4 and 6 are the selected options and "2-4,6" is the
read-only summary.  
 
I've started trying to adapt the Combo widget, but I wonder if
this is the right path.  Does anyone have a better suggestion,
or ideas of how to cleanly (from python) use the Combo widget
to this end?

More generally, I need to allow selection of arbitrary items,
(short strings, often just integers)
as well as an easy way to select a range (e.g. with a swipe of
the mouse), but when closed, the display shows a compacted 
summary of the selections.  My app has typically from 5 to 25
items, but occasionally 50.  The screen is already very crowded,
so only the compressed display should show except while the user
is changing the selection set.

One concern is that "combo" and "list" that is used by combo are
both marked as deprecated in the gtk source.  But I've read that
optionmenu shouldn't be used for multiple select.  So what's left
for a popup multiple select widget?

-- George
-- 
 I cannot think why the whole bed of the ocean is
 not one solid mass of oysters, so prolific they seem. Ah,
 I am wandering! Strange how the brain controls the brain!
        -- Sherlock Holmes in "The Dying Detective"



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]