From 402d2fea7025356c7abcb891017a1b7ddf99cbbf Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Fri, 15 Apr 2005 21:00:38 +0000 Subject: updated for version 7.0066 --- src/charset.c | 23 ++++++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) (limited to 'src/charset.c') diff --git a/src/charset.c b/src/charset.c index bd319ffe7..a82a7264b 100644 --- a/src/charset.c +++ b/src/charset.c @@ -972,6 +972,19 @@ init_spell_chartab() } #endif #ifdef FEAT_MBYTE + else if (STRCMP(p_enc, "iso-8859-2") == 0) + { + /* latin2 */ + for ( ; i <= 0xa0; ++i) + spell_chartab[i] = FALSE; + for ( ; i <= 255; ++i) + spell_chartab[i] = TRUE; + spell_chartab[0xa4] = FALSE; /* currency sign */ + spell_chartab[0xa7] = FALSE; /* paragraph sign */ + spell_chartab[0xad] = FALSE; /* dash */ + spell_chartab[0xb0] = FALSE; /* degrees */ + spell_chartab[0xf7] = FALSE; /* divide-by */ + } else #endif #if defined(FEAT_MBYTE) || !defined(MSDOS) @@ -1117,6 +1130,7 @@ win_lbr_chartabsize(wp, s, col, headp) int numberextra; char_u *ps; int tab_corr = (*s == TAB); + int n; /* * No 'linebreak' and 'showbreak': return quickly. @@ -1160,9 +1174,12 @@ win_lbr_chartabsize(wp, s, col, headp) col2 = col; colmax = W_WIDTH(wp) - numberextra; if (col >= colmax) - colmax += (((col - colmax) - / (colmax + win_col_off2(wp))) + 1) - * (colmax + win_col_off2(wp)); + { + n = colmax + win_col_off2(wp); + if (n > 0) + colmax += (((col - colmax) / n) + 1) * n; + } + for (;;) { ps = s; -- cgit v1.2.1