


heXcalc(1)               USER COMMANDS                 heXcalc(1)



NAME
     heXcalc - programmers calculator for X

SYNOPSIS
     heXcalc [standard X options]

DESCRIPTION
     _h_e_X_c_a_l_c is a mutli-radix calculator that offers the standard
     C integer operations.

OPTIONS
     The standard X toolkit options.

OPERATION
     _C_a_l_c_u_l_a_t_o_r _M_o_d_e_s: The calculator operates in several  modes.
     The  modes  are controlled by buttons on the calculator. The
     current mode setting is indicated by setting the correspond-
     ing button to "insensitive".


     _P_o_i_n_t_e_r _U_s_a_g_e: All operations  are  done  with  the  Button1
     (usually  leftmost  button  on  the  pointer).  These can be
     changed using the translation manager.


     _b_u_t_t_o_n _U_s_a_g_e: Most of the buttons are self explanatory  (for
     C programmers).  The others are explained below.


     _1_6/_3_2 buttons: These buttons toggle the  calculator  between
     16 and 32 bit mode.

     _s_g_n/_u_s_g_n buttons: These buttons determine  whether  data  is
     treated as signed (2's complement) or unsinged.


     _C_E/_C button: Clears  the  current  entry  without  affecting
     other settings of the calculator.


     _C button: Clears everything. The display and memory are  set
     to zero.  The mode is set to signed, 32 bit decimal.


KEYBOARD EQUIVALENTS
     All calculator buttons are also available from the keyboard.
     The default bindings are shown below.








X Version 11       Last change: 1 October 1989                  1






heXcalc(1)               USER COMMANDS                 heXcalc(1)



             _K_e_y_b_o_a_r_d         _B_u_t_t_o_n

                 (            (
                 &            &
                 ^            ^
                 )            )
                 ^c           off
                 H            hex
                 O            oct
                 D            dec
                 B            bin
                 R            Rcl
                 S            Sto
                 s            16
                 l            32
                 +            +
                 -            -
                 *            *
                 /            /
                 %            %
                 >            >>
                 <            <<
                 0            0
                 1            1
                 2            2
                 3            3
                 4            4
                 5            5
                 6            6
                 7            7
                 8            8
                 9            9
                 a            a
                 b            b
                 c            c
                 d            d
                 e            e
                 f            f
                 ^h           Delete last digit (Not available via button)
                 Delete       Delete last digit (Not available via button)
                 =            =
                Return             =



     You can rebind the keys to your liking using the X  defaults
     file.   The  action  'doKey("string")'  makes the calculator
     behave as though the button labeled "string" was  hit.   For
     example






X Version 11       Last change: 1 October 1989                  2






heXcalc(1)               USER COMMANDS                 heXcalc(1)



               <Key>Return:          DoKey(=)

     binds the return key to act as though the equals button  was
     pressed.


RESOURCES
     heXcalc consists of a a vPaned widget ("wholePane") with two
     panes.  The top pane is a label widget ("display"). The bot-
     tom half is a from widget ("buttonForm") holding the command
     widgets that make up the calculator buttons. The buttons are
     named in such that groups of buttons  have  the  same  name.
     This  allows like buttons to be assigned similar colors with
     a single entry in the .Xdefaults file.  These groups are:

               _N_a_m_e           _B_u_t_t_o_n_s

               baseKey        dec, hex, oct, bin
               controlKey     off, C, CE/C
               evalKey        (, ), =
               sizeKey        16, 32
               signKey        sgn, usgn
               memKey         Stro, Rcl, Clr
               shiftKey       <<, >>
               digitKey       [0-9a-f]
               arithKey       +, -, *, /
               bitKey         ~, |, &, ^
               +/-            +/-


     Two actions are supported.  "DoKey"  (described  above)  and
     "Delete" with deletes the last digit button pressed.


SEE ALSO
     X(1), xrdb(1), xaclc(1)

BUGS
     Shift operations probably should have the shift count always
     interpreted as decimal.

     Overflow detection on input leaves something to be desired.

COPYRIGHT
     Copyright 1989, Tom Jarmolowski.
     See _X(_1) for a full statement of rights and permissions.

AUTHORS
     Tom Jarmolowski. GE Corp.

ACKNOWLEDGMENTS
     This manual page, and the hexCalc icon are minimaly  changed



X Version 11       Last change: 1 October 1989                  3






heXcalc(1)               USER COMMANDS                 heXcalc(1)



     versions of those supplied by xcalc.






















































X Version 11       Last change: 1 October 1989                  4



