You are not logged in.

#1 2009-05-17 19:05:49

Peasantoid
Member
Registered: 2009-04-26
Posts: 928
Website

[solved-ish] `urxvt -e <ncurses program>` = really weird output issues

If I start an ncurses application with `urxvt -e <appname>`, odd things happen to the output: lines appear in random places, stuff gets clobbered, and so on. I suck at explaining things, so here's an example with cmus:

thumb-1242586437.png

And here's what it looks like if I start it from the bash prompt (this is what it should look like):

thumb-1242586783.png

Note: This isn't restricted to cmus; it happens with ncmpcpp as well and probably others I haven't tested. (vim and nano work fine)

I'm probably mistaken, but I think this has something to do with urxvt not setting certain environment variables such as $LINES and $COLUMNS. `xterm -e ...` works perfectly, so...huh.

Any ideas?

# Interestingly, `urxvt -e bash -c 'echo $LINES'` doesn't output anything, which suggests that urxvt is indeed not setting the aforementioned variables.
# Actually: neither does `xterm -e bash -c 'echo $LINES'`, so that probably isn't the reason. The output issues fix themselves when the window is resized, so this suggests that some signal isn't being sent to the ncurses app to update its size.
# *sigh* Or maybe it's the window manager (Musca)...
# Seriously though, I'd switch back to xterm if it had transparency. neutral

Last edited by Peasantoid (2009-05-17 20:18:28)

Offline

#2 2009-05-17 19:55:02

Peasantoid
Member
Registered: 2009-04-26
Posts: 928
Website

Re: [solved-ish] `urxvt -e <ncurses program>` = really weird output issues

Well, now I'm having even more problems. I have to run `xterm -e ncmpcpp` multiple times just to get the window to stay open — it closes immediately. So. Annoying...

*groan*

# I finally managed to track down an error message relating to the xterm-keeps-closing problem:

terminate called after throwing an instance of 'std::out_of_range'
what():  vector::_M_range_check

Seems to be a bug in ncmpcpp's code.

Last edited by Peasantoid (2009-05-17 20:11:43)

Offline

#3 2009-05-17 20:17:40

Peasantoid
Member
Registered: 2009-04-26
Posts: 928
Website

Re: [solved-ish] `urxvt -e <ncurses program>` = really weird output issues

You know what? Screw ncmpcpp! I switched to ncmpc and all is well — it seems to be better-coded, and I like it more despite there being no colors (boo-frickin'-hoo). Also, it doesn't have the urxvt + ncurses issue.

Considered this somewhat solved — my problem is fixed, but there's still an underlying one in urxvt.

# Oh wait -- ncmpc does have colors. roll

Last edited by Peasantoid (2009-05-17 20:23:58)

Offline

Board footer

Powered by FluxBB