]> code.delx.au - gnu-emacs/blobdiff - lisp/nxml/nxml-outln.el
Update copyright year to 2015
[gnu-emacs] / lisp / nxml / nxml-outln.el
index 6a2a9daf7e494f2764e27e00c254200a205a8012..a8dc5b158b254a7f9a425bcc36ef0067172aac2a 100644 (file)
@@ -1,9 +1,9 @@
 ;;; nxml-outln.el --- outline support for nXML mode
 
-;; Copyright (C) 2004, 2007-201 Free Software Foundation, Inc.
+;; Copyright (C) 2004, 2007-2015 Free Software Foundation, Inc.
 
 ;; Author: James Clark
-;; Keywords: XML
+;; Keywords: wp, hypermedia, languages, XML
 
 ;; This file is part of GNU Emacs.
 
@@ -60,7 +60,7 @@
 ;; form.  Single-line form is used when the outline state is hide-children
 ;; or there are no child sections; multi-line form is used otherwise.
 ;; There are two flavors of single-line form: with children and without.
-;; The with-childen flavor is used when there are child sections.
+;; The with-children flavor is used when there are child sections.
 ;; Single line with children looks like
 ;;    <+section>A section title...</>
 ;; Single line without children looks like
@@ -109,23 +109,20 @@ See the variable `nxml-section-element-name-regexp' for more details."
   :group 'nxml
   :type 'integer)
 
-(defface nxml-heading
-  '((t (:weight bold)))
-  "Face used for the contents of abbreviated heading elements."
+(defface nxml-heading '((t :weight bold))
+  "Face for the contents of abbreviated heading elements."
   :group 'nxml-faces)
 
-(defface nxml-outline-indicator
-  '((t (:inherit default)))
-  "Face used for `+' or `-' before element names in outlines."
+(defface nxml-outline-indicator '((t))
+  "Face for `+' or `-' before element names in outlines."
   :group 'nxml-faces)
 
 (defface nxml-outline-active-indicator
-  '((t (:box t :inherit nxml-outline-indicator)))
-  "Face used for clickable `+' or `-' before element names in outlines."
+  '((t :box t :inherit nxml-outline-indicator))
+  "Face for clickable `+' or `-' before element names in outlines."
   :group 'nxml-faces)
 
-(defface nxml-outline-ellipsis
-  '((t (:bold t :inherit default)))
+(defface nxml-outline-ellipsis '((t :weight bold))
   "Face used for `...' in outlines."
   :group 'nxml-faces)
 
@@ -152,7 +149,7 @@ See the variable `nxml-section-element-name-regexp' for more details."
 (defun nxml-show-all ()
   "Show all elements in the buffer normally."
   (interactive)
-  (nxml-with-unmodifying-text-property-changes
+  (with-silent-modifications
     (remove-text-properties (point-min)
                            (point-max)
                            '(nxml-outline-state nil)))
@@ -373,7 +370,7 @@ customize which elements are recognized as sections and headings."
   (get-text-property pos 'nxml-outline-state))
 
 (defun nxml-set-outline-state (pos state)
-  (nxml-with-unmodifying-text-property-changes
+  (with-silent-modifications
     (if state
        (put-text-property pos (1+ pos) 'nxml-outline-state state)
       (remove-text-properties pos (1+ pos) '(nxml-outline-state nil)))))
@@ -1011,13 +1008,8 @@ immediately after the section's start-tag."
 (defun nxml-outline-error (&rest args)
   (signal 'nxml-outline-error args))
 
-(put 'nxml-outline-error
-     'error-conditions
-     '(error nxml-error nxml-outline-error))
-
-(put 'nxml-outline-error
-     'error-message
-     "Cannot create outline of buffer that is not well-formed")
+(define-error 'nxml-outline-error
+  "Cannot create outline of buffer that is not well-formed" 'nxml-error)
 
 ;;; Debugging