emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Time zone support for agenda item timestamps
@ 2011-04-09 10:23 Matt Curtis
  2011-04-09 15:54 ` Michael Brand
  2011-06-26 18:28 ` David Maus
  0 siblings, 2 replies; 3+ messages in thread
From: Matt Curtis @ 2011-04-09 10:23 UTC (permalink / raw)
  To: emacs-orgmode

Hello,

I would like agenda timestamps to support time zones somehow, and I'm after
some guidance from org-mode developers.

My plan is to support the time offset +HHMM or -HHMM, at a minimum.

After looking at the code I believe I need to modify org-agenda-get-timestamps
quite heavily to effect this change.

Currently it looks like it scans for timestamps which match the search date
(YYYY-MM-DD), which would need to be changed to at least match adjacent
days, and then filtered after applying the time zone offset, and
finally adjusted
with the offset to match local time.

This would mean the agenda/list displays would get the same sort of results
set, as the timestamps would be adjusted back to the search date - i.e. the
search date would be considered "local time"; the change is to consider the
offset when figuring out which items fall on this date.

I have a couple of questions:

* Is this a reasonable approach? (It would slow down agenda generation
with the extra scanning and filtering)

* If not, is there another design I can look at? (I wonder why this hasn't been
done before, so I think maybe others have done some thinking about it.)

* What parts of org-mode should I be looking at to ensure this change does
not cause a regression?

cheers,
Matt

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Time zone support for agenda item timestamps
  2011-04-09 10:23 Time zone support for agenda item timestamps Matt Curtis
@ 2011-04-09 15:54 ` Michael Brand
  2011-06-26 18:28 ` David Maus
  1 sibling, 0 replies; 3+ messages in thread
From: Michael Brand @ 2011-04-09 15:54 UTC (permalink / raw)
  To: Matt Curtis; +Cc: emacs-orgmode

Hi Matt

I know only of an old thread about this
http://thread.gmane.org/gmane.emacs.orgmode/5145

Of course it would be very welcome and valuable for e. g. traveling
but I fear it is now too expensive to introduce. The trouble I see is
that the smallest possible first change has to include already almost
all of the work to be done in order to not break any of the many
things that are supported now and to hold on with backwards
compatibility. I hope that there are ideas that I can not imagine now,
how this could be broken down into reasonable parts.

Michael


On Sat, Apr 9, 2011 at 12:23, Matt Curtis <matt.r.curtis@gmail.com> wrote:
> Hello,
>
> I would like agenda timestamps to support time zones somehow, and I'm after
> some guidance from org-mode developers.
>
> My plan is to support the time offset +HHMM or -HHMM, at a minimum.
>
> After looking at the code I believe I need to modify org-agenda-get-timestamps
> quite heavily to effect this change.
>
> Currently it looks like it scans for timestamps which match the search date
> (YYYY-MM-DD), which would need to be changed to at least match adjacent
> days, and then filtered after applying the time zone offset, and
> finally adjusted
> with the offset to match local time.
>
> This would mean the agenda/list displays would get the same sort of results
> set, as the timestamps would be adjusted back to the search date - i.e. the
> search date would be considered "local time"; the change is to consider the
> offset when figuring out which items fall on this date.
>
> I have a couple of questions:
>
> * Is this a reasonable approach? (It would slow down agenda generation
> with the extra scanning and filtering)
>
> * If not, is there another design I can look at? (I wonder why this hasn't been
> done before, so I think maybe others have done some thinking about it.)
>
> * What parts of org-mode should I be looking at to ensure this change does
> not cause a regression?

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Time zone support for agenda item timestamps
  2011-04-09 10:23 Time zone support for agenda item timestamps Matt Curtis
  2011-04-09 15:54 ` Michael Brand
@ 2011-06-26 18:28 ` David Maus
  1 sibling, 0 replies; 3+ messages in thread
From: David Maus @ 2011-06-26 18:28 UTC (permalink / raw)
  To: Matt Curtis; +Cc: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 1412 bytes --]

At Sat, 9 Apr 2011 20:23:38 +1000,
Matt Curtis wrote:
>
> Hello,
>
> I would like agenda timestamps to support time zones somehow, and I'm after
> some guidance from org-mode developers.

Nothing Org mode specific but with regards to the problem of
representing time I recently stumbled across Erik Naggum's essay

"The Long, Painful History of Time"

http://naggum.no/lugm-time.html

ABSTRACT The programming language Common Lisp offers a few functions
to support the concept of time as humans experience it, including
GET-UNIVERSAL-TIME, ENCODE-UNIVERSAL-TIME, DECODE-UNIVERSAL-TIME, and
GET-DECODED-TIME. These functions assume the existence of a timezone
and a daylight saving time regime, such that they can support the
usual expression of time in the environment in which a small number of
real-life applications run. The majority of applications, however,
need more support to be able to read and write dates and times,
calculate with time, schedule events at specific clock times daily,
and work with several time zones and daylight saving time
regimes. This paper discusses some of the problems inherent in
processing time suitable to humans and describes a solution employed
by the author in a number of applications, the LOCAL-TIME concept.

Maybe this might give a clue on the "somehow" part.

Best,
  -- David
--
OpenPGP... 0x99ADB83B5A4478E6
Jabber.... dmjena@jabber.org
Email..... dmaus@ictsoc.de

[-- Attachment #2: Type: application/pgp-signature, Size: 230 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2011-06-26 18:28 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-04-09 10:23 Time zone support for agenda item timestamps Matt Curtis
2011-04-09 15:54 ` Michael Brand
2011-06-26 18:28 ` David Maus

Code repositories for project(s) associated with this inbox:

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).