From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#61553: 29.0.60; Inconsistent use of dialog boxes by read-multiple-choice Date: Thu, 16 Feb 2023 22:17:18 +0200 Message-ID: <83a61d2wmp.fsf@gnu.org> References: <87a61dfur1.fsf@gmail.com> <83edqp330z.fsf@gnu.org> <875yc1foej.fsf@gmail.com> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="9286"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 61553@debbugs.gnu.org To: Augusto Stoffel Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Feb 16 21:18:18 2023 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pSkht-0002CY-FH for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 16 Feb 2023 21:18:17 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pSkhg-0000L9-Aw; Thu, 16 Feb 2023 15:18:04 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pSkhf-0000L1-Ce for bug-gnu-emacs@gnu.org; Thu, 16 Feb 2023 15:18:03 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pSkhf-0008WD-3E for bug-gnu-emacs@gnu.org; Thu, 16 Feb 2023 15:18:03 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pSkhe-0006Hd-9C for bug-gnu-emacs@gnu.org; Thu, 16 Feb 2023 15:18:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 16 Feb 2023 20:18:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 61553 X-GNU-PR-Package: emacs Original-Received: via spool by 61553-submit@debbugs.gnu.org id=B61553.167657864824109 (code B ref 61553); Thu, 16 Feb 2023 20:18:02 +0000 Original-Received: (at 61553) by debbugs.gnu.org; 16 Feb 2023 20:17:28 +0000 Original-Received: from localhost ([127.0.0.1]:37724 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pSkh5-0006Gn-JB for submit@debbugs.gnu.org; Thu, 16 Feb 2023 15:17:27 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:46450) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pSkh4-0006Ga-13 for 61553@debbugs.gnu.org; Thu, 16 Feb 2023 15:17:26 -0500 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pSkgy-0008Qo-G2; Thu, 16 Feb 2023 15:17:20 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=bkdghUKQMZX/YN0k8RY+9IOXHydDgMGdUcF2izYu04k=; b=BGJ4FgiSC2rd cqFqYIeYcmWtsj0LJNkAqoWXZrZPfbArv9i3/OtIOpdqAgXOGd1aGRWlKNItyNpt7zKFCFXSCwxqO 9x0su7f2Sq4r0E75tLLK6l65xEQ5NKTZl4Yp0e7np65qPFDV1ha60m3TiHVoU8jW8kwEJ5z/dg/Oq 0ZrmL3k6qWWcIWzqeEde2pUlTe8pn+IW73Kccw6e8ZmYGuq5wO8eng1tN3516CL+g9fZ4Cdfd7zjH u/p+G0aQNWJ0eL7ggsl4jl/BRkBM1No7+uhVVorbhaVll0d5ctcgTjzrk9PsBOuyWMGBlVU4JmfTr 3fZ3p6qtSMqRhd2XW9BcWg==; Original-Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pSkgx-0003w5-Vj; Thu, 16 Feb 2023 15:17:20 -0500 In-Reply-To: <875yc1foej.fsf@gmail.com> (message from Augusto Stoffel on Thu, 16 Feb 2023 19:36:36 +0100) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:255835 Archived-At: > From: Augusto Stoffel > Cc: 61553@debbugs.gnu.org > Date: Thu, 16 Feb 2023 19:36:36 +0100 > > On Thu, 16 Feb 2023 at 19:59, Eli Zaretskii wrote: > > >> (read-multiple-choice "Question" '((?y "yes") (?n "no")) nil nil t) > >> > >> Then I get a minibuffer query, but I would expect a dialog box in the > >> case as well. > > > > The long-form call does a completing-read, and we don't support that > > via GUI dialogs (how could we?). > > Of course. The point is what takes precedence: the decision to prefer a > dialog over keyboard input, or the decision to do a completing-read > instead of reading a single char? I don't think the function itself can make that decision. Only the caller knows what's right for the context. > The purpose of long-form is to protect the user from doing something > dangerous by accidentally pressing a key. That's only one possible cause of using the long form. There could be others. > So instead of adding a special case for kill-buffer, I would rather > modify the behavior of RMC to just ignore the long-form argument if > (use-dialog-box-p) returns t. Apart from that, your patch seems fine. I disagree that rmc.el should make that decision. It isn't its call (pun intended).