After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 310931 - Choosing combobox entry by typing first few letters
Choosing combobox entry by typing first few letters
Status: RESOLVED DUPLICATE of bug 262687
Product: gtk+
Classification: Platform
Component: Widget: GtkComboBox
2.6.x
Other Linux
: Normal enhancement
: Medium feature
Assigned To: gtk-bugs
gtk-bugs
: 318458 569149 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2005-07-19 21:15 UTC by Samuli Kärkkäinen
Modified: 2017-08-15 00:32 UTC
See Also:
GNOME target: ---
GNOME version: 2.9/2.10



Description Samuli Kärkkäinen 2005-07-19 21:15:41 UTC
Version details: 2.6.7
Distribution/Version: Fedora Core 4

When a combobox is focused, typing letters from keyboard should select the
combobox item whose start matches the typed characters, just as in the File
Chooser. This would make it much easier to select the desired bookmark without
using mouse.
Comment 1 Matthias Clasen 2005-10-11 03:15:11 UTC
*** Bug 318458 has been marked as a duplicate of this bug. ***
Comment 2 Shawn Maclaga 2007-07-13 18:47:47 UTC
Can someone please give a status update on this bug?  There's been no activity on this issue for over a year and a half.

Thanks
Shawn
Comment 3 Samuli Kärkkäinen 2007-07-13 21:03:29 UTC
Behavior of gtk 2.10.11 appears unchanged from 2.6.7 in this regard.
Comment 4 Matthew Paul Thomas (mpt) 2009-01-26 17:05:52 UTC
*** Bug 569149 has been marked as a duplicate of this bug. ***
Comment 5 Steffen Gutmann 2009-01-26 23:48:03 UTC
About the design of this typeahead search: would the search string be visible (like in GtkTreeView below the list) or should it be a hidden search string (blind edit)?

MS Windows is using the latter and characters entered are sometimes appended to the search string and sometimes they start a new search string depending on various conditions (time out, search matches, etc.).

Also the design should allow an extension for using it in GtkComboBoxEntry (I would expect that typeahead would auto-fill the entry with the fill-in pre-selected such that it can be typed over).

Has anyone seen a GTK application that has some custom implementation for this feature?
Comment 6 Thomas M. Hinkle 2009-06-23 20:29:21 UTC
I think the ideal thing would be for typing to drop down the list and then highlight as you type ahead (like in gtktreeview below the list).

I did a custom implementation of this for Gourmet Recipe Manager in python. Here's a link to the library where I put the typeahead stuff (along with other convenience methods for working with combo boxes): 

http://grecipe-manager.git.sourceforge.net/git/gitweb.cgi?p=grecipe-manager;a=blob;f=src/lib/gtk_extras/cb_extras.py;h=a017b19f70586226374da976bf08dcb1361bb3f1;hb=HEAD

If you just run that python file, you should see a demo of the minimal functionality requested here -- in this case, just typing the letter selects automatically -- no graphical slickness there.
Comment 7 tvst 2009-07-30 14:23:41 UTC
IMO, the search string should be visible. This is one of the details that really shine in GTK. So the whole behavior would be like this:

1) focus the combo box
2) *optional* - open the combo-box
3) start typing
then:
letters appear in a small HUD pop-up window as you type, like with GtkTreeView. At the same time, the combo box opens and highlights the best-matching item (or no item if there are no matches).

The HUD pop-up window should not overlap the combo-box pop-up. Instead, it should be placed *after* the combo-box pop-up, i.e. beneath the last item. If there is no space there, the combo-box pop-up should shrink by one item to make room for the HUD window.
Comment 8 Mike Reiser 2010-05-06 01:39:01 UTC
I am a blind Orca user and think it would be beneficial to have it just jump to the item needed.  This functionality seems to work as expected in list-views, and as it stands navigating combo boxes with orca is quite painful.  I also like the idea of typing and it narrowing down the list, a combination of both approaches would be great.
Comment 9 Chris Wilson 2011-01-23 20:39:47 UTC
What is the status on this bug? Is there a discussion taking place somewhere that can be linked to?
Comment 10 TROADEC 2011-11-21 13:04:20 UTC
We do have a need of such functionality too. When will it be provided ?
Comment 11 Alexandre Provencio 2011-11-22 01:31:42 UTC
IMO, this issue extends to the whole system when I understand that all items in all menus (contexts menus, comboboxes etc) should have a way to be accessed by at least its first letter, even when there is not an accel key assigned to it provided by the application or all items should have an accel key given by gnome/gtk.  This way, items can be easily accessed without the need of arrows, which is the reason accel keys exist. I can't remember if this has ever worked anytime in prior gnome/gtk versions.
Comment 12 tvst 2011-11-23 17:38:37 UTC
Agreed ^

So just to get things going: does anyone know if the GTK project is interested in adding this functionality at all? 

I ask this because one of the reasons bugs/feature requests like this often go nowhere is that outside contributors tend to be afraid that if they write code it will never be given a real chance. And, conversely, if GTK shows interest maybe some code ninja will pop up with a solution :)
Comment 13 Daniel Boles 2017-08-15 00:32:19 UTC

*** This bug has been marked as a duplicate of bug 262687 ***