CommandLine_en.html 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <!-- Automatically generated file. Do not edit. -->
  3. <html xmlns="http://www.w3.org/1999/xhtml">
  4. <head>
  5. <title>Command Line</title>
  6. <link rel="stylesheet" type="text/css" href="../../../../style.css" />
  7. <meta http-equiv="content-type" content="text/html; charset=UTF-8" /></head>
  8. <body style="font-family:Arial, Helvetica, sans-serif">
  9. <p style="text-align:right;"><a href="/doc/qcad/latest/reference/en/index.php?page=scripts/Widgets/CommandLine/doc/CommandLine">&#160;&#160;&#160;&#160;&#160;&#160;</a></p>
  10. <div class="nobreak">
  11. <h2>Command Line</h2>
  12. <p class="toolinfo">
  13. <b>Toolbar / Icon:</b>
  14. <br /><img src="../doc/CommandLine.png" width="40" height="40" />
  15. &#160;&#160;&#160;
  16. <br/>
  17. <b>Menu:</b> <font face="courier new">View &gt; Command Line</font>
  18. <br /><b>Shortcut:</b> <font face="courier new">G, M</font>
  19. <br /><b>Commands:</b> <font face="courier new">gm</font>
  20. </p>
  21. </div>
  22. <h3>Description</h3>
  23. <div>
  24. <p>The command line of QCAD allows you to start commands, enter coordinates or
  25. enter values such as distances or radii.</p>
  26. <h3>Entering Coordinates</h3>
  27. <p>
  28. Absolute coordinates are entered in the format "x,y":
  29. </p>
  30. <p class="code">
  31. 40,5
  32. </p>
  33. <p>
  34. Relative coordinates are entered in the format "@x,y":
  35. </p>
  36. <p class="code">
  37. @10,6
  38. </p>
  39. <p>
  40. Absolute polar coordinates are entered in the format "distance&lt;angle":
  41. </p>
  42. <p class="code">
  43. 10&lt;30
  44. </p>
  45. <p>
  46. Relative polar coordinates are entered in the format "@distance&lt;angle":
  47. </p>
  48. <p class="code">
  49. @10&lt;45
  50. </p>
  51. <p>
  52. When entering coordinates or values, <a href="#expr">mathematical expressions</a>
  53. may be used to calculate a coordinate based on known values. For example the
  54. coordinate 10,5 may also be entered as:
  55. </p>
  56. <p class="code">
  57. 5+5,30/6
  58. </p>
  59. <h3>Calculator</h3>
  60. <p>
  61. The command line can also be used as a calculator. To do this, enter a
  62. <a href="#expr">mathematical expression</a> proceeded by an equal sign:
  63. </p>
  64. <p class="code">
  65. =3+4<br/>
  66. 7
  67. </p>
  68. <p>
  69. Variables may be used to store values:
  70. </p>
  71. <p class="code">
  72. =a=5+6<br/>
  73. 11<br/>
  74. =a/2<br/>
  75. 5.5<br/>
  76. </p>
  77. <a name="expr"></a>
  78. <h3>Mathematical Expressions</h3>
  79. <p>Mathematical constants available are:</p>
  80. <p class="code">
  81. PI, LN2, LN10, LOG2E, LOG10E, SQRT1_2, SQRT2
  82. </p>
  83. <p>Mathematical functions available are:</p>
  84. <p class="code">
  85. abs, ceil, floor, exp, log, max, min, pow, sqrt, random, round, rad2deg, deg2rad,
  86. sin, cos, tan, asin, acos, atan, atan2, log10, log1p, log2, sign, cosh, sinh, tanh,
  87. acosh, asinh, atanh, expm1, hypot, cbrt, trunc
  88. </p>
  89. <p>Most of these constants and functions are standard ECMAScript (JavaScript) functions and
  90. documented online. In standard ECMAScript, these functions are part of the Math class so the
  91. function <i>abs</i> would have to written as <i>Math.abs</i>. In the QCAD command line, you can
  92. leave away the <i>Math.</i> part for convenience. Trigonometric functions (sin, cos, tan, asin, acos, atan, atan2)
  93. accept or return angles in degrees. If you prefer the radian versions of these functions,
  94. use the original <i>Math.</i> functions instead.</p>
  95. <p>The functions <i>rad2deg</i> and <i>deg2rad</i> can be used to convert angles between
  96. radian and degrees.</p>
  97. </div>
  98. </body>
  99. </html>