From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#24596: 25.1; `f10' behavior Date: Mon, 03 Oct 2016 19:13:18 +0300 Message-ID: <838tu5pg0x.fsf@gnu.org> References: Reply-To: Eli Zaretskii NNTP-Posting-Host: blaine.gmane.org X-Trace: blaine.gmane.org 1475511277 22159 195.159.176.226 (3 Oct 2016 16:14:37 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 3 Oct 2016 16:14:37 +0000 (UTC) Cc: 24596@debbugs.gnu.org To: Drew Adams Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Oct 03 18:14:29 2016 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1br5sh-0003de-Px for geb-bug-gnu-emacs@m.gmane.org; Mon, 03 Oct 2016 18:14:20 +0200 Original-Received: from localhost ([::1]:38035 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1br5sg-00045c-DL for geb-bug-gnu-emacs@m.gmane.org; Mon, 03 Oct 2016 12:14:18 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:36738) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1br5sW-00042S-2w for bug-gnu-emacs@gnu.org; Mon, 03 Oct 2016 12:14:09 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1br5sP-0004rU-UR for bug-gnu-emacs@gnu.org; Mon, 03 Oct 2016 12:14:06 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:36971) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1br5sP-0004rF-QJ for bug-gnu-emacs@gnu.org; Mon, 03 Oct 2016 12:14:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1br5sP-0002sP-Ib for bug-gnu-emacs@gnu.org; Mon, 03 Oct 2016 12:14:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 03 Oct 2016 16:14:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 24596 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 24596-submit@debbugs.gnu.org id=B24596.147551122711013 (code B ref 24596); Mon, 03 Oct 2016 16:14:01 +0000 Original-Received: (at 24596) by debbugs.gnu.org; 3 Oct 2016 16:13:47 +0000 Original-Received: from localhost ([127.0.0.1]:43160 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1br5sA-0002rZ-LX for submit@debbugs.gnu.org; Mon, 03 Oct 2016 12:13:46 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:45508) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1br5s9-0002rI-Gl for 24596@debbugs.gnu.org; Mon, 03 Oct 2016 12:13:45 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1br5rz-0004fJ-Ik for 24596@debbugs.gnu.org; Mon, 03 Oct 2016 12:13:40 -0400 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:33306) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1br5ro-0004bA-7t; Mon, 03 Oct 2016 12:13:24 -0400 Original-Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:1844 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.82) (envelope-from ) id 1br5rl-0005Nw-8r; Mon, 03 Oct 2016 12:13:21 -0400 In-reply-to: (message from Drew Adams on Mon, 3 Oct 2016 08:41:45 -0700 (PDT)) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.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" Xref: news.gmane.org gmane.emacs.bugs:123961 Archived-At: severity 24596 minor thanks > Date: Mon, 3 Oct 2016 08:41:45 -0700 (PDT) > From: Drew Adams > > `f10' used to just be bound to `tmm-menubar', for both TTY and > graphic-display Emacs. Now it is bound to `menu-bar-open'. Not true: F10 in a GUI session, at least on Windows, always activated the GUI menus from the menu bar. I just tried that in Emacs 23.1. What you say is only true for a TTY frame. It was changed when text-mode frames learned to display menus. > 1. User option `tty-menu-open-use-tmm' makes `f10' use `tmm-menubar' > instead, but only on TTY. Why not also on graphic displays? Because F10 never invoked tmm on GUI frames, at least not on MS-Windows. If you are asking for a new feature, then I guess it could be added if enough people want it, but then the variable's name will need to change, of course. > Or why not have the option value let you choose: always > `tmm-menubar', never `tmm-menubar', or `tmm-menubar only for TTY? > (And of course rename it, if it is made to apply to more than TTYs.) No reason, except that no one considered this important enough to write the code. > 2. Why can you not exit `menu-bar-open' (with nil > `tty-menu-open-use-tmm')? Why is ESC the only way to cancel (at least > on MS Windows)? Why are not the canonical Emacs ways of canceling > implemented here (`C-g' and `ESC ESC ESC')? ESC ESC works for me on MS-Windows GUI frames. ESC ESC ESC and C-g work for me on TTY frames. C-g doesn't work on a GUI frame because the menu is controlled by Windows, not by Emacs, and Windows doesn't know about C-g. IOW, this is a limitation we can do very little about. > 3. The doc string of `menu-bar-open' says nothing about the behavior. > It says nothing about what it does or what keys you can use, etc. It > should. Instead, it passes you off to commands `x-menu-bar-open', > `w32-menu-bar-open', `popup-menu', and `tmm-menubar'. Details of how menus work depend on the toolkit, so we refer to the toolkit-specific parts for the details. However, patches are welcome to describe what every toolkit does, presumably in the manual (because I suspect the description will be long and complicated). > Are the keys you can use different for `x-menu-bar-open' and > `w32-menu-bar-open'? Yes, I think so. > The latter's doc tells you about keys you can use, but the former's > doc says nothing about keys. w32-menu-bar-open describes just one toolkit, whereas x-menu-bar-open stands for several different ones. I believe this is the reason. > 4. The doc in the Emacs manual (node Menu Bar) is not too bad. But > AFAICT, `C-g' does NOT work (in MS Windows), as it says it does. It > also says that you can cancel using `ESC ESC ESC'. But the doc of > `w32-menu-bar-open' (correctly) says that a single `ESC' cancels. Dunno > whether this is a doc bug or the behavior (on Windows) is bugged. You are trying to apply the description of what happens with TTY menus to GUI menus. They don't behave the same. > 5. Overall, it looks a bit like someone wrote `menu-bar-open', > `x-menu-bar-open', and `w32-menu-bar-open', and it was decided to > replace `tmm-menubar' as the binding of `f10'. But I don't really see > the advantage, especially considering the lack of good doc. The advantage is unified behavior across frame types, at least by default. The tty-menu-open-use-tmm was added later by popular demand; initially I didn't imagine someone would want it when true menus are available.