GNOME Bugzilla – Bug 346099
more granular time chosing
Last modified: 2009-04-02 02:51:20 UTC
I am lpanning events (more exactly Live Action Role Playing Games). The normal duration of this event is about 2 days with a week of organizing beforehand. During these two days there are many parallel tasks I want to plan. They can only be 10 minutes long and start at a very exact time (maybe midnight). Can you please adjust planner to allow durations passed in minutes/hours and start times not in days but more exact (up to minutes/hours) to allow events to be planned. Thanks a lot for planner Thorsten Sick
Re-assigning to planner. :-)
I'd appreciate the ability to enter hours directly as well (not using fractional days). "1 H" never worked in 0.13 for me...
I'm also interrested in creating task items, with a duration under on hour. Thanks Alexander Wahl
+1 on this feature request.
*** Bug 393740 has been marked as a duplicate of this bug. ***
Hi All. I needed this too - and have just written a patch to resolve it ( it is just a display / unit problem and was very simple to resolve. I will submit shortly for review. Josh
I'm curious to know what you changed. I've always been able to enter times in a number of hours (1h) or even in minutes (30mins).
Created attachment 121524 [details] [review] Diff for planner-format.c
It's the display of minutes which was screwed up. 0.5h does not get shown in the task list - the cell is blank as the code did not cater for minutes. I have augmented planner_format_duration_with_day_length to allow for minutes to be displayed. Also, I added 'm' to the units array to allow the displayed result with minutes to be parsed correctly. If you are happy with my changes and want to commit to trunk, that would be great. Additionally, I'd be happy to lend a hand with any other issues that need looking at. It's a great project. Diff is attached. Josh
Thanks for your patch, Joshua, but there are a few things that need to be changed before I can apply it. 1) The patch is reversed. Create it with diff -ruN planner-svn planner-local instead. That will also use unified diff format, which is the preferred patch format. Running 'svn diff' will do this for you automatically. 2) Make hour_length and minute_length const. 3) Use translated strings for units (see the units array around line 387). The original code wasn't doing this, but you may as well fix that while you're changing it. As you'll see the abbreviation for minutes is actually "min" to prevent ambiguity with the abbreviation for months. 4) Instead of strcatting to a preallocated buffer, use g_strconcat() to create a new string from all parts. Also don't forget to free the strings that are allocated by g_strdup_printf when you're done with them.
*** Bug 568397 has been marked as a duplicate of this bug. ***
Didn't see this bug out here until just now - committed my own patch for this, so this is now resolved.