From 8f33b5f8734810e2feb0036bd9b0b34f51f7bc17 Mon Sep 17 00:00:00 2001 From: Nathan Weizenbaum Date: Tue, 10 Apr 2012 13:27:44 +0200 Subject: `python-fill-paragraph' filling fixup when font-lock is disabled * progmodes/python.el (python-fill-paragraph): Make python-fill-region in a multiline string work when font-lock is disabled. Fixes: debbugs:7018 --- lisp/progmodes/python.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lisp/progmodes/python.el') diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el index f7566c31b41..09b89993626 100644 --- a/lisp/progmodes/python.el +++ b/lisp/progmodes/python.el @@ -1959,7 +1959,7 @@ the string's indentation." ;; paragraph in a multi-line string properly, so narrow ;; to the string and then fill around (the end of) the ;; current line. - ((eq t (nth 3 syntax)) ; in fenced string + ((nth 3 syntax) ; in fenced string (goto-char (nth 8 syntax)) ; string start (setq start (line-beginning-position)) (setq end (condition-case () ; for unbalanced quotes -- cgit v1.2.1 From f45f90f33151dc74ef541cba4fe87565215382a0 Mon Sep 17 00:00:00 2001 From: Leo Liu Date: Tue, 17 Apr 2012 03:28:57 +0800 Subject: * lisp/progmodes/python.el: Trivial cleanup. --- lisp/progmodes/python.el | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) (limited to 'lisp/progmodes/python.el') diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el index 09b89993626..6f8758ebec1 100644 --- a/lisp/progmodes/python.el +++ b/lisp/progmodes/python.el @@ -69,11 +69,7 @@ (require 'comint) (require 'ansi-color) -(eval-when-compile - (require 'compile) - (require 'hippie-exp)) - -(autoload 'comint-mode "comint") +(eval-when-compile (require 'compile)) (defgroup python nil "Silly walks in the Python language." @@ -1488,8 +1484,6 @@ Don't save anything for STR matching `inferior-python-filter-regexp'." res) (t (concat res s))))) -(autoload 'comint-check-proc "comint") - (defvar python-version-checked nil) (defun python-check-version (cmd) "Check that CMD runs a suitable version of Python." @@ -1684,8 +1678,6 @@ value to determine defaults." "Caches (directory . file) pair used in the last `python-load-file' command. Used for determining the default in the next one.") -(autoload 'comint-get-source "comint") - (defun python-load-file (file-name) "Load a Python file FILE-NAME into the inferior Python process. If the file has extension `.py' import or reload it as a module. -- cgit v1.2.1 From 376cbaccd90fe54837eb452f5d6c1cda42e0e8fc Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Thu, 19 Apr 2012 18:50:07 +0200 Subject: Remove some `toggle-read-only' warnings. * lisp/bs.el (bs-toggle-readonly): Call `toggle-read-only' interactively. * lisp/descr-text.el (describe-char): lisp/progmodes/python.el (python-describe-symbol): Don't call `toggle-read-only', set `buffer-read-only'. --- lisp/progmodes/python.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lisp/progmodes/python.el') diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el index 6f8758ebec1..2922330e6f9 100644 --- a/lisp/progmodes/python.el +++ b/lisp/progmodes/python.el @@ -1768,7 +1768,7 @@ will." ;; allow C-c C-f in help buffer. (let ((temp-buffer-show-hook ; avoid xref stuff (lambda () - (toggle-read-only 1) + (setq buffer-read-only t) (setq view-return-to-alist (list (cons (selected-window) help-return-method)))))) (with-output-to-temp-buffer (help-buffer) -- cgit v1.2.1