diff options
| author | Richard M. Stallman | 1994-08-25 23:23:09 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 1994-08-25 23:23:09 +0000 |
| commit | dcd12c89db5fd376f80a878759c1a6dff18dfcb3 (patch) | |
| tree | 5114f0d4ad078d6c4d867bfa1913ee214dc093a7 | |
| parent | 911398a97f4cdd8f40ff090e40fe2015dd1e0ead (diff) | |
| download | emacs-dcd12c89db5fd376f80a878759c1a6dff18dfcb3.tar.gz emacs-dcd12c89db5fd376f80a878759c1a6dff18dfcb3.zip | |
(toggle-rot13-mode): New function.
| -rw-r--r-- | lisp/rot13.el | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/lisp/rot13.el b/lisp/rot13.el index 3cad307cab5..9c831320707 100644 --- a/lisp/rot13.el +++ b/lisp/rot13.el | |||
| @@ -52,6 +52,15 @@ To terminate the rot13 display, delete that window." | |||
| 52 | (let ((w (display-buffer (current-buffer) t))) | 52 | (let ((w (display-buffer (current-buffer) t))) |
| 53 | (set-window-display-table w rot13-display-table))) | 53 | (set-window-display-table w rot13-display-table))) |
| 54 | 54 | ||
| 55 | ;;;###autoload | ||
| 56 | (defun toggle-rot13-mode () | ||
| 57 | "Toggle the use of rot 13 encoding for the current window." | ||
| 58 | (interactive) | ||
| 59 | (if (eq (window-display-table (selected-window)) rot13-display-table) | ||
| 60 | (set-window-display-table (selected-window) nil) | ||
| 61 | (if (null (window-display-table (selected-window))) | ||
| 62 | (set-window-display-table (selected-window) rot13-display-table)))) | ||
| 63 | |||
| 55 | (provide 'rot13) | 64 | (provide 'rot13) |
| 56 | 65 | ||
| 57 | ;;; rot13.el ends here | 66 | ;;; rot13.el ends here |