summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog4
-rw-r--r--win/tkWinInt.h4
-rw-r--r--win/tkWinMenu.c7
-rw-r--r--win/tkWinX.c6
4 files changed, 16 insertions, 5 deletions
diff --git a/ChangeLog b/ChangeLog
index 5c3e23f..a8f605b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
2004-05-03 Jeff Hobbs <jeffh@ActiveState.com>
+ * win/tkWinX.c: fix drawing of unicode chars in menu
+ * win/tkWinInt.h (TkWinProcs): titles. [Bug #904371] (riefenstahl)
+ * win/tkWinMenu.c (ReconfigureWindowsMenu):
+
* generic/tkClipboard.c: Move TkClipCleanup from tkClipboard.c
* mac/tkMacXStubs.c: to being implemented in a platform
* macosx/tkMacOSXXStubs.c: specific manner. The cleanup order was
diff --git a/win/tkWinInt.h b/win/tkWinInt.h
index cbe2290..cfcc7c0 100644
--- a/win/tkWinInt.h
+++ b/win/tkWinInt.h
@@ -11,7 +11,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkWinInt.h,v 1.14 2003/02/26 02:47:05 hobbs Exp $
+ * RCS: @(#) $Id: tkWinInt.h,v 1.14.2.1 2004/05/03 22:40:58 hobbs Exp $
*/
#ifndef _TKWININT
@@ -187,6 +187,8 @@ typedef struct TkWinProcs {
LPCTSTR lpWindowName, DWORD dwStyle, int x, int y,
int nWidth, int nHeight, HWND hWndParent, HMENU hMenu,
HINSTANCE hInstance, LPVOID lpParam);
+ BOOL (WINAPI *insertMenu)(HMENU hMenu, UINT uPosition, UINT uFlags,
+ UINT uIDNewItem, LPCTSTR lpNewItem);
} TkWinProcs;
EXTERN TkWinProcs *tkWinProcs;
diff --git a/win/tkWinMenu.c b/win/tkWinMenu.c
index ff2d557..0d89cbe 100644
--- a/win/tkWinMenu.c
+++ b/win/tkWinMenu.c
@@ -9,7 +9,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkWinMenu.c,v 1.21 2002/08/08 01:42:57 hobbs Exp $
+ * RCS: @(#) $Id: tkWinMenu.c,v 1.21.2.1 2004/05/03 22:40:58 hobbs Exp $
*/
#define OEMRESOURCE
@@ -570,7 +570,7 @@ ReconfigureWindowsMenu(
itemText = GetEntryText(mePtr);
if ((menuPtr->menuType == MENUBAR)
|| (menuPtr->menuFlags & MENU_SYSTEM_MENU)) {
- Tcl_UtfToExternalDString(NULL, itemText, -1, &translatedText);
+ Tcl_WinUtfToTChar(itemText, -1, &translatedText);
lpNewItem = Tcl_DStringValue(&translatedText);
} else {
lpNewItem = (LPCTSTR) mePtr;
@@ -669,7 +669,8 @@ ReconfigureWindowsMenu(
}
}
if (!systemMenu) {
- InsertMenu(winMenuHdl, 0xFFFFFFFF, flags, itemID, lpNewItem);
+ (*tkWinProcs->insertMenu)(winMenuHdl, 0xFFFFFFFF, flags,
+ itemID, lpNewItem);
}
Tcl_DStringFree(&translatedText);
if (itemText != NULL) {
diff --git a/win/tkWinX.c b/win/tkWinX.c
index 26a76a3..550bc34 100644
--- a/win/tkWinX.c
+++ b/win/tkWinX.c
@@ -10,7 +10,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkWinX.c,v 1.25.2.1 2004/05/03 22:23:09 hobbs Exp $
+ * RCS: @(#) $Id: tkWinX.c,v 1.25.2.2 2004/05/03 22:40:58 hobbs Exp $
*/
#include "tkWinInt.h"
@@ -52,6 +52,8 @@ static TkWinProcs asciiProcs = {
LPCTSTR lpWindowName, DWORD dwStyle, int x, int y,
int nWidth, int nHeight, HWND hWndParent, HMENU hMenu,
HINSTANCE hInstance, LPVOID lpParam)) CreateWindowExA,
+ (BOOL (WINAPI *)(HMENU hMenu, UINT uPosition, UINT uFlags,
+ UINT uIDNewItem, LPCTSTR lpNewItem)) InsertMenuA,
};
static TkWinProcs unicodeProcs = {
@@ -67,6 +69,8 @@ static TkWinProcs unicodeProcs = {
LPCTSTR lpWindowName, DWORD dwStyle, int x, int y,
int nWidth, int nHeight, HWND hWndParent, HMENU hMenu,
HINSTANCE hInstance, LPVOID lpParam)) CreateWindowExW,
+ (BOOL (WINAPI *)(HMENU hMenu, UINT uPosition, UINT uFlags,
+ UINT uIDNewItem, LPCTSTR lpNewItem)) InsertMenuW,
};
TkWinProcs *tkWinProcs;