Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

A better/faster task deferring feature #244

Closed
nekohayo opened this issue Feb 21, 2020 · 9 comments
Closed

A better/faster task deferring feature #244

nekohayo opened this issue Feb 21, 2020 · 9 comments
Assignees
Labels
enhancement low-hanging-fruit "Easy picks" suitable for new contributors to tackle priority:low

Comments

@nekohayo
Copy link
Member

In 0.3.x, GTG had a "Not today" plugin, that we're supposed to merge into core GTG (as per #222) for what will become 0.4. It added a button toolbar to one-click change the start date of a task to "tomorrow". More generally, GTG also allowed right-clicking on any task in the main window to "Set Start Date" with one of these values:

  • Today
  • Tomorrow
  • Next week
  • Next month
  • Next year
  • Clear start date

Those are reasonably useful, but what I've really wanted all these years is to also have:

  1. A "Custom date" action and to be able to use the task editor's smart date input (which parses various formats in natural* and standardized language, in both the user's locale and English for those who still prefer to use English regardless of their DE's locale; syntax needs to be properly documented as of Update and extend the User Manual, automate publication of a readable online copy #243). I'm not sure how the UI/UX would be exactly for this yet...
  2. Quick dates that take into account the standard work week vs week-end, by providing Friday, Saturday, Sunday and Monday as quick targets, and renaming "Next week" by "Next [current day name]". Because I very very very frequently need to "push tasks to the week-end" or "eh, I'll do that on Monday, no way I can request Person XYZ to act on that this week"

...otherwise I have to double-click to open a task, click to focus the Start Date field, pick next Monday, save, etc. It's not really efficient.

Now, of course, we can imagine that a traditional menu with "Today, Tomorrow, Friday, Saturday, Sunday, Monday, Next Thursday, Next month, Next year, Custom" would get kind of ridiculously overloaded. Some potential ways I can imagine solving all this:

  • Using a multi-columns submenu instead of a single column, to spread/organize those many menu items. I think this is technically feasible in GTK, but not sure anymore.
  • Using a popover or some kind of dialog containing a Gtk Calendar widget AND shortcut buttons for the already existing action menu items (because the Gtk Calendar widget sucks and it's hard to be quick with it as a user). This is the easiest/laziest approach that solves at least part of the issue, and can be a good starting point until a potentially better approach is implemented.
  • A custom (and bigger) calendar "next 5 weeks" (or next two months side by side) representation, with the shortcut buttons too, and a smart parsing GtkEntry input field. This might turn into a pretty crazy thing ;)

Some of those features might already be implemented in the git version, I'm not sure / don't remember... but if they're not, well, this is my user experience wishlist starting point ;)

@nekohayo nekohayo added enhancement priority:low low-hanging-fruit "Easy picks" suitable for new contributors to tackle labels Feb 21, 2020
@ploum
Copy link
Contributor

ploum commented Feb 21, 2020

The goal of "not today" is really to be a simple, one clic action. The goal is to clean your task list so you can end your day with an empty task list.

Anything that requires a choice would completely defeat the purpose of the feature, IMHO.

@nekohayo nekohayo changed the title A better/faster task deferring ("not today") feature A better/faster task deferring feature Feb 21, 2020
@nekohayo
Copy link
Member Author

nekohayo commented Feb 21, 2020

Ah, I think I introduced some confusion with the issue title there... my idea here is to extend the general "Set Start Date" contextual menu feature, not replace the simplicity of the "Not today" button. Though there's also the question of what happens of the "Not today" button in a world of headerbars, but that's not what I was trying to look at here ;)

@diegogangl
Copy link
Contributor

I haven't really used the old plugin, but I've wanting a way to reschedule tasks more easily for a while. Right now I can select some tasks, right-click and change the due date to tomorrow but if I wanted to defer them to say, the end of the week I would need to go task-by-task.

I don't think requiring an extra click is a bad trade if we get something more powerful.

Here's another idea, we add a button in the headerbar (at least for now). That button opens a popup menu with submenus/sections like this:

  • Today (set due date for today)
  • Tomorrow
  • Over the next week (goes to submenu)
    • Wednesday (tomorrow + 1)
    • Thursday
    • Friday
    • Saturday
    • Sunday
    • Next Monday
  • Another date
    • Opens section with a calendar and a text field to pick a date. The text field can take fuzzy dates
  • Clear due date

@diegogangl
Copy link
Contributor

I have this done in the defer_task branch. I couldn't figure out how to do sub-popups, so I settled for a single menu ¯\(ツ)

Here's a demo:
https://drive.google.com/file/d/17nYrz_llb6GZtR-tY9gwcyEd-fDNfVs1/view?usp=sharing

