my .emacs

Learning is always from book.Reading "Learning gnu Emacs,2nd(Debra Cameron,Bill Rosenblatt, Eric Raymond)",clutz' cut in the way.

Useful memo is here:
C-f    move forward one character
C-b   move backward one character
M-f   move forward one word
M-b   move backward one word
C-a   move ahead of line
C-e   move to the end of line
M-a   move ahead of statement
M-e  move to end of statement
M-{  move to paragraph beginning
M-} move to paragraph end
C-n   move to next line
C-p   move to previous line
C-v  continue to view
M-v  return to view
C-l    view in middle
-------------------------------------these are move key sequences
--more enhanced in C mode:
C-M-a                            move to function ahead
C-M-e                            move to function end
M-m                                move to mark beginning
C-M-p                             move to previous block {
C-M-n                           move to next block }
M-;                                add comment here
M-x comment-region   comment activated region
C-x C-u                        current preprocessor conditional
C-x C-p                         previous preprocessor conditional
C-x C-n                        next preprocessor conditional
C-/                                 fill activated region
M-j                               jump to next line and continue comment
M-q                              fill current comment region
-------with etags(M-! etags * --language=c RET):
M-x visit-tags-table     load TAGS
M-.                           search word under cursor according to TAGS table
M-,                           search forward
--------using bookmark:
C-x r m                  bookmark cursor with a name
C-x r b                   jump to bookmark (input name)

-------------------------------------about frame and buffer
C-x b                  switch to previous buffer
C-x C-b               select buffer by name
C-x k                  close buffer by name
C-x C-q               lock buffer (read-only)
C-x 0                  close current frame
C-x 1                  keep only current frame
C-x 2                   horizontally split frame
C-x 3                   vertically split frame
C-M-v               continue view in the other frame
M-x compare-windows   (set cursor first)
------------------------------------------search and replace
C-s C-w             search word under cursor
C-s                    search increasely
C-r                     search return
M-%                  replace
------------------------------------------select and operation
C-@                  mark region beginning(then cursor position is the end)
C-x C-x             exchange region begining and cursor
C-w                  remove region to kill-ring
M-w                  copy region to kill-ring
C-k                  kill to line end
C-y                  yank back the nearest region in kill-ring
M-y                  select and yank back region in kill-ring
C-/                  undo previous action
C-x C-t            exchange line in context
C-t                  exchange character in context
M-t                  exchange word in context
---------------------------------------when compile
M-x compile      compile current buffer
C-x `                  jump to the line complier report error at
M-p                    view report previous
M-n                  view report next

;; .emacs

;;; uncomment this line to disable loading of "default.el" at startup
;; (setq inhibit-default-init t)

;; turn on font-lock mode
(when (fboundp 'global-font-lock-mode)
  (global-font-lock-mode t))

;; enable visual feedback on selections
;(setq transient-mark-mode t)

;; default to better frame titles
(setq frame-title-format
      (concat  "%b - emacs@" (system-name)))

;; default to unified diffs
(setq diff-switches "-u")

;; always end a file with a newline
;(setq require-final-newline 'query)

(custom-set-variables
[jin@localhost ~]$ more .emacs
;; .emacs

;;; uncomment this line to disable loading of "default.el" at startup
;; (setq inhibit-default-init t)

;; turn on font-lock mode
(when (fboundp 'global-font-lock-mode)
  (global-font-lock-mode t))

;; enable visual feedback on selections
;(setq transient-mark-mode t)

;; default to better frame titles
(setq frame-title-format
      (concat  "%b - emacs@" (system-name)))

;; default to unified diffs
(setq diff-switches "-u")

;; always end a file with a newline
;(setq require-final-newline 'query)

(custom-set-variables
  ;; custom-set-variables was added by Custom -- don't edit or cut/paste it!
  ;; Your init file should contain only one such instance.
 '(auto-compression-mode t nil (jka-compr))
 '(case-fold-search t)
 '(current-language-environment "Chinese-GB")
 '(default-input-method "chinese-py-punct")
 '(global-font-lock-mode t nil (font-lock))
 '(show-paren-mode t nil (paren))
 '(transient-mark-mode t))
(custom-set-faces
  ;; custom-set-faces was added by Custom -- don't edit or cut/paste it!
  ;; Your init file should contain only one such instance.
 )
1、资源项目源码均已通过严格测试验证,保证能够正常运行; 2、项目问题、技术讨论,可以给博主私信或留言,博主看到后会第一时间与您进行沟通; 3、本项目比较适合计算机领域相关的毕业设计课题、课程作业等使用,尤其对于人工智能、计算机科学与技术等相关专业,更为适合; 、4下载使用后,可先查看README.md或论文文件(如有),本项目仅用作交流学习参考,请切勿用于商业用途。 5、资源来自互联网采集,如有侵权,私聊博主删除。 6、可私信博主看论文后选择购买源代码。 1、资源项目源码均已通过严格测试验证,保证能够正常运行; 2、项目问题、技术讨论,可以给博主私信或留言,博主看到后会第一时间与您进行沟通; 3、本项目比较适合计算机领域相关的毕业设计课题、课程作业等使用,尤其对于人工智能、计算机科学与技术等相关专业,更为适合;、下载 4使用后,可先查看README.md或论文文件(如有),本项目仅用作交流学习参考,请切勿用于商业用途。 5、资源来自互联网采集,如有侵权,私聊博主删除。 6、可私信博主看论文后选择购买源代码。 1、资源项目源码均已通过严格测试验证,保证能够正常运行; 2、项目问题、技术讨论,可以给博主私信或留言,博主看到后会第一时间与您进行沟通; 3、本项目比较适合计算机领域相关的毕业设计课题、课程作业等使用,尤其对于人工智能、计算机科学与技术等相关专业,更为适合;、 4下载使用后,可先查看README.md或论文文件(如有),本项目仅用作交流学习参考,请切勿用于商业用途。 5、资源来自互联网采集,如有侵权,私聊博主删除。 6、可私信博主看论文后选择购买源代码。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值