Bug 149473 - Find and Replace dialog remembers most options, but not all
Summary: Find and Replace dialog remembers most options, but not all
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
7.1.8.1 release
Hardware: x86-64 (AMD64) Windows (All)
: medium enhancement
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Dialog-Remember-Settings Find&Replace-Dialog
  Show dependency treegraph
 
Reported: 2022-06-07 02:44 UTC by guruglenn
Modified: 2023-05-17 10:33 UTC (History)
3 users (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 guruglenn 2022-06-07 02:44:45 UTC
Description:
The options for Match case, formatted display, entire cells, and all sheets are not remembered across exiting and restarting LibreOffice (Calc, at least).

I think they should be.  All the "other options" seem to be remembered.

Steps to Reproduce:
1. Open a spreadsheet, Ctrl-H, tick "All sheets"
2. Close LibreOffice
3. Open a spreadsheet, Ctrl-H

Actual Results:
note that "All sheets" is no longer ticked.

Expected Results:
"All sheets" should remain ticked


Reproducible: Always


User Profile Reset: No



Additional Info:
I know I'm a few versions behind, but am coordinating versions with other people on a project.
Comment 1 Rafael Lima 2022-06-07 16:34:01 UTC
I confirm that the "All sheets" option is not remembered after you close and reopen LO Calc.

Considering that the options under "Other options" are saved across LO sessions, maybe we could save these as well.

Let's hear from the UX team.

System info:
Version: 7.4.0.0.alpha1+ / LibreOffice Community
Build ID: 0f70f4d76b5f68e5b1d81f0e300435ccef893c9a
CPU threads: 16; OS: Linux 5.13; UI render: default; VCL: kf5 (cairo+xcb)
Locale: pt-BR (pt_BR.UTF-8); UI: en-US
Calc: CL
Comment 2 Heiko Tietze 2022-06-09 06:31:09 UTC
Don't see why "All Sheets" should not be remembered.
Comment 3 ady 2023-05-09 10:15:42 UTC
(In reply to Heiko Tietze from comment #2)
> Don't see why "All Sheets" should not be remembered.

Just a minor warning. Users tend to forget to disable options after they enabled them, more frequently than enabling them the firs time.

Therefore, when not selecting multiple sheets, it is common that the "all sheets" checkbox be disabled, so users won't be replacing things by accident in other sheets.

I am just warning that, if this set is remembered, some users will fall into this problem and might request for "all sheets" not to be remember.

FWIW, I am in favor of maintaining the current situation of having to actively select the "all sheets" checkbox every time when only one sheet has the focus.
Comment 4 ady 2023-05-09 10:18:22 UTC
(In reply to ady from comment #3)
> FWIW, I am in favor of maintaining the current situation of having to
> actively select the "all sheets" checkbox every time when only one sheet has
> the focus.

I meant each time after closing the dialog. If the dialog is kept opened, then evidently the checkbox are left as the user selected them.
Comment 5 Andreas Heinisch 2023-05-09 10:30:55 UTC
What do you think about remembering the all sheets checkbox by user session and not by user configuration?
Comment 6 ady 2023-05-09 14:59:26 UTC
(In reply to Andreas Heinisch from comment #5)
> What do you think about remembering the all sheets checkbox by user session
> and not by user configuration?

I'm sorry, user configuration? Is there a user configuration setting to either remember or not the status of this checkbox? If there is, I don't remember it.

As for maintaining the status of this checkbox for the length of the session, I think this is how it works already. Once I set the checkbox ON, it stays that way until I deselect it, whether I close the F&R dialog or not, even when I change to another file.

So, currently, it is not per worksheet, not per window, not per file, but per session. It even remains sticky when Calc is closed but another module (or the start center) is kept open.

It is easier for a user to find out that the checkbox is not set ON and modify it, than to find out (too late) that a replacement was performed on additional worksheets (maybe without noticing at the very same moment, loosing data).

Considering the risk of replacing "text" in all sheets unintentionally (and perhaps even not noticing), I would not make this checkbox stick beyond the current session.

In short, considering how things are currently, and considering the potential risk I mentioned, I would leave the current behavior of the "all sheets" checkbox as it is, per session, going always to OFF every time LO is re-opened.
Comment 7 Andreas Heinisch 2023-05-09 15:34:51 UTC
LO can write a UserItem directly to the local settings of the application, remembering a setting even after closing it.

You are right. The risk is very high that a user may forget about the setting and accidently replaces a search term in all the sheets.

My take is to close the enhancement as WONTFIX.
Comment 8 guruglenn 2023-05-09 18:35:11 UTC
Note, the discussion has all been about the one checkbox I mentioned in "steps to reproduce", but the bug is about 4 checkboxes.

The only downside that has been presented, is the case of "all sheets" together with "replace".  I don't agree with any of the discussion: "replace" only replaces the current instance that was found.  I think that while the discussion mentions the downside of "replace", that there isn't a major downside to "replace", but only to "replace all".

I can see that the "replace all" case could lead to unintentional changes, but here are a couple other ideas to alleviate concern about that particular case, to allow the issue to be addressed by saving the 4 checkboxes that are not presently saved.

1. When "All sheets" is ticked, change the text in the "replace all" button to "replace in all sheets".  When "All sheets" is not ticked, change the text in the "replace all" button to "replace all in this sheet".

2. If the "replace all" button text is not changed as in idea 1, and "all sheets" is ticked, add a popup when replace all is selected, so the user can confirm that they want the replacement in all sheets, or cancel.  Or maybe a third option of "replace in this sheet only" could be added to the popup.
Comment 9 Andreas Heinisch 2023-05-17 10:24:24 UTC
Imho, remembering the "All sheets" checkbox and changing the label of the buttons will change the width of the dialog itself which is not prefered.

There even exists some special cases where checkboxes are not enabled. So at the moment to much uncertainty in order to solve this enhancement request from my side.
Comment 10 Andreas Heinisch 2023-05-17 10:33:09 UTC
Code pointers:

include/unotools/searchopt.hxx
svx/source/dialog/srchdlg.cxx
unotools/source/config/searchopt.cxx