unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: martin rudalics <rudalics@gmx.at>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 11732@debbugs.gnu.org, mhatta@gmail.com
Subject: bug#11732: Follow-up to bug#11732
Date: Sat, 30 Jun 2018 14:51:04 +0200	[thread overview]
Message-ID: <5B377CB8.1030602@gmx.at> (raw)
In-Reply-To: <83d0w8mrvu.fsf@gnu.org>

 >> 	  SetWindowPos (dialog, HWND_TOPMOST, 0, 0, 0, 0,
 >> 			SWP_NOMOVE | SWP_NOSIZE | SWP_NOOWNERZORDER);
 >> 	  SetWindowPos (FRAME_W32_WINDOW (SELECTED_FRAME ()),
 >> 			dialog, 0, 0, 0, 0, SWP_NOMOVE | SWP_NOSIZE
 >> 			| SWP_NOACTIVATE);
 >>
 >> Note that I can't test it because nothing is broken here in the first
 >> place.
 >
 > I think I tried with HWND_TOPMOST,

You had HWND_TOPMOST here in the patch you attached to the first
message I read.  I only moved the SWP_NOACTIVATE from the dialog
window to that of the selected frame.

 > but what it does (and I see it now
 > with your suggestion) is it doesn't allow raising any other
 > (non-Emacs) window above the file-selection dialog (in the z-order).
 > The original code didn't behave that way, so I looked for a better
 > option, and HWND_NOTOPMOST seemed to do the job...

I probably don't understand the original problem sketched as

	 But doing so causes trouble with displaying
	 dialog boxes, such as the file selection dialog or font
	 selection dialog.

A dialog box uses a modal window on top of the owning window.
Anything else will almost certainly cause problems with any windowing
system we use.

 > By "support frame" here you mean the dialog box?

No.  I mean a frame that in many regards acts like a child frame but
uses a top-level window instead of a child window.

 > If not, then why is
 > this function called every time we are about to show a dialog box?

Because a dialog box should appear on top of any support frame.  And
it doesn't necessarily do that when both are in the topmost group.
That's why I temporarily remove the support frame from that group.

 > If it's an internal setting that should never be seen outside the C
 > sources, then it should be documented in the commentary preceding
 > x_set_z_group, and the comment should tell this value is internal, so
 > that whoever reads the code will understand what each setting wants to
 > achieve.

OK.  I'll do that.

 > This looks good on XP,

Your initial patch for the font dialog showed many bad symptoms
(buttons not responding, couldn't drag the dialog box, combo box for
script dropping down beneath the dialog box) on XP.

 > I will try on Windows 7 later.  Curiously,
 > HWND_TOPMOST here doesn't prevent raising other windows above the
 > dialog box, as it does with file selector.

The windows of other applications (including other Emacs instances) or
that of the Emacs instance involved in the dialog?

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.

martin





  reply	other threads:[~2018-06-30 12:51 UTC|newest]

Thread overview: 43+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-18  5:20 bug#11732: 24.1; Microsoft IME Japanese input problem xavier.dahan
2015-02-17 10:26 ` Fujii Hironori
2015-02-18 15:17   ` Eli Zaretskii
2015-02-19  2:03     ` Fujii Hironori
2015-02-19  6:44       ` Eli Zaretskii
     [not found]         ` <CALus1PmqiC8TnQTfcpVFD5ObjqbK_4hkOczRKmG1=+mkWXUHWQ@mail.gmail.com>
2015-02-19 11:44           ` Eli Zaretskii
2015-03-06 20:29             ` Eli Zaretskii
2015-03-06 22:37               ` Fujii Hironori
2015-03-07 10:53                 ` Eli Zaretskii
2015-03-09  2:13               ` Fujii Hironori
2015-03-09 16:30                 ` Eli Zaretskii
2018-06-26  9:10 ` bug#11732: Follow-up to bug#11732 Masayuki Hatta
2018-06-27 15:54   ` Eli Zaretskii
2018-06-28  8:04     ` martin rudalics
2018-06-28 10:13       ` Masayuki Hatta
2018-06-28 12:25         ` martin rudalics
2018-06-28 13:09           ` Eli Zaretskii
2018-06-28 10:11     ` Masayuki Hatta
2018-06-28 13:28       ` Eli Zaretskii
2018-06-28 19:17         ` Noam Postavsky
2018-06-28 19:24           ` Eli Zaretskii
2018-06-29  7:39             ` Masayuki Hatta
2018-06-29  8:43               ` martin rudalics
2018-06-29  8:59                 ` Eli Zaretskii
2018-06-30  3:14                 ` Masayuki Hatta
2018-06-30  7:46                   ` Eli Zaretskii
2018-06-30  8:30                     ` Masayuki Hatta
2018-06-29  8:56               ` Eli Zaretskii
2018-06-29  8:43     ` martin rudalics
2018-06-29  9:07       ` Eli Zaretskii
2018-06-30  8:06         ` martin rudalics
2018-06-30 11:32           ` Eli Zaretskii
2018-06-30 12:51             ` martin rudalics [this message]
2018-06-30 13:21               ` Eli Zaretskii
2018-07-01  9:00                 ` martin rudalics
2018-07-01 14:29                   ` Eli Zaretskii
2018-07-03  8:29                     ` martin rudalics
2018-07-03 18:50                       ` Eli Zaretskii
2018-07-07  7:45                         ` Tak Kunihiro
2018-07-07 10:00                           ` Eli Zaretskii
2018-07-07 10:21                             ` martin rudalics
2018-07-07 11:32                               ` Eli Zaretskii
2018-07-01 14:34             ` Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5B377CB8.1030602@gmx.at \
    --to=rudalics@gmx.at \
    --cc=11732@debbugs.gnu.org \
    --cc=eliz@gnu.org \
    --cc=mhatta@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).