mirror of
https://github.com/tmate-io/tmate.git
synced 2025-08-15 00:02:36 +02:00
Nuke the utf8 and status-utf8 options and make tmux only a UTF-8
terminal. We still support non-UTF-8 terminals outside tmux, but inside it is always UTF-8 (as when the utf8 and status-utf8 options were on).
This commit is contained in:
7
paste.c
7
paste.c
@ -275,7 +275,7 @@ paste_set(char *data, size_t size, const char *name, char **cause)
|
||||
|
||||
/* Convert start of buffer into a nice string. */
|
||||
char *
|
||||
paste_make_sample(struct paste_buffer *pb, int utf8flag)
|
||||
paste_make_sample(struct paste_buffer *pb)
|
||||
{
|
||||
char *buf;
|
||||
size_t len, used;
|
||||
@ -287,10 +287,7 @@ paste_make_sample(struct paste_buffer *pb, int utf8flag)
|
||||
len = width;
|
||||
buf = xreallocarray(NULL, len, 4 + 4);
|
||||
|
||||
if (utf8flag)
|
||||
used = utf8_strvis(buf, pb->data, len, flags);
|
||||
else
|
||||
used = strvisx(buf, pb->data, len, flags);
|
||||
used = utf8_strvis(buf, pb->data, len, flags);
|
||||
if (pb->size > width || used > width)
|
||||
strlcpy(buf + width, "...", 4);
|
||||
return (buf);
|
||||
|
Reference in New Issue
Block a user