Subject: Re: bug#11520: 24.1.50; delete-selection-mode conflicts with electric-pair-mode

From: Simon Law <[email-masked]>
Date: Mon, 11 Jun 2012 17:24:14 -0400

I now use the following workaround, in order to preserve
string-wrapping behaviour:

(defadvice delete-active-region (around electric-pair-or-delete-active-region
                                        activate)
  "Prevent delete-active-region from clobbering electric-pair-mode."
  (unless (and electric-pair-mode
               (or (memq (char-syntax last-command-event) '(?\( ?\"))
                   (assq last-command-event electric-pair-pairs)))
    ad-do-it)
  t)

-- 
Cheers,
Simon - http://ca.linkedin.com/in/sfllaw/