[referencer] [PATCH] Add tags through a cell in the tags view instead of a dialog

John Spray jcspray at icculus.org
Thu May 17 03:16:41 EDT 2007


On Wed, 2007-05-16 at 20:28 -0700, Eric Lesh wrote:
> This patch gets rid of the "New Tag" dialog and instead adds a "Type a
> tag" entry at the bottom of the tags list for editing.  This is how
> Epiphany works in the bookmarks editor when adding a topic.
> 
> You commented in the code that "For intelligent tags we'll need a dialog
> here."  I'm not sure what you you meant by that, but I think the dialog
> is a bit of a nuisance.

The idea was that eventually there would be tags such as "All documents
<1 year old" or "All documents by author foo".  But yes, as long as
those don't actually exist the dialog is a bit excessive and can easily
be reinstated if it's needed.

One thing that makes me uncomfortable is the way the treepath for the
new tag is found -- I'm not sure the assumption that it's going to be at
the end will always be valid, if there is any sorting going on.  Also,
adding 2 to skip the "All documents" and "Untagged documents" is a
dangerously magic number.

I've committed your version, but could you look into making it a little
bit more robust?  For instance, newTag returns the integer ID of the new
tag, and you could find this in the tag treemodel to be sure you're
getting the right path without making too many assumptions.

Thanks for the patch.

John




More information about the referencer mailing list