| Summary: | Cannot copy formula by copying cell when displaying with Show Formula | ||
|---|---|---|---|
| Product: | LibreOffice | Reporter: | Shinji Enoki <shinji.enoki> |
| Component: | Calc | Assignee: | Heiko Tietze <heiko.tietze> |
| Status: | VERIFIED FIXED | ||
| Severity: | normal | CC: | buzea.bogdan, heiko.tietze, ktopyes, stephane.guillou |
| Priority: | medium | ||
| Version: | 7.5.3.2 release | ||
| Hardware: | All | ||
| OS: | All | ||
| See Also: | https://bugs.documentfoundation.org/show_bug.cgi?id=159871 | ||
| Whiteboard: | target:24.2.0 inReleaseNotes:24.2 | ||
| Crash report or crash signature: | Regression By: | ||
| Bug Depends on: | |||
| Bug Blocks: | 108253, 108844 | ||
|
Description
Shinji Enoki
2023-07-18 14:18:44 UTC
Also in recent LO Dev 24.2. The state of Tools->Options->Calc->View->Formulas [1] is sticky and not affected by View->Formulas or Ctrl+` shortcut [2]. i.e. if [1] is off always the value is copy-pasted, even when toggling [2], and if [1] is on always the formula is copy-pasted, also when toggling [2]. I really don't know if that is on purpose, but if it is then it should be documented. (I _can_ imagine it could come handy in certain scenarios, and [2] is only View ...). I think that documentation should be improved in this regard. The current documentation seems to imply that these are equivalent (or at least it gives that impression to a common reader, perhaps unwillingly). https://help.libreoffice.org/7.6/en-US/text/scalc/guide/formula_value.html?&DbPAR=SHARED https://help.libreoffice.org/7.6/en-US/text/shared/optionen/01060100.html?&DbPAR=SHARED When checking ON the menu View > Show Formula item, then also the Options entry gets immediately checked ON, but then [CTRL]+[C] acts as if the latter was OFF. This part seems somewhat inconsistent with comment 2. Is this behavior a bug, or intentional? Perhaps better documentation + better tool-tips + some modification in the name of the Option is also needed(?). Or maybe the current Options checkbox should rather be 2; one main checkbox and one sub-checkbox, with the second being equivalent to the current menu View > Show formula. (In reply to ady from comment #3) > When checking ON the menu View > Show Formula item, then also the Options > entry gets immediately checked ON To be clear, from the POV of how these _look_, they seem equivalent: setting either of them ON (or OFF) immediately sets the other ON (or OFF) too. The resulting behavior, as reported here, is not actually the same. a) both paste the value when formula is shown b) both paste the formula when formula is shown c) view > show formula and options > formula is labelled differently My take is b) -> WYSIWYG. (In reply to Heiko Tietze from comment #5) > a) both paste the value when formula is shown > b) both paste the formula when formula is shown > c) view > show formula and options > formula is labelled differently > > My take is b) -> WYSIWYG. +1 to b) Since the formula is displayed, I think it is natural that it is copied (In reply to Heiko Tietze from comment #5) > c) view > show formula and options > formula is labelled differently While it would seem intuitive for users to understand both settings as equivalent (i.e. option "b"), it is still not clear what was supposed to be the original intention of the two alternatives. Currently, they are labeled the same while they are not performing the same; so what was supposed to be the intention / use-case for each of the two actions? IOW, is there a bug (i.e. they were supposed to be the same), or are we missing something (i.e. they were not intended to be the same)? FID_TOGGLEFORMULA in sc/source/ui/view/tabvwsh3.cxx for the menu command and VOPT_FORMULAS in sc/inc/viewopti.hxx for the option Both are closely entangled (and I don't see a reference when it was implemented). Restarting the application does the trick and you copy/paste the formula -- but switching back via the command still copy/pastes the formula and a restart is needed again. One solution is to commit the modifications properly. Likely per rDoc.SetViewOptions( aViewOpt ); May I ask... why is this now suddenly set as fixed? What "fixed" it? Is this a documentation-only issue? Is it a UI issue? An implementation error issue? A mix of these? Is there any commit or patch (or more than one) that "fixed" this bug 156357 somewhere? Heiko Tietze committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/27fa859bb85ba7ac5b8cb22db5ae85750c7effba Resolves tdf#156357 - Submit Show Formula to document It will be available in 24.2.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback. (In reply to ady from comment #9) > May I ask... why is this now suddenly set as fixed? Mistakenly closed the ticket while the patch still was on review. No feedback within two weeks, let's have the user test it. *** Bug 159338 has been marked as a duplicate of this bug. *** Piotr added it to the release notes, with a gif: https://wiki.documentfoundation.org/index.php?title=ReleaseNotes%2F24.2&type=revision&diff=739956&oldid=739882 Verified in: Version: 24.8.0.0.alpha0+ (X86_64) / LibreOffice Community Build ID: d2fa44db6f8a1badece63856ee0f12db4cba9b28 CPU threads: 8; OS: Linux 6.5; UI render: default; VCL: gtk3 Locale: en-AU (en_AU.UTF-8); UI: en-US Calc: threaded Thanks Heiko, it's great to be able to paste into Writer with Unformatted Text now. |