0
0
mirror of https://github.com/vim/vim.git synced 2025-09-29 04:34:16 -04:00

patch 8.2.3304: popup window title with wide characters is truncated

Problem:    Popup window title with wide characters is truncated.
Solution:   Use vim_strsize() instead of MB_CHARLEN(). (Naruhiko Nishino,
            closes #8721)
This commit is contained in:
rbtnn
2021-08-07 13:08:45 +02:00
committed by Bram Moolenaar
parent 3276f5846f
commit c611941c60
4 changed files with 5 additions and 3 deletions

View File

@@ -3896,7 +3896,7 @@ update_popups(void (*win_update)(win_T *wp))
title_wincol = wp->w_wincol + 1;
if (wp->w_popup_title != NULL)
{
title_len = (int)MB_CHARLEN(wp->w_popup_title);
title_len = vim_strsize(wp->w_popup_title);
// truncate the title if too long
if (title_len > total_width - 2)