home *** CD-ROM | disk | FTP | other *** search
/ Media Share 9 / MEDIASHARE_09.ISO / progmisc / nfsrc21.zip / SHIFT.C < prev    next >
Text File  |  1991-08-16  |  2KB  |  63 lines

  1. /*
  2.  * File......: SHIFT.C
  3.  * Author....: Ted Means
  4.  * Date......: $Date:   15 Aug 1991 23:08:26  $
  5.  * Revision..: $Revision:   1.2  $
  6.  * Log file..: $Logfile:   E:/nanfor/src/shift.c_v  $
  7.  * 
  8.  * This is an original work by Ted Means and is placed in the
  9.  * public domain.
  10.  *
  11.  * Modification history:
  12.  * ---------------------
  13.  *
  14.  * $Log:   E:/nanfor/src/shift.c_v  $
  15.  * 
  16.  *    Rev 1.2   15 Aug 1991 23:08:26   GLENN
  17.  * Forest Belt proofread/edited/cleaned up doc
  18.  * 
  19.  *    Rev 1.1   14 Jun 1991 19:53:56   GLENN
  20.  * Minor edit to file header
  21.  * 
  22.  *    Rev 1.0   01 Apr 1991 01:03:00   GLENN
  23.  * Nanforum Toolkit
  24.  * 
  25.  *
  26.  */
  27.  
  28.  
  29. /*  $DOC$
  30.  *  $FUNCNAME$
  31.  *     FT_SHIFT()
  32.  *  $CATEGORY$
  33.  *     Keyboard/Mouse
  34.  *  $ONELINER$
  35.  *     Determine status of shift key
  36.  *  $SYNTAX$
  37.  *     FT_SHIFT() -> lValue
  38.  *  $ARGUMENTS$
  39.  *     None
  40.  *  $RETURNS$
  41.  *     .T. if a shift key is pressed, .F. if otherwise.
  42.  *  $DESCRIPTION$
  43.  *     This function is useful for times you need to know whether or not the
  44.  *     shift key is pressed, such as during a MemoEdit().
  45.  *  $EXAMPLES$
  46.  *     IF FT_SHIFT()
  47.  *        @24, 0 say "Shift"
  48.  *     ELSE
  49.  *        @24, 0 say "     "
  50.  *     ENDIF
  51.  *  $SEEALSO$
  52.  *     FT_CAPLOCK() FT_CTRL() FT_NUMLOCK() FT_PRTSCR() FT_ALT()
  53.  *  $END$
  54.  */
  55.  
  56. #include <extend.h>
  57.  
  58. CLIPPER FT_SHIFT(void)
  59. {
  60.    _retl( (int) ((*(char *) 0x00000417) & 0x3) );
  61.    return;
  62. }
  63.