View Issue Details

IDProjectCategoryView StatusLast Update
0004156ExpressionsFeaturepublic2021-01-07 15:11
ReporteropenBrain Assigned Tohyarion  
PrioritynormalSeverityminorReproducibilityN/A
Status assignedResolutionopen 
Summary0004156: [Spreadsheet] Necessarily use of leading '=' to enter an expression
DescriptionAs is, a spreadsheet cell value tends to be automatically converted to an expression.
Also it creates inconsistent behavior depending on the spreadsheet state
Example reproducing process :
  1. In cell A3, enter text 'A1'
  2. In cell A1, enter value '1000'
  3. In cell A3, delete value then enter again 'A1' => This time it is considered an expression and '1000' value appears
To get a simple consistent behavior, proposed solution is that an expression necessarily shall start with a leading '=' sign.
All other inputs are just considered as user direct entries and displayed as such.

Forum thread
Tagsexpressions, spreadsheet
FreeCAD Information

Activities

hyarion

2020-12-30 17:09

developer   ~0015181

Just for the record, I've created a pull request ( https://github.com/FreeCAD/FreeCAD/pull/4215 ) with a possible solution.

The PR includes a test case for this issue but since numbers are expressions too, requiring '=' for them too didn't feely feel like a good option. Instead I took some creative freedom and allowed simple number inputs such as "1", "1 mm", "1/4", "1m/2m", etc. to be parsed without '='.
More about this can be read in the pull request.

Issue History

Date Modified Username Field Change
2019-10-08 11:28 openBrain New Issue
2019-10-08 11:28 openBrain Tag Attached: expressions
2019-10-08 11:28 openBrain Tag Attached: spreadsheet
2020-12-04 04:22 Kunda1 Project FreeCAD => Expressions
2020-12-30 17:09 hyarion Note Added: 0015181
2021-01-07 15:11 Kunda1 Assigned To => hyarion
2021-01-07 15:11 Kunda1 Status new => assigned