~rjarry/aerc#46: 
mouse in aerc's terminal doesn't work?

Either it's just me, or this is such an old limitation that we all simply learned to live with it :)

So, for me, mouse doesn't work in either $EDITOR when composing/replying, or in the :term.

aerc 0.10.0-23-g83e0e26-dirty

Status
RESOLVED CLOSED
Submitter
~john1doe
Assigned to
No-one
Submitted
9 months ago
Updated
3 months ago
Labels
bug

~mtvec 8 months ago

I can confirm this and would like to add that it also doesn't work when displaying emails. My pager is set to the default "less -R".

aerc 0.11.0

~rjarry 8 months ago

Do you have:

[ui]
mouse-enabled=true

in aerc.conf?

~mtvec 8 months ago

Yes.

~rjarry 8 months ago

Then this is expected behaviour. Aerc captures mouse events and does not forward them to the underlying application running in its terminal emulator.

You can try disabling mouse for aerc, and let the pager, $EDITOR or :term see the mouse events. This is not guaranteed to work however depending on the applications. The terminal capabilities of aerc's :term are not "standard" like xterm or vt100.

We would need to look deeper into libvterm code to understand what is expected to happen.

~mtvec 8 months ago

You can try disabling mouse for aerc, and let the pager, $EDITOR or :term see the mouse events.

Thanks a lot, that worked for me!

~john1doe 7 months ago

You can try disabling mouse for aerc, and let the pager, $EDITOR or :term see the mouse events.

For me, this doesn't work.

I set mouse-enabled=false in aerc.conf, and the mouse didn't work both in aerc (expected) and in $EDITOR when composing / replying (my $EDITOR is Vim with set mouse=a) or :term's applications (like Midnight Commander, for instance). Just reporting :)

(aerv v.0.11.0)

~rockorager REPORTED FIXED 6 months ago

~john1doe 6 months ago

~rockorager:

Partially :) I still have problems with Vim (though the mouse seems to work in some other applications, like the Midnight Commander, for example).

I run aerc, open :term, run vim -u NONE +'set mouse=a' +'set showcmd', and the cursor in Vim moves to some almost random locations when I click, while the showcmd option reports things like 18m, 22m, 11m etc in the statusline.

~rockorager 6 months ago

On Sun Sep 25, 2022 at 8:23 AM CDT, ~john1doe wrote:

~rockorager:

Partially :) I still have problems with Vim (though the mouse seems to work in some other applications, like the Midnight Commander, for example).

I run aerc, open :term, run vim -u NONE +'set mouse=a' +'set showcmd', and the cursor in Vim moves to some almost random locations when I click, while the showcmd option reports things like 18m, 22m, 11m etc in the statusline.

-- View on the web: https://todo.sr.ht/~rjarry/aerc/46#event-207115

Are you running the latest master? Robin just applied a patch that updated tcell-term, which has some rendering bug fixes (particularly some I found in vim)

~rockorager referenced this from #46 6 months ago

~john1doe 6 months ago*

Are you running the latest master?

Today's latest master, commit da10dae8.

~john1doe 5 months ago*

May be the resolved/fixed status should be revoked for this not to get buried among closed tickets? It's certainly not resolved from my side :)

~rjarry FIXED REPORTED 5 months ago

~rjarry 5 months ago

~rockorager, I confirm that opening :term and run /usr/bin/vim -u NONE +'set mouse=a' +'set showcmd' with mouse-enabled=true results in erratic behaviour. With mouse-enabled=false, mouse events seem not forwarded to vim.

~rjarry 3 months ago

~john1doe, can you confirm that your mouse works properly outside of aerc's terminal?

~rockorager 3 months ago*

~john1doe, can you also try :set ttymouse=sgr and see if it fixes it?

EDIT: also what terminal are you using?

~john1doe 3 months ago

@rjarry, it does :) As I said above, it even worked in other applications in aerc's term, the problem was Vim. And now @rockorager's hint, set ttymouse=sgr, seems to solve it (thanks, Tim! As per your question, it's mainly kitty, but I was testing in xterm, too).

So, we can probably close this now, thank you guys for support.

~rjarry REPORTED CLOSED 3 months ago

Cheers

~rjarry 3 months ago

Tim Culverhouse referenced this ticket in commit 9433a79.

Register here or Log in to comment, or comment via email.