-
-
Notifications
You must be signed in to change notification settings - Fork 73
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can't scroll using mouse in a terminal ? #153
Comments
vscode ? Is that issue related to bacon ? If it is, then yes, you should be able to use the mouse wheel to scroll the report in bacon. |
I'm on Windows, and I tried in Git Bash, CMD and powershell and I still have the same issue outside of vscode this time |
On Linux
On Windows
Investigations :I tried getting Mouse Events instead of key events inside the project with no luck, I then tried in an empty project with only After some investigation you have to : // Have to do this part because of crossterm
let mut stdout = io::stdout();
execute!(
stdout,
EnableMouseCapture, // termimad::crossterm::event::EnableMouseCapture
)?;
// Have to do this part because of crossterm` And then match the events : #[cfg(windows)]
Event::Mouse(mouse_event) => {
let key_code =
match mouse_event.kind {
MouseEventKind::ScrollDown => {KeyCode::Down}
MouseEventKind::ScrollUp => {KeyCode::Up}
_ => {KeyCode::Null}
};
action = keybindings.get(KeyEvent::new(key_code,KeyModifiers::NONE));
}
#[cfg(not(windows))]
_ => {} If this is going to be merged : I created an action using |
Thanks for the investigation. I should have rememembered this myself as I had the problem before in broot. Regarding your code, I'll comment on the PR |
Now fixed in 2.13.0 |
(On linux) Works in normal terminals, but not in tmux. I think tmux detects if the program captures mouse events, and forwards the mouse events to the program only if so. Probably related to the mentioned |
Hello,
I can't seem to scroll using my mouse in a terminal, I tried outside and inside vscode but without success. Is it even possible or is it an issue on my computer ?
The text was updated successfully, but these errors were encountered: