Added folding-mode, might be useful after all

This commit is contained in:
Tom Willemsen 2011-04-13 16:54:04 +02:00
parent 8cb832f073
commit 2173039ef6
6 changed files with 5479 additions and 31 deletions

View file

@ -1,5 +1,4 @@
(global-set-key "\C-m" 'newline-and-indent)
; Automatically indent on newline
(global-set-key (kbd "C-x n r") 'narrow-to-region)
(global-set-key [C-tab] 'hs-toggle-hiding)
(global-set-key (kbd "<f9>") 'compile)

View file

@ -1,21 +1,22 @@
;;{{{ Requires
(require 'naquadah-theme)
(require 'autopair)
;(load "autostart.el")
(autoload 'vala-mode
"vala-mode" "A Major mode for editing Vala files" t)
(autoload 'csharp-mode
"csharp-mode" "A Major mode for editing C# files" t)
(autoload 'javascript-mode
"javascript" "A Major mode for editing JavaScript files" t)
(autoload 'sqlplus-mode
"sqlplus" "A Major mode for communicating with Oracle" t)
(autoload 'batch-mode
"batch-mode" "A Major mode for editing Batch files" t)
(autoload 'lua-mode
"lua-mode" "A Major mode for editing Lua files" t)
(autoload 'php-mode
"php-mode-improved" "A Major mode for editing PHP files" t)
(autoload 'graphviz-dot-mode
"graphviz-dot-mode" "A Major mode for editing graphviz dot files" t)
;;}}}
;;{{{ Auto loads
(autoload 'vala-mode "vala-mode"
"A Major mode for editing Vala files" t)
(autoload 'csharp-mode "csharp-mode"
"A Major mode for editing C# files" t)
(autoload 'javascript-mode "javascript"
"A Major mode for editing JavaScript files" t)
(autoload 'sqlplus-mode "sqlplus"
"A Major mode for communicating with Oracle" t)
(autoload 'batch-mode "batch-mode"
"A Major mode for editing Batch files" t)
(autoload 'lua-mode "lua-mode"
"A Major mode for editing Lua files" t)
(autoload 'php-mode "php-mode-improved"
"A Major mode for editing PHP files" t)
(autoload 'graphviz-dot-mode "graphviz-dot-mode"
"A Major mode for editing graphviz dot files" t)
;;}}}

View file

@ -1,10 +1,19 @@
;;{{{ Load
(require 'column-marker)
(add-hook 'c-mode-hook
(lambda ()
(column-marker-1 73)
(column-marker-2 81)))
(add-hook 'html-mode-hook
(lambda ()
(column-marker-1 73)
(column-marker-2 81)))
;;}}}
;;{{{ Functions
(defun set-column-marker ()
(column-marker-1 73)
(column-marker-2 81))
;;}}}
;;{{{ Hooks
(add-hook 'c-mode-hook 'set-column-marker)
(add-hook 'emacs-lisp-mode-hook 'set-column-marker)
(add-hook 'html-mode-hook 'set-column-marker)
;;}}}

26
emacs.d/20-folding.el Normal file
View file

@ -0,0 +1,26 @@
;;{{{ Load
(autoload 'folding-mode "folding" "Folding mode" t)
;;}}}
;;{{{ Settings
;;{{{ Startup
(add-hook 'folding-mode-hook
(lambda ()
(local-set-key [C-Tab] 'folding-toggle-show-hide)))
;;}}}
;;}}}
;;{{{ Hooks
;;{{{ C
(add-hook 'c-mode-hook
(lambda ()
(folding-mode)))
;;}}}
;;{{{ Emacs Lisp
(add-hook 'emacs-lisp-mode-hook
(lambda ()
(folding-mode)))
;;}}}
;;}}}

View file

@ -1,3 +0,0 @@
(add-hook 'c-mode-hook
(lambda ()
(hs-minor-mode t)))

5416
emacs.d/elisp/folding.el Normal file

File diff suppressed because it is too large Load diff