issues icon indicating copy to clipboard operation
issues copied to clipboard

t_8uを設定してもundercurlの色がguispで変更できない

Open yamam opened this issue 2 years ago • 1 comments

不具合の内容

t_8uを設定していてもundercurl(波下線)の色が環境によって変更できないことがあります。

mintty : NG mintty + tmux : OK gnome-terminal : OK

現象・ログ・再現手順

以下のvimrcを用意し、mintty(wsltty) で以下のコマンドでvimを起動します。 % vim -u vimrc --noplugin vimrc

wsltty/config

Term=mintty

vimrc

set nocompatible
set termguicolors
set spell
set lazyredraw
let &t_8f = "\<Esc>[38;2;%lu;%lu;%lum"
let &t_8b = "\<Esc>[48;2;%lu;%lu;%lum"
let &t_8u = "\<Esc>[58;2;%lu;%lu;%lum"
let &t_RV = "\<Esc>[>c"
let &t_Cs = "\<Esc>[4:3m"
let &t_Ce = "\<Esc>[4:0m"
hi SpellBad     guisp=red cterm=undercurl ctermbg=NONE
syntax on
" aaa

minttyの場合、以下のように波下線が表示されません。 image

minttyからtmux (.tmux.confは空)を起動し、vimを起動した場合、波下線が赤になります。 tmuxではTERM=tmux-256colorとなっています。 image

gnome-terminal(TERM=xterm-256color)もmintty+tmuxと同じ結果となります。 gnome-terminalの場合はt_8f、t_8b、t_8u、t_RVを設定しなくても同じ結果となります。 image

また、set lazyredrawをしていない場合はCtrl-Lを押下するまでは波下線の色表示が正しくありません。

期待動作

波下線が赤で表示される

Vimのバージョン

8.2.5034

OSの種類/ディストリ/バージョン

Linux 5.10.102.1-microsoft-standard-WSL2 mintty 3.6.1 Ubuntu 22.04 gnome-terminal 3.44.0 tmux next-3.4

yamam avatar May 28 '22 00:05 yamam

再現しました。

mintty image

mintty + tmux image

mattn avatar Jun 18 '22 03:06 mattn