You are not logged in.

#1 2012-09-16 14:30:05

piotr.domagalski
Member
Registered: 2012-09-16
Posts: 4

rxvt-unicode, TERM and visible content redraw (CTRL+L)

Hi,

I've recently switched to rxvt-unicode (from community) from gnome-terminal. The thing is that with the default TERM=rxvt-unicode-256color I can see the screen being redrawn, e.g. when I hit CTRL+L while I'm in the shell or when I use Page-Down/Up in VIM. It looks as if there was some kind of double-buffering lacking. In other words: open rxvt-unicode and when I hit CTRL+L I can see the shell prompt being redrawn (it's fast but still noticeable).

The phenomenon doesn't exist in gnome-terminal. What's even more important, it doesn't exist in rxvt-unicode when I'm in tmux (which I have set to use TERM=screen-256color inside).

What's also worth noting is that when I set TERM to screen-256color in rxvt itself (not using tmux) the flickering while the screen is redrawn is also gone. But I don't want to use it like this - it's never a good idea to mix TERM settings.

Has anyone solved this problem without setting TERM to some non-rxvt value?

Last edited by piotr.domagalski (2012-09-16 14:32:46)

Offline

#2 2012-09-16 14:38:49

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: rxvt-unicode, TERM and visible content redraw (CTRL+L)

I use urxvt (the stock one, from [community]) in dwm and I have no problems with redrawing I see the prompt blink - is this what you mean?
^L doesn't work for me, maybe because I use vi keys and not the emacs defaults https://wiki.archlinux.org/index.php/Re … ne_editing
Yup, I needed to 'set -o emacs'.


Edit: You're right: setting TERM to screen-256color makes the blinking prompt go away.

Last edited by karol (2012-09-16 14:43:07)

Offline

#3 2012-09-16 14:43:15

piotr.domagalski
Member
Registered: 2012-09-16
Posts: 4

Re: rxvt-unicode, TERM and visible content redraw (CTRL+L)

karol wrote:

I see the prompt blink - is this what you mean?

Exactly - the blinking. You should also see the vim's statusbar blink while you scroll a longer file with Page-Down/Up.

Last edited by piotr.domagalski (2012-09-16 14:47:21)

Offline

#4 2012-09-16 14:52:15

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: rxvt-unicode, TERM and visible content redraw (CTRL+L)

piotr.domagalski wrote:
karol wrote:

I see the prompt blink - is this what you mean?

Exactly - the blinking. You should also see the vim's statusbar blink while you scroll a longer file with Page-Down/Up.

It does blink indeed - even with TERM set to screen-256color (not every time I page through though). It never bothered me, but I see that rxvt-unicode is advertised as 'Completely flicker-free' http://software.schmorp.de/pkg/rxvt-unicode.html ;P

Offline

#5 2012-09-16 15:49:02

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

Re: rxvt-unicode, TERM and visible content redraw (CTRL+L)

karol wrote:

^L doesn't work for me, maybe because I use vi keys and not the emacs defaults ...
Yup, I needed to 'set -o emacs'.

or press <ESC> before Ctrl-L.


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

Offline

#6 2012-09-16 17:12:59

thisoldman
Member
From: Pittsburgh
Registered: 2009-04-25
Posts: 1,172

Re: rxvt-unicode, TERM and visible content redraw (CTRL+L)

Probably a TGN.

A flicker with vim's status bar is difficult to notice, I have line, column, % of file, and the clock updating.  I believe, if there's any flicker with vim's status bar, it's less noticeable when using horizontally split windows.  At first, I thought there might be a difference between using PageUp and PageDown rather than Ctrl-f and Ctrl-b, but the flicker is so small I could be imagining a difference.

There is a noticeable flicker of the bash prompt in urxvt when I use Ctrl-L, and slightly less flicker when I use the 'clear' command.  With an xterm, the flicker for Ctrl-L is about the same as with urxvt but I have no flicker when using the 'clear' command.

Offline

#7 2012-09-16 17:16:35

piotr.domagalski
Member
Registered: 2012-09-16
Posts: 4

Re: rxvt-unicode, TERM and visible content redraw (CTRL+L)

thisoldman wrote:

A flicker with vim's status bar is difficult to notice, I have line, column, % of file, and the clock updating.  I believe, if there's any flicker with vim's status bar, it's less noticeable when using horizontally split windows.  At first, I thought there might be a difference between using PageUp and PageDown rather than Ctrl-f and Ctrl-b, but the flicker is so small I could be imagining a difference.

Try vim with something like "set lastatus=2" and it should be a lot more visible...

Offline

#8 2012-09-16 17:47:01

thisoldman
Member
From: Pittsburgh
Registered: 2009-04-25
Posts: 1,172

Re: rxvt-unicode, TERM and visible content redraw (CTRL+L)

I normally have laststatus=2, it's in my default .vimrc.  I'm not surprised at a flicker from vim's status bar, the information has to be reevaluated and the characters redrawn with every cursor movement.

I don't use transparency with urxvt, could that be an aggravating factor for the prompt flicker?  I also wonder if screen flicker is as noticeable with a different shell or a different prompt?

Does bash-completion affect the flicker?  It used to affect the redrawing of my PS1 but I haven't had that app installed for a couple of years now.

Offline

#9 2012-09-16 17:52:19

piotr.domagalski
Member
Registered: 2012-09-16
Posts: 4

Re: rxvt-unicode, TERM and visible content redraw (CTRL+L)

thisoldman wrote:

I normally have laststatus=2, it's in my default .vimrc.  I'm not surprised at a flicker from vim's status bar, the information has to be reevaluated and the characters redrawn with every cursor movement.

I don't use transparency with urxvt, could that be an aggravating factor for the prompt flicker?  I also wonder if screen flicker is as noticeable with a different shell or a different prompt?

Does bash-completion affect the flicker?  It used to affect the redrawing of my PS1 but I haven't had that app installed for a couple of years now.

No, I don't think it has anything to do with bash-completion. It is not a shell specific problem.

I think it's something more low level, lack of some buffering or using it if TERM=rxvt-unicode-256color. You can see this effect in many applications (mocp, vim) when you force the terminal to be redrawn with ctrl+l. There's no such flicker with gnome-terminal (haven't tested other vte-based, though).

And it's not that there's a major flaw in rxvt-unicode because by simply using tmux I can make this flickering stop in all these situations.

Last edited by piotr.domagalski (2012-09-16 17:52:59)

Offline

Board footer

Powered by FluxBB