Bug 61996

Summary: FORMATTING: user-defined cell formatting fails with semicolon between quotation marks
Product: LibreOffice Reporter: AxelF <bugzilla>
Component: SpreadsheetAssignee: Not Assigned <libreoffice-bugs>
Status: NEW --- QA Contact:
Severity: major    
Priority: high CC: klauspeter.schmitt
Version: 4.0.1.2 release   
Hardware: All   
OS: Windows (All)   
Whiteboard:
i915 platform: i915 features:
Attachments: correct and incorrect cell formatting examples

Description AxelF 2013-03-08 01:49:43 UTC
Created attachment 76139 [details]
correct and incorrect cell formatting examples

Problem description:
--------------------
The cell-formatting parser does not recognize the semicolon inside quotation marks (as string limiter) correctly as string, as the semicolon is also used as separator between positive and negative format information.

Steps to reproduce:
-------------------
a1. Select some cells
a2. Open 'Format cells...' dialogue
a3. Select 'user-defined'
a4. Enter first format code "L#"0"s@";"L#"-0"s@" (with quotation marks)
a5. Click OK
a6. Enter a number (e.g. '123') into one of the formatted cells
a7. Displayed result is 'L#123s@' (= correct)
a8. Enter a negative number (e.g. '-123') into one of the formatted cells
a9. Displayed result is 'L#-123s@' (= correct)

b1. Select some cells
b2. Open 'Format cells...' dialogue
b3. Select 'user-defined'
b4. Enter second format code "L#"0"s;";"L#"-0"s;" ('@' is replaced by ';')
b5. Click OK
b6. Enter a number (e.g. '123') into one of the formatted cells
b7. Displayed result is 'L#123"s' (= incorrect)
b8. Enter a negative number (e.g. '-123') into one of the formatted cells
b9. Displayed result is '"' (= incorrect)

Expected behaviour:
-------------------
User-defined cell formatting of number (e.g. '123') shall lead to output like 'L#123s;' (with 'L#" before the number and 's;' after the number).
Comment 1 Peter Schmitt 2013-03-08 08:04:25 UTC
Comment on attachment 76139 [details]
correct and incorrect cell formatting examples

changed Mime-Type to image/png
Comment 2 Peter Schmitt 2013-03-08 08:09:36 UTC
I can confirm this behaviour also in
Version 3.6.4.3 , German version
on
Windows7x64 Professional SP1
Intel Core i5 CPU, M480@2.67GHz 2.66 GHz
RAM 8 GB (7.8 GB eff.)

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.