GTG

Be able to add tag from main treeview

Bug #339188 reported by Guillaume Desmottes
40
This bug affects 5 people
Affects Status Importance Assigned to Milestone
GTG
Fix Released
Medium
Matthew Rasmus

Bug Description

I'd like to be able to add a tag to a task by right clicking on the task in the main treeview.

Related branches

description: updated
Revision history for this message
Lionel Dricot (ploum-deactivatedaccount) wrote :

Good idea and should be easy to do.

Changed in gtg:
importance: Undecided → Medium
milestone: none → 0.2
status: New → Confirmed
Revision history for this message
Pititjo (jonathan-barnoud) wrote :

Being able to add a tag by drag-and-drop might be cool too.

Revision history for this message
Bertrand Rousseau (bertrand-rousseau) wrote :

>Pititjo If you could change "This bug doesn't affect me" to "This bug affects me", that would be great. It allows us to see roughly what feature counts for people.

Revision history for this message
Pititjo (jonathan-barnoud) wrote :

@Bertrand : done

Adding tags by drag and drop is already mentioned in this bug : <https://bugs.launchpad.net/gtg/+bug/340791>

Revision history for this message
Paul Natsuo Kishimoto (khaeru) wrote :

I would prefer via right-click.

Changed in gtg:
milestone: 0.2 → 0.3
Revision history for this message
Jonathan Lange (jml) wrote :

I just filed a bug for this that describes the problem without specifying a solution. I've marked it as a dupe, but it might be useful to refer to it when fixing this bug.

Matthew Rasmus (mrasmus)
Changed in gtg:
assignee: nobody → Matthew Rasmus (mrasmus)
Revision history for this message
Matthew Rasmus (mrasmus) wrote :

I'm going to see what I can do with this. The way I'm visualizing it right now, you should be able to right click on a task and click on a context menu item "Apply new tag" (or something to that effect). Doing this would bring up a dialog asking for the name of the new tag, and a checkbox option "Apply to subtasks" (it should also complain if you try to enter in something invalid). Eventually it would be nice to have a tag submenu in which you could create or assign a tag through the right click menu (although perhaps it wouldn't even be necessary, since we have drag and drop tagging now--I'm just thinking out loud now).

Revision history for this message
Jonathan Lange (jml) wrote : Re: [Bug 339188] Re: Be able to add tag from main treeview

On Wed, Jan 6, 2010 at 10:41 AM, Matthew Rasmus <email address hidden> wrote:
> I'm going to see what I can do with this. The way I'm visualizing it
> right now, you should be able to right click on a task and click on a
> context menu item "Apply new tag" (or something to that effect).

That makes sense, but remember that mouse operations are for people
with spare time -- it would be good to have keyboard bindings for this
right from the start.

For example, in GMail, the 'L' key pulls up the label menu, you can
then *immediately* start typing the name of the tag, which will
autocomplete. For many of my tags, I just type 'L @ A <RET>' and I'm
done -- no mouse at all.

> Doing
> this would bring up a dialog asking for the name of the new tag,

Yeah, I think you have to have a dialog. If you do, it'd be nice if it
did auto-completion.

> and a
> checkbox option "Apply to subtasks" (it should also complain if you try
> to enter in something invalid).

You might not need this now, given that the taskbrowser is multi-select.

