diff options
| author | Stefan Monnier | 2010-05-02 22:29:46 -0400 |
|---|---|---|
| committer | Stefan Monnier | 2010-05-02 22:29:46 -0400 |
| commit | 56eb09046e00ac7ee6d3d3d752cb1ee664b7e062 (patch) | |
| tree | 6ff481ffba16576053b3cb2a8ad24a4f66bdec4a /lisp/term | |
| parent | 063371f2b0dc2519db3abcbe54955167bde8ca9e (diff) | |
| download | emacs-56eb09046e00ac7ee6d3d3d752cb1ee664b7e062.tar.gz emacs-56eb09046e00ac7ee6d3d3d752cb1ee664b7e062.zip | |
Use define-minor-mode where applicable.
* mh-show.el (mh-showing-mode): Move function to mh-e.el.
* mh-e.el (mh-showing-mode):
* url-dired.el (url-dired-minor-mode):
* org-table.el (orgtbl-mode):
* view.el (view-mode):
* type-break.el (type-break-query-mode)
(type-break-mode-line-message-mode):
* textmodes/reftex.el (reftex-mode):
* term/vt100.el (vt100-wide-mode):
* tar-mode.el (tar-subfile-mode):
* savehist.el (savehist-mode):
* ibuf-ext.el (ibuffer-auto-mode):
* composite.el (auto-composition-mode):
* progmodes/vhdl-mode.el (vhdl-electric-mode, vhdl-stutter-mode):
Use define-minor-mode.
(vhdl-mode): Use static mode-line format.
(vhdl-mode-line-update): Delete.
(vhdl-create-mode-menu, vhdl-activate-customizations)
(vhdl-hs-minor-mode): Don't bother calling it.
Diffstat (limited to 'lisp/term')
| -rw-r--r-- | lisp/term/vt100.el | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/lisp/term/vt100.el b/lisp/term/vt100.el index d0560702ac0..017c976ed51 100644 --- a/lisp/term/vt100.el +++ b/lisp/term/vt100.el | |||
| @@ -41,19 +41,13 @@ | |||
| 41 | (tty-run-terminal-initialization (selected-frame) "lk201")) | 41 | (tty-run-terminal-initialization (selected-frame) "lk201")) |
| 42 | 42 | ||
| 43 | ;;; Controlling the screen width. | 43 | ;;; Controlling the screen width. |
| 44 | (defvar vt100-wide-mode (= (frame-width) 132) | 44 | (define-minor-mode vt100-wide-mode |
| 45 | "t if vt100 is in 132-column mode.") | ||
| 46 | |||
| 47 | (defun vt100-wide-mode (&optional arg) | ||
| 48 | "Toggle 132/80 column mode for vt100s. | 45 | "Toggle 132/80 column mode for vt100s. |
| 49 | With positive argument, switch to 132-column mode. | 46 | With positive argument, switch to 132-column mode. |
| 50 | With negative argument, switch to 80-column mode." | 47 | With negative argument, switch to 80-column mode." |
| 51 | (interactive "P") | 48 | :global t :initial-value (= (frame-width) 132) |
| 52 | (setq vt100-wide-mode | 49 | (send-string-to-terminal (if vt100-wide-mode "\e[?3h" "\e[?3l")) |
| 53 | (if (null arg) (not vt100-wide-mode) | 50 | (set-frame-width terminal-frame (if vt100-wide-mode 132 80))) |
| 54 | (> (prefix-numeric-value arg) 0))) | ||
| 55 | (send-string-to-terminal (if vt100-wide-mode "\e[?3h" "\e[?3l")) | ||
| 56 | (set-frame-width terminal-frame (if vt100-wide-mode 132 80))) | ||
| 57 | 51 | ||
| 58 | ;; arch-tag: 9ff41f24-a7c9-4dee-9cf2-fbaa951eb840 | 52 | ;; arch-tag: 9ff41f24-a7c9-4dee-9cf2-fbaa951eb840 |
| 59 | ;;; vt100.el ends here | 53 | ;;; vt100.el ends here |