can formulae be entered in the command line?
Moderator: andrew
Forum rules
Always indicate your operating system and QCAD version.
Attach drawing files and screenshots.
Post one question per topic.
Always indicate your operating system and QCAD version.
Attach drawing files and screenshots.
Post one question per topic.
can formulae be entered in the command line?
I need to draw some geometric figure with a high precision and need to enter formulae in the command line. Does QCAD accept formulae entry and if so which ones? More specifically: is there a way of entering a distance as for example @rootx,0 or √x,0? In Autocad it was possible using Lisp. What about QCAD?
Re: can formulae be entered in the command line?
Yes, you can enter formulas in almost every field for which a numerical value is expected.
For example:
@sqrt(x),0
For available constants and functions, please refer to the documentation of the JavaScript Math object:
http://www.w3schools.com/js/js_math.asp
For convenience, you can write 'sqrt(x)' instead of 'Math.sqrt(x)' but Math.sqrt(x) also works.
If you are adventurous, you may also use other standard JavaScript terms and expressions, for example to start a line at the X coordinate matching the current hour:
new Date().getHours(),0
This will start the line at 10,0 at 10:xx in the morning.
For example:
@sqrt(x),0
For available constants and functions, please refer to the documentation of the JavaScript Math object:
http://www.w3schools.com/js/js_math.asp
For convenience, you can write 'sqrt(x)' instead of 'Math.sqrt(x)' but Math.sqrt(x) also works.
If you are adventurous, you may also use other standard JavaScript terms and expressions, for example to start a line at the X coordinate matching the current hour:
new Date().getHours(),0
This will start the line at 10,0 at 10:xx in the morning.
Re: can formulae be entered in the command line?
Great, I love that!
Thank you for your reply.
Thank you for your reply.