Bug 112275 - Find & Replace all for cell styles in empty cells shows an empty results window
Summary: Find & Replace all for cell styles in empty cells shows an empty results window
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
(earliest affected) release
Hardware: All All
: medium minor
Assignee: Not Assigned
Keywords: implementationError
Depends on:
Blocks: Find&Replace-Styles
  Show dependency treegraph
Reported: 2017-09-07 14:14 UTC by Emil Tanev
Modified: 2023-12-11 03:14 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:

Results window (104.15 KB, image/png)
2017-09-07 14:14 UTC, Emil Tanev

Note You need to log in before you can comment on or make changes to this bug.
Description Emil Tanev 2017-09-07 14:14:26 UTC
Created attachment 136093 [details]
Results window

Open a new sheet
Open Find/Replace
Check "Cell Styles"
Click Replace all

Issue: A results window is displayed. 
1. It is empty 
2. Its title is Search Results (while the operation was Find/Replace)
Comment 1 Thomas Lendo 2017-09-09 23:54:02 UTC
The Search result window is empty till there is a content in a cell. For me this is a bug because when you search for cell styles you don't search for content.

It's the same window for Find all and Replace all - this is a minor bug or a maybe wanted by the developer.
Comment 2 Buovjaga 2017-09-11 05:41:53 UTC

I think we should ignore the Search Results title for now. Somewhat related are bug 104849 and bug 104871.

The results window was apparently added in 4.2.

Win 10
Build ID: b7cfa1eab1cb1e94f71d6df6612b73f231d0bf92
Comment 3 QA Administrators 2018-09-12 02:38:56 UTC Comment hidden (obsolete)
Comment 4 Stéphane Guillou (stragu) 2020-01-07 06:58:42 UTC
I can reproduce with:

Build ID: 1b6477b31f0334bd8620a96f0aeeb449b587be9f
CPU threads: 8; OS: Linux 4.15; UI render: default; VCL: gtk3; 
Locale: en-AU (en_AU.UTF-8); UI-Language: en-US
Calc: threaded

To me, seeing a "search results" window makes sense, because searching is one part of the whole "Replace All" process: you first need to search and find matches, then replace them.

The issue is that the window show 0 results, and the style has *not* been replaced in the sheet. All the cells still have the "Default" style.

You can also try it with one cell (with no cell selection):

1. Assign the "Accent 1" style to a cell
2. Open Find & Replace
3. Tick "Cell Styles"
4. Find "Accent 1" and replace it with "Bad", for example

Nothing happens. But with all my testing, I get seemingly inconsistent results:

* Sometimes, there are no results but the cell selection has moved to the relevant cells that have the searched style. So they are actually found and given focus, but they are not listed as matches in the search results??
* Sometimes, selecting an area and searching in "Current selection only" gives the expected result: style applied to the matches.
* Sometimes, selecting an area and using Replace All will replace for the whole selection, not the expected matches only.
* Usually, I get 0 results in the "Search results" window, but in some cases, I get one single match (even though there were more cells than that, and Replace All replaced the whole of the selection anyway...).

Looks like there's quite a bit to fix with that!

The behaviour is no different in:

Build ID: 1:6.3.4-0ubuntu0.18.04.1~lo2
CPU threads: 8; OS: Linux 4.15; UI render: default; VCL: gtk3; 
Locale: en-AU (en_AU.UTF-8); UI-Language: en-US
Calc: threaded
Comment 5 Stéphane Guillou (stragu) 2020-01-07 07:44:20 UTC
I noticed that the Search Results window will only list the matched cells that contain text.

I decided to test all different cases for a search and replace of styles, and listed the results in this attachment to bug 112321 : http://bugs.documentfoundation.org/attachment.cgi?id=156978
Comment 6 Stéphane Guillou (stragu) 2021-12-10 21:55:58 UTC
Reproduced with:

Version: / LibreOffice Community
Build ID: 436f14c25ec1847646b953cf13d0db4f7ca3be57
CPU threads: 4; OS: Linux 5.4; UI render: default; VCL: gtk3
Locale: en-AU (en_AU.UTF-8); UI: en-US
Calc: threaded

Changed meta to a more precise one.
Comment 7 QA Administrators 2023-12-11 03:14:33 UTC
Dear Emil Tanev,

To make sure we're focusing on the bugs that affect our users today, LibreOffice QA is asking bug reporters and confirmers to retest open, confirmed bugs which have not been touched for over a year.

There have been thousands of bug fixes and commits since anyone checked on this bug report. During that time, it's possible that the bug has been fixed, or the details of the problem have changed. We'd really appreciate your help in getting confirmation that the bug is still present.

If you have time, please do the following:

Test to see if the bug is still present with the latest version of LibreOffice from https://www.libreoffice.org/download/

If the bug is present, please leave a comment that includes the information from Help - About LibreOffice.
If the bug is NOT present, please set the bug's Status field to RESOLVED-WORKSFORME and leave a comment that includes the information from Help - About LibreOffice.

Please DO NOT

Update the version field
Reply via email (please reply directly on the bug tracker)
Set the bug's Status field to RESOLVED - FIXED (this status has a particular meaning that is not 
appropriate in this case)

If you want to do more to help you can test to see if your issue is a REGRESSION. To do so:
1. Download and install oldest version of LibreOffice (usually 3.3 unless your bug pertains to a feature added after 3.3) from https://downloadarchive.documentfoundation.org/libreoffice/old/

2. Test your bug
3. Leave a comment with your results.
4a. If the bug was present with 3.3 - set version to 'inherited from OOo';
4b. If the bug was not present in 3.3 - add 'regression' to keyword

Feel free to come ask questions or to say hello in our QA chat: https://web.libera.chat/?settings=#libreoffice-qa

Thank you for helping us make LibreOffice even better for everyone!

Warm Regards,
QA Team