Usually the tree of categories can reach to 500 - 1500 keywords or even more which is way to big in order to be searched by "hand" (there are generational dimensions like 'People', 'Events', 'Animals', 'Flowers', 'Places' etc.).
The classical approach to this is to have an Auto Complete / Auto Fill Engine with Partial Match Anywhere like this one:

The mockup in our GUI:
Implementation considerations:
1. Use in a background thread (perhaps delayed at 400ms like in Windows Explorer) a simple...
Code: Select all
Select TagID, Label from Tags where Label Like '%foo%' order by Label collate nocase limit 50;
This should work near real-time till 50-60-70k rows (or even more), much more than our needs.
Take care - we'll use this elsewhere for paths. There we'll need to 'escape' the % and _ because these characters can appear in a path. More on this, later.
See here for more details:
http://stackoverflow.com/questions/8196 ... d-lag?rq=1
If one needs help or anything, please drop a line.
2. Be sure to implement this engine abstract. We'll need it in other areas. (eg. in the soon-to-be presented Catalog pane

3. If the User presses Enter or the ">" button then the first item from the drop-down list is selected and assigned to the selection of photos. If nothing is in the list then a message appears "Do you want to add 'blah' as a new Category?" {yes} {no}. Also, perhaps is better for this to add a button called 'Add...' and a shortcut in the drop down keyboard handler (usually Ctrl+Enter). Beware, as I said, the main Auto Complete Engine should be abstract, hence this part perhaps could be implemented as a delegate / event.
Any comments?