SlickEdit Community

SlickEdit Product Discussion => SlickEdit® => Features and/or Improvements => Topic started by: Graeme on May 01, 2018, 12:22:32 AM

Title: math calculations
Post by: Graeme on May 01, 2018, 12:22:32 AM
I often do math calculations on the slick command line and sometimes forget to put the word "math" at the start.  Slick then gives me "unknown command".  How about instead of giving unknown command, treat it as a math expression if it's numerical.
Title: Re: math calculations
Post by: Dan on May 01, 2018, 10:36:53 AM
I think the problem with this is that you can use +x or -x on the SlickEdit command line to move the cursor up or down a number of lines.

Love to hear users still use the command line ;)
Title: Re: math calculations
Post by: Graeme on May 01, 2018, 12:21:16 PM
If slick is going to output "invalid command" then it can't have been a goto line or up/ down command so there's no reason it couldn't check for a math expression.  Anyway I should probably bind the calculator tool to a key so I can bring it up quickly.
Title: Re: math calculations
Post by: Clark on May 01, 2018, 02:23:33 PM
Unknown commands are parsed as external program command lines. If the program (path search first arg) isn’t found, then you get unknown command. Otherwise the external program is executed. This isnt used much. Not really a fan of having yet another meaning to something you type on the command line. I use the math commands a lot but I usually pick a specific one like mathx. That way the result i want is copied to the clipboard for pasting.