Mercurial > emacs
comparison src/w32fns.c @ 89971:cce1c0ee76ee
Revision: miles@gnu.org--gnu-2004/emacs--unicode--0--patch-36
Merge from emacs--cvs-trunk--0, emacs--gnus--5.10, gnus--rel--5.10
Patches applied:
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-523
Merge from emacs--gnus--5.10, gnus--rel--5.10
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-524
- miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-534
Update from CVS
* miles@gnu.org--gnu-2004/emacs--gnus--5.10--base-0
tag of miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-464
* miles@gnu.org--gnu-2004/emacs--gnus--5.10--patch-1
Import from CVS branch gnus-5_10-branch
* miles@gnu.org--gnu-2004/emacs--gnus--5.10--patch-2
Merge from lorentey@elte.hu--2004/emacs--multi-tty--0, emacs--cvs-trunk--0
* miles@gnu.org--gnu-2004/emacs--gnus--5.10--patch-3
Merge from gnus--rel--5.10
* miles@gnu.org--gnu-2004/emacs--gnus--5.10--patch-4
Merge from gnus--rel--5.10
* miles@gnu.org--gnu-2004/gnus--rel--5.10--patch-18
Update from CVS
* miles@gnu.org--gnu-2004/gnus--rel--5.10--patch-19
Remove autoconf-generated files from archive
* miles@gnu.org--gnu-2004/gnus--rel--5.10--patch-20
Update from CVS
author | Miles Bader <miles@gnu.org> |
---|---|
date | Thu, 09 Sep 2004 09:36:36 +0000 |
parents | 3219f94257bc a35b92556545 |
children | f3ec05478165 |
comparison
equal
deleted
inserted
replaced
89970:a849e5779b8c | 89971:cce1c0ee76ee |
---|---|
259 typedef BOOL (WINAPI * TrackMouseEvent_Proc) | 259 typedef BOOL (WINAPI * TrackMouseEvent_Proc) |
260 (IN OUT LPTRACKMOUSEEVENT lpEventTrack); | 260 (IN OUT LPTRACKMOUSEEVENT lpEventTrack); |
261 | 261 |
262 TrackMouseEvent_Proc track_mouse_event_fn = NULL; | 262 TrackMouseEvent_Proc track_mouse_event_fn = NULL; |
263 ClipboardSequence_Proc clipboard_sequence_fn = NULL; | 263 ClipboardSequence_Proc clipboard_sequence_fn = NULL; |
264 extern AppendMenuW_Proc unicode_append_menu; | |
264 | 265 |
265 /* W95 mousewheel handler */ | 266 /* W95 mousewheel handler */ |
266 unsigned int msh_mousewheel = 0; | 267 unsigned int msh_mousewheel = 0; |
267 | 268 |
268 /* Timers */ | 269 /* Timers */ |
3456 old_font = SelectObject (hdc, menu_font); | 3457 old_font = SelectObject (hdc, menu_font); |
3457 | 3458 |
3458 pMis->itemHeight = GetSystemMetrics (SM_CYMENUSIZE); | 3459 pMis->itemHeight = GetSystemMetrics (SM_CYMENUSIZE); |
3459 if (title) | 3460 if (title) |
3460 { | 3461 { |
3461 GetTextExtentPoint32 (hdc, title, strlen (title), &size); | 3462 if (unicode_append_menu) |
3463 GetTextExtentPoint32W (hdc, (WCHAR *) title, | |
3464 wcslen ((WCHAR *) title), | |
3465 &size); | |
3466 else | |
3467 GetTextExtentPoint32 (hdc, title, strlen (title), &size); | |
3468 | |
3462 pMis->itemWidth = size.cx; | 3469 pMis->itemWidth = size.cx; |
3463 if (pMis->itemHeight < size.cy) | 3470 if (pMis->itemHeight < size.cy) |
3464 pMis->itemHeight = size.cy; | 3471 pMis->itemHeight = size.cy; |
3465 } | 3472 } |
3466 else | 3473 else |
3494 GetObject (menu_font, sizeof (menu_logfont), &menu_logfont); | 3501 GetObject (menu_font, sizeof (menu_logfont), &menu_logfont); |
3495 menu_logfont.lfWeight = FW_BOLD; | 3502 menu_logfont.lfWeight = FW_BOLD; |
3496 menu_font = CreateFontIndirect (&menu_logfont); | 3503 menu_font = CreateFontIndirect (&menu_logfont); |
3497 old_font = SelectObject (hdc, menu_font); | 3504 old_font = SelectObject (hdc, menu_font); |
3498 | 3505 |
3499 /* Always draw title as if not selected. */ | 3506 /* Always draw title as if not selected. */ |
3500 ExtTextOut (hdc, | 3507 if (unicode_append_menu) |
3501 pDis->rcItem.left | 3508 ExtTextOutW (hdc, |
3502 + GetSystemMetrics (SM_CXMENUCHECK), | 3509 pDis->rcItem.left |
3503 pDis->rcItem.top, | 3510 + GetSystemMetrics (SM_CXMENUCHECK), |
3504 ETO_OPAQUE, &pDis->rcItem, | 3511 pDis->rcItem.top, |
3505 title, strlen (title), NULL); | 3512 ETO_OPAQUE, &pDis->rcItem, |
3513 (WCHAR *) title, | |
3514 wcslen ((WCHAR *) title), NULL); | |
3515 else | |
3516 ExtTextOut (hdc, | |
3517 pDis->rcItem.left | |
3518 + GetSystemMetrics (SM_CXMENUCHECK), | |
3519 pDis->rcItem.top, | |
3520 ETO_OPAQUE, &pDis->rcItem, | |
3521 title, strlen (title), NULL); | |
3506 | 3522 |
3507 SelectObject (hdc, old_font); | 3523 SelectObject (hdc, old_font); |
3508 DeleteObject (menu_font); | 3524 DeleteObject (menu_font); |
3509 } | 3525 } |
3510 return TRUE; | 3526 return TRUE; |