summaryrefslogtreecommitdiff
path: root/lisp/help-fns.el
diff options
context:
space:
mode:
authorMiles Bader <miles@gnu.org>2006-11-07 23:22:48 +0000
committerMiles Bader <miles@gnu.org>2006-11-07 23:22:48 +0000
commitdbc3b08c405a7b1c0ddb0fb0c98164b355802af5 (patch)
tree00c6f28244409d14bec11e221fb3c03daef63fc6 /lisp/help-fns.el
parentbbb6e8f2b6037dc1ee4ddd6cb63a1a6ddb04a591 (diff)
parent86cb14475e9e76f0b3323d2e7110a4a2bd310cdb (diff)
downloademacs-dbc3b08c405a7b1c0ddb0fb0c98164b355802af5.tar.gz
emacs-dbc3b08c405a7b1c0ddb0fb0c98164b355802af5.tar.bz2
emacs-dbc3b08c405a7b1c0ddb0fb0c98164b355802af5.zip
Merge from emacs--devo--0
Patches applied: * emacs--devo--0 (patch 490-504) - Update from CVS - Merge from gnus--rel--5.10 * gnus--rel--5.10 (patch 161-163) - Update from CVS - Merge from emacs--devo--0 Revision: emacs@sv.gnu.org/emacs--unicode--0--patch-130
Diffstat (limited to 'lisp/help-fns.el')
-rw-r--r--lisp/help-fns.el66
1 files changed, 0 insertions, 66 deletions
diff --git a/lisp/help-fns.el b/lisp/help-fns.el
index cddfa3611ed..8df079433f1 100644
--- a/lisp/help-fns.el
+++ b/lisp/help-fns.el
@@ -35,72 +35,6 @@
(require 'help-mode)
-
-;;;###autoload
-(defun help-with-tutorial (&optional arg)
- "Select the Emacs learn-by-doing tutorial.
-If there is a tutorial version written in the language
-of the selected language environment, that version is used.
-If there's no tutorial in that language, `TUTORIAL' is selected.
-With ARG, you are asked to choose which language."
- (interactive "P")
- (let ((lang (if arg
- (let ((minibuffer-setup-hook minibuffer-setup-hook))
- (add-hook 'minibuffer-setup-hook
- 'minibuffer-completion-help)
- (read-language-name 'tutorial "Language: " "English"))
- (if (get-language-info current-language-environment 'tutorial)
- current-language-environment
- "English")))
- file filename)
- (setq filename (get-language-info lang 'tutorial))
- (setq file (expand-file-name (concat "~/" filename)))
- (delete-other-windows)
- (if (get-file-buffer file)
- (switch-to-buffer (get-file-buffer file))
- (switch-to-buffer (create-file-buffer file))
- (setq buffer-file-name file)
- (setq default-directory (expand-file-name "~/"))
- (setq buffer-auto-save-file-name nil)
- (insert-file-contents (expand-file-name filename data-directory))
- (hack-local-variables)
- (goto-char (point-min))
- (search-forward "\n<<")
- (beginning-of-line)
- ;; Convert the <<...>> line to the proper [...] line,
- ;; or just delete the <<...>> line if a [...] line follows.
- (cond ((save-excursion
- (forward-line 1)
- (looking-at "\\["))
- (delete-region (point) (progn (forward-line 1) (point))))
- ((looking-at "<<Blank lines inserted.*>>")
- (replace-match "[Middle of page left blank for didactic purposes. Text continues below]"))
- (t
- (looking-at "<<")
- (replace-match "[")
- (search-forward ">>")
- (replace-match "]")))
- (beginning-of-line)
- (let ((n (- (window-height (selected-window))
- (count-lines (point-min) (point))
- 6)))
- (if (< n 8)
- (progn
- ;; For a short gap, we don't need the [...] line,
- ;; so delete it.
- (delete-region (point) (progn (end-of-line) (point)))
- (newline n))
- ;; Some people get confused by the large gap.
- (newline (/ n 2))
-
- ;; Skip the [...] line (don't delete it).
- (forward-line 1)
- (newline (- n (/ n 2)))))
- (goto-char (point-min))
- (setq buffer-undo-list nil)
- (set-buffer-modified-p nil))))
-
-
;; Functions
;;;###autoload