aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJason Rumney2001-11-28 20:34:46 +0000
committerJason Rumney2001-11-28 20:34:46 +0000
commit4e3a1c6137e8e7850b94c484a34db7b4c3e1a655 (patch)
treed8e129dbddd35329c12936c98536be62d52824a8 /src
parent1c5acb8c6d238498d78f427b7ea2c2682dc191e0 (diff)
downloademacs-4e3a1c6137e8e7850b94c484a34db7b4c3e1a655.tar.gz
emacs-4e3a1c6137e8e7850b94c484a34db7b4c3e1a655.zip
(w32_wnd_proc) <WM_MENUSELECT>: Display help directly.
(Fx_show_tip): Don't subtract last width from row width.
Diffstat (limited to 'src')
-rw-r--r--src/w32fns.c19
1 files changed, 8 insertions, 11 deletions
diff --git a/src/w32fns.c b/src/w32fns.c
index 74602bb7765..bad08848023 100644
--- a/src/w32fns.c
+++ b/src/w32fns.c
@@ -55,6 +55,7 @@ Boston, MA 02111-1307, USA. */
55extern void free_frame_menubar (); 55extern void free_frame_menubar ();
56extern double atof (); 56extern double atof ();
57extern int w32_console_toggle_lock_key (int vk_code, Lisp_Object new_state); 57extern int w32_console_toggle_lock_key (int vk_code, Lisp_Object new_state);
58extern void w32_menu_display_help (HWND owner, HMENU menu, UINT menu_item, UINT flags);
58extern int quit_char; 59extern int quit_char;
59 60
60/* A definition of XColor for non-X frames. */ 61/* A definition of XColor for non-X frames. */
@@ -4686,23 +4687,16 @@ w32_wnd_proc (hwnd, msg, wParam, lParam)
4686 goto dflt; 4687 goto dflt;
4687 4688
4688 case WM_MENUSELECT: 4689 case WM_MENUSELECT:
4689#if DIRECT_MENU_HELP 4690 /* Direct handling of help_echo in menus. Should be safe now
4691 that we generate the help_echo by placing a help event in the
4692 keyboard buffer. */
4690 { 4693 {
4691 /* Tooltips seemed to behave better when help_echo was directly
4692 displayed, but this causes crashes when GC kicks in when the
4693 tip_frame is active. */
4694 HMENU menu = (HMENU) lParam; 4694 HMENU menu = (HMENU) lParam;
4695 UINT menu_item = (UINT) LOWORD (wParam); 4695 UINT menu_item = (UINT) LOWORD (wParam);
4696 UINT flags = (UINT) HIWORD (wParam); 4696 UINT flags = (UINT) HIWORD (wParam);
4697 4697
4698 BLOCK_INPUT; 4698 w32_menu_display_help (hwnd, menu, menu_item, flags);
4699 w32_menu_display_help (menu, menu_item, flags);
4700 UNBLOCK_INPUT;
4701 } 4699 }
4702#else
4703 wmsg.dwModifiers = w32_get_modifiers ();
4704 my_post_msg (&wmsg, hwnd, msg, wParam, lParam);
4705#endif
4706 return 0; 4700 return 0;
4707 4701
4708 case WM_MEASUREITEM: 4702 case WM_MEASUREITEM:
@@ -13547,6 +13541,8 @@ Text larger than the specified size is clipped. */)
13547 /* Let the row go over the full width of the frame. */ 13541 /* Let the row go over the full width of the frame. */
13548 row->full_width_p = 1; 13542 row->full_width_p = 1;
13549 13543
13544#ifdef TODO /* Investigate why some fonts need more width than is
13545 calculated for some tooltips. */
13550 /* There's a glyph at the end of rows that is use to place 13546 /* There's a glyph at the end of rows that is use to place
13551 the cursor there. Don't include the width of this glyph. */ 13547 the cursor there. Don't include the width of this glyph. */
13552 if (row->used[TEXT_AREA]) 13548 if (row->used[TEXT_AREA])
@@ -13555,6 +13551,7 @@ Text larger than the specified size is clipped. */)
13555 row_width = row->pixel_width - last->pixel_width; 13551 row_width = row->pixel_width - last->pixel_width;
13556 } 13552 }
13557 else 13553 else
13554#endif
13558 row_width = row->pixel_width; 13555 row_width = row->pixel_width;
13559 13556
13560 /* TODO: find why tips do not draw along baseline as instructed. */ 13557 /* TODO: find why tips do not draw along baseline as instructed. */