Support comments in expressions
Originally reported on Google Code with ID 293
What steps will reproduce the problem?
1. Go through a set of calculations to come up with a result, e.g. converting Mbits/sec
to 2
hours of data.
2. Get an answer that looks wrong
3. Review your steps in the "paper tape"and wonder what your steps were.
It would be so nice if I could annotate my calculations. Maybe by separating with
a
comment character, thus:
19.4 # ATSC MPEG-2 Mbits/sec
ans / 8 # MBytes/sec
ans * 60 * 60 # MBytes in an hour.
What is the expected output?
The comments would be displayed specially, e.g. in italics, and set off from the
calculations.
What do you see instead?
I get errors.
I tried this using single and double quotes, and it works! Is this an undocumented
feature?
But there's no syntax highlighting of the "comment.
What version of the product are you using? On what operating system?
SpeedCrunch 0.10.1, KDE 4.2.4, Kubuntu 9.04
Reported by skierpage
on 2009-06-14 01:17:38
Comments (20)
-
Account Deleted -
Account Deleted ``` BTW, lots of other characters do the trick (\, &, etc), but that's totally unintentional. The parser needs to be improved. ```
Reported by `helder.pereira.correia` on 2009-06-18 14:16:07
-
Account Deleted Reported by `helder.pereira.correia` on 2009-06-18 14:16:25 - Labels added: Milestone-0.11
-
Account Deleted ``` Issue 297 has been merged into this issue. ```
Reported by `helder.pereira.correia` on 2009-07-25 14:56:53
-
Account Deleted ``` The "trick" doesn't work anymore since commit ea2aff5c8185b7792c8c0e9555cf0dd11e44f9aa. ```
Reported by `helder.pereira.correia` on 2010-10-31 08:36:45
-
Account Deleted ``` I just tried this and wanted to stick a note in that this works now in 0.10.1. I think it's of value for anybody who reads through this issue can see a recently-dated note that reports it is a success. ```
Reported by `ryjobil` on 2011-12-16 17:24:08
-
Account Deleted ``` @ryjobil, what is "it" that works? I'm using Speedcrunch 0.10.1 / Qt 4.7.4 (Kubuntu 11.10 / KDE 4.7.3). My proposed syntax (# comment follows) doesn't work; 'comment follows and "comment follows work (and the other characters @helder mentions), but SpeedCrunch doesn't color-code or italicize the text. If quote followed by comment to end of line is going to continue to work then I suggest http://www.speedcrunch.org/en_US/features.html and/or http://www.speedcrunch.org/en_US/faq.html should document the syntax. ```
Reported by `skierpage` on 2011-12-18 05:50:57
-
Account Deleted This is so needed, especially that we can't open multiple windows (at least on mac). I end up multiplexing calculations of different types and get confused looking at the history.
Reported by
haridara
on 2013-03-15 06:47:13 -
Account Deleted Added in commit 1b1b72fd8733d697b1a7adc52718eece19b0d3ff
Reported by
helder.pereira.correia
on 2013-10-11 09:25:06 - Status changed:Fixed
-
Account Deleted Any text following a '?' (question mark character, inclusive) will be ignored for evaluation purposes. It is kept visible in the result display and history and has its own highlighting color.
Reported by
helder.pereira.correia
on 2013-10-11 09:26:00 -
Account Deleted Issue 561 has been merged into this issue.
Reported by
helder.pereira.correia
on 2015-04-18 20:45:08 -
Account Deleted I am using OpenSUSE 13.2 64 bit and use the SpeedCrunch 0.11 (Qt 4.8.6). I triyed all suggestions in all comments above and can confirm nor one of them is working whth this version. My first suggestion for improvement to make possible to write comments in the calculation is from 2009. It is very sad that since 6 years this very needed functionality is not done as needed.
Reported by
kiv@mail.orbitel.bg
on 2015-04-19 16:14:30 -
Account Deleted If the milestone for solution to make annotations in the calculations is SpeedCrunch 0.11, can some one confirm it is offficially possible? If is made possible, please describe how to make it working?
Reported by
kiv@mail.orbitel.bg
on 2015-04-19 16:18:54 -
Account Deleted @klv: see comment 11. It is valid since version 0.11.
Reported by
helder.pereira.correia
on 2015-04-19 16:35:47 -
Account Deleted Sorry to write more comments, but I found out my explanation in my notes above is not clear. So I am writting here to explain what I mean. Oct, 2013 there is a commit to make "any text following a '?' (question mark character, inclusive) to be ignored for evaluation purposes. It is kept visible in the result display and history and has its own highlighting color." It is very good to have this possibility, but I thing it is not enough for status Fixed. Unfortunately it is working only after some calculation expression and does not work on a new (empty) row. This way this solution even is working but does not left enough place for longer texts. Especially if more rows of text will be needed. My suggestion is to remove the status Fixed until will be possible to put a '?' (question mark character), and write there a text without any calculation expressions and after hitting Enter, to have a new row with this '?' followed by the text needed. This way we may write multirow comments. My expectation is that just after it, this issue may be considered fully solved and then can be marked as Fixed.
Reported by
kiv@mail.orbitel.bg
on 2015-04-19 16:36:27 -
Account Deleted This issue is absolutely "Fixed". It was about "Support(ing) comments in expressions". I think you have a point, but it belongs in a new feature request. Please go ahead and file it if it's a feature you find very useful (preferably with use case descriptions). Thanks for the feedback.
Reported by
helder.pereira.correia
on 2015-04-19 16:41:13 -
Account Deleted Sorry Helder The English is not my mother Language and may be I was not clear in writting my comment #16. My idea was not to offend the developers, but some how help by suggesting some thing useful. Unfortunately I got tired to wait all long years to have finally 1/2 of the feature I suggested back in 2009. Please see 'Issue 297: Make possible to input lines with comments'. So I will not suggest same thing again. I am very thankful for the availability of SpeedCrunch as free software and highly appreciate your personal efforts and the efforts of the team. You are developing you can decide to reject my suggestion. I have nothing to say additionally. With best regards,
Reported by
kiv@mail.orbitel.bg
on 2015-04-19 19:14:16 -
Account Deleted I marked issue 297 as duplicate of this one in 2009! Why haven't you called me to attention that they weren't the same thing? :)
Reported by
helder.pereira.correia
on 2015-04-20 14:02:26 -
repo owner - edited description
- changed milestone to 0.11
- changed component to editor
-
assigned issue to
- marked as major
-
repo owner - changed status to closed
- Log in to comment
``` I think this is a brilliant idea, thank you. ```
Reported by `helder.pereira.correia` on 2009-06-18 14:13:11 - Status changed: `Accepted` - Labels added: Type-Enhancement, Priority-Low, Component-UI, Component-Logic, OpSys-All, Usability