aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKevin Ryde2009-11-16 22:53:21 +0000
committerKevin Ryde2009-11-16 22:53:21 +0000
commite3c39c01f5cf08b0a1f1135c0ac721d142cc8a09 (patch)
tree54badefd323569d9e70e3ed9a023c9035a77804f
parent8834a98b6bef215589a21a0832b50a11def7de34 (diff)
downloademacs-e3c39c01f5cf08b0a1f1135c0ac721d142cc8a09.tar.gz
emacs-e3c39c01f5cf08b0a1f1135c0ac721d142cc8a09.zip
* textmodes/flyspell.el (sgml-mode-flyspell-verify): Use
`sgml-lexical-context' instead of own parse for tag. (Further to Bug#4511).
-rw-r--r--lisp/ChangeLog6
-rw-r--r--lisp/textmodes/flyspell.el15
2 files changed, 14 insertions, 7 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 67a56445aff..cfe1492a962 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,9 @@
12009-11-16 Kevin Ryde <user42@zip.com.au>
2
3 * textmodes/flyspell.el (sgml-mode-flyspell-verify): Use
4 `sgml-lexical-context' instead of own parse for tag. (Further to
5 Bug#4511).
6
12009-11-16 Dan Nicolaescu <dann@ics.uci.edu> 72009-11-16 Dan Nicolaescu <dann@ics.uci.edu>
2 8
3 * vc.el (vc-log-show-limit): Default to 2000. 9 * vc.el (vc-log-show-limit): Default to 2000.
diff --git a/lisp/textmodes/flyspell.el b/lisp/textmodes/flyspell.el
index bffbbbc3cc1..9aaf466f0ed 100644
--- a/lisp/textmodes/flyspell.el
+++ b/lisp/textmodes/flyspell.el
@@ -360,13 +360,14 @@ property of the major mode name.")
360(put 'nxml-mode 'flyspell-mode-predicate 'sgml-mode-flyspell-verify) 360(put 'nxml-mode 'flyspell-mode-predicate 'sgml-mode-flyspell-verify)
361 361
362(defun sgml-mode-flyspell-verify () 362(defun sgml-mode-flyspell-verify ()
363 "Function used for `flyspell-generic-check-word-predicate' in SGML mode." 363 "Function used for `flyspell-generic-check-word-predicate' in SGML mode.
364 (not (save-excursion 364Tag and attribute names are not spell checked, everything else is.
365 (or (looking-at "[^<\n]*>") 365
366 (ispell-looking-back "<[^>\n]*" (line-beginning-position)) 366String values of attributes are checked because they can be text
367 (and (looking-at "[^&\n]*;") 367like <img alt=\"Some thing.\">."
368 (ispell-looking-back "&[^;\n]*" 368
369 (line-beginning-position))))))) 369 (not (memq (car (sgml-lexical-context))
370 '(tag pi))))
370 371
371;;*---------------------------------------------------------------------*/ 372;;*---------------------------------------------------------------------*/
372;;* Programming mode */ 373;;* Programming mode */