aboutsummaryrefslogtreecommitdiffstats
path: root/admin/admin.el
diff options
context:
space:
mode:
authorGlenn Morris2013-12-30 10:58:16 -0800
committerGlenn Morris2013-12-30 10:58:16 -0800
commit9d1804dcb8b711a6d7eee16f0f54f3d418e2cb53 (patch)
treefa478f9b188b389bcb68bff7bfe1a037b7b83379 /admin/admin.el
parent1b7259fce2719182e2b557682e40d02807784d1f (diff)
downloademacs-9d1804dcb8b711a6d7eee16f0f54f3d418e2cb53.tar.gz
emacs-9d1804dcb8b711a6d7eee16f0f54f3d418e2cb53.zip
* admin.el (manual-html-fix-headers, manual-html-fix-index-1):
Some updates for changes in Texinfo 5 output.
Diffstat (limited to 'admin/admin.el')
-rw-r--r--admin/admin.el19
1 files changed, 12 insertions, 7 deletions
diff --git a/admin/admin.el b/admin/admin.el
index 571bd824143..f178ef61f16 100644
--- a/admin/admin.el
+++ b/admin/admin.el
@@ -395,20 +395,25 @@ the @import directive."
395 395
396(defun manual-html-fix-headers () 396(defun manual-html-fix-headers ()
397 "Fix up HTML headers for the Emacs manual in the current buffer." 397 "Fix up HTML headers for the Emacs manual in the current buffer."
398 (let (opoint) 398 (let ((texi5 (search-forward "<!DOCTYPE" nil t))
399 (insert manual-doctype-string) 399 opoint)
400 ;; Texinfo 5 supplies a DOCTYPE.
401 (or texi5
402 (insert manual-doctype-string))
400 (search-forward "<head>\n") 403 (search-forward "<head>\n")
401 (insert manual-meta-string) 404 (insert manual-meta-string)
402 (search-forward "<meta") 405 (search-forward "<meta")
403 (setq opoint (match-beginning 0)) 406 (setq opoint (match-beginning 0))
404 (re-search-forward "<!--") 407 (unless texi5
408 (search-forward "<!--")
405 (goto-char (match-beginning 0)) 409 (goto-char (match-beginning 0))
406 (delete-region opoint (point)) 410 (delete-region opoint (point))
407 (insert manual-style-string)
408 (search-forward "<meta http-equiv=\"Content-Style") 411 (search-forward "<meta http-equiv=\"Content-Style")
409 (setq opoint (match-beginning 0)) 412 (setq opoint (match-beginning 0)))
410 (search-forward "</head>") 413 (search-forward "</head>")
411 (delete-region opoint (match-beginning 0)))) 414 (goto-char (match-beginning 0))
415 (delete-region opoint (point))
416 (insert manual-style-string)))
412 417
413(defun manual-html-fix-node-div () 418(defun manual-html-fix-node-div ()
414 "Fix up HTML \"node\" divs in the current buffer." 419 "Fix up HTML \"node\" divs in the current buffer."
@@ -426,7 +431,7 @@ the @import directive."
426 431
427(defun manual-html-fix-index-1 () 432(defun manual-html-fix-index-1 ()
428 (let (opoint) 433 (let (opoint)
429 (re-search-forward "<body>\n") 434 (re-search-forward "<body.*>\n")
430 (setq opoint (match-end 0)) 435 (setq opoint (match-end 0))
431 (search-forward "<h2 class=\"") 436 (search-forward "<h2 class=\"")
432 (goto-char (match-beginning 0)) 437 (goto-char (match-beginning 0))