禁用Emacs中的鼠标滚动 [英] Disabling mouse scrolling in Emacs

查看:451
本文介绍了禁用Emacs中的鼠标滚动的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在互联网上发现的一切告诉我,默认情况下,emacs禁用鼠标滚动,但是当我的拇指太靠近笔记本电脑上的触控板时,我的热情非常热情,滚动到它的内心。我有不是,因为它允许这样做,这里是我的.emacs来证明它:

  ;;逐行滚动
(setq scroll-step 1)

;;关闭备份文件创建
;;(setq make-backup-files nil)

;;启用备份文件
(setq make-backup-files t)

;;将所有备份文件保存到此目录
(setq backup-directory-alist(quote((。*。〜/ .emacs_backups /))))

;;显示列号
(column-number-mode 1)

;;修正C缩进
(setq c-default-stylebsd
c-basic-offset 8)

每一次,我的拇指会刷轨迹板,突然间,我将打开另一条线的中间,或者从刚刚出现的方式开始。如何阻止这种情况发生?



编辑
运行Mx自定义选项鼠标滚轮模式产生:



鼠标轮模式:[隐藏值] [切换]关(nil)



[状态]:自定义以外更改;在这里操作可能是不可靠的。



如果启用了鼠标滚轮模式,则为非零。 [隐藏休息]

有关此次要模式的说明,请参阅命令 mouse-wheel-mode。

直接设置此变量不生效;

自定义它(请参阅信息节点
轻松自定义')

或调用鼠标滚轮模式功能。
组:[鼠标]

解决方案

默认情况下启用(至少自Emacs 23起)



将其关闭(本地):

 (鼠标滚轮模式 - 1)

关闭(全球):

  Mx自定义选项鼠标滚轮模式;设置为nil并保存

但也许您只需要调整设置:看看Mx自定义-group mouse RET


Everything I've found on the internet has told me that emacs disables mouse scrolling by default, but mine is very enthusiastic and scrolls to its hearts content when my thumbs get too close to the trackpad on my laptop. I have not given it permission to do so, and here is my .emacs to prove it:

;; Line by line scrolling                                                                                                                                      
(setq scroll-step 1)

;; Turn off backup file creation                                                                                                                               
;;(setq make-backup-files nil)                                                                                                                                 

;; Enable backup files                                                                                                                                         
(setq make-backup-files t)

;; Save all backup files to this directory                                                                                                                     
(setq backup-directory-alist (quote ((".*" . "~/.emacs_backups/"))))

;; Show column number                                                                                                                                          
(column-number-mode 1)

;; Fix C indenting                                                                                                                                             
(setq c-default-style "bsd"
      c-basic-offset 8)

Every once and a while my thumbs will brush the track pad, and suddenly I'll be typing in the middle of another line way up or way below from where I had just been. How can I stop this from happening?

EDIT Running M-x customize-option mouse-wheel-mode yields:

Mouse Wheel Mode: [Hide Value] [Toggle] off (nil)

[State]: CHANGED outside Customize; operating on it here may be unreliable.

Non-nil if Mouse-Wheel mode is enabled. [Hide Rest]
See the command mouse-wheel-mode' for a description of this minor mode.
Setting this variable directly does not take effect;
either customize it (see the info node
Easy Customization')
or call the function `mouse-wheel-mode'. Groups: [Mouse]

解决方案

It's enabled by default (at least since Emacs 23).

To turn it off (locally):

(mouse-wheel-mode -1)

To turn it off (globally):

M-x customize-option mouse-wheel-mode ; set to nil and save

But maybe you just want to adjust the settings: Take a look at M-x customize-group mouse RET

这篇关于禁用Emacs中的鼠标滚动的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