Fix/mouse coordinate selection
These changes make mouse text selection in the TUI chat work as expected - like other terminal applications. Users can now select text beyond the viewport with automatic scrolling, and clipboard behavior follows standard Ctrl+C patterns instead of immediate copy on release.
Thank you! This solves the text-selection problem for me. Without this PR, trying to select text actually writes text all over the screen. After this PR, I can select text normally without disturbing it.
However, this PR has broken my ability to scroll down after scrolling up. Steps to reproduce: start opencode; resume a session with enough history to require scrolling; scroll up, then try scrolling back down. Only the bottom 5% of the window scrolls back down. Although I didn't actually use opencode yet before applying this PR, I can't seem to reproduce this scroll bug without this PR so I think it's new behavior.
@benemorius I can't reproduce your error. Are you certain you can't scroll back down?
added right click copy into pastebuffer
If you're interested in using this pr or patching opencode, just lmk I've merged it into my own working branch "unchained" which has this and some other performance enhancements. Thanks