home *** CD-ROM | disk | FTP | other *** search
/ PDA Software Library / pdasoftwarelib.iso / WIN_CE / PC / coolcalczip.exe / function.htp < prev    next >
Encoding:
Text File  |  1997-09-24  |  14.1 KB  |  279 lines

  1. <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
  2. <html>
  3.  
  4. <head>
  5. <meta http-equiv="refer" content="file:coolcalc.htc">
  6.  
  7.  
  8.  
  9. <title>Function Reference</title>
  10. </head>
  11.  
  12. <body bgcolor="#FFFFFF">
  13.  
  14. <h2>Function Reference</h2>
  15.  
  16. <p>The following sections are in this document:</p>
  17.  
  18. <dl>
  19.     <dt>_functions (underbar functions) vs. functions</dt>
  20.     <dt>Calculator Function List</dt>
  21.     <dt>Layout Function List</dt>
  22. </dl>
  23.  
  24. <h3>_functions (underbar functions) vs. functions</h3>
  25.  
  26. <blockquote>
  27.     <p>CoolCalc's function set is divided into two types of
  28.     functions: calculator functions, and layout functions. Two
  29.     distinguish between the two, layout functions always start
  30.     with the underbar character: "_". Also, note that
  31.     the calculator can function in two modes: RPN, or non-RPN.
  32.     Some functions won't work in certain modes; for example, the
  33.     Enter function is meaningless in non-RPN mode, and the Equals
  34.     function is meaningless in RPN mode.</p>
  35.     <p>When you look at a macro via the macro editor, you'll see
  36.     something after each function name. These are parameters, and
  37.     all functions can take a single parameter, although not all
  38.     of them use one. Parameters are always text strings. If you
  39.     look at a macro file in the macro editor, you will see
  40.     functions like <strong>_AddDisplay:"1"</strong>.
  41.     The "1" is the parameter to the AddDisplay
  42.     function, and this function adds the digit one to the
  43.     display.</p>
  44.     <p>Another important point: not all layout functions are
  45.     assignable to buttons. The ones that aren't assignable will
  46.     not appear in the list of functions when you request the
  47.     button properties. For example, you cannot have a button that
  48.     changes the typeface of the small font. However, if you look
  49.     at the layout macros, you will see some of these functions.</p>
  50. </blockquote>
  51.  
  52. <h3>Calculator Function List</h3>
  53.  
  54. <blockquote>
  55.     <p><strong>Absolute value:</strong> Make the value in the
  56.     display positive.</p>
  57.     <p><strong>Arc Cosine: </strong>Calculate the arc-cosine of
  58.     the display (in degrees).</p>
  59.     <p><strong>Arc Sine: </strong>Calculate the arc-sine of the
  60.     display (in degrees).</p>
  61.     <p><strong>Arc Tangent: </strong>Calculate the arc-tangent of
  62.     the display (in degrees).</p>
  63.     <p><strong>Change Sign:</strong> Changes the value in the
  64.     display from positive to negative, or negative to positive.</p>
  65.     <p><strong>ClearStack: </strong>Clears all values previously
  66.     saved by pressing the Enter key (RPN mode), or by pressing
  67.     the left parenthesis key (non-RPN mode). Use this in
  68.     combination with the _Clear function to reset the calculator.
  69.     </p>
  70.     <p><strong>Cosine: </strong>Calculate the cosine of the
  71.     display (in degrees).</p>
  72.     <p><strong>Divide: </strong>Divides the last two values.</p>
  73.     <p><strong>E to the x: </strong>Calculate e to the power
  74.     shown in the display.</p>
  75.     <p><strong>Enter: </strong>Pushes the value in the display
  76.     onto the stack (RPN mode only).</p>
  77.     <p><strong>Equals:</strong> Finishes the calculation (non-RPN
  78.     mode, only).</p>
  79.     <p><strong>Factorial: </strong>Calculates the factorial (n!)
  80.     of the value in the display. </p>
  81.     <p><strong>Fractional Part: </strong>Changes the display to
  82.     show only the fractional part. For example, 97.432 becomes
  83.     0.432.</p>
  84.     <p><strong>Hyperbolic Cosine: </strong>Calculate the
  85.     hyperbolic cosine of the display (in degrees).</p>
  86.     <p><strong>Hyperbolic Sine:</strong> Calculate the hyperbolic
  87.     sine of the display (in degrees).</p>
  88.     <p><strong>Hyperbolic Tangent: </strong>Calculate the
  89.     hyperbolic tangent of the display (in degrees).</p>
  90.     <p><strong>Integer part:</strong> Changes the display to show
  91.     only the integer part. For example, 97.432 becomes 97.</p>
  92.     <p><strong>Left Parenthesis: </strong>Used to do complicated
  93.     calculations in non-RPN mode. This has the same effect as a
  94.     "(" would in a formula.</p>
  95.     <p><strong>Log base 10:</strong> Calculate the logarithm of
  96.     the display.</p>
  97.     <p><strong>Minus:</strong> Subtraction.</p>
  98.     <p><strong>Multiply:</strong> Multiplication.</p>
  99.     <p><strong>Natural Logarithm: </strong>Calculate the log to
  100.     the base of e using the value in the display.</p>
  101.     <p><strong>Percent: </strong>Percentage function. This mimics
  102.     the percent function of standard calculators. For example, to
  103.     figure out the total bill including the tip for a restaurant
  104.     bill of $70, you could do: 70 + 15 % =</p>
  105.     <p><strong>Plus:</strong> Addition</p>
  106.     <p><strong>Reciprocal: </strong>Takes the reciprocal of the
  107.     value in the display. (One divided by the value in the
  108.     display).</p>
  109.     <p><strong>Right Parenthesis:</strong> Ends a calculation
  110.     started by a Left Parenthesis. This works only in non-RPN
  111.     mode, and has the same effect as a ")" would in a
  112.     formula.</p>
  113.     <p><strong>RPN Mode:</strong> Turns RPN mode on or off. This
  114.     function requires a parameter of "On" to turn RPN
  115.     mode on, and a parameter of "Off" to turn RPN mode
  116.     off. The parameter is case sensitive.</p>
  117.     <p><strong>Sine:</strong> Calculate the sine of the display
  118.     (in degrees).</p>
  119.     <p><strong>Square:</strong> Squares the display; i.e.
  120.     multiplies the value in the display by itself.</p>
  121.     <p><strong>Square root: </strong>Takes the square root of the
  122.     value in the display.</p>
  123.     <p><strong>Swap last 2 values:</strong> RPN mode only.
  124.     Switches the last value pushed onto the stack via the Enter
  125.     function with the value currently in the display.</p>
  126.     <p><strong>Tangent: </strong>Calculate the tangent of the
  127.     display (in degrees).</p>
  128.     <p><strong>Y to the x: </strong>The first value entered is
  129.     raised to the power of the value in the display.</p>
  130.     <p><br>
  131.     </p>
  132. </blockquote>
  133.  
  134. <h3>Layout Function List</h3>
  135.  
  136. <blockquote>
  137.     <p><strong>(blank): </strong>This does nothing. Blank buttons
  138.     needed to be assigned to some function. (Note that the name
  139.     of this function starts with a space character. This insures
  140.     it is the first function to appear in the list).</p>
  141.     <p><strong>_AddButton:</strong> (Layout only) Starts the
  142.     definition of a new button. The button won't be created until
  143.     the left, right, top and bottom points of the button are
  144.     specified via the _SetButtonLeft, _SetButtonRight,
  145.     _SetButtonTop, and _SetButtonBottom functions are called.</p>
  146.     <p><strong>_AddDisplay: </strong>Adds the parameter text to
  147.     the display.</p>
  148.     <p><strong>_Backspace: </strong>Erases the last character
  149.     entered via _AddDisplay from the display.</p>
  150.     <p><strong>_Clear: </strong>Clears the display.</p>
  151.     <p><strong>_Display: </strong>This doesn't do anything in
  152.     itself, but any button that has the _Display function
  153.     assigned to it will show the value in the display. Note that
  154.     the button format should be Real Number.</p>
  155.     <p><strong>_EnterText:</strong> Clears the display, then
  156.     enters the parameter into the display. This is useful for
  157.     setting up constants such as pi or e.</p>
  158.     <p><strong>_EraseVariables:</strong> Erases all variables.</p>
  159.     <p><strong>_Help: </strong>Launches help. The help file to be
  160.     launched is the parameter.</p>
  161.     <p><strong>_Label: </strong>(Layout Only) This does nothing,
  162.     but a button assigned to the _Label function will display the
  163.     parameter, but won't have the grey background and border
  164.     normally associated with a button.</p>
  165.     <p><strong>_ModifyLargeFont:</strong> (Layouts only). The
  166.     ensuing font functions will relate to the Large Font.</p>
  167.     <p><strong>_ModifyMediumFont: </strong>(Layouts only). The
  168.     ensuing font functions will relate to the Medium Font</p>
  169.     <p><strong>_ModifySmallFont: </strong>(Layouts only). The
  170.     ensuing font functions will relate to the Small Font</p>
  171.     <p><strong>_PlayMacro: </strong>The macro specified in the
  172.     parameter is played. This can be a new layout, or any other
  173.     type of macro.</p>
  174.     <p><strong>_Precision: </strong>The parameter value is used
  175.     to set the precision for real number display.</p>
  176.     <p><strong>_ResetButtons: </strong>(Layout only). This erases
  177.     all buttons from the screen. Macros that launch a new layout
  178.     MUST call this function before any new buttons are defined.</p>
  179.     <p><strong>_SetButtonAlignment: </strong>(Layout only). The
  180.     parameter is the alignment ("Left",
  181.     "Center", or "Right") for the new button
  182.     we're defining. This must be preceded by the _AddButton
  183.     function.</p>
  184.     <p><strong>_SetButtonBottom: </strong>(Layout only). Sets the
  185.     bottom coordinate for the button currently being added.</p>
  186.     <p><strong>_SetButtonFont: </strong>(Layout only). The
  187.     parameter dictates the font to assign to the button currently
  188.     being added. The parameter can be "0" for Small,
  189.     "1" for Medium or "2" for Large.</p>
  190.     <p><strong>_SetButtonFormat:</strong> (Layout only). The
  191.     parameter dictates the format to assign to the button
  192.     currently being added. The parameter can be "0" for
  193.     money, "1" for a non-integer number, "2"
  194.     for text, "3" for an integer, and "4" for
  195.     a bitmap file.</p>
  196.     <p><strong>_SetButtonFunction: </strong>(Layout only). The
  197.     parameter has the name of the function to assign to the
  198.     button currently being added.</p>
  199.     <p><strong>_SetButtonKey: </strong>(Layout only). The
  200.     parameter is the keyboard equivalent for the button. You can
  201.     see a list of legal keystrokes from the button properties
  202.     menu (Go into Program Mode, then hold down Alt and select a
  203.     button).</p>
  204.     <p><strong>_SetButtonKeycap: </strong>(Layout only). The
  205.     parameter has the text for the button display for the button
  206.     currently being added.</p>
  207.     <p><strong>_SetButtonLeft: </strong>(Layout only). Sets the
  208.     left coordinate for the button currently being added.</p>
  209.     <p><strong>_SetButtonParameter: </strong>(Layout only). The
  210.     parameter has the text of the parameter to assign to the
  211.     button currently being added.</p>
  212.     <p><strong>_SetButtonRight: </strong>(Layout only). Sets the
  213.     right coordinate for the button currently being added.</p>
  214.     <p><strong>_SetButtonTop: </strong>(Layout only). Sets the
  215.     top coordinate for the button currently being added.</p>
  216.     <p><strong>_SetDefaultButtonHeight: </strong>(Layout only)
  217.     New buttons get the value of the parameter as their height.</p>
  218.     <p><strong>_SetDefaultButtonWidth: </strong>(Layout only) New
  219.     buttons get the value of the parameter as their width.</p>
  220.     <p><strong>_SetDisplayHeight: </strong>(Layout only) The
  221.     height of the screen in which this layout was created. This
  222.     is used so that if the layout is displayed on another device
  223.     with a different screen size, the layout will scale properly.</p>
  224.     <p><strong>_SetDisplayWidth: </strong>(Layout only) The width
  225.     of the screen in which this layout was created. This is used
  226.     so that if the layout is displayed on another device with a
  227.     different screen size, the layout will scale properly.</p>
  228.     <p><strong>_SetFontBold: </strong>(Layout only) The boldness
  229.     of the font being defined is set. A parameter of
  230.     "0" means non-bold, "1" means bold. (See
  231.     also _ModifySmallFont, _ModifyMediumFont or _ModifyLargeFont)</p>
  232.     <p><strong>_SetFontFace: </strong>(Layout only) The typeface
  233.     of the font being defined is set. The parameter has the name
  234.     of the typeface. (See also _ModifySmallFont,
  235.     _ModifyMediumFont or _ModifyLargeFont)</p>
  236.     <p><strong>_SetFontItalic: </strong>(Layout only) The italics
  237.     of the font being defined is set. A parameter of
  238.     "0" means non-italic, "1" means italic.
  239.     (See also _ModifySmallFont, _ModifyMediumFont or
  240.     _ModifyLargeFont)</p>
  241.     <p><strong>_SetFontSize: </strong>(Layout only) The size of
  242.     the font being defined is set. The parameter is the size is
  243.     in points. (See also _ModifySmallFont, _ModifyMediumFont or
  244.     _ModifyLargeFont). </p>
  245.     <p><strong>_SetFunctionLibrary: </strong>(Layout only) Assign
  246.     a function library to the current layout. This MUST be a part
  247.     of every layout macro. For CoolCalc, the function library is
  248.     always "coolcalc.dll"</p>
  249.     <p><strong>_SetRegistryVariable: </strong>The parameter
  250.     contains the name of a registry variable to be assigned to
  251.     the value of the display. Registry variables are stored in
  252.     the system registry, and hence, are permanently saved, even
  253.     when the CoolCalc program is terminated. </p>
  254.     <p><strong>_SetStatus: </strong>The parameter holds the text
  255.     to be displayed in the status display.</p>
  256.     <p><strong>_SetTitle: </strong>(Layout only) Sets the title
  257.     of the current layout to the parameter string.</p>
  258.     <p><strong>_SetVariable: </strong>The parameter contains the
  259.     name of a variable to be assigned to the value of the
  260.     display.</p>
  261.     <p><strong>_ShowRegistryVariable: </strong>A button with this
  262.     function assigned to it displays the value of the registry
  263.     variable named in the parameter. Make sure to set the format
  264.     of the button properly when using this function; for example,
  265.     a numeric variable should have type Real Number. </p>
  266.     <p><strong>_ShowStatus: </strong>A button with this function
  267.     assigned to it displays the value of the current status
  268.     string. The status string is set with the _SetStatus
  269.     function, but may change depending upon whether Program Mode
  270.     is active, or if a macro is being recorded. The status button
  271.     is usually placed alongside the top menu bar.</p>
  272.     <p><strong>_ShowVariable: </strong>A button with this
  273.     function assigned to it displays the value of the variable
  274.     named in the parameter. Make sure to set the format of the
  275.     button properly when using this function.</p>
  276.     <p> </p>
  277. </blockquote>
  278. </body>
  279. </html