Mercurial > emacs
comparison lisp/man.el @ 50062:b43d8c1413de
* man.el (Man-getpage-in-background): Always use `setenv' for
environment variables, instead of modifying process-environment
directly. The previous version let-bound process-environment --
the let-binding is skipped for GROFF_NO_SGR because there is
already a let-binding in effect in some outer scope.
* emulation/crisp.el (top-level): Interoperate with cua.
author | Kai Großjohann <kgrossjo@eu.uu.net> |
---|---|
date | Sun, 09 Mar 2003 14:05:25 +0000 |
parents | a323f25ec045 |
children | 7dc2f9f7086b |
comparison
equal
deleted
inserted
replaced
50061:16f19efe98b2 | 50062:b43d8c1413de |
---|---|
621 (if (fboundp 'start-process) | 621 (if (fboundp 'start-process) |
622 (set-process-sentinel | 622 (set-process-sentinel |
623 (start-process manual-program buffer "sh" "-c" | 623 (start-process manual-program buffer "sh" "-c" |
624 (format (Man-build-man-command) man-args)) | 624 (format (Man-build-man-command) man-args)) |
625 'Man-bgproc-sentinel) | 625 'Man-bgproc-sentinel) |
626 (let ((process-environment | 626 (setenv "GROFF_NO_SGR" "1") |
627 (cons "GROFF_NO_SGR=1" process-environment))) | 627 (let ((exit-status |
628 | 628 (call-process shell-file-name nil (list buffer nil) nil "-c" |
629 (let ((exit-status | 629 (format (Man-build-man-command) man-args))) |
630 (call-process shell-file-name nil (list buffer nil) nil "-c" | 630 (msg "")) |
631 (format (Man-build-man-command) man-args))) | 631 (or (and (numberp exit-status) |
632 (msg "")) | 632 (= exit-status 0)) |
633 (or (and (numberp exit-status) | 633 (and (numberp exit-status) |
634 (= exit-status 0)) | 634 (setq msg |
635 (and (numberp exit-status) | 635 (format "exited abnormally with code %d" |
636 (setq msg | 636 exit-status))) |
637 (format "exited abnormally with code %d" | 637 (setq msg exit-status)) |
638 exit-status))) | 638 (Man-bgproc-sentinel bufname msg))))))) |
639 (setq msg exit-status)) | |
640 (Man-bgproc-sentinel bufname msg)))))))) | |
641 | 639 |
642 (defun Man-notify-when-ready (man-buffer) | 640 (defun Man-notify-when-ready (man-buffer) |
643 "Notify the user when MAN-BUFFER is ready. | 641 "Notify the user when MAN-BUFFER is ready. |
644 See the variable `Man-notify-method' for the different notification behaviors." | 642 See the variable `Man-notify-method' for the different notification behaviors." |
645 (let ((saved-frame (save-excursion | 643 (let ((saved-frame (save-excursion |