From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Mauro Aranda Newsgroups: gmane.emacs.bugs Subject: bug#64046: 30.0.50; Quoting in customize choice tags Date: Wed, 14 Jun 2023 17:05:32 -0300 Message-ID: <47e13491-1654-db22-2f8b-f12195953232@gmail.com> References: <87v8frihny.fsf@gmx.net> <837cs7we2z.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="40137"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.11.0 Cc: Eli Zaretskii , Stefan Monnier , 64046@debbugs.gnu.org To: Stephen Berman Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Jun 14 22:06:21 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 1q9Wl3-000AI7-3G for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 14 Jun 2023 22:06:21 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1q9Wkm-000856-St; Wed, 14 Jun 2023 16:06:05 -0400 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 1q9Wkl-00084v-NS for bug-gnu-emacs@gnu.org; Wed, 14 Jun 2023 16:06:03 -0400 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 1q9Wkk-0003Fh-Bj for bug-gnu-emacs@gnu.org; Wed, 14 Jun 2023 16:06:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1q9Wkj-0003Hl-Ql for bug-gnu-emacs@gnu.org; Wed, 14 Jun 2023 16:06:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Mauro Aranda Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 14 Jun 2023 20:06:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 64046 X-GNU-PR-Package: emacs Original-Received: via spool by 64046-submit@debbugs.gnu.org id=B64046.168677314312604 (code B ref 64046); Wed, 14 Jun 2023 20:06:01 +0000 Original-Received: (at 64046) by debbugs.gnu.org; 14 Jun 2023 20:05:43 +0000 Original-Received: from localhost ([127.0.0.1]:45520 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q9WkQ-0003HE-S8 for submit@debbugs.gnu.org; Wed, 14 Jun 2023 16:05:43 -0400 Original-Received: from mail-oa1-f46.google.com ([209.85.160.46]:49511) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q9WkP-0003H1-E5 for 64046@debbugs.gnu.org; Wed, 14 Jun 2023 16:05:41 -0400 Original-Received: by mail-oa1-f46.google.com with SMTP id 586e51a60fabf-1a994308bc6so232222fac.3 for <64046@debbugs.gnu.org>; Wed, 14 Jun 2023 13:05:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1686773136; x=1689365136; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=XwWrQyUE3VspgjU286ziWRZhBuVJ8mTbQDrH6Eyi5+w=; b=Z/W3ZHMRl5PsyYTC2EpB07OzlICeifFiS0p2LcV16irpk+qSzhW2YGXzn6tWseZ3aY XgHlHfLy1XEbIcQRAdPiETSOZeXYUzPJa0rEb8DEYXGvY98LQ8MGIsgWI6FnMgWs0dO5 KapYVTI7JnJjXoVShuVvkxoGTqoLYQljcblReba8rsZap0EAmn54aBgQIN+qNp0vE2jD nXJtxyGQI4s8o1D7SbQ8P6JTe7VbwJyyKyoPFN0TVlxa1JkhVB4+FcZuhpCI+hiSTSQr IHgUskhAC3iiYS1Ul5Mm64R7HVBFgnUTOfMLxk9Ed53VTTrTYKKkSFgTlQoM+EHKLLCL pEEQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1686773136; x=1689365136; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=XwWrQyUE3VspgjU286ziWRZhBuVJ8mTbQDrH6Eyi5+w=; b=R+ZHTaxLgvvR8WZLqJd8gNXfbBY1k2MV3LANtLm/q2R7f5P7dx7e8KULiCZahXDoeZ hEZauIgxZcHzagEFBaT0Ij6PdPrgemmFpY+iXyCqObmt7nSiLDcr8YtWbNTPgb0IcZxt FEyjM2FuLiGRTyi2rRN8r/Cztf7qBjo1ADqrkkQ3PspqwDUU1IE9qiKpqnjGDeUi436W gmGHDlOHICtrAnkzy4Rc2zh1sbLvf1CcXBLn//vIslbA8YVMmJnpC1glPLuvnsLPVHo1 lmHLWFrk/or95JtdDpEVy7SPMq8U4ZOYLi3ymHoC0CTrXs6XRvl+3+fyaMpnX1KXPxKQ EK2A== X-Gm-Message-State: AC+VfDyc5jwrsKBzCKZpJENkCcEqM3K4Seb2d2HXhHSnuNzEFYn8caHe 3ehjK/7s0vHYs260ESeKxX8= X-Google-Smtp-Source: ACHHUZ5KInMXOKl7NqOeNdcHswszb9/jWPRz3D46jItM93n0scMLMewoF8lt00gT97ASFEPgNc2DYA== X-Received: by 2002:a05:6870:c788:b0:1a7:5726:a52b with SMTP id dy8-20020a056870c78800b001a75726a52bmr1945458oab.52.1686773135840; Wed, 14 Jun 2023 13:05:35 -0700 (PDT) Original-Received: from [192.168.0.234] ([186.127.128.249]) by smtp.gmail.com with ESMTPSA id ne16-20020a056871449000b0019f4f5c8298sm9127546oab.56.2023.06.14.13.05.34 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 14 Jun 2023 13:05:35 -0700 (PDT) Content-Language: en-US In-Reply-To: <837cs7we2z.fsf@gnu.org> 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:263379 Archived-At: Stephen Berman writes: > 0. emacs -Q > 1. Evaluate the following defcustom: >    (defcustom my-test "a" >      "Test." >      :type '(choice (string :tag "Use `a'" "a") >                (string :tag "Use `b'" "b"))) > 2. M-x customize-option RET my-test RET > 3. In the buffer *Customize Option: My Test* note that in the string >    "Use ‘a’" following the "Value Menu" button the quote marks are in >    the "curve" style (‘’). > 4. Put point on the "Value Menu" button and type RET. > 5. The buffer " widget-choose" contains these lines: >    0 = Use ‘a’ >    1 = Use ‘b’ >    Note that the quote marks in this buffer are also in the "curve" >    style. > 6. With the mouse pointer over the "Value Menu" button press mouse-1, >    popping up a menu titled "Choice" containing these items: >    Use `a' >    Use `b' >    Note that the quote marks in this menu are in the "grave" style (`') >    instead of the "curve" style. > > The use of the "curve" style in the " widget-choose" buffer is due to > commit bd3b426ebb7a60045839e97c9da9bfd249fab1f1, but that commit did not > take popup menus into account.  The attached patch does so. Since the > status quo ante long predates emacs-29 and this is just a stylistic bug, > I made the patch against master. > > In this patch I chose to apply substitute-command-keys just once at the > beginning of the function `widget-choose', rather than several times > within the function, but I restricted its application to item tags, so > other uses of the ITEMS argument should not be affected (and my brief > testing hasn't found any problem with the patch). By moving the call to substitute-command-keys to the beginning, extended menus simplified with widget--simplify-menu don't benefit anymore from it.  Perhaps that won't ever show up as a problem, but I think we should guard against that. To do that, maybe widget--simplify-menu can call substitute-command-keys when it builds the simplified menu.