[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[screen-devel] Hacking in different alt-screen support
From: |
cwillu |
Subject: |
[screen-devel] Hacking in different alt-screen support |
Date: |
Fri, 23 Jul 2010 04:39:22 -0600 |
I'm experimenting with implementing a different approach to
alt-screen, similar to the effect of termcapinfo ti@:te@, except when
using an app which actually requests alt mode.
The specific goal I have is to have a working mouse-wheel in both
shells and pagers in terminals which change mouse-wheel behavior
depending on the terminal mode. Currently, scrolling in a shell pages
through the history list or similar, while scrolling in a pager or
editor generally works properly. Setting ti@:te@ gets usable behavior
out of shells, but loses the ability to scroll in less, vim, and so
forth.
The idea is to restore somewhat sane mouse-wheel scrolling by setting
screen to not use alternate mode until a running app actually requests
it.
Attached is the (not working) patch I've come up with so far.
AddCStr(...) appears to be modifying a global, which then gets flushed
out to the tty on Flush(), but repeating the calls (D_TI/TE) in
Enter/LeaveAltScreen doesn't seem to do anything (after removing the
D_TI/TE's in the initialization); I'm not certain if that's because
it's the wrong call, or just the wrong place for the call. It's
possible that Enter/LeaveAltScreen isn't the right place to put those
calls, although that seems unlikely, as they're called almost directly
from where an app's ti/te would be handled.
--Carey Underwood
different-altscreen-behaviour.patch
Description: Text Data
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [screen-devel] Hacking in different alt-screen support,
cwillu <=