Re: another multiple selection question



On Wednesday 16 April 2003 17:41, Sven Neumann wrote:
> Hi,
> 
> Dave Reed <dreed capital edu> writes:
> 
> > How do you tell which rows are selected when in multiple selection
> > mode?
> > 
> > When I call get_selected, I get:
> > 
> > Gtk-CRITICAL **: file gtktreeselection.c: line 360 
> > (gtk_tree_selection_get_selected): assertion `selection->type != 
> > GTK_SELECTION_MULTIPLE' failed
> > Segmentation fault (core dumped)
> 
> you better report that as a bug. It might be wrong to use that
> function when GTK_SELECTION_MULTIPLE is active, but it should not run
> into an assertion.

It does appear from the documentation that you can't use get_selected
when the mode GTK_SELECTION_MULTIPLE is so I don't know whether it
should be a bug or not.

Another person suggested gtk_tree_selection_get_selected_rows. That
must be fairly recent. It's not in the gtk2 that comes with RHL 8.0,
but is in the one for RHL 9, but the pygtk bindings that come with RHL
9 don't include it. Looks like the gtk web documentation hasn't caught
up since it's not on there yet either.

For now, I found that gtk.TreeSelection.selected_foreach does work.

I'd still like to make it so that holding the control key is not
required for multiple selection. Does anyone know if that is possible
and if so, how to do it?

Thanks,
Dave




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