Subject: Re: bug#11732: 24.1; Microsoft IME Japanese input problem

From: Eli Zaretskii <[email-masked]>
Date: Mon, 09 Mar 2015 18:30:07 +0200

> Date: Mon, 9 Mar 2015 11:13:43 +0900
> From: Fujii Hironori <[email-masked]>
> Cc: [email-masked]
> 
> On Sat, Mar 7, 2015 at 5:29 AM, Eli Zaretskii <[email-masked]> wrote:
> > Unfortunately, it looks like that change has a devastating effect on
> > dialog boxes.  Try clicking File->Open File, and then click anywhere
> > inside the file selection dialog that opens: the dialog will disappear
> > from the display!
> 
> I don't see such problem. I'm testing on Windows 7.
> Could you tell me your Windows version.

I originally saw this on 32-bit XP, but now tried on 64-bit Windows 7,
and I see the same problem there.  So I don't think the Windows
version is a factor here.

> This is my environment:
> 
>   In GNU Emacs 25.0.50.2 (x86_64-unknown-cygwin)
>    of 2015-03-09 on win7-pc
>   Repository revision: 6b134bcba9de5605086ee9382c0be13174480cac
>   Windowing system distributor `Microsoft Corp.', version 6.1.7601
>   Configured using:
>    `configure --prefix=/cygdrive/c/home/fujii/opt/emacs --with-w32'

You are using a 64-bit Cygwin-w32 build.  I'm using a 32-bit MinGW
build:

  In GNU Emacs 25.0.50.232 (i686-pc-mingw32)
   of 2015-03-07 on HOME-C4E4A596F7
  Repository revision: 35e2b6ab4d28547ec079de18cf1cf65623e6909a
  Windowing system distributor `Microsoft Corp.', version 5.1.2600
  Configured using:
   `configure --prefix=/d/usr --enable-checking=yes,glyphs 'CFLAGS=-O0 -g3''

  Configured features:
  XPM JPEG TIFF GIF PNG RSVG SOUND NOTIFY ACL GNUTLS LIBXML2 ZLIB

So either the way Cygwin implements reading of Windows messages from
/dev/windows, or the 64- vs 32-bit difference, is somehow responsible
for the differences in behavior.

Yet another difference is that I compiled without optimizations, but I
doubt if that could cause such an effect.

> I applied a following patch to test:
> 
> diff --git a/src/w32fns.c b/src/w32fns.c
> index 6abb433..685d30c 100644
> --- a/src/w32fns.c
> +++ b/src/w32fns.c
> @@ -3330,7 +3330,7 @@ w32_wnd_proc (HWND hwnd, UINT msg, WPARAM
> wParam, LPARAM lParam)
>   dialog boxes, such as the file selection dialog or font
>   selection dialog.  So something else is needed to fix the
>   former without breaking the latter.  See bug#11732.  */
> -      break;
> +      goto dflt;

Me too.