mirror of
https://github.com/rfivet/uemacs.git
synced 2024-12-20 16:22:38 -05:00
Fix getccol reporting when dealing with characters in range 0x80 .. 0xA0.
This commit is contained in:
parent
135238106c
commit
3f1ac2596c
6
random.c
6
random.c
@ -173,13 +173,13 @@ int getccol(int bflg)
|
|||||||
unicode_t c;
|
unicode_t c;
|
||||||
|
|
||||||
i += utf8_to_unicode(dlp->l_text, i, len, &c);
|
i += utf8_to_unicode(dlp->l_text, i, len, &c);
|
||||||
if (c != ' ' && c != '\t' && bflg)
|
if( bflg && c != ' ' && c != '\t') /* Request Stop at first non-blank */
|
||||||
break;
|
break;
|
||||||
if (c == '\t')
|
if (c == '\t')
|
||||||
col |= tabmask;
|
col |= tabmask;
|
||||||
else if (c < 0x20 || c == 0x7F)
|
else if (c < 0x20 || c == 0x7F) /* displayed as ^c */
|
||||||
++col;
|
++col;
|
||||||
else if (c >= 0xc0 && c <= 0xa0)
|
else if (c >= 0x80 && c <= 0xa0) /* displayed as \xx */
|
||||||
col += 2;
|
col += 2;
|
||||||
++col;
|
++col;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user