diff options
Diffstat (limited to 'new/util_windows.c')
| -rw-r--r-- | new/util_windows.c | 16 |
1 files changed, 0 insertions, 16 deletions
diff --git a/new/util_windows.c b/new/util_windows.c index 5034dae..4959a70 100644 --- a/new/util_windows.c +++ b/new/util_windows.c @@ -1,22 +1,6 @@ // 6 april 2015 #include "uipriv_windows.h" -#define MBTWC(str, wstr, bufsiz) MultiByteToWideChar(CP_UTF8, 0, str, -1, wstr, bufsiz) - -WCHAR *toUTF16(const char *str) -{ - WCHAR *wstr; - int n; - - n = MBTWC(str, NULL, 0); - if (n == 0) - logLastError("error figuring out number of characters to convert to in toUTF16()"); - wstr = (WCHAR *) uiAlloc(n * sizeof (WCHAR), "WCHAR[]"); - if (MBTWC(str, wstr, n) != n) - logLastError("error converting from UTF-8 to UTF-16 in toUTF16()"); - return wstr; -} - intmax_t uiWindowsWindowTextWidth(HWND hwnd) { int len; |
