Mercurial > vim
comparison src/ops.c @ 835:8bebcabccc2c v7.0e01
updated for version 7.0e01
author | vimboss |
---|---|
date | Mon, 17 Apr 2006 22:14:47 +0000 |
parents | f664cc974a7a |
children | 2c885fab04e3 |
comparison
equal
deleted
inserted
replaced
834:5117153003bd | 835:8bebcabccc2c |
---|---|
2021 copy_spaces(newp + bd.textcol, (size_t)bd.startspaces); | 2021 copy_spaces(newp + bd.textcol, (size_t)bd.startspaces); |
2022 /* insert replacement chars CHECK FOR ALLOCATED SPACE */ | 2022 /* insert replacement chars CHECK FOR ALLOCATED SPACE */ |
2023 #ifdef FEAT_MBYTE | 2023 #ifdef FEAT_MBYTE |
2024 if (has_mbyte) | 2024 if (has_mbyte) |
2025 { | 2025 { |
2026 n = STRLEN(newp); | 2026 n = (int)STRLEN(newp); |
2027 while (--num_chars >= 0) | 2027 while (--num_chars >= 0) |
2028 n += (*mb_char2bytes)(c, newp + n); | 2028 n += (*mb_char2bytes)(c, newp + n); |
2029 } | 2029 } |
2030 else | 2030 else |
2031 #endif | 2031 #endif |
2223 | 2223 |
2224 pos = oap->start; | 2224 pos = oap->start; |
2225 while (pos.lnum < oap->end.lnum) | 2225 while (pos.lnum < oap->end.lnum) |
2226 { | 2226 { |
2227 ptr = ml_get_buf(curbuf, pos.lnum, FALSE); | 2227 ptr = ml_get_buf(curbuf, pos.lnum, FALSE); |
2228 count = STRLEN(ptr) - pos.col; | 2228 count = (int)STRLEN(ptr) - pos.col; |
2229 netbeans_removed(curbuf, pos.lnum, pos.col, (long)count); | 2229 netbeans_removed(curbuf, pos.lnum, pos.col, (long)count); |
2230 netbeans_inserted(curbuf, pos.lnum, pos.col, | 2230 netbeans_inserted(curbuf, pos.lnum, pos.col, |
2231 &ptr[pos.col], count); | 2231 &ptr[pos.col], count); |
2232 pos.col = 0; | 2232 pos.col = 0; |
2233 pos.lnum++; | 2233 pos.lnum++; |
2884 ) | 2884 ) |
2885 bd.textlen = 0; | 2885 bd.textlen = 0; |
2886 else | 2886 else |
2887 { | 2887 { |
2888 if (endcol == MAXCOL) | 2888 if (endcol == MAXCOL) |
2889 endcol = STRLEN(p); | 2889 endcol = (colnr_T)STRLEN(p); |
2890 bd.textlen = endcol - startcol + oap->inclusive; | 2890 bd.textlen = endcol - startcol + oap->inclusive; |
2891 } | 2891 } |
2892 bd.textstart = p + startcol; | 2892 bd.textstart = p + startcol; |
2893 if (yank_copy_line(&bd, y_idx) == FAIL) | 2893 if (yank_copy_line(&bd, y_idx) == FAIL) |
2894 goto fail; | 2894 goto fail; |
4908 int col; | 4908 int col; |
4909 char_u *buf1; | 4909 char_u *buf1; |
4910 char_u buf2[NUMBUFLEN]; | 4910 char_u buf2[NUMBUFLEN]; |
4911 int hex; /* 'X' or 'x': hex; '0': octal */ | 4911 int hex; /* 'X' or 'x': hex; '0': octal */ |
4912 static int hexupper = FALSE; /* 0xABC */ | 4912 static int hexupper = FALSE; /* 0xABC */ |
4913 long_u n; | 4913 unsigned long n; |
4914 long_u oldn; | 4914 long_u oldn; |
4915 char_u *ptr; | 4915 char_u *ptr; |
4916 int c; | 4916 int c; |
4917 int length = 0; /* character length of the number */ | 4917 int length = 0; /* character length of the number */ |
4918 int todel; | 4918 int todel; |
5315 if (max_kbyte > 0) | 5315 if (max_kbyte > 0) |
5316 { | 5316 { |
5317 /* Skip register if there is more text than the maximum size. */ | 5317 /* Skip register if there is more text than the maximum size. */ |
5318 len = 0; | 5318 len = 0; |
5319 for (j = 0; j < num_lines; j++) | 5319 for (j = 0; j < num_lines; j++) |
5320 len += STRLEN(y_regs[i].y_array[j]) + 1L; | 5320 len += (long)STRLEN(y_regs[i].y_array[j]) + 1L; |
5321 if (len > (long)max_kbyte * 1024L) | 5321 if (len > (long)max_kbyte * 1024L) |
5322 continue; | 5322 continue; |
5323 } | 5323 } |
5324 | 5324 |
5325 switch (y_regs[i].y_type) | 5325 switch (y_regs[i].y_type) |