[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Lynx-dev] UTF-8 MS Windows
From: |
Gisle Vanem |
Subject: |
Re: [Lynx-dev] UTF-8 MS Windows |
Date: |
Wed, 21 May 2014 12:22:39 +0200 |
"Thomas Dickey" <address@hidden> wrote:
say, but for windows, it's buried in the dll information (the wide-character
pdcurses.dll is 118784 bytes, while the non-wide one is a few hundred bytes
shorter). The installers that I built last year use the wide-character
pdcurses.
I have not tried this option. But using SLang 2.2.4 (build with
-D_UNICODE + -DUNOCODE) and the same in lynx all hell breaks
loose. E.g.:
src/LYUtils.c(7782) : warning C4133: 'function' : incompatible types - from
'const char *' to 'LPCWSTR'
src/LYUtils.c(7822) : warning C4133: 'return' : incompatible types - from
'LPTSTR' to 'char *'
The MS-convention (as we all know?) is that LPTSTR etc. maps to 'char *'
or 'wchar_t *' depending on ASCII (default) or UNICODE. But the lynx-sources
can never accept building with '-DUNICODE' because of such errors shown
above.
So using TCHAR/LPTSTR etc. in the sources has no point as-is. The good
news is that it won't be so difficult to fix AFAICS. I have identified these
files with ASCII/UNICODE errors/warnings:
# err/warn file:
-------------------------
7 src/LYExtern.c
1 src/LYMain.c
1 src/LYMainLoop.c
13 src/LYUtils.c
2 lib/dirent.c
4 WWW/Library/Implementation/HTFile.c
4 WWW/Library/Implementation/HTTCP.c
2 WWW/Library/Implementation/HTDOS.c
Btw. line 7782 of LYUtils.c is:
lstrcpy((LPTSTR) pLogData, szBuffer);
So I'm not sure what the "official" way to support wide-chars in Lynx/Win32
is.
--gv