home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 5 / 05.iso / a / a013 / 1.ddi / SOURCE.EXE / F_CSRINS.PRG < prev    next >
Encoding:
Text File  |  1991-01-25  |  760 b   |  33 lines

  1. ****************************************************************
  2. FUNCTION CSRINSERT (proc_name, proc_line, input_var, toggle_csr)
  3. ****************************************************************
  4.  
  5. * Sets cursor form based on current insert state
  6.  
  7. * Copyright(c) 1991 - James Occhiogrosso
  8.  
  9. #include "setcurs.ch"
  10.  
  11. LOCAL ins_mode, old_col, old_color, old_row
  12.  
  13. toggle_csr = IF( toggle_csr == NIL, .T., toggle_csr )
  14.  
  15. * Get entry insert state
  16. ins_mode =  READINSERT()
  17.  
  18. * Toggle setting unless toggle parameter passed false
  19. ins_mode = IF( toggle_csr, !ins_mode, ins_mode )
  20. READINSERT(ins_mode)
  21.  
  22. IF ins_mode
  23.    * Set block cursor
  24.    SETCURSOR(SC_INSERT)
  25. ELSE
  26.    * Set normal underscore cursor
  27.    SETCURSOR(SC_NORMAL)
  28. ENDIF
  29.  
  30. RETURN NIL
  31.  
  32.  
  33.