home *** CD-ROM | disk | FTP | other *** search
/ vim.ftp.fu-berlin.de / 2015-02-03.vim.ftp.fu-berlin.de.tar / vim.ftp.fu-berlin.de / patches / 6.2.178 < prev    next >
Encoding:
Internet Message Format  |  2004-01-08  |  2.2 KB

  1. To: vim-dev@vim.org
  2. Subject: Patch 6.2.178
  3. Fcc: outbox
  4. From: Bram Moolenaar <Bram@moolenaar.net>
  5. Mime-Version: 1.0
  6. Content-Type: text/plain; charset=ISO-8859-1
  7. Content-Transfer-Encoding: 8bit
  8. ------------
  9.  
  10. Patch 6.2.178
  11. Problem:    People who don't know how to exit Vim try pressing CTRL-C.
  12. Solution:   Give a message how to exit Vim when CTRL-C is pressed and it
  13.         doesn't cancel anything.
  14. Files:        src/normal.c
  15.  
  16.  
  17. *** ../vim-6.2.177/src/normal.c    Mon Dec 29 20:32:43 2003
  18. --- src/normal.c    Thu Jan  8 21:19:53 2004
  19. ***************
  20. *** 7760,7767 ****
  21. --- 7760,7785 ----
  22.   nv_esc(cap)
  23.       cmdarg_T    *cap;
  24.   {
  25. +     int        no_reason;
  26. +     no_reason = (cap->oap->op_type == OP_NOP
  27. +         && cap->opcount == 0
  28. +         && cap->count0 == 0
  29. +         && cap->oap->regname == 0
  30. +         && !p_im);
  31.       if (cap->arg)        /* TRUE for CTRL-C */
  32.       {
  33. +     if (restart_edit == 0
  34. + #ifdef FEAT_CMDWIN
  35. +         && cmdwin_type == 0
  36. + #endif
  37. + #ifdef FEAT_VISUAL
  38. +         && !VIsual_active
  39. + #endif
  40. +         && no_reason)
  41. +         msg(_("Type  :quit<Enter>  to exit Vim"));
  42.       restart_edit = 0;
  43.   #ifdef FEAT_CMDWIN
  44.       if (cmdwin_type != 0)
  45. ***************
  46. *** 7783,7794 ****
  47.       }
  48.       else
  49.   #endif
  50. !     if (cap->oap->op_type == OP_NOP
  51. !         && cap->opcount == 0
  52. !         && cap->count0 == 0
  53. !         && cap->oap->regname == 0
  54. !         && !p_im)
  55. !     vim_beep();
  56.       clearop(cap->oap);
  57.   
  58.       /* A CTRL-C is often used at the start of a menu.  When 'insertmode' is
  59. --- 7801,7808 ----
  60.       }
  61.       else
  62.   #endif
  63. !     if (no_reason)
  64. !         vim_beep();
  65.       clearop(cap->oap);
  66.   
  67.       /* A CTRL-C is often used at the start of a menu.  When 'insertmode' is
  68. *** ../vim-6.2.177/src/version.c    Fri Jan  9 15:10:05 2004
  69. --- src/version.c    Fri Jan  9 19:16:24 2004
  70. ***************
  71. *** 639,640 ****
  72. --- 639,642 ----
  73.   {   /* Add new patch number below this line */
  74. + /**/
  75. +     178,
  76.   /**/
  77.  
  78. -- 
  79. hundred-and-one symptoms of being an internet addict:
  80. 214. Your MCI "Circle of Friends" are all Hayes-compatible.
  81.  
  82.  /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
  83. ///        Sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
  84. \\\              Project leader for A-A-P -- http://www.A-A-P.org        ///
  85.  \\\  Help AIDS victims, buy here: http://ICCF-Holland.org/click1.html  ///
  86.