Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to realize the interchange of left and right mouse buttons in linux

2025-03-28 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/01 Report--

How to realize the interchange of left and right mouse buttons in linux? Many novices are not very clear about this. In order to help you solve this problem, the following editor will explain it in detail. People with this need can come and learn. I hope you can gain something.

Lr= "l" for id in `xinput list | grep "pointer" | sed-r's pointer. Roomid = ([0-9] +). * /\ 1bot'` Do if [[$lr = = "r"]] then xinput-- set-button-map $id 1 2 32 > / dev/null else xinput-- set-button-map $id 3 2 12 > / dev/null fidonefilepath=$0if [[$lr = = "r"]] then echo "now is right hand." Sed-I'1s now is left hand LR = "r" / lr= "l" /'$filepathelse echo "now is left hand." Sed-I'1s bind LR = "l" / lr= "r" /'$filepathfi

Ubuntu command toggles the left and right mouse button

Without saying much, let's start switching:

First of all, let's switch the mouse to the backhand (the word backhand is used here because some people may be left-handed, some may be right-handed "and right-handed? "):

Xmodmap-e'pointer = 3 21'

Please take out your little mouse and shake it a little bit

Have you switched to the backhand?!

Okay, let's switch back to:

Xmodmap-e'pointer = 1 23'

Please click again violently!

Are you fat again?!

But you have to enter 29 characters for each switch, Yazi butterfly!

Then give them a little nickname!

# filename .bashrc

Alias mr= "xmodmap-e'pointer = 3 21'"

Alias ml= "xmodmap-e 'pointer = 1 23'"

What is Linux system Linux is a free-to-use and free-spread UNIX-like operating system, is a POSIX-based multi-user, multi-task, multi-threaded and multi-CPU operating system, using Linux can run major Unix tools, applications and network protocols.

Is it helpful for you to read the above content? If you want to know more about the relevant knowledge or read more related articles, please follow the industry information channel, thank you for your support.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report