Bug 343331

Summary: Sorting data ignores background colour
Product: [Applications] calligrasheets Reporter: San Zamoyski <san>
Component: generalAssignee: Calligra Sheets (KSpread) Bugs <calligra-sheets-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: inge, san
Priority: NOR    
Version First Reported In: 2.8.1   
Target Milestone: ---   
Platform: Mint (Ubuntu based)   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: sorts but lefts collours

Description San Zamoyski 2015-01-26 14:20:10 UTC
Hi!

I have data in about 400 rows, some of them (whole row) has background with diffrent colours.
When I sort data by one to three columns, they do sort, but colors stays the same.

In example - second row is painted red. Sort data (so row 2. is now 12.). New data on row 2. has red background while 12th does not.

Regards!

Reproducible: Always

Steps to Reproduce:
1. Prepare data. Set background colour for background.
2. Sort data.

Actual Results:  
As i described befor. Data sorts, but colour stays at the same rows.

Expected Results:  
Colours should go with rows!
Comment 1 Inge Wallin 2015-02-02 12:58:52 UTC
Hi San and thanks for your bug report, 

Is the same happening in other spreadsheets like LO calc or Excel?  I think we want to be compatible with what's happening in those spreadsheets. Personally I would have guessed that the cell's value and its style information was separate and that the sort operation only handled the data. But I have never thought much about it.

Also: would it be possible for you to attach a small test file which shows the problem to this bug report?
Comment 2 San Zamoyski 2015-02-23 21:30:21 UTC
Created attachment 91256 [details]
sorts but lefts collours

This file was created in calligra from the beggining.
Comment 3 Justin Zobel 2021-03-09 22:44:09 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.
Comment 4 Tomas Mecir 2021-04-17 15:20:00 UTC
Git commit 0ca31476b194f90d112f53885cfe041061f7fce4 by Tomas Mecir.
Committed on 17/04/2021 at 15:18.
Pushed by mecir into branch 'master'.

properly set the default style isntead of ignoring it - fixes some issues with format copying

M  +7    -3    sheets/StyleStorage.cpp

https://invent.kde.org/office/calligra/commit/0ca31476b194f90d112f53885cfe041061f7fce4