* lisp/ps-print.el (ps-generate-postscript-with-faces):
authorStefan-W. Hahn <stefan.hahn@s-hahn.de>
Wed, 19 Mar 2014 19:12:50 +0000 (15:12 -0400)
committerStefan Monnier <monnier@iro.umontreal.ca>
Wed, 19 Mar 2014 19:12:50 +0000 (15:12 -0400)
Explicitly deactivate the mark.
* lisp/simple.el (deactivate-mark): Update region highlight.

Fixes: debbugs:16866

lisp/ChangeLog
lisp/ps-print.el
lisp/simple.el

index 50afbc2..4e75e88 100644 (file)
@@ -1,3 +1,9 @@
+2014-03-19  Stefan-W. Hahn  <stefan.hahn@s-hahn.de>
+
+       * ps-print.el (ps-generate-postscript-with-faces):
+       Explicitly deactivate the mark (bug#16866).
+       * simple.el (deactivate-mark): Update region highlight.
+
 2014-03-19  Juanma Barranquero  <lekktu@gmail.com>
 
        * emacs-lisp/package.el (describe-package-1):
index 6251a6c..004bdce 100644 (file)
@@ -6429,6 +6429,7 @@ If FACE is not a valid face name, use default face."
   (save-restriction
     (narrow-to-region from to)
     (ps-print-ensure-fontified from to)
+    (deactivate-mark)                   ;bug#16866.
     (ps-generate-postscript-with-faces1 from to)))
 
 (defun ps-generate-postscript (from to)
index 09a9d45..d77de2f 100644 (file)
@@ -4386,7 +4386,8 @@ run `deactivate-mark-hook'."
       (if (eq (car-safe transient-mark-mode) 'only)
          (setq transient-mark-mode (cdr transient-mark-mode)))
       (setq mark-active nil)
-      (run-hooks 'deactivate-mark-hook))))
+      (run-hooks 'deactivate-mark-hook))
+    (redisplay--update-region-highlight (selected-window))))
 
 (defun activate-mark (&optional no-tmm)
   "Activate the mark.