home *** CD-ROM | disk | FTP | other *** search
/ Monster Media 1993 #2 / Image.iso / clipper / nfpat8.zip / CTRL.C < prev    next >
C/C++ Source or Header  |  1993-07-16  |  2KB  |  69 lines

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