Re: Interactive search capability for TreeView
- From: Jonathan Blandford <jrb redhat com>
- To: <kristian planet nl>
- Cc: GTK Development list <gtk-devel-list gnome org>
- Subject: Re: Interactive search capability for TreeView
- Date: 29 Jun 2001 23:13:52 -0400
Kristian Rietveld <kristian planet nl> writes:
> Hi all,
>
> This patch will add an interactive search capability to the TreeView
> widget. Consider this as a first snapshot, there're still some issues with
> it.
>
> How does it work? Give the TreeView the focus and press C-f, a little
> window with an entry will pop up. Type the first characters of the row
> you're searching, as you type all matching items will be selected. Press
> escape to get rid of the window.
>
> Issues:
> 1. only if the selection mode is set to GTK_TREE_SELECTION_MULTI,
> multiple items will be selected when typing. If not, only the latest item
> found will be selected.
This can't be helped, I think. I don't think we want to even select all
items in multi mode either, just the first one. Perhaps there should be
a way to cycle through them.
> 2. I think it's really slow if you use it with big TreeViews. Haven't
> tested this though.
Probably, though there's not much we can do.
> 3. The window which pops up is a GTK_WINDOW_TOPLEVEL and not a
> GTK_WINDOW_POPUP. Should it be a GTK_WINDOW_POPUP?
Probably -- I don't think it needs to be decorated. I think a small
entry in the lower left corner or something, is prolly sufficient.
> 4. I think the TreeView should scroll to the item which will be selected
> first.
Certainly.
> I hope this is a step in the right direction. If not, please tell me, I'll
> be open for any suggestions.
It's certainly a good step in the right direction, but there's more that
needs to happen, and you need to experiment with it some. Additionally,
I think you need to connect to any key press, and not just C-f. Also, I
think that the window needs to grab keyboard/mouse, and go away on a
click/tab/Escape/Return or whatever. Also, you need to be able to set
the column you search on (and allow people to set their own custom func
-- typing Apple and going ot the apple image would truly rock. (-: )
Thanks,
-Jonathan
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]