Problem description: When using certain curses apps (for example, ufed or kernel menuconfig) in screen in an Eterm (with default configs for both screen and Eterm), rendering of some parts breaks (see screenshots) when switching to another screen window and back, or detaching and reattaching. Steps to reproduce: 1. Start an Eterm; start screen within. 2. Run /usr/sbin/ufed; wait until the USE flags list appears. 3. Detach (^A d). 4. Reattach (screen -x). Possible solutions: 1. Modify the default Eterm terminal name ($TERM) from the default "Eterm" to "xterm"; preferably by changing the term_name setting in the shipped theme.cfg files in /usr/share/Eterm/themes/. If step 4. in "Steps to reproduce" is replaced with "TERM=xterm screen -x", everything looks okay again. (A side-effect is that screen now signals the hardstatus line to Eterm.) 2. Patch screen so that it recognizes TERM=Eterm...? Add some Eterm related tweak to /etc/screenrc (using xterm|Eterm in all those voodoo termcap/terminfo/termcapinfo tweaks at least modifies the symptoms in a way that they are not reproducible _every_ time anymore)? Correct /usr/share/terminfo/E/Eterm? Temporary workaround: Replace "term_name = Eterm" with "term_name = xterm" in ~/.Eterm/themes/Eterm/user.cfg for each affected user, or system globally in /usr/share/Eterm/themes/{Eterm,auto,trans}/theme.cfg.
Created attachment 81247 [details] screenshot before detaching
Created attachment 81248 [details] screenshot after reattaching
Created attachment 81249 [details] emerge info I doubt this is relevant in this case, but I'll add this just for the records.
Another note: The TERM=xterm workaround has additional side effects for curses applications within screen; for example, the END key doesn't jump to the line end in vim anymore. Any suggestions how to resolve that?
For the title update, Eterm needs to advertise hardstatus support in its terminfo file, else screen won't update it. We can tell screen that Eterm has support for hardstatus without changing the terminfo file via our global screenrc. I'm currently looking at the display weirdness with Eterm and screen.
i dont really know much (of anything) about the lower terminal settings ... can you be more specific about what needs to happen to the Eterm file ? i can get this fixed upstream pretty easily ...
hs, tsl=\E]0;, fsl=\007, dsl=\E]0;\007 this are the needed terminfo settings for hardstatus support hs = has extra status line tsl = move to status line, column #1 fsl = return from status line dsl = disable status line
xterm doesn't advertise the capabilities too, we override them in our system screenrc. It seems that terminal developers don't consider the X window title equivalent to a hardstatus line.
And the display weirdness comes from how screen and Eterm interact while switching to alternate character set. termcapinfo Eterm ae=\E(B:as=\E(0 in screenrc will emulate for Eterm how xterm does it. gnome-terminal uses the same way as Eterm and doesn't suffer from this problem. Eterm also behaves different when used in the POSIX and de_DE.UTF-8 locale.
eterm doesnt support unicode so dont try ;)
Thomas: any idea on getting changes made to ncurses now that Eterm terminfo is in there ?
I don't recall noticing this bug - it's possible to accommodate screen in a couple of different ways (maing a screen.Eterm, or just modifying Eterm).
any suggestions on the "correct" way to go about things ? i can bug the Eterm maintainer if you think that the better route ...
well - just looking at the thread, there are two different types of terminal capabilities mentioned. The status line stuff is partly bogus, because (like anything else that uses xterm title strings), it doesn't provide a correct "tsl" capability (because there's no parameter for the column). I like to stay away from those, since there's little value-added. The other is the alternate-character switching stuff. This has to be limited to make "screen" work, since screen uses a subset of the _termcap_ interpretation of the capability. Adding a screen.Eterm entry is a way to do this (see ncurses' terminfo.src). But a pitfall here is that when screen is asked to do this, it diverges slightly from its interpretation of the "termcap", so it's often necessary to add other capabilities to make the entry work correctly. You can see a handful of examples in ncurses where I've done this. See ftp://invisible-island.net/ncurses/terminfo.src.gz
I added a "screen.Eterm" entry to ncurses' terminfo in last night's (20090110) patch.
Is this fixed? Thank you
It would be fixed if Eterm sets its TERM variable to Eterm. You can verify that.