I'm using Mac OS X as a workstation. With iTerm2, I connect to a remote host (Ubuntu Server) using this command:
ssh -t user@host screen -D -R -R
But I can't get the scroll wheel to work correctly, especially when using split windows. When I'm scrolling up I expect to see the scrollback buffer of the current split window; instead, the entire iTerm2 scrollback buffer goes up, revealing part of the output of the commands before the ssh.
Putting termcapinfo xterm* ti@:te@ on ~/.screenrc, as suggested here, both in local and remote home directories, does not change the behavior.
The TERM environment variable is xterm-256color in both consoles.