dvtm icon indicating copy to clipboard operation
dvtm copied to clipboard

Doesn't display all 256 colors, only 204 or 209

Open mik13ST opened this issue 4 years ago • 2 comments

I am trying to migrate from Tmux to this simpler tool, but I am facing problems with 256 color support. Can anyone help me troubleshoot this?

To test the color support I am using (x=\`tput op` y=`printf %76s`;for i in {0..256};do o=00$i;echo -e ${o:${#o}-3:3} `tput setaf $i;tput setab $i`${y// /=}$x;done) from ArchWiki.

What I get looks like this: image

This works fine outside DVTM.

I am running this test in Xterm 361 while using Bash 5.0.18. DVTM version is 0.15. I test this by launching Xterm and running the test (it works fine). Then from that shell I launch dvtm and run the test inside it (it looks bad). For the sake of simple troubleshooting I reduced my configs as much as possible.

.bashrc: empty .profile: doesn't exist .Xresources:

XTerm*termName: xterm-256color

With my custom .Xresources file, the test stops changing color at number 209 instead of 204. It might be hint something, I don't know.

EDIT: This definitely isn't a bug, it works on a different Debian based system in my vicinity. So I am just asking for help with troubleshooting.

mik13ST avatar Nov 12 '20 21:11 mik13ST

What's the value of the env. variable $TERM inside dvtm? If it's not dvtm-256color, you could try setting that before running the colour test script. That terminfo should be available on arch.

If it works, you should export DVTM_TERM=dvtm-256color from your shell config to persist that change. See the man-page section titled ENVIRONMENT VARIABLES.

Hope this helps.

pspeder avatar Feb 14 '21 16:02 pspeder

I export the variables DVTM_TERM=dvtm-256color and TERM=dvtm-256color inside .zshrc and .profile but still cannot display all 256 colors.

imlauera avatar May 11 '23 23:05 imlauera