Version: 3.5.9 (using KDE 3.5.9) OS: Linux Installed from: Debian testing/unstable Packages As per http://tools.ietf.org/html/rfc2445#page-78, the correct way to represent multiple categories in an iCal file is to have just one CATEGORIES filed, containing possibly multiple entries spearated by a comma. Korganizer incorrectly creates one CATEGORIES field for each category, which makes the resulting iCal file non standard, with lots of problems of interoperability with other tools. The easy fix is to change ONLY the output routines for iCal files, to make sure they produce only one CATEGORIES line with all the categories separated by one comma (this should be just a few lines of changes, but I have unfortunately not the time to set up a full KDE build environment to play with this). I tested that the input routines are able to read proper iCal files with multiple categories in one line, as well as incorrect ones with multiple CATEGORIES entries, so there is no need to change them.
Sorry but you misunderstood the RFC : categories = "CATEGORIES" catparam ":" text *("," text) CRLF catparam = *( ; the following is optional, ; but MUST NOT occur more than once (";" languageparam ) / ; the following is optional, ; and MAY occur more than once (";" xparam) ) Only the 'languageparam' must be unique on each CATEGORIES line (and the catparam is optional). Nothing prevents from using several CATEGORIES lines.
Thank you! I stand corrected, even if not exactly for the reasons you invoke; the relevant section of the RFC that allows multiple instances of the CATEGORIES property is below (I paste it here for future reference). Nevertheless, as the CATEGORIES property allows for encoding multiple values in comma separated form (see also section 4.1.1), producing multiple CATEGORIES lines instead of a single CATEGORIES line is an option, not an obligation. Now, it happens that iCal::Parser only recognizes the first CATEGORIES line in a VEVENT as well as Google Calendar, and possibly many other pieces of software out there. The simple change I suggested would allow to interoperate seamlessly with these tools, whose authors apparently also misunderstood the RFC, while still being perfectly compliant with the RFC. Not making the change is of course perfectly defendable, but will reduce the usability of Korganizer in conjunction with other tools, and it would be a pity to turn users away. So I reopen the bug, and kindly suggest that the compromise solution of reading multiple CATEGORIES lines, but writing only one CATEGORIES line with comma separated values, be considered once again under the light of these considerations before dismissing it. ---------RFC excerpt showing that CATEGORIES can occurr multiple times----- 4.6.1 Event Component Component Name: "VEVENT" Purpose: Provide a grouping of component properties that describe an event. Format Definition: A "VEVENT" calendar component is defined by the following notation: eventc = "BEGIN" ":" "VEVENT" CRLF eventprop *alarmc "END" ":" "VEVENT" CRLF eventprop = *( ; the following are optional, ; but MUST NOT occur more than once class / created / description / dtstart / geo / Dawson & Stenerson Standards Track [Page 52] RFC 2445 iCalendar November 1998 last-mod / location / organizer / priority / dtstamp / seq / status / summary / transp / uid / url / recurid / ; either 'dtend' or 'duration' may appear in ; a 'eventprop', but 'dtend' and 'duration' ; MUST NOT occur in the same 'eventprop' dtend / duration / ; the following are optional, ; and MAY occur more than once attach / attendee / categories / comment / contact / exdate / exrule / rstatus / related / resources / rdate / rrule / x-prop )
I agree and I'll see what I can do in KDE 4. Reassigning to the kdepimlibs product.
SVN commit 990792 by winterz: Write only 1 CATEGORIES property per component, according to RFC. multiple values are comma-separated. We continue to support reading multiple CATEGORIES property per component, for back compat. MERGE: e4 BUG: 171576 M +18 -11 icalformat_p.cpp M +1 -2 tests/data/Compat/KOrganizer_3.1.ics.ical.ref M +1 -2 tests/data/Compat/KOrganizer_3.2.ics.ical.ref WebSVN link: http://websvn.kde.org/?view=rev&revision=990792
Great news, let me thank you wholeheartedly: this will improve the workflow of several people her (as soon as we deploy the new version) >>>>> "Allen" == Allen Winter <winter@kde.org> writes: Allen> https://bugs.kde.org/show_bug.cgi?id=171576 Allen Winter Allen> <winter@kde.org> changed: Allen> What |Removed |Added Allen> ---------------------------------------------------------------------------- Allen> Status|UNCONFIRMED |RESOLVED Resolution| |FIXED Allen> --- Comment #4 from Allen Winter <winter kde org> 2009-07-03 12:46:24 Allen> --- SVN commit 990792 by winterz: Allen> Write only 1 CATEGORIES property per component, according to RFC. Allen> multiple values are comma-separated. Allen> We continue to support reading multiple CATEGORIES property per Allen> component, for back compat. Allen> MERGE: e4 BUG: 171576 Allen> M +18 -11 icalformat_p.cpp M +1 -2 Allen> tests/data/Compat/KOrganizer_3.1.ics.ical.ref M +1 -2 Allen> tests/data/Compat/KOrganizer_3.2.ics.ical.ref Allen> WebSVN link: http://websvn.kde.org/?view=rev&revision=990792 Allen> -- Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email Allen> ------- You are receiving this mail because: ------- You are on the Allen> CC list for the bug. You reported the bug.
You're welcome. Thanks for the kind words. I haven't decided yet if I will put this into KDE 4.3 (due out in a few weeks). Currently, the fix is in KDE 4.4 only. Problem is: 4.3 is in release candidate mode and we shouldn't be introducing stuff that could possibly lead to regressions. So I'm not sure.
No problem, I can wait :-) >>>>> "Allen" == Allen Winter <winter@kde.org> writes: Allen> https://bugs.kde.org/show_bug.cgi?id=171576 --- Comment #6 from Allen Allen> Winter <winter kde org> 2009-07-03 12:57:59 --- You're welcome. Allen> Thanks for the kind words. Allen> I haven't decided yet if I will put this into KDE 4.3 (due out in a Allen> few weeks). Currently, the fix is in KDE 4.4 only. Allen> Problem is: 4.3 is in release candidate mode and we shouldn't be Allen> introducing stuff that could possibly lead to regressions. So I'm Allen> not sure. Allen> -- Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email Allen> ------- You are receiving this mail because: ------- You are on the Allen> CC list for the bug. You reported the bug.
SVN commit 997499 by tmcguire: Crossport r990792 by winterz from trunk to the enterprise4 branch: Write only 1 CATEGORIES property per component, according to RFC. multiple values are comma-separated. We continue to support reading multiple CATEGORIES property per component, for back compat. MERGE: e4 CCBUG: 171576 M +18 -11 icalformat_p.cpp M +1 -2 tests/data/Compat/KOrganizer_3.1.ics.ical.ref M +1 -2 tests/data/Compat/KOrganizer_3.2.ics.ical.ref WebSVN link: http://websvn.kde.org/?view=rev&revision=997499