我的.emacs 2012年6月27日updated


(setq delete-auto-save-files t)
;; quit message
(fset 'yes-or-no-p 'y-or-n-p)
;;设置有用的个人信息。这在很多地方有用
(setq user-full-name "liuyao")
(setq user-mail-address "liuyaouestc@163.com")
;;把缺省的 major mode 设置为 text-mode, 而不是几乎什么功能也
;;没有的 fundamental-mode.
(setq default-major-mode 'text-mode)
(setq initial-major-mode 'text-mode)
;;光标靠近鼠标指针时,让鼠标指针自动让开,别挡住视线。
(mouse-avoidance-mode 'animate)
;;显示列号
(setq column-number-mode t) 
;;防止页面滚动时跳动, scroll-margin 3 可以在靠近屏幕边沿3行时就开始滚动,可以很好的看到上下文
(setq scroll-margin 3
      scroll-conservatively 10000)
;;在标题栏显示buffer的名字
;;(setq frame-title-format "emacs@%b")
(setq frame-title-format "%n%F/%b")
;;不要在鼠标点击的那个地方插入剪贴板内容。我不喜欢那样,经常把 我的文档搞的一团糟。我觉得先用光标定位,然后鼠标中键点击要好 的多。不管你的光标在文档的那个位置,或是在 minibuffer,鼠标 中键一点击,X selection 的内容就被插入到那个位置。
(setq mouse-yank-at-point t)
(define-key global-map "\C-h" 'backward-delete-char)
;;make ctrl-h work in searches, too
(setq search-delete-char (string-to-char "\C-h"))




;;bring the "help" facility somewhere else (ctrl-?)
;;make alt-h delete the previous word
(define-key global-map "\M-h" 'backward-kill-word)




;;make ctl-x ctrl-u the "undo" command; this is better than ctrl-u
(define-key global-map "\C-x \C-u" 'undo)



;;z在debian/ubuntu到某一行的命令是 ALt-g-g
;;goto-line
;;(define-key global-map "\C-x\C-l" 'goto-line)
;;loadpath
(setq load-path (append load-path '("/home/yao/.emacs.d/")))
;; c-toggle-auto-state
(add-hook 'c-mode-hook
      '(lambda ()
(linum-mode t)
         (c-toggle-auto-state)))
(add-hook 'c++-mode-hook
      '(lambda ()
         (c-toggle-auto-state)))
;;括号匹配时显示另一端的括号,而不是跳过去
(show-paren-mode t)
(setq show-paren-style 'parentheses)
;;-------------------------语法加亮--------------------------
(global-font-lock-mode t)
;;-------------------------关闭启动时的`开机画面'------------
(setq inhibit-startup-message t)
(scroll-bar-mode nil)
(tool-bar-mode nil)
(menu-bar-mode nil)
(set-face-attribute 'default nil :height 120)
;;;auto-complete
;;(add-to-list 'load-path "/home/yao/.emacs.d/")
;;(require 'auto-complete-config)
;;(add-to-list 'ac-dictionary-directories "/home/yao/.emacs.d//ac-dict")
;;(ac-config-default)


;;**************************COlOR THEME*********************


(require 'color-theme)
    (color-theme-initialize)
    (color-theme-hober)


(require 'sr-speedbar)
(global-set-key (kbd "<f5>") 'sr-speedbar-toggle)
(custom-set-variables
 '(speedbar-show-unknown-files t)
)

http://homepages.inf.ed.ac.uk/s0243221/emacs/

http://dotfiles.org/~rretzbach/.emacs

https://sites.google.com/site/steveyegge2/my-dot-emacs-file

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值