mathpad icon indicating copy to clipboard operation
mathpad copied to clipboard

Result display suggestion

Open nemosmithasf opened this issue 5 years ago • 2 comments

Love this idea, hope you keep up the good work.

One suggestion for the way results are displayed. Rather than offsetting it by X amount of spaces, perhaps it would be better to put it next the to output, but with a // so there's no confusion.

Alternatively, you can consider the way Quokka does it, which is to render the output in a different colour.

Screen Shot 2020-10-16 at 5 55 29 PM

ideal

Screen Shot 2020-10-16 at 5 56 42 PM

nemosmithasf avatar Oct 16 '20 21:10 nemosmithasf

The different color approach looks cool!

dufferzafar avatar Mar 25 '21 19:03 dufferzafar

Hi,

Made an account just to post this. You can do the following to change the output style. I'll show an example.

On Windows navigate to following folder C:\Users\ YourUserHere\ .vscode\extensions\sagebind.mathpad-0.0.2\out

Find the decorator.js file, make a copy and save as decorator.js.bak. Just in case anything goes wrong you can revert back.

Open decorator.js, on line# 72 - 75.

Change this

                        after: {
                            contentText: ` = ${this.format(value)}`,
                            margin: "0 0 0 24em"
                        }

to this

                        after: {
                            contentText: ` // ${this.format(value)}`,
                            margin: "0 0 0 1em"
                        }

This will make the result appear at the end of the line with 2 slashes before the result.

Mammal4963 avatar Sep 13 '22 17:09 Mammal4963