aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGlenn Morris2007-09-19 07:24:45 +0000
committerGlenn Morris2007-09-19 07:24:45 +0000
commit120d9fb5a2cf634cf3bf0ca612d44599a0c31f07 (patch)
tree408b00793d899fe50a33c36f38a33c9a67f874bc
parent41c12ad8763e633735e1b9b7e2d786ec20219341 (diff)
downloademacs-120d9fb5a2cf634cf3bf0ca612d44599a0c31f07.tar.gz
emacs-120d9fb5a2cf634cf3bf0ca612d44599a0c31f07.zip
(tex-terminate-paragraph): Leave point at the site of any mismatch.
-rw-r--r--lisp/textmodes/tex-mode.el23
1 files changed, 11 insertions, 12 deletions
diff --git a/lisp/textmodes/tex-mode.el b/lisp/textmodes/tex-mode.el
index 3a7a9880d38..e2e0f702547 100644
--- a/lisp/textmodes/tex-mode.el
+++ b/lisp/textmodes/tex-mode.el
@@ -1272,19 +1272,18 @@ area if a mismatch is found."
1272Check for mismatched braces or $s in paragraph being terminated. 1272Check for mismatched braces or $s in paragraph being terminated.
1273A prefix arg inhibits the checking." 1273A prefix arg inhibits the checking."
1274 (interactive "*P") 1274 (interactive "*P")
1275 (insert "\n\n")
1275 (or inhibit-validation 1276 (or inhibit-validation
1276 (save-excursion 1277 ;; For the purposes of this, a "paragraph" is a block of text
1277 ;; For the purposes of this, a "paragraph" is a block of text 1278 ;; wherein all the brackets etc are expected to be balanced. It
1278 ;; wherein all the brackets etc are expected to be balanced. It 1279 ;; may start after a blank line (ie a "proper" paragraph), or
1279 ;; may start after a blank line (ie a "proper" paragraph), or 1280 ;; a begin{} or end{} block, etc.
1280 ;; a begin{} or end{} block, etc. 1281 (tex-validate-region
1281 (tex-validate-region 1282 (save-excursion
1282 (save-excursion 1283 (backward-paragraph)
1283 (backward-paragraph) 1284 (point))
1284 (point)) 1285 (point))
1285 (point))) 1286 (message "Paragraph being closed appears to contain a mismatch")))
1286 (message "Paragraph being closed appears to contain a mismatch"))
1287 (insert "\n\n"))
1288 1287
1289(define-skeleton tex-insert-braces 1288(define-skeleton tex-insert-braces
1290 "Make a pair of braces and be poised to type inside of them." 1289 "Make a pair of braces and be poised to type inside of them."