@nekohayo
Copy link
Member Author

This looks like a great improvement already, I'm looking forward to using it!

There's the theoretical question of if the "pick custom date" widget set could be embedded directly in the popover (maybe with a two-columns Grid) to "save one click" I guess, but that might be crowding that UI and complexifying the implementation and I'm not sure how it would work for Accessibility either so... yeah, I think your current implementation is already good for 99.9% of cases ;)

Some suggestions:

  • Those buttons should be set insensitive if no tasks are selected (maybe you already did that, dunno, just making sure), which is something that normally happens when you switch views/tags or ctrl+click a task to deselect it (okay nobody does that, but still ;)
  • Those buttons could have some Gtk Tooltips, "Defer the start date of the selected task(s) to tomorrow" and "Defer the start date of the selected task(s) to another day" (if you want to be extra smart and a pain to translators, you could use ngettext to handle the plural variants)

I also thought of some more things now:

  • The quick "Start Tomorrow" button does not get replaced by the last used deferment value, so maybe we shouldn't have "Tomorrow" in the toolbar's custom deferment date menu thingy, as it becomes redundant? (but for right-click contextual menus, yes it makes sense for "Tomorrow" to be present)
  • Now that I think of it, I'm not sure what is the point of an action to set the start date to "Today"; because today is the present, it's kind of equivalent to "clearing" the start date in practice?

@diegogangl
Copy link
Contributor

diegogangl commented Mar 28, 2020

There's the theoretical question of if the "pick custom date" widget set could be embedded directly in the popover (maybe with a two-columns Grid) to "save one click" I guess, but that might be crowding that UI and complexifying the implementation and I'm not sure how it would work for Accessibility either so... yeah, I think your current implementation is already good for 99.9% of cases ;)

I wanted to do that but I couldn't figure out how to do sub-menus in popups and just went ahead with something easier. We could include it as an improvement for 0.5

Those buttons should be set insensitive if no tasks are selected (maybe you already did that, dunno, just making sure), which is something that normally happens when you switch views/tags or ctrl+click a task to deselect it (okay nobody does that, but still ;)

Good point, done!

Those buttons could have some Gtk Tooltips, "Defer the start date of the selected task(s) to tomorrow" and "Defer the start date of the selected task(s) to another day" (if you want to be extra smart and a pain to translators, you could use ngettext to handle the plural variants)

They had tooltips, except the start tomorrow button (cause I forgot). Fixed too.

The quick "Start Tomorrow" button does not get replaced by the last used deferment value, so maybe we shouldn't have "Tomorrow" in the toolbar's custom deferment date menu thingy, as it becomes redundant? (but for right-click contextual menus, yes it makes sense for "Tomorrow" to be present)

I thought it would look weird to have the sequence of days with one of them missing. But I think I found a nicer solution with separators

Screenshot from 2020-03-28 20-36-07

Now that I think of it, I'm not sure what is the point of an action to set the start date to "Today"; because today is the present, it's kind of equivalent to "clearing" the start date in practice?

You can still use it when sorting by start date in the open pane. I think we should have it for completeness sake, and it might be useful when we add more powerful filtering/sorting later

@nekohayo nekohayo added this to the 0.4 "Work of love" milestone Apr 3, 2020
@nekohayo
Copy link
Member Author

nekohayo commented Apr 3, 2020

Gave it a shot tonight, some UI remarks:

  • Now the right-click "Set Start Date" menu items are not consistent with the entries offered with your new feature in the headerbar; could you harmonize the contextual menus so that they tend to match?
  • Having tried out the UI in practice tonight, I'm not sure the main headerbar toolbar is the right place for the "Do it tomorrow" (or what I'd call simply "Defer"), likewise for the "+" (New task) button. It feels a bit too crowded with the 3 View switcher buttons.
    • My guess is that I'll be suggesting we move both of those to be an inline toolbar below the task treeview (and take the opportunity to add other frequently used contextual actions...). Any opinion on that, should I file a ticket to make that case?

@diegogangl
Copy link
Contributor

The best place would probably be a popup that comes from the rows, or subtoolbar like you are suggesting. But before we do any of those we need to move to listboxes. That's why I added it in the headerbar.

I've also added the start date options to the context menu but I haven't been able to change the labels to reflect the days of the week. Apparently you can't modify a GtkMenuModel and all the menus are coming from .ui files. Another thing to fix once we get to listboxes.

@diegogangl
Copy link
Contributor

Closing since we will tackle this when we move to listboxes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement low-hanging-fruit "Easy picks" suitable for new contributors to tackle priority:low
Projects
None yet
Development

No branches or pull requests

3 participants