From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/83942 Path: news.gmane.org!not-for-mail From: Jan Tatarik Newsgroups: gmane.emacs.gnus.general Subject: Re: iCalendar integration - time zone issue Date: Thu, 28 Nov 2013 22:20:47 +0100 Message-ID: <87k3fs2pg0.fsf@nb-jtatarik2.xing.hh> References: <87a9hbdlil.fsf@topper.koldfront.dk> <87mwlao89b.fsf@nb-jtatarik2.xing.hh> <874n7icya4.fsf@topper.koldfront.dk> <87eh6mng2t.fsf@nb-jtatarik2.xing.hh> <87wqkeuglx.fsf@topper.koldfront.dk> <87zjp9n4xv.fsf@nb-jtatarik2.xing.hh> <8761rxv8bt.fsf@topper.koldfront.dk> <87a9gphj2f.fsf@gmail.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: ger.gmane.org 1385868033 3911 80.91.229.3 (1 Dec 2013 03:20:33 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 1 Dec 2013 03:20:33 +0000 (UTC) To: ding@gnus.org Original-X-From: ding-owner+M32197@lists.math.uh.edu Sun Dec 01 04:20:33 2013 Return-path: Envelope-to: ding-account@gmane.org Original-Received: from util0.math.uh.edu ([129.7.128.18]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1VmxaB-0001dk-Up for ding-account@gmane.org; Sun, 01 Dec 2013 04:20:32 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.math.uh.edu) by util0.math.uh.edu with smtp (Exim 4.63) (envelope-from ) id 1VmxZ9-0001cX-H6; Sat, 30 Nov 2013 21:19:27 -0600 Original-Received: from mx2.math.uh.edu ([129.7.128.33]) by util0.math.uh.edu with esmtps (TLSv1:AES256-SHA:256) (Exim 4.63) (envelope-from ) id 1Vm91H-0005av-D8 for ding@lists.math.uh.edu; Thu, 28 Nov 2013 15:21:07 -0600 Original-Received: from quimby.gnus.org ([80.91.231.51]) by mx2.math.uh.edu with esmtps (TLSv1:AES128-SHA:128) (Exim 4.76) (envelope-from ) id 1Vm917-00060h-16 for ding@lists.math.uh.edu; Thu, 28 Nov 2013 15:21:07 -0600 Original-Received: from mail-bk0-f48.google.com ([209.85.214.48]) by quimby.gnus.org with esmtp (Exim 4.80) (envelope-from ) id 1Vm915-0002ue-9p for ding@gnus.org; Thu, 28 Nov 2013 22:20:55 +0100 Original-Received: by mail-bk0-f48.google.com with SMTP id v10so4009254bkz.35 for ; Thu, 28 Nov 2013 13:20:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:subject:references:date:in-reply-to:message-id:user-agent :mime-version:content-type; bh=Tdv3nk0vsORcMkahC3WB5G6LFkoOiRXHlaH0YsnmZo4=; b=IkPJOfIwNz62JnsPPFGpVO2k9e5/86FdCSoG2Pf8su9rzEtUzX9D20O5rx2pXUG0e6 e0ttWr0k46fe0qVEMZdewMyFM0XdRB724ZMQbe8P5sEU4tz4D8V5tSy5seadsSyMG9QA oPI2EL2vvfQ36bolOG9iwuCTVYS7MRn9KWUJMTO76Mg42e9V9o2fY5qSNFRTv8CbB+N5 XbVLGDylduvwJG0o7jHc8oFDvubeS7tXwjdFr44Qbb5AEljJbvDaIwNyoxd5v+MmosP5 4o2uDgL/vcTxk7SWRtjwLcK4e66bjPoJZOlR5Jr8Bx3bg5OXboWqykf6ZEsy0IcVpsm/ Zigg== X-Received: by 10.204.200.78 with SMTP id ev14mr13555740bkb.32.1385673649898; Thu, 28 Nov 2013 13:20:49 -0800 (PST) Original-Received: from nb-jtatarik2.xing.hh (f054079226.adsl.alicedsl.de. [78.54.79.226]) by mx.google.com with ESMTPSA id xm9sm4816509bkb.1.2013.11.28.13.20.48 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Thu, 28 Nov 2013 13:20:48 -0800 (PST) In-Reply-To: <87a9gphj2f.fsf@gmail.com> (Mario Peter's message of "Wed, 27 Nov 2013 18:04:56 +0100") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) X-Spam-Score: -3.0 (---) List-ID: Precedence: bulk Xref: news.gmane.org gmane.emacs.gnus.general:83942 Archived-At: --=-=-= Content-Type: text/plain On Wed, Nov 27 2013, Mario Peter wrote: > Hi All, > I have quite the same issue with the following almost all of my > vcalendar attachments. The vcalendar entry below shows up in this way: > Summary: bla > Location: Mobil > Time: <2013-11-28 Thu 10:30-11:30 +1w> > Organizer: > Attendance: Required > Method: REQUEST > Status: Not replied yet > which is wrong and ment to be 1h earlier. > could you help here? Try the enclosed patch. After applying/restarting, customize the gnus-icalendar-custom-tz variable and add the following translation: From: GMT +0100 (Standard) / GMT +0200 (Daylight) To: CET --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=custom_tz.diff diff --git a/lisp/gnus-icalendar.el b/lisp/gnus-icalendar.el index 56c56f3dd466975da7b23edd257058ff63fb8bfd..12455aff8622101eb93f4378b0564c4f8dfcc0fd 100644 --- a/lisp/gnus-icalendar.el +++ b/lisp/gnus-icalendar.el @@ -52,6 +52,22 @@ ;;; ical-event ;;; +(defgroup gnus-icalendar nil + "Settings for inline display of iCalendar invitations." + :group 'gnus-article + :prefix "gnus-icalendar-") + +(defcustom gnus-icalendar-custom-tz nil + "Translate non-standard timezone names. + +Invitations might show with wrong start/end times when the ical +timestamps contain non-standard timezone names. If this happens, +you can tell gnus to translate the timezone name to something +gnus will recognize." + :type '(alist :key-type string :value-type string) + :group 'gnus-icalendar) + + (defclass gnus-icalendar-event () ((organizer :initarg :organizer :accessor gnus-icalendar-event:organizer @@ -143,7 +159,9 @@ (defun gnus-icalendar-event--decode-datefield (ical field) (let* ((date (icalendar--get-event-property ical field)) (date-props (icalendar--get-event-property-attributes ical field)) - (tz (plist-get date-props 'TZID))) + (tzid (plist-get date-props 'TZID)) + (tz (or (cdr (assoc tzid gnus-icalendar-custom-tz)) + tzid))) (date-to-time (timezone-make-date-arpa-standard date nil tz)))) @@ -639,11 +657,6 @@ is searched." ;;; gnus-icalendar ;;; -(defgroup gnus-icalendar nil - "Settings for inline display of iCalendar invitations." - :group 'gnus-article - :prefix "gnus-icalendar-") - (defcustom gnus-icalendar-reply-bufname "*CAL*" "Buffer used for building iCalendar invitation reply." :type '(string) --=-=-=--