From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Juanma Barranquero Newsgroups: gmane.emacs.bugs Subject: bug#11017: 24.0.94; emacs-lock--kill-emacs-query-functions should ding Date: Thu, 15 Mar 2012 13:54:12 +0100 Message-ID: References: <86mx7i79lb.fsf@web.de> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1331816177 9679 80.91.229.3 (15 Mar 2012 12:56:17 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 15 Mar 2012 12:56:17 +0000 (UTC) Cc: 11017@debbugs.gnu.org To: Michael Heerdegen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Mar 15 13:56:15 2012 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1S8AE1-0001x6-5S for geb-bug-gnu-emacs@m.gmane.org; Thu, 15 Mar 2012 13:56:13 +0100 Original-Received: from localhost ([::1]:50084 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1S8AE0-0003Tj-Kf for geb-bug-gnu-emacs@m.gmane.org; Thu, 15 Mar 2012 08:56:12 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:58986) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1S8ADp-0003SW-U6 for bug-gnu-emacs@gnu.org; Thu, 15 Mar 2012 08:56:11 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1S8ADk-0002BZ-Ox for bug-gnu-emacs@gnu.org; Thu, 15 Mar 2012 08:56:01 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:44961) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1S8ADk-0002BT-Ix for bug-gnu-emacs@gnu.org; Thu, 15 Mar 2012 08:55:56 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1S8Ags-000490-Kr for bug-gnu-emacs@gnu.org; Thu, 15 Mar 2012 09:26:03 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Juanma Barranquero Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 15 Mar 2012 13:26:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 11017 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 11017-submit@debbugs.gnu.org id=B11017.133181792515887 (code B ref 11017); Thu, 15 Mar 2012 13:26:02 +0000 Original-Received: (at 11017) by debbugs.gnu.org; 15 Mar 2012 13:25:25 +0000 Original-Received: from localhost ([127.0.0.1]:51793 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1S8Ag6-000482-Kt for submit@debbugs.gnu.org; Thu, 15 Mar 2012 09:25:19 -0400 Original-Received: from mail-yx0-f172.google.com ([209.85.213.172]:62055) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1S8Afs-00047U-BX for 11017@debbugs.gnu.org; Thu, 15 Mar 2012 09:25:12 -0400 Original-Received: by yenm5 with SMTP id m5so2937778yen.3 for <11017@debbugs.gnu.org>; Thu, 15 Mar 2012 05:54:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type:content-transfer-encoding; bh=HXzIte3gIugGpvAVO8V6tbqLdNKNKTNhqKy0U5nvspo=; b=BKBw2aTkLjfXoflDU1TukNQ6/JvjyzmrDT8y+MVJClpVkK4YsAFij9Id5je4+gUFiL bnsHcmjgFeKnQn+8qgP2xP+lTHYRx/q7N/hA+lpK8Vzhod8BUNH8MLpR6B0QcWaf+r+q E9gi7iug9zmLF0DxQa7WkKzll5ioSezWnor+vlrTNK+8xpTWO4mDcBl69t8wTZ1fDlkg zKL1j0gVlGXW2rC+5Mg7TF4vRPjnVrO6M7xHWK/69r98SBKAt9nHK6helueM4ElkgtMH OMtMa8mRPtCeUYi2QqTMliLG8jfXhpM/3ABWTHs8hD/9IHDv9+lzKvF1ueAqUvId7viV QKfA== Original-Received: by 10.68.229.33 with SMTP id sn1mr5129455pbc.59.1331816092230; Thu, 15 Mar 2012 05:54:52 -0700 (PDT) Original-Received: by 10.142.71.15 with HTTP; Thu, 15 Mar 2012 05:54:12 -0700 (PDT) In-Reply-To: <86mx7i79lb.fsf@web.de> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:57804 Archived-At: On Thu, Mar 15, 2012 at 05:48, Michael Heerdegen wrote: > if I lock a buffer and try to exit Emacs, I only get a message: > > =C2=A0"Buffer %S is locked and cannot be killed" Really? I get "Emacs cannot exit because buffer %S is locked". > This is IMHO not enough. =C2=A0If the user tries to exit Emacs while ther= e > are locked buffers, he obviously has forgotten about these locks. So, > there should be a (ding) to attract the user's attention. A ding is obnoxious to many people. It could be added as an option, but it is not really necessary IMHO. You can use (defadvice emacs-lock--kill-emacs-query-functions (around do-ding activate) ad-do-it (unless ad-return-value (ding))) (defadvice emacs-lock--kill-emacs-hook (around do-ding activate) (condition-case err ad-do-it (error (ding) (signal (car err) (cdr err))))) > Without this, the user will possibly continue saying "yes" to the > expected questions Emacs typically asks, and accidentally modify some > buffer, which is annoying. Getting into the habit of typing without reading what Emac is saying is dangerous because you can end typing Y to a question you would've rather said N... =C2=A0 =C2=A0 Juanma