comparison .elisp/settings/40.modes.el @ 290:7a99481ab888

python-mode: enable flyspell-prog-mode for spellchecking in comments in Python
author Augie Fackler <raf@durin42.com>
date Wed, 17 Oct 2012 08:21:19 -0500
parents 884f7f932a83
children a9e3c2ca6fa5
comparison
equal deleted inserted replaced
289:5fd871a98b5f 290:7a99481ab888
46 (add-to-list 'auto-mode-alist '("\\.rhtml$'" . django-html-mode)) 46 (add-to-list 'auto-mode-alist '("\\.rhtml$'" . django-html-mode))
47 (add-hook 'django-html-mode-hook '(lambda () 47 (add-hook 'django-html-mode-hook '(lambda ()
48 (local-set-key (kbd "RET") 48 (local-set-key (kbd "RET")
49 'reindent-then-newline-and-indent))) 49 'reindent-then-newline-and-indent)))
50 (defun af-python-mode-hook () 50 (defun af-python-mode-hook ()
51 (flyspell-prog-mode)
51 ; highlight tabs in Python 52 ; highlight tabs in Python
52 (make-variable-buffer-local 'font-lock-mode-hook) 53 (make-variable-buffer-local 'font-lock-mode-hook)
53 (make-variable-buffer-local 'python-indent) 54 (make-variable-buffer-local 'python-indent)
54 (if (and buffer-file-name (string-match "melange" buffer-file-name)) 55 (if (and buffer-file-name (string-match "melange" buffer-file-name))
55 (set-variable 'python-indent 2)) 56 (set-variable 'python-indent 2))