Issue 59646 - Number format code with trailing quoted separator (text) loaded unquoted
Summary: Number format code with trailing quoted separator (text) loaded unquoted
Alias: None
Product: Calc
Classification: Application
Component: formatting (show other issues)
Version: OOo 2.0
Hardware: All All
: P5 (lowest) Trivial (vote)
Target Milestone: ---
Assignee: AOO issues mailing list
QA Contact:
Keywords: oooqa
Depends on:
Reported: 2005-12-21 15:53 UTC by aukejan
Modified: 2017-05-20 11:13 UTC (History)
3 users (show)

See Also:
Latest Confirmation in: ---
Developer Difficulty: ---


Note You need to log in before you can comment on or make changes to this issue.
Description aukejan 2005-12-21 15:53:33 UTC
I have created a sheet with a numbered list like
1. item a
2. item b
3. etc.

The numbers are in column 1; the item description in column 2. I have formatted
column 1 using the format codes: '0"."' or '0\.' (excluding the single parentheses).

When I save the sheet and reopen it, the (double) parentheses or the backslash
has disappeared, leaving only '0.'. All cells in column 1 seem to contain zeros.
Comment 1 lars 2005-12-21 19:05:33 UTC
cannot reproduce with OOo 2.0.1 RC5; can you give a step-by-step description 
with which to reproduce the problem? and try the latest version
Comment 2 aukejan 2005-12-24 15:04:16 UTC
You are correct. I cannot reproduce the problem with 2.0.1 either. The
parentheses do still disappear, but with formatting codes '0.' OOo Calc now
shows the numbers in the correct format (i.e. with a full stop next to the
number) whereas OOo 2.0.0 showed only zeroes.
Comment 3 lars 2005-12-24 16:18:50 UTC
what do you mean by "The parentheses do still disappear". For me the number 
code 0"." is preserved. 0\. however is not, it is replaced by the former.
Comment 4 aukejan 2005-12-25 12:10:15 UTC
When I enter formatting codes '0"."' save, close and reopen the spreadsheet, the
remaining formatting codes are '0.' without parentheses and without a backslash.
When I enter '0\.', also the backslash disappears (leaving '0.'). When I enter
'0.0" m"', everything stays as it is entered.

I tested this with the released version 2.0.1. The tar file contains files like
Comment 5 frank 2006-02-01 11:59:54 UTC
Hi Eike,

please have a look.

Comment 6 ooo 2006-02-01 14:06:42 UTC
This needs some explanation:

In the ODF file format we don't store the number format code, we store
a description of the format instead. A literal escaped character \c
behaves equal to a literal quoted character "c". Stored in the file
format is the text >c<, which upon loading gets quoted as "c" for the
format code. For the display result it makes no difference.

The observation that a trailing escaped decimal separator as in 0\. is
loaded as 0. is a special case. A single trailing separator character,
if not the group AKA thousand separator that devides by 1000, is treated
always as literal. Here OOo2.0.0 had a bug that the separator was not
stored as text, resulting in a broken format after load. This was fixed
for OOo2.0.1.

I'm taking this issue here as a reminder that we could implement
a different behavior differentiating between separators and text in
certain cases. This is not a defect and not urgent, changing type to
enhancement, lowering priority, adjusting summary.
Comment 7 Marcus 2017-05-20 11:13:49 UTC
Reset assigne to the default "".