1

This question already has an answer here:

In normal mode, I can use mouse left button to copy and right button to paste, but not with mouse mode:

-m        --mouse         Enable the use of the mouse

Is copy/paste still possible with mouse mode?

marked as duplicate by Thomas Dickey, Stephen Rauch, GAD3R, user34720, Kusalananda Jun 29 '17 at 11:01

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

0

The Issue at it's simplest is that your terminal emulator has two ways to deal with the mouse (besides ignore it). They are do something intelligent with the mouse since the program being run doesn't know what to do with it, or let the application deal with it. Most terminal emulators do both and chose between the two based on whether or not the application says it can use the mouse (termcap and terminfo come into play here but let's skip the details).

If the terminal emulator has decided to do something intelligent with the mouse in most cases the reasonable decision is to implement copy and paste.

If the terminal emulator is just passing mouse information to the application it is entirely the responsibility of the application to do the right thing, and applications vary widely in what they do. vim implements copy and paste and visual mode and is well thought out (if you like vi). aptitude does not it only does selection (which is decent in the menu and a couple other places but often leaves me reaching for the shift key).

Then there is xterm and those that emulate it to some degree, where they decided that if the application is wrong you can hold down the shift key and change what the mouse does, which is how I copy urls from aptitude, and once in a blue moon send mouse events to cat (I think this still works I haven't done it in years).

In the case of nano I avoid it as its vi compatibility mode is broken, so I can't give you advice beyond what is mentioned in the man pages (and besides I haven't read them lately).

Not the answer you're looking for? Browse other questions tagged or ask your own question.