comparison src/misc2.c @ 5995:ef83b423ebf7 v7.4.338

updated for version 7.4.338 Problem: Cannot wrap lines taking indent into account. Solution: Add the 'breakindent' option. (many authors, final improvements by Christian Brabandt)
author Bram Moolenaar <bram@vim.org>
date Wed, 25 Jun 2014 14:39:50 +0200
parents 8e9db1f27a00
children 18ac55444b37
comparison
equal deleted inserted replaced
5994:ca18c797aafe 5995:ef83b423ebf7
199 ptr = line; 199 ptr = line;
200 while (col <= wcol && *ptr != NUL) 200 while (col <= wcol && *ptr != NUL)
201 { 201 {
202 /* Count a tab for what it's worth (if list mode not on) */ 202 /* Count a tab for what it's worth (if list mode not on) */
203 #ifdef FEAT_LINEBREAK 203 #ifdef FEAT_LINEBREAK
204 csize = win_lbr_chartabsize(curwin, ptr, col, &head); 204 csize = win_lbr_chartabsize(curwin, line, ptr, col, &head);
205 mb_ptr_adv(ptr); 205 mb_ptr_adv(ptr);
206 #else 206 #else
207 csize = lbr_chartabsize_adv(&ptr, col); 207 csize = lbr_chartabsize_adv(line, &ptr, col);
208 #endif 208 #endif
209 col += csize; 209 col += csize;
210 } 210 }
211 idx = (int)(ptr - line); 211 idx = (int)(ptr - line);
212 /* 212 /*
2154 *((char *)gap->ga_data + gap->ga_len) = c; 2154 *((char *)gap->ga_data + gap->ga_len) = c;
2155 ++gap->ga_len; 2155 ++gap->ga_len;
2156 } 2156 }
2157 } 2157 }
2158 2158
2159 #if (defined(UNIX) && !defined(USE_SYSTEM)) || defined(WIN3264) 2159 #if (defined(UNIX) && !defined(USE_SYSTEM)) || defined(WIN3264) \
2160 || defined(PROTO)
2160 /* 2161 /*
2161 * Append the text in "gap" below the cursor line and clear "gap". 2162 * Append the text in "gap" below the cursor line and clear "gap".
2162 */ 2163 */
2163 void 2164 void
2164 append_ga_line(gap) 2165 append_ga_line(gap)