mirror of
git://git.sv.gnu.org/nano.git
synced 2024-11-22 21:01:24 +03:00
build: include a workaround for VTE only when using an older libvte
Checking for the actual version of libvte is too complicated, so assume that libvte is 0.58 or newer (where the problem is fixed) when ncurses is 6.2 or newer.
This commit is contained in:
parent
39705c60df
commit
0c87a4ba41
@ -37,6 +37,11 @@
|
||||
#define BRANDING PACKAGE_STRING
|
||||
#endif
|
||||
|
||||
/* When having an older ncurses, then most likely libvte is older too. */
|
||||
#if defined(NCURSES_VERSION_PATCH) && (NCURSES_VERSION_PATCH < 20200212)
|
||||
#define USING_OLDER_LIBVTE yes
|
||||
#endif
|
||||
|
||||
static int *key_buffer = NULL;
|
||||
/* A buffer for the keystrokes that haven't been handled yet. */
|
||||
static size_t key_buffer_len = 0;
|
||||
@ -2601,6 +2606,7 @@ void draw_row(int row, const char *converted, linestruct *line, size_t from_col)
|
||||
if (*(converted + target_x) != '\0') {
|
||||
charlen = collect_char(converted + target_x, striped_char);
|
||||
target_column = wideness(converted, target_x);
|
||||
#ifdef USING_OLDER_LIBVTE
|
||||
} else if (target_column + 1 == editwincols) {
|
||||
/* Defeat a VTE bug -- see https://sv.gnu.org/bugs/?55896. */
|
||||
#ifdef ENABLE_UTF8
|
||||
@ -2611,6 +2617,7 @@ void draw_row(int row, const char *converted, linestruct *line, size_t from_col)
|
||||
} else
|
||||
#endif
|
||||
striped_char[0] = '.';
|
||||
#endif
|
||||
} else
|
||||
striped_char[0] = ' ';
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user