Mercurial > emacs
comparison lisp/progmodes/cperl-mode.el @ 90070:95879cc1ed20
Revision: miles@gnu.org--gnu-2004/emacs--unicode--0--patch-81
Merge from emacs--cvs-trunk--0
Patches applied:
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-748
- miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-749
Update from CVS
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-750
Merge from gnus--rel--5.10
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-751
- miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-753
Update from CVS
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-754
Merge from gnus--rel--5.10
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-755
- miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-757
Update from CVS
* miles@gnu.org--gnu-2004/gnus--rel--5.10--patch-78
Merge from emacs--cvs-trunk--0
* miles@gnu.org--gnu-2004/gnus--rel--5.10--patch-79
- miles@gnu.org--gnu-2004/gnus--rel--5.10--patch-80
Update from CVS
* miles@gnu.org--gnu-2004/gnus--rel--5.10--patch-81
Merge from emacs--cvs-trunk--0
* miles@gnu.org--gnu-2004/gnus--rel--5.10--patch-82
Update from CVS
author | Miles Bader <miles@gnu.org> |
---|---|
date | Sun, 02 Jan 2005 09:13:19 +0000 |
parents | f2ebccfa87d4 520077017d32 |
children | 4da4a09e8b1b |
comparison
equal
deleted
inserted
replaced
90069:fa0a5c4db2c8 | 90070:95879cc1ed20 |
---|---|
1460 (setq paragraph-ignore-fill-prefix t) | 1460 (setq paragraph-ignore-fill-prefix t) |
1461 (set (make-local-variable 'fill-paragraph-function) 'cperl-fill-paragraph) | 1461 (set (make-local-variable 'fill-paragraph-function) 'cperl-fill-paragraph) |
1462 (make-local-variable 'indent-line-function) | 1462 (make-local-variable 'indent-line-function) |
1463 (setq indent-line-function 'cperl-indent-line) | 1463 (setq indent-line-function 'cperl-indent-line) |
1464 (make-local-variable 'require-final-newline) | 1464 (make-local-variable 'require-final-newline) |
1465 (setq require-final-newline t) | 1465 (setq require-final-newline mode-require-final-newline) |
1466 (make-local-variable 'comment-start) | 1466 (make-local-variable 'comment-start) |
1467 (setq comment-start "# ") | 1467 (setq comment-start "# ") |
1468 (make-local-variable 'comment-end) | 1468 (make-local-variable 'comment-end) |
1469 (setq comment-end "") | 1469 (setq comment-end "") |
1470 (make-local-variable 'comment-column) | 1470 (make-local-variable 'comment-column) |
6024 Prompts user for insertion of spaces. | 6024 Prompts user for insertion of spaces. |
6025 Currently it is tuned to C and Perl syntax." | 6025 Currently it is tuned to C and Perl syntax." |
6026 (interactive) | 6026 (interactive) |
6027 (let (found-bad (p (point))) | 6027 (let (found-bad (p (point))) |
6028 (setq last-nonmenu-event 13) ; To disable popup | 6028 (setq last-nonmenu-event 13) ; To disable popup |
6029 (beginning-of-buffer) | 6029 (with-no-warnings ; It is useful to push the mark here. |
6030 (beginning-of-buffer)) | |
6030 (map-y-or-n-p "Insert space here? " | 6031 (map-y-or-n-p "Insert space here? " |
6031 (lambda (arg) (insert " ")) | 6032 (lambda (arg) (insert " ")) |
6032 'cperl-next-bad-style | 6033 'cperl-next-bad-style |
6033 '("location" "locations" "insert a space into") | 6034 '("location" "locations" "insert a space into") |
6034 '((?\C-r (lambda (arg) | 6035 '((?\C-r (lambda (arg) |
7181 | 7182 |
7182 | 7183 |
7183 ;;; Plug for wrong font-lock: | 7184 ;;; Plug for wrong font-lock: |
7184 | 7185 |
7185 (defun cperl-font-lock-unfontify-region-function (beg end) | 7186 (defun cperl-font-lock-unfontify-region-function (beg end) |
7186 (let* ((modified (buffer-modified-p)) (buffer-undo-list t) | 7187 ;; Simplified now that font-lock-unfontify-region uses save-buffer-state. |
7187 (inhibit-read-only t) (inhibit-point-motion-hooks t) | 7188 (let (before-change-functions after-change-functions) |
7188 before-change-functions after-change-functions | 7189 (remove-text-properties beg end '(face nil)))) |
7189 deactivate-mark buffer-file-name buffer-file-truename) | |
7190 (remove-text-properties beg end '(face nil)) | |
7191 (when (and (not modified) (buffer-modified-p)) | |
7192 (set-buffer-modified-p nil)))) | |
7193 | 7190 |
7194 (defvar cperl-d-l nil) | 7191 (defvar cperl-d-l nil) |
7195 (defun cperl-fontify-syntaxically (end) | 7192 (defun cperl-fontify-syntaxically (end) |
7196 ;; Some vars for debugging only | 7193 ;; Some vars for debugging only |
7197 ;; (message "Syntaxifying...") | 7194 ;; (message "Syntaxifying...") |