use c-subword-mode everywhere. autoload whitespace.el.

This commit is contained in:
Sami Samhuri 2010-01-22 22:06:51 -08:00
parent 29a19618b1
commit 36cb06bb92
2 changed files with 2561 additions and 3 deletions

21
emacs
View file

@ -74,7 +74,8 @@
(setq tab-width 8 (setq tab-width 8
;; this will make sure spaces are used instead of tabs ;; this will make sure spaces are used instead of tabs
indent-tabs-mode nil) indent-tabs-mode nil)
(c-toggle-auto-newline 1)) (c-toggle-auto-newline 1)
(c-subword-mode))
;; (setq skeleton-pair t) ;; (setq skeleton-pair t)
;; (setq skeleton-autowrap t) ;; (setq skeleton-autowrap t)
;; (let ((chars '("'" "\"" "(" "[" "{"))) ;; (let ((chars '("'" "\"" "(" "[" "{")))
@ -111,7 +112,8 @@
(add-hook 'ruby-mode-hook (add-hook 'ruby-mode-hook
'(lambda () '(lambda ()
(inf-ruby-keys) (inf-ruby-keys)
(ruby-electric-mode))) (ruby-electric-mode)
(c-subword-mode)))
(autoload 'rubydb "rubydb3x" "Ruby debugger" t) (autoload 'rubydb "rubydb3x" "Ruby debugger" t)
@ -152,7 +154,8 @@
(autoload 'js2-mode "js2-mode" nil t) (autoload 'js2-mode "js2-mode" nil t)
(add-to-list 'auto-mode-alist '("\\.js$" . js2-mode)) (add-to-list 'auto-mode-alist '("\\.js$" . js2-mode))
(add-hook 'js2-mode-hook '(lambda () (add-hook 'js2-mode-hook '(lambda ()
(local-set-key "\C-m" 'newline))) (local-set-key "\C-m" 'newline)
(c-subword-mode)))
(autoload #'espresso-mode "espresso" "Start espresso-mode" t) (autoload #'espresso-mode "espresso" "Start espresso-mode" t)
;;(add-to-list 'auto-mode-alist '("\\.js$" . espresso-mode)) ;;(add-to-list 'auto-mode-alist '("\\.js$" . espresso-mode))
@ -175,6 +178,18 @@
)) ))
;;;;;;;;;;;;
;; python ;;
;;;;;;;;;;;;
;; handy but ugly as fuck
(autoload 'whitespace-mode "whitespace"
"Toggle whitespace visualization." t)
(add-hook 'python-mode-hook '(lambda ()
(c-subword-mode)))
;;;;;;;;;;;; ;;;;;;;;;;;;
;; markup ;; ;; markup ;;
;;;;;;;;;;;; ;;;;;;;;;;;;

2543
emacs.d/whitespace.el Normal file

File diff suppressed because it is too large Load diff