<!-- $XConsortium: calc.sgm /main/6 1996/09/08 19:50:01 rws $ -->
<!-- (c) Copyright 1995 Digital Equipment Corporation. -->
<!-- (c) Copyright 1995 Hewlett-Packard Company. -->
<!-- (c) Copyright 1995 International Business Machines Corp. -->
<!-- (c) Copyright 1995 Sun Microsystems, Inc. -->
<!-- (c) Copyright 1995 Novell, Inc. -->
<!-- (c) Copyright 1995 FUJITSU LIMITED. -->
<!-- (c) Copyright 1995 Hitachi. -->
<refentry id="CDEMX.MAN3.rsml.1">
<refmeta><refentrytitle>dtcalc</refentrytitle><manvolnum>user cmd</manvolnum>
</refmeta>
<refnamediv><refname><command>dtcalc</command></refname><refpurpose>The CDE
Calculator</refpurpose></refnamediv>
<!-- CDE Common Source Format, Version 1.0.0-->
<!-- **  (c) Copyright 1987, 1988, 1989, 1993, 1994 Hewlett-Packard Company-->
<!-- **  (c) Copyright 1993, 1994 International Business Machines Corp.-->
<!-- **  (c) Copyright 1993, 1994 Sun Microsystems, Inc.-->
<!-- **  (c) Copyright 1993, 1994 Novell, Inc.-->
<refsynopsisdiv>
<cmdsynopsis>
<command>dtcalc</command><arg choice="opt">-a accuracy</arg><arg choice="opt">-m mode</arg><arg choice="opt">-b numeric_base</arg><arg choice="opt">-notation
display_notation</arg><arg choice="opt">-trig trigonometric_type</arg><arg
choice="opt">-no_menu_bar</arg><arg choice="opt">-session session_file</arg>
<arg choice="opt">-?</arg>
</cmdsynopsis>
</refsynopsisdiv>
<refsect1>
<title>DESCRIPTION</title>
<para>The <command>dtcalc</command> utility is a calculator for use within
the CDE. It provides an easy-to-use interface designed to give access to common
arithmetic and financial calculations.</para>
<para>The calculator is designed to operate in much the same way as many
hand-held calculators. It provides three modes of operation: scientific, financial,
and logical. The default operation is scientific, but with the easy-to-use
GUI, changing to the modes of operation is easy. When the operation mode is
changed, a number of the keys change for the new operations.</para>
</refsect1>
<refsect1>
<title>OPTIONS</title>
<para>The <command>dtcalc</command> utility defines a number of command-line
options that allow the user to configure how the calculator displays itself.
Command-line options have a higher precedence than resources. By using command-line
options a user can override anything specified in a resource file.</para>
<variablelist>
<varlistentry><term><literal>-a</literal> <emphasis>&lt;accuracy></emphasis></term>
<listitem>
<para>This is the initial number of digits displayed after the numeric point.
This value must be in the range 0 to 9. The default value is 2.</para>
</listitem>
</varlistentry>
<varlistentry><term><literal>-m</literal> <emphasis>&lt;mode></emphasis></term>
<listitem>
<para>This determines which mode the calculator will display itself in. The
possible values for &lt;<symbol role="Variable">mode</symbol>> are: scientific,
financial, or logical. Scientific is the default mode. Some of the calculator
keys change operations when the calculator's mode is changed.</para>
</listitem>
</varlistentry>
<varlistentry><term><literal>-b</literal> <emphasis>&lt;numeric_base></emphasis></term>
<listitem>
<para>This determines which numeric base the calculator will use when it does
calculations. There are four bases the calculator supports: binary (base 2),
octal (base 8), decimal (base 10), or hexadecimal (base 16). The possible
values for &lt;<emphasis>numeric_base</emphasis>> are: binary, octal, decimal,
or hexadecimal. The default is decimal.</para>
</listitem>
</varlistentry>
<varlistentry><term><literal>-notation</literal> <emphasis>&lt;display_notation></emphasis></term>
<listitem>
<para>This determines how the answers are to be displayed on the calculator.
The possible values for &lt;<emphasis>display_notation</emphasis>> are: scientific,
engineering, or fixed. The default is fixed.</para>
</listitem>
</varlistentry>
<varlistentry><term><literal>-trig</literal> <emphasis>&lt;trigonometric_type></emphasis></term>
<listitem>
<para>This determines how answers are presented when the calculator is in
scientific mode. The possible values for &lt;<emphasis>trigonometric_type</emphasis> > are: degrees, radians, or gradients. The default is degrees.
</para>
</listitem>
</varlistentry>
<varlistentry><term><literal>-no_menu_bar</literal></term>
<listitem>
<para>This option makes the calculator come up with no menubar.</para>
</listitem>
</varlistentry>
<varlistentry><term><literal>-session</literal> <emphasis>&lt;session_file></emphasis></term>
<listitem>
<para>The dtcalc utility runs with the session file specified in the <emphasis>session_file</emphasis> parameter. Session files are generated as a dtcalc
session shuts down.</para>
</listitem>
</varlistentry>
<varlistentry><term><literal>-?</literal></term>
<listitem>
<para>This prints out the usage message.</para>
</listitem>
</varlistentry>
</variablelist>
</refsect1>
<refsect1>
<title>RESOURCES</title>
<para>The calculator supports a number of resources which make it much more
configurable. Following is the list of supported resources and their default
values.</para>
<refsect2>
<title>Client Resource Set</title>
<informaltable remap="center" orient="port">
<tgroup cols="4" colsep="0" rowsep="0">
<colspec align="left" colwidth="113*">
<colspec align="left" colwidth="115*">
<colspec align="left" colwidth="76*">
<colspec align="left" colwidth="152*">
<tbody>
<row>
<entry align="left" valign="top">Name</entry>
<entry align="left" valign="top">Class</entry>
<entry align="left" valign="top">Type</entry>
<entry align="left" valign="top">Default</entry></row>
<row>
<entry align="left" valign="top">postMenuBar</entry>
<entry align="left" valign="top">PostMenuBar</entry>
<entry align="left" valign="top">Boolean</entry>
<entry align="left" valign="top">True</entry></row>
<row>
<entry align="left" valign="top">accuracy</entry>
<entry align="left" valign="top">Accuracy</entry>
<entry align="left" valign="top">int</entry>
<entry align="left" valign="top">2</entry></row>
<row>
<entry align="left" valign="top">base</entry>
<entry align="left" valign="top">Base</entry>
<entry align="left" valign="top">string</entry>
<entry align="left" valign="top">decimal</entry></row>
<row>
<entry align="left" valign="top">displayNotation</entry>
<entry align="left" valign="top">DisplayNotation</entry>
<entry align="left" valign="top">string</entry>
<entry align="left" valign="top">fixed</entry></row>
<row>
<entry align="left" valign="top">mode</entry>
<entry align="left" valign="top">Mode</entry>
<entry align="left" valign="top">string</entry>
<entry align="left" valign="top">scientific</entry></row>
<row>
<entry align="left" valign="top">trigType</entry>
<entry align="left" valign="top">TrigType</entry>
<entry align="left" valign="top">string</entry>
<entry align="left" valign="top">degrees</entry></row></tbody></tgroup></informaltable>
<variablelist>
<varlistentry><term><literal>Dtcalc*postMenuBar:</literal></term>
<listitem>
<para>Specifies whether the menu bar should appear or not.</para>
</listitem>
</varlistentry>
<varlistentry><term><literal>Dtcalc*accuracy:</literal></term>
<listitem>
<para>Specifies whether the menu bar should appear or not.</para>
</listitem>
</varlistentry>
<varlistentry><term><literal>Dtcalc*base:</literal></term>
<listitem>
<para>This resource allows the user to change the default for the numeric
base the calculator uses when it does its calculations. The default is "decimal"
which is base 10. Possible values are: <literal>binary</literal> (or <literal>bin</literal>): do calculations in base 2. <literal>octal</literal> (or <literal>oct</literal>): do calculations in base 8. <literal>decimal</literal> (or <literal>dec</literal>): do calculations in base 10. <literal>hexadecimal</literal>
(or <literal>hex</literal>): do calculations in base 16.</para>
</listitem>
</varlistentry>
<varlistentry><term><literal>Dtcalc*display:</literal></term>
<listitem>
<para>This resource allows the user to change the default for the way answers
are displayed on the calculator. The default is "fixed". Possible values are: <literal>fixed</literal> (or <literal>fix</literal>): display in fixed mode. <literal>scientific</literal> (or <literal>sci</literal>): display in scientific mode. <literal>engineering</literal> (or <literal>eng</literal>): display in engineering
mode.</para>
</listitem>
</varlistentry>
</variablelist>
</refsect2>
</refsect1>
<refsect1>
<title>FILES</title>
<variablelist>
<varlistentry><term><Filename>/usr/dt/bin/dtcalc</Filename></term>
<listitem>
<para>This is the executable for the CDE Calculator.</para>
</listitem>
</varlistentry>
<varlistentry><term><literal>/usr/dt/app-defaults/&lt;LANG>/Dtcalc</literal></term>
<listitem>
<para>This file includes the application defaults for the CDE Calculator.
</para>
</listitem>
</varlistentry>
</variablelist>
<para></para>
</refsect1>
</refentry>
<!--fickle 1.12 mancsf-to-docbook 1.2 08/07/95 01:31:55-->
<?Pub Caret>
<?Pub *0000037604>
