summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard M. Stallman <rms@gnu.org>1997-07-20 17:41:31 +0000
committerRichard M. Stallman <rms@gnu.org>1997-07-20 17:41:31 +0000
commit61b42f915a09c42564d79db4db149ff09cfcd667 (patch)
tree0efca530f7efeca99ea6f4b7d535b870c93fca73
parent44ceef9fb9ba3b7ecc8250918c3bf97168ea3694 (diff)
downloademacs-61b42f915a09c42564d79db4db149ff09cfcd667.tar.gz
(texinfo-no-refill-regexp): Add "direntry".
(texinfo-format-direntry, texinfo-end-direntry): New functions. (texinfo-format-dircategory): New function.
-rw-r--r--lisp/textmodes/texinfmt.el24
1 files changed, 24 insertions, 0 deletions
diff --git a/lisp/textmodes/texinfmt.el b/lisp/textmodes/texinfmt.el
index 885a0625901..0ecaa91a7c5 100644
--- a/lisp/textmodes/texinfmt.el
+++ b/lisp/textmodes/texinfmt.el
@@ -467,6 +467,7 @@ Info-split to do these manually."
(concat
"^@"
"\\("
+ "direntry\\|"
"example\\|"
"smallexample\\|"
"lisp\\|"
@@ -2370,6 +2371,29 @@ If used within a line, follow `@bullet' with braces."
(insert "\n ")))
+;; @direntry and @dircategory
+
+(put 'direntry 'texinfo-format 'texinfo-format-direntry)
+(defun texinfo-format-direntry ()
+ (texinfo-push-stack 'direntry nil)
+ (texinfo-discard-line)
+ (insert "START-INFO-DIR-ENTRY\n\n"))
+
+(put 'direntry 'texinfo-end 'texinfo-end-direntry)
+(defun texinfo-end-direntry ()
+ (texinfo-discard-command)
+ (insert "END-INFO-DIR-ENTRY\n")
+ (texinfo-pop-stack 'direntry))
+
+(put 'dircategory 'texinfo-format 'texinfo-format-dircategory)
+(defun texinfo-format-dircategory ()
+ (texinfo-discard-command)
+ (delete-region (point)
+ (progn
+ (skip-chars-forward " ")
+ (point)))
+ (insert "INFO-DIR-SECTION "))
+
;;; @cartouche
;; The @cartouche command is a noop in Info; in a printed manual,