You are not logged in.

#1 2018-02-14 09:53:14

ctpfaff
Member
Registered: 2017-08-29
Posts: 27

[solved] Strange artifacts in vim in tmux session

Hello

Since a while I have strange artifacts when working with the vim editor in a tmux session. When I type sometimes it can happen that characters are sticking around which even if I delete the line still are shown although they do not exist. I attached an screenshot to show this. Does anybody have an idea what could cause this and help me fix it if it is possible somehow?


https://github.com/cpfaff/ease/blob/mas … _scrot.png

Here you see a "G" sticking around.

Any help would be appreciated. Thanks

Last edited by ctpfaff (2018-02-21 08:04:02)

Offline

#2 2018-02-14 13:02:39

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,525
Website

Re: [solved] Strange artifacts in vim in tmux session

Post your configs and describe your environment if you actually want help.  My suspicion is that you are setting the TERM enviornment variable (you shouldn't).

Does this happen in a tty, or only in a terminal emulator under X?  If the latter, which terminal are you using?  Does the problem happen outside of tmux, or just in tmux?  If the latter, post your tmux configs.  Does this happen in other shells, or with a new user, etc?


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#3 2018-02-14 19:33:45

ctpfaff
Member
Registered: 2017-08-29
Posts: 27

Re: [solved] Strange artifacts in vim in tmux session

He

Thanks for the helping hand. First of all. Yes I do set the TERM or terminal type variable in my tmux configuration but for a reason. I never got vim and the color themes play well together within a tmux session they were always looking odd.  But maybe I have a solution now which is not working 100%ently. This does not happen in a tty but in my terminal emulator (rxvt-unicode runing zsh) and as far as I can tell only when I am in a tmux session. I did not try another shell yet or not long enough to tell if this is making a difference. And I also cannot rule out the user. Here you can find my configuration:

* Zsh
* Xresources
* Tmux

https://github.com/cpfaff/dotfiles

Thanks.

Last edited by ctpfaff (2018-02-14 19:48:51)

Offline

#4 2018-02-14 19:36:58

ctpfaff
Member
Registered: 2017-08-29
Posts: 27

Re: [solved] Strange artifacts in vim in tmux session

Ah and my TERM outside of tmux is "rxvt-unicode-256color" and inside it is "screen-256color".

Offline

#5 2018-02-14 19:37:24

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,426
Website

Re: [solved] Strange artifacts in vim in tmux session

export ZSH=$HOME/.oh-my-zsh

Naturally.


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#6 2018-02-14 19:43:55

ctpfaff
Member
Registered: 2017-08-29
Posts: 27

Re: [solved] Strange artifacts in vim in tmux session

I do not get your point! Could you elaborate please?

Last edited by ctpfaff (2018-02-14 19:49:12)

Offline

#7 2018-02-14 19:49:38

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,525
Website

Re: [solved] Strange artifacts in vim in tmux session

Having a defaullt-terminal entry in tmux.conf is fine, that is the right way of doing that.  I was curious whether you were explicitly setting TERM which is known to cause all sorts of problems - but it doesn't appear that you are.

But as flagged above, oh-my-zsh is a rat's-nest of spaghetti code and brokenness.  That is most likely the cause of your problems, or at very least, it should be the first variable taken out of the equation: do you have this problem without oh-my-zsh (and/or in another shell).


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#8 2018-02-14 19:56:38

ctpfaff
Member
Registered: 2017-08-29
Posts: 27

Re: [solved] Strange artifacts in vim in tmux session

I see. Well that is a pity. I did not try without oh-my-zsh yet as I did not even think about that it might cause such strange problems. I will replace it and try for a few days and see if it helps. Thanks.

Offline

#9 2018-02-14 20:10:41

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,426
Website

Re: [solved] Strange artifacts in vim in tmux session

OMZ takes a beautiful, modern shell and cripples it with bloat. It's like buying a performance sports car and, before you drive it, welding a portable toilet block to it in the belief that it will somehow improve it. Give vanilla Zsh a shot and, as you find you need personalisation or specific functionality, add it incrementally and thoughtfully.


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#10 2018-02-14 20:28:13

ctpfaff
Member
Registered: 2017-08-29
Posts: 27

Re: [solved] Strange artifacts in vim in tmux session

Well I understand your point. I would like to roll my own config if I just had enough time ;-)

Last edited by ctpfaff (2018-02-14 20:28:28)

Offline

#11 2018-02-14 21:04:17

2ManyDogs
Forum Fellow
Registered: 2012-01-15
Posts: 4,648

Re: [solved] Strange artifacts in vim in tmux session

If you must use someone else's zsh config, try grml. The monthly Arch iso uses the grml config. In my opinion there is still a lot of stuff in the grml config you will never use, but at least it's not broken like omz. You are really better off rolling your own config -- that way you will understand what's in there and there won't be anything you don't need. And zsh is perfectly usable without much configuration at all.

https://wiki.archlinux.org/index.php/Zs … shrc_files

Last edited by 2ManyDogs (2018-02-14 21:05:52)

Offline

#12 2018-02-21 07:59:32

ctpfaff
Member
Registered: 2017-08-29
Posts: 27

Re: [solved] Strange artifacts in vim in tmux session

Well after testing a little bit it turned out it is not related to oh-my-zsh. It also happened with pretzo and it happened outside of tmux as well. I finally made the switch from solarized color schema in vim to gruvbox and now the issue seems to be gone. However I cannot understand yet why a color schema should cause such strange issues. Thanks to you all for your input.

Offline

#13 2018-02-21 11:59:21

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,525
Website

Re: [solved] Strange artifacts in vim in tmux session

ctpfaff wrote:

Well after testing a little bit it turned out it is not related to oh-my-zsh. It also happened with pretzo

It means it's not *specific* to OMZ.  But chaning one bloated black box of someone else's configs with another bloated black box of someone else's configs is not really a fair test.  The problem is you didn't know what was going on in your shell: no one but the author of OMZ could know.  Now you still don't know what is going on in your shell: no one but the author of pretzo could.

I'm not familiar with prezto, so I don't know if it is as broken as OMZ or if perhaps it is more-or-less well done like grml, but regardless, using any one of these three is not getting to the root of the suspected problem: you need to know what is going on in your system.

ctpfaff wrote:

I finally made the switch from solarized color schema in vim to gruvbox and now the issue seems to be gone.

So more of the same.  This issue may be gone, but you will still be as clueless about troubleshooting the next one that comes along.

ctpfaff wrote:

However I cannot understand yet why a color schema should cause such strange issues.

If you install and run huge bloated black box tools, you can't expect to understand why/how they break: you should only expect that they will.  Decent vim colorschemes (even elaborate ones) are in the range of a hundred lines of code or so: that's the most it should take to set some colors.  I don't know which implementation of solarized you tried, but the gruvbox I found was over 1500 lines of code for just the color file: what the hell is it doing?  (that's a hypothetical question, I have no idea what it is doing, and I'm pretty sure neither do you).


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

Board footer

Powered by FluxBB