[Message Prev][Message Next][Thread Prev][Thread Next][Message Index][Thread Index]
Problem in IME control on moving focus between frames.
- X-ml-count: 122
- Subject: Problem in IME control on moving focus between frames.
- From: horiguti@xxxxxxxxxxxxx (Kyotaro HORIGUCHI)
- Date: Mon, 27 Apr 1998 19:10:20 +0900 (JST)
- X-mailer: Mew version 1.93b28 on Emacs 20.2 / Mule 3.0 (MOMIJINOGA)
堀口と申します. Meadow でフレーム間でフォーカスの移動があったとき
に IME の ON/OFF が切り替わらないようです. とりあえず切り替わる
ようにしてみました.
修正の内容は IMEの状態が変わるたびにフレーム情報にその状態を保
存して, フレームが切り替わったときに記憶した状態に戻す処理を追
加したというものです.
--
堀口恭太郎.
*** ../../org/Meadow/src/mw32ime.c Sat Feb 07 01:34:45 1998
--- mw32ime.c Mon Apr 27 16:30:53 1998
***************
*** 355,366 ****
void w32_set_ime_status(HWND hwnd, int openp)
{
HIMC himc;
himc = (ImmGetContextProc)(hwnd);
(ImmSetOpenStatusProc)(himc, openp);
(ImmReleaseContextProc)(hwnd, himc);
!
return;
}
int w32_get_ime_status(HWND hwnd)
--- 355,375 ----
void w32_set_ime_status(HWND hwnd, int openp)
{
HIMC himc;
+ struct frame *f;
himc = (ImmGetContextProc)(hwnd);
(ImmSetOpenStatusProc)(himc, openp);
(ImmReleaseContextProc)(hwnd, himc);
! f = w32_window_to_frame(hwnd);
! FRAME_W32_IME_STATUS(f) = w32_get_ime_status(hwnd);
return;
+ }
+
+ void w32_restore_ime_status(struct frame *f)
+ {
+ if (fIME && !NILP (Vime_control))
+ w32_set_ime_status(FRAME_W32_WINDOW(f),
+ FRAME_W32_IME_STATUS(f));
}
int w32_get_ime_status(HWND hwnd)
*** ../../org/Meadow/src/mw32term.c Sat Feb 07 19:27:53 1998
--- mw32term.c Mon Apr 27 16:32:27 1998
***************
*** 3962,3968 ****
#if defined(MEADOW) && defined(IME_CONTROL)
if ((f == w32_highlight_frame) && on)
! w32_set_ime_conv_window(f);
#endif
UNBLOCK_INPUT;
--- 3962,3971 ----
#if defined(MEADOW) && defined(IME_CONTROL)
if ((f == w32_highlight_frame) && on)
! {
! w32_set_ime_conv_window(f);
! w32_restore_ime_status(f);
! }
#endif
UNBLOCK_INPUT;
*** ../../org/Meadow/src/mw32term.h Sat Feb 07 00:41:13 1998
--- mw32term.h Mon Apr 27 16:19:11 1998
***************
*** 217,222 ****
--- 217,223 ----
struct face **param_faces;
int n_param_faces;
+ int ime_status;
#ifndef TERMINAL_FACE
/* Table of computed faces for this frame. These are the faces
whose indexes go into the upper bits of a glyph, computed by
***************
*** 257,262 ****
--- 258,264 ----
#define FRAME_DESIRED_CURSOR(f) ((f)->output_data.w32->desired_cursor)
+ #define FRAME_W32_IME_STATUS(f) ((f)->output_data.w32->ime_status)
/* When X windows are used, a glyph may be a 16 bit unsigned datum.
The high order byte is the face number and is used as an index