Created attachment 193911 [details] Screencast If you edit a cell and type an incomplete formula, e.g. `=-5 *` then click a cell, Calc will paste the cell's address at the cursor in the formula, e.g. `=-5 * A3`. If you edit a cell that contains a negative number, e.g. `-5` and add `* 2`, Calc will correctly interpret that as a formula, `-5 * 2`. But if you edit a cell consisting of a negative number, type an operator (e.g. `-5 * `), then click another cell, Calc won't paste that cell's address. Please see the attached screencast, recorded with the attached spreadsheet. Version: 24.2.0.3 (X86_64) / LibreOffice Community Build ID: da48488a73ddd66ea24cf16bbc4f7b9c08e9bea1 CPU threads: 20; OS: Linux 6.7; UI render: default; VCL: kf5 (cairo+wayland) Locale: en-US (en_US.UTF-8); UI: en-US Calc: threaded
Created attachment 193912 [details] Spreadsheet to reproduce the bug
IMHO, there are enough issues with unary operators. If the cell contains a simple negative numeric value and users want to modify the cell to contain instead a formula, then the initial equal sign should also be (manually) added by the user. That's just my personal subjective opinion. Having Calc guessing the user's intention is nice, until each user wants the guess to be different. That's how we (users) get the "initial sometimes-hidden apostrophe" (which some users are unaware of, or don't understand its meaning), or "why this column in my csv file is imported as text instead of as numbers", or the exact opposite reports/questions. Now, if the request from comment 0 (to automatically add the equal sign when the user modifies a simple negative/positive numeric value, turning it into what could probably be interpreted as a formula), then all sorts of regression tests should be added too, in order to reduce follow-ups such as "my csv is imported differently now", or, if some other behavior is modified as a consequence, it should be clearly described too (instead of finding out just by chance, in the best case). If this behavior is implemented, it would mean that instead of the current suggestion (i.e. adding the apostrophe and changing the value from numerical to text), the new behavior would silently skip any suggestion and would automatically add the initial equal sign, turning the cell into a formula. When there is no additional operator edited, clicking on another cell should leave the original cell without change and the clicked-on cell would be the new active cell. This is the current behavior and should not change. Please note that the reported behavior happens not only with negative values, but with any numerical value. Please also note that the reported behavior happens only when editing existing numerical values. When the cell has no prior content (and it is not pre-formatted as text), then the initial equal sign is indeed automatically added when clicking on some other cell.
(In reply to ady from comment #2) > If this behavior is implemented, it would mean that instead of the current > suggestion (i.e. adding the apostrophe and changing the value from numerical > to text), the new behavior would silently skip any suggestion and would > automatically add the initial equal sign, turning the cell into a formula. I would like to suggest, if the request from comment 0 is implemented, instead of being silently and automatically converted into a formula, that a suggestion should still be presented, as it is currently the case (just with a different suggestion, converting the cell into a formula rather than into a text cell). A silent and automatic action would allow mistakes that would not be easy to spot in real time, especially when the current behavior would stop such mistake.
The equal sign triggers the formula likewise minus and plus as a convenience feature. See also bug 132026 (in particular c3 and c17). => NAB