mirror of
https://github.com/rfivet/uemacs.git
synced 2024-06-10 05:50:42 +00:00
Display non breaking space according to code page instead of \A0.
This commit is contained in:
parent
54145a48f8
commit
12d307b5b4
2
basic.c
2
basic.c
|
@ -42,7 +42,7 @@ static unsigned getgoal( line_p dlp) {
|
|||
col += tabwidth - col % tabwidth ;
|
||||
else if( c < 0x20 || c == 0x7F) /* ^x */
|
||||
col += 2 ;
|
||||
else if( c >= 0x80 && c <= 0xA0) /* \xx */
|
||||
else if( c >= 0x80 && c < 0xA0) /* \xx */
|
||||
col += 3 ;
|
||||
else
|
||||
col += utf8_width( c) ;
|
||||
|
|
|
@ -235,7 +235,7 @@ static void vtputuc( unicode_t c) {
|
|||
} else if( c < 0x20 || c == 0x7F) {
|
||||
sane_vtputc( '^') ;
|
||||
sane_vtputc( c ^ 0x40) ;
|
||||
} else if( c >= 0x80 && c <= 0xA0) {
|
||||
} else if( c >= 0x80 && c < 0xA0) {
|
||||
static const char hex[] = "0123456789abcdef" ;
|
||||
sane_vtputc( '\\') ;
|
||||
sane_vtputc( hex[ c >> 4]) ;
|
||||
|
@ -556,7 +556,7 @@ static void updpos( void) {
|
|||
curcol += tabwidth - curcol % tabwidth ;
|
||||
else if( c < 0x20 || c == 0x7F)
|
||||
curcol += 2 ; /* displayed as ^c */
|
||||
else if( c >= 0x80 && c <= 0xA0)
|
||||
else if( c >= 0x80 && c < 0xA0)
|
||||
curcol += 3 ; /* displayed as \xx */
|
||||
else
|
||||
curcol += utf8_width( c) ; /* non printable are displayed as \u */
|
||||
|
|
Loading…
Reference in New Issue
Block a user