Bug 133207 - LibreOffice Calc not saving cell fill-color
Summary: LibreOffice Calc not saving cell fill-color
Status: RESOLVED WORKSFORME
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
6.3.2.2 release
Hardware: All All
: medium minor
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-05-20 21:12 UTC by rhacer
Modified: 2020-05-21 16:23 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description rhacer 2020-05-20 21:12:16 UTC
Description:
FILESAVE, FORMATTING

I just:
1) changed the cell fill color on multiple cells (different colors each cell)
2) saved the file 
3) closed the program.
4) reopened the file
5) Found the cell fill color missing

Possible explanations:
Libre Office not save data for cells with no data in them?  (I colored the cells, but entered no data)


Steps to Reproduce:
1) changed the cell fill color on multiple cells (different colors each cell)
2) saved the file 
3) closed the program.
4) reopened the file
5) Found the cell fill color missing

Actual Results:
The cells I had changed were no longer filled with the fill-colors I had chosen

Expected Results:
The cells should have the color selected for fill-color when the file is reloaded.
Changing the fill-color of a cell IS data and work.  I shouldn't have to redo it?
Adding text to the cell is a workaround, though it is an extra step.


Reproducible: Always


User Profile Reset: No



Additional Info:
Version: 6.3.2.2 (x64)
Build ID: 98b30e735bda24bc04ab42594c85f7fd8be07b9c
CPU threads: 24; OS: Windows 10.0; UI render: default; VCL: win; 
Locale: en-US (en_US); UI-Language: en-US
Calc: CL
Comment 1 V Stuart Foote 2020-05-20 21:55:19 UTC
What document format are you saving out to? ODF calc .ODS, or OOXML excel .XLSX?
Comment 2 rhacer 2020-05-20 21:59:48 UTC
.ODS
I know I mentioned that, but must have removed it when editing/proofreading my submission. Apologies.
Comment 3 rhacer 2020-05-20 22:24:24 UTC
Btw, I can see how this may open a huge can of worms.  The program may be in the midst of a catch-22.

Specifically, the current behavior appears to be:
If data is present in cell > write out data and metadata
Else > write nothing

If this were changed to...
If data OR metadata is present in cell > write out data and metadata
Else > write nothing

... you'd have worse headaches.

In the latter case, the following steps...

1) Enter some data in a few cells.
2) Select All
3) Change cell formatting on selected cells
4) Save the file

... would result in EVERY cell currently in memory being written out creating unnecessarily large files.

I can think of other solutions, but all come with similar complications except 1:
Have a flag on each cell in memory that only changes if:
1) Data is entered
2) Metadata is changed while Select All is not "on"

But that's just off the top of my head and may have other undesirable results.

As I said, I found a workaround, so I lowered the importance, but I'll be interested to learn what you find out.

Thanks.
Comment 4 rhacer 2020-05-21 03:09:52 UTC
Complication...

Changing a fill color on an empty cell makes the save button in the tool bar indicate there are "unsaved changes" (the little red dot appears)

So you have a choice to make.  Fix the original bug in this post or change the behavior of the save button in the toolbar so it doesn't mislead people into believing it's going to save fill color changes on dataless cells if that's the only change that's been made.

Sorry.  The rabbit hole got a little deeper...
Comment 5 QA Administrators 2020-05-21 03:44:25 UTC Comment hidden (obsolete)
Comment 6 Stéphane Guillou (stragu) 2020-05-21 13:16:47 UTC
I can't seem to reproduce this with:

Version: 6.4.3.2 (x64)
Build ID: 747b5d0ebf89f41c860ec2a39efd7cb15b54f2d8
CPU threads: 8; OS: Windows 10.0 Build 18363; UI render: GL; VCL: win; 
Locale: en-AU (en_AU); UI-Language: en-US
Calc: threaded

Would you mind trying with a more recent version of LibreOffice? 6.4 or the pre-release 7.0
Comment 7 rhacer 2020-05-21 16:07:28 UTC
Problem no longer exists in 6.4.4.2.

Opened file.
Changed fill color in BY5 to green (an empty cell).
Saved file.
Closed program.
Restarted program.
Reloaded file.
Fill color for BY5 was still green.

So we're all good.

Not sure what was up with 6.3.2.2, but no longer matters.
Thanks for your assistance, the both of you.