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 / old / 5.4.46 < prev    next >
Encoding:
Internet Message Format  |  1999-08-21  |  4.0 KB

  1. To: vim-dev@vim.org
  2. Subject: patch 5.4.46
  3. Fcc: outbox
  4. From: Bram Moolenaar <Bram@moolenaar.net>
  5. ------------
  6.  
  7. Patch 5.4.46
  8. Problem:    Backspacing did not always use 'softtabstop' after hitting <CR>,
  9.         inserting a register, moving the cursor, etc.
  10. Solution:   Reset inserted_space much more often in edit().
  11. Files:        src/edit.c
  12.  
  13.  
  14. *** ../vim-5.4.45/src/edit.c    Sun Aug 22 16:12:18 1999
  15. --- src/edit.c    Sun Aug 22 16:46:23 1999
  16. ***************
  17. *** 208,214 ****
  18.       int        line_is_white = FALSE;        /* line is empty before insert */
  19.   #endif
  20.       linenr_t    old_topline = 0;        /* topline before insertion */
  21. !     int        inserted_space = FALSE;    /* just inserted a space */
  22.       int        has_startsel;            /* may start selection */
  23.       int        replaceState = REPLACE;
  24.       int        did_restart_edit = restart_edit;
  25. --- 208,214 ----
  26.       int        line_is_white = FALSE;        /* line is empty before insert */
  27.   #endif
  28.       linenr_t    old_topline = 0;        /* topline before insertion */
  29. !     int        inserted_space = FALSE;     /* just inserted a space */
  30.       int        has_startsel;            /* may start selection */
  31.       int        replaceState = REPLACE;
  32.       int        did_restart_edit = restart_edit;
  33. ***************
  34. *** 772,777 ****
  35. --- 772,778 ----
  36.           if (stuff_inserted(NUL, 1L, (c == Ctrl('A'))) == FAIL
  37.                              && c != Ctrl('A') && !p_im)
  38.           goto doESCkey;        /* quit insert mode */
  39. +         inserted_space = FALSE;
  40.           break;
  41.   
  42.       /*
  43. ***************
  44. *** 779,784 ****
  45. --- 780,786 ----
  46.        */
  47.       case Ctrl('R'):
  48.           need_redraw |= ins_reg();
  49. +         inserted_space = FALSE;
  50.           break;
  51.   
  52.   #ifdef RIGHTLEFT
  53. ***************
  54. *** 801,806 ****
  55. --- 803,809 ----
  56.       case Ctrl('T'):
  57.           ins_shift(c, lastc);
  58.           need_redraw = TRUE;
  59. +         inserted_space = FALSE;
  60.           break;
  61.   
  62.       /* delete character under the cursor */
  63. ***************
  64. *** 826,831 ****
  65. --- 829,835 ----
  66.       case Ctrl('U'):
  67.           did_backspace = ins_bs(c, BACKSPACE_LINE, &inserted_space);
  68.           need_redraw = TRUE;
  69. +         inserted_space = FALSE;
  70.           break;
  71.   
  72.   #ifdef USE_MOUSE
  73. ***************
  74. *** 943,948 ****
  75. --- 947,953 ----
  76.       case NL:
  77.           if (ins_eol(c) && !p_im)
  78.           goto doESCkey;        /* out of memory */
  79. +         inserted_space = FALSE;
  80.           break;
  81.   
  82.   #if defined(DIGRAPHS) || defined (INSERT_EXPAND)
  83. ***************
  84. *** 1097,1102 ****
  85. --- 1102,1111 ----
  86.           }
  87.           break;
  88.       }   /* end of switch (c) */
  89. +     /* If the cursor was moved we didn't just insert a space */
  90. +     if (arrow_used)
  91. +         inserted_space = FALSE;
  92.   
  93.   #ifdef CINDENT
  94.       if (curbuf->b_p_cin && can_cindent
  95. *** ../vim-5.4.45/src/version.h    Sun Aug 22 14:14:53 1999
  96. --- src/version.h    Sun Aug 22 16:52:21 1999
  97. ***************
  98. *** 19,26 ****
  99.   #define VIM_VERSION_MINOR_STR        "4"
  100.   #define VIM_VERSION_BUILD         57
  101.   #define VIM_VERSION_BUILD_STR        "57"
  102. ! #define VIM_VERSION_PATCHLEVEL         45
  103. ! #define VIM_VERSION_PATCHLEVEL_STR    "45"
  104.   
  105.   /*
  106.    * VIM_VERSION_NODOT is used for the runtime directory name.
  107. --- 19,26 ----
  108.   #define VIM_VERSION_MINOR_STR        "4"
  109.   #define VIM_VERSION_BUILD         57
  110.   #define VIM_VERSION_BUILD_STR        "57"
  111. ! #define VIM_VERSION_PATCHLEVEL         46
  112. ! #define VIM_VERSION_PATCHLEVEL_STR    "46"
  113.   
  114.   /*
  115.    * VIM_VERSION_NODOT is used for the runtime directory name.
  116. ***************
  117. *** 30,35 ****
  118.    */
  119.   #define VIM_VERSION_NODOT    "vim54"
  120.   #define VIM_VERSION_SHORT    "5.4"
  121. ! #define VIM_VERSION_MEDIUM    "5.4.45"
  122. ! #define VIM_VERSION_LONG    "VIM - Vi IMproved 5.4.45 (1999 Aug 22)"
  123. ! #define VIM_VERSION_LONG_DATE    "VIM - Vi IMproved 5.4.45 (1999 Aug 22, compiled "
  124. --- 30,35 ----
  125.    */
  126.   #define VIM_VERSION_NODOT    "vim54"
  127.   #define VIM_VERSION_SHORT    "5.4"
  128. ! #define VIM_VERSION_MEDIUM    "5.4.46"
  129. ! #define VIM_VERSION_LONG    "VIM - Vi IMproved 5.4.46 (1999 Aug 22)"
  130. ! #define VIM_VERSION_LONG_DATE    "VIM - Vi IMproved 5.4.46 (1999 Aug 22, compiled "
  131.  
  132. --
  133. hundred-and-one symptoms of being an internet addict:
  134. 188. You purchase a laptop so you can surf while sitting on the can.
  135.  
  136. --/-/---- Bram Moolenaar ---- Bram@moolenaar.net ---- Bram@vim.org ---\-\--
  137.   \ \    www.vim.org/iccf      www.moolenaar.net       www.vim.org    / /
  138.