From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: martin rudalics Newsgroups: gmane.emacs.bugs Subject: bug#11732: Follow-up to bug#11732 Date: Sun, 01 Jul 2018 11:00:55 +0200 Message-ID: <5B389847.6000204@gmx.at> References: <87obohkxga.fsf@XAVIER-PC.i-did-not-set--mail-host-address--so-tickle-me> <83y3f0p6n7.fsf@gnu.org> <5B35F120.9040807@gmx.at> <83fu16nepn.fsf@gnu.org> <5B373A21.9050407@gmx.at> <83d0w8mrvu.fsf@gnu.org> <5B377CB8.1030602@gmx.at> <837emgmmu2.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Trace: blaine.gmane.org 1530435669 31233 195.159.176.226 (1 Jul 2018 09:01:09 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 1 Jul 2018 09:01:09 +0000 (UTC) Cc: 11732@debbugs.gnu.org, mhatta@gmail.com To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Jul 01 11:01:04 2018 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 1fZYE9-0007yh-8m for geb-bug-gnu-emacs@m.gmane.org; Sun, 01 Jul 2018 11:01:01 +0200 Original-Received: from localhost ([::1]:51579 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fZYGG-0005Gy-EP for geb-bug-gnu-emacs@m.gmane.org; Sun, 01 Jul 2018 05:03:12 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:51054) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fZYFC-0004Sa-87 for bug-gnu-emacs@gnu.org; Sun, 01 Jul 2018 05:02:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fZYF9-0006qG-7E for bug-gnu-emacs@gnu.org; Sun, 01 Jul 2018 05:02:06 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:33702) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fZYF9-0006pt-2y for bug-gnu-emacs@gnu.org; Sun, 01 Jul 2018 05:02:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1fZYF8-0004RO-Hu for bug-gnu-emacs@gnu.org; Sun, 01 Jul 2018 05:02:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: martin rudalics Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 01 Jul 2018 09:02:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 11732 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 11732-submit@debbugs.gnu.org id=B11732.153043567017001 (code B ref 11732); Sun, 01 Jul 2018 09:02:02 +0000 Original-Received: (at 11732) by debbugs.gnu.org; 1 Jul 2018 09:01:10 +0000 Original-Received: from localhost ([127.0.0.1]:41599 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fZYEH-0004Q8-T8 for submit@debbugs.gnu.org; Sun, 01 Jul 2018 05:01:10 -0400 Original-Received: from mout.gmx.net ([212.227.17.22]:33485) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fZYEE-0004PV-Q3 for 11732@debbugs.gnu.org; Sun, 01 Jul 2018 05:01:07 -0400 Original-Received: from [192.168.1.101] ([46.125.250.78]) by mail.gmx.com (mrgmx102 [212.227.17.168]) with ESMTPSA (Nemesis) id 0LviG8-1gBzdf1L2q-017Wkr; Sun, 01 Jul 2018 11:00:59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UYDXmGjXWdq9tRmHhCPXQyOUJBgor2rq5jkbhj8L9Qlr7y+OSaUQULZ 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:148038 Archived-At: > I didn't mean the owing window, I meant the other windows on the > desktop, belonging to applications other than Emacs. Using > HWND_TOPMOST makes me unable to raise any window of another > application above the dialog box in the z-order. The existing code > does allow that. Because it leaves the entire z-order handling to Windows. The idea of using a dialog box is that you tell Windows to glue together the frame with the dialog box and let no other window enter the z-order in between these two. How Windows implements that has likely never been analyzed so we won't know. But I suppose that Windows simply intercepts all (implicit) z-reorder requests to let no other window in. Now if Masayuki's proposal breaks this relationship please tell me exactly how. IIUC you mean to say that with focus follows mouse sans autoraise the two Emacs windows (always) appear on top of other applications. But sans autoraise means that the z-order should not change when you move the mouse so you apparently clicked into another application's window or tried to Alt-tab to it. Please clarify this giving us the precise steps you used. In either case having Emacs fiddle with the z-order and activation of dialog box windows is dangerous and should be avoided in the first place. Also, the code below is creepy and certainly not what a well-behaved application is supposed to do: EnableWindow (edit_control, FALSE); /* Note that at least on Windows 7, the above call to EnableWindow disables the window that would ordinarily have focus. If we do not set focus to some other window here, focus will land in no man's land and the user will be unable to tab through the dialog box (pressing tab will only result in a beep). Avoid that problem by setting focus to the list here. */ if (hdr_code == CDN_INITDONE) SetFocus (list); > OK, so the call to w32_dialog_in_progress has nothing to do with the > z-order of the dialog wrt its owning frame, right? Right. I meanwhile tried to document this better. Please have a look. >> Note that Emacs waits for the dialog to finish and doesn't redisplay >> in this time. Hence if during a dialog I temporarily show another >> window on top of the dialog and remove that other window, the text in >> the Emacs frame is usually garbled until the dialog finishes. > > Yes, I know. That wasn't what I was worried about. I know. My note was just a reminder that moving other windows above the Emacs frame while a dialog is in progress doesn't result in a pleasant user experience anyway. martin