Bug 257228 - week-of-year formatting is not implemented
Summary: week-of-year formatting is not implemented
Status: CONFIRMED
Alias: None
Product: calligrasheets
Classification: Applications
Component: opendocument (show other bugs)
Version: Git
Platform: Unlisted Binaries Linux
: NOR normal
Target Milestone: ---
Assignee: Calligra Sheets (KSpread) Bugs
URL:
Keywords:
: 287812 (view as bug list)
Depends on:
Blocks:
 
Reported: 2010-11-18 11:13 UTC by Jos van den Oever
Modified: 2021-03-09 22:43 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
ODS document showing the problem (7.84 KB, application/vnd.oasis.opendocument.spreadsheet)
2011-12-09 03:55 UTC, Sebastian Sauer
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jos van den Oever 2010-11-18 11:13:48 UTC
Version:           svn (using KDE 4.5.3) 
OS:                Linux

number:week-of-year formatting is not implemented
This type of formatting shows the number of the week for a given date.
Instead kspread currently shows 2010-01-01 type date, i.e. no formatting.

Reproducible: Didn't try

Steps to Reproduce:
Create document in other ODF spreadsheet application or make it by hand.
Use this for formatting style:
   <number:date-style style:name="N85">
      <number:week-of-year/>
    </number:date-style>
Comment 1 Myriam Schweingruber 2011-12-03 09:22:46 UTC
*** Bug 287812 has been marked as a duplicate of this bug. ***
Comment 2 Sebastian Sauer 2011-12-09 03:55:46 UTC
Created attachment 66526 [details]
ODS document showing the problem

Attached document shows the problem. OO.org displays "41" in A1 while we display the full date.
Comment 3 Sebastian Sauer 2011-12-09 04:05:53 UTC
See calligra/libs/odf/KoOdfNumberStyles.cpp:112

} else if (localName == "week-of-year" || localName == "quarter") {
    // ### not supported in Qt
}

So, the reason is that QDate/QDateTime to not support week-of-year in there toString formatting. But QDate::weekNumber does exist. So, the functionality is there but not supported in format-strings :-/
Comment 4 Justin Zobel 2021-03-09 22:43:47 UTC
Thank you for the bug report.

As this report hasn't seen any changes in 5 years or more, we ask if you can please confirm that the issue still persists.

If this bug is no longer persisting or relevant please change the status to resolved.