> Eventually it would be nice to have a
> tag submenu in which you could create or assign a tag through the right
> click menu (although perhaps it wouldn't even be necessary,  since we
> have drag and drop tagging now--I'm just thinking out loud now).

Maybe. I think it's worth getting an initial implementation up and see
what looks good.

jml

Revision history for this message
Matthew Rasmus (mrasmus) wrote :

I have a branch going with a very basic solution to this. Right now it will allow you to right click a task (or multiple tasks), select "Add Tag," and bring up a dialog that lets you input a tag. There are still plenty of things that need to be done before I feel this feature is ready, but since it _technically_ fixes this bug in its current state I figured I'd post this.

Revision history for this message
Bertrand Rousseau (bertrand-rousseau) wrote :

Looks nice! Thanks for coding this! Some suggestions:

 - menu item: Could you insert three dots "..." a the end of "Add a
Tag" to tell the user that it will require interaction with a dialog?
could you add an icon as well?
 - dialog: maybe you could add a label saying "Type in the tag you
want to add:". I also think you can drop the interrogation mark at the
end of "Apply to subtask?".One last thing: could you change the label
"Ok" from the button to something like "Add tag", to be more
HIG-compliant?

Thanks a lot!

On Thu, Jan 7, 2010 at 3:00 AM, Matthew Rasmus <email address hidden> wrote:
> I have a branch going with a very basic solution to this. Right now it
> will allow you to right click a task (or multiple tasks), select "Add
> Tag," and bring up a dialog that lets you input a tag. There are still
> plenty of things that need to be done before I feel this feature is
> ready, but since it _technically_ fixes this bug in its current state I
> figured I'd post this.
>
> --
> Be able to add tag from main treeview
> https://bugs.launchpad.net/bugs/339188
> You received this bug notification because you are subscribed to Getting
> Things GNOME!.
>

--
Bertrand Rousseau

Revision history for this message
Matthew Rasmus (mrasmus) wrote :

Thanks for the suggestions, I'll add these to my todo list. ;)

Revision history for this message
Kevin Mehall (kevin-mehall) wrote :

Another option: What if instead of a dialog, you added a tag named New and then triggered a rename on it. This is how Nautilus and the GTK file chooser handle new folder creation. It would be cleaner than a dialog IMHO, but you lose the ability to ask whether to apply the tag to subtasks. Just a thought.

Revision history for this message
Matthew Rasmus (mrasmus) wrote :

Kevin Mehall wrote:
> Another option: What if instead of a dialog, you added a tag named New
> and then triggered a rename on it. This is how Nautilus and the GTK file
> chooser handle new folder creation. It would be cleaner than a dialog
> IMHO, but you lose the ability to ask whether to apply the tag to
> subtasks. Just a thought.
>

If the dialog's sole purpose was to create new tags, I'd agree, but
through the dialog you should also be able to add existing tags to a
task, and add multiple tags at once. I'm not sure that this sort of
functionality would make sense with the type of solution you're talking
about. Maybe there's something that combines the best of both worlds?

Revision history for this message
Jonathan Lange (jml) wrote :

On Fri, Jan 8, 2010 at 12:42 PM, Matthew Rasmus <email address hidden> wrote:
> Kevin Mehall wrote:
>> Another option: What if instead of a dialog, you added a tag named New
>> and then triggered a rename on it. This is how Nautilus and the GTK file
>> chooser handle new folder creation. It would be cleaner than a dialog
>> IMHO, but you lose the ability to ask whether to apply the tag to
>> subtasks. Just a thought.
>>
>
> If the dialog's sole purpose was to create new tags, I'd agree, but
> through the dialog you should also be able to add existing tags to a
> task, and add multiple tags at once. I'm not sure that this sort of
> functionality would make sense with the type of solution you're talking
> about. Maybe there's something that combines the best of both worlds?
>

How about copying the interface that Launchpad uses for tagging bugs?
In-line tags, with auto-complete for existing tags.

jml

Revision history for this message
Matthew Rasmus (mrasmus) wrote :

Jonathan Lange wrote:
>
> How about copying the interface that Launchpad uses for tagging bugs?
> In-line tags, with auto-complete for existing tags.
>
> jml
>

I think something like that would probably be the best way to go. For
now, I'll finish the dialog stuff--most of the code in that should still
be useful--and then I'll start experimenting with a more in-line solution.

Revision history for this message
Matthew Rasmus (mrasmus) wrote :

The dialog is mostly finished now. There's an issue where autocomplete will suggest "tg-tags-sep" for anything beginning with "t", and autocomplete will only work on the first tag if you're trying to add more than one at once (I'm not familiar enough with GTK to know what the alternatives are for EntryCompletion, but I'll start poking around the documentation tomorrow). Those issues aside, it seems to be working nicely, at least from my testing.

Revision history for this message
Bertrand Rousseau (bertrand-rousseau) wrote :

It's nice to have autocompletion! I could not succeed in having tags
that are children from others to autocomplete however, maybe a GtkTree
issue. Thanks also for putting an icon in the contextual menu. Could
you check its size? It seems to me that it is bigger than the other
icons. I saw that you add a shortcut too, good idea! One last thing:
the label is a bit verbose, maybe you could just put "Type in the
tag(s) you want to add below:" and have a dark greyed-out label under
the input with "Hint: you can add several tags by separating them with
a comma." Thanks again!

On Sat, Jan 9, 2010 at 11:00 PM, Matthew Rasmus <email address hidden> wrote:
> The dialog is mostly finished now. There's an issue where autocomplete
> will suggest "tg-tags-sep" for anything beginning with "t", and
> autocomplete will only work on the first tag if you're trying to add
> more than one at once (I'm not familiar enough with GTK to know what the
> alternatives are for EntryCompletion, but I'll start poking around the
> documentation tomorrow). Those issues aside, it seems to be working
> nicely, at least from my testing.
>
> --
> Be able to add tag from main treeview
> https://bugs.launchpad.net/bugs/339188
> You received this bug notification because you are subscribed to Getting
> Things GNOME!.
>

--
Bertrand Rousseau

Revision history for this message
Matthew Rasmus (mrasmus) wrote :

I _think_ this is ready to go. :)

tags: added: toreview
Changed in gtg:
status: Confirmed → Fix Committed
tags: removed: toreview
Changed in gtg:
milestone: 0.3 → 0.2.2
Changed in gtg:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.