changeset 3728:6765f2581182

[xemacs-hg @ 2006-12-08 02:21:53 by vins] Added Benson Margulies's patch to avoid the dreaded: "File not found and directory write-protected" message under Windows.
author vins
date Fri, 08 Dec 2006 02:22:02 +0000
parents 3246cf3e564d
children 96cba27916dd
files lib-src/ChangeLog lib-src/make-mswin-unicode.pl src/ChangeLog src/fileio.c src/intl-auto-encap-win32.c src/intl-auto-encap-win32.h src/intl-encap-win32.c src/syswindows.h
diffstat 8 files changed, 1863 insertions(+), 1721 deletions(-) [+]
line wrap: on
line diff
--- a/lib-src/ChangeLog	Fri Dec 08 02:17:16 2006 +0000
+++ b/lib-src/ChangeLog	Fri Dec 08 02:22:02 2006 +0000
@@ -1,3 +1,8 @@
+2006-11-24  Benson Margulies  <benson@dchbk.us>
+
+	* make-mswin-unicode.pl: allow for lower case header file names in
+	the current platform SDK.
+
 2006-08-11  Jerry James  <james@xemacs.org>
 
 	* pop.h: Sync with Emacs.
--- a/lib-src/make-mswin-unicode.pl	Fri Dec 08 02:17:16 2006 +0000
+++ b/lib-src/make-mswin-unicode.pl	Fri Dec 08 02:22:02 2006 +0000
@@ -107,7 +107,7 @@
     $dir=$ENV{"MSVCDIR"} or die "Environment variable MSVCDIR undefined - run vcvars32.bat from your MSVC installation";
     $dir.='/include';
   }
-die "Can't find MSVC include files in \"$dir\"" unless (-f $dir.'/WINDOWS.H');
+die "Can't find MSVC include files in \"$dir\"" unless ((-f $dir.'/WINDOWS.H') || (-f $dir.'/windows.h'));
 
 open (COUT, ">$cout") or die "Can't open C output file $cout: $!";
 open (HOUT, ">$hout") or die "Can't open C output file $hout: $!";
--- a/src/ChangeLog	Fri Dec 08 02:17:16 2006 +0000
+++ b/src/ChangeLog	Fri Dec 08 02:22:02 2006 +0000
@@ -1,3 +1,18 @@
+2006-12-07  Vin Shelton  <acs@xemacs.org>
+
+	* fileio.c: Added cast to qxeGetNamedSecurityInfofix call to fix
+	VC6 build.
+
+2006-11-24  Benson Margulies  <benson@dchbk.us>
+
+	* fileio.c: Change check_writable to use the full Win32 mechanism
+	to check access.
+	* intl-auto-encap-win32.c: Add GetNamedSecurityInfo
+	* intl-auto-encap-win32.h: Add GetNamedSecurityInfo
+	* intl-auto-encap-win32.h Add qxeGetNamedSecurityInfo.
+	* intl-encap-win32.c: Add aclapi.h : GetNamedSecurityInfo
+	* syswindows.h: Add aclapi.h
+
 2006-12-06  Aidan Kehoe  <kehoea@parhasard.net>
 
 	* text.c (Fsplit_char):
--- a/src/fileio.c	Fri Dec 08 02:17:16 2006 +0000
+++ b/src/fileio.c	Fri Dec 08 02:22:02 2006 +0000
@@ -2291,6 +2291,75 @@
 static int
 check_writable (const Ibyte *filename)
 {
+#if defined(WIN32_NATIVE) || defined(CYGWIN)
+#ifdef CYGWIN
+    char filename_buffer[PATH_MAX];
+#endif
+	// Since this has to work for a directory, we can't just call 'CreateFile'
+	PSECURITY_DESCRIPTOR pDesc; /* Must be freed with LocalFree */
+	/* these need not be freed, they point into pDesc */
+	PSID psidOwner;
+	PSID psidGroup;
+	PACL pDacl;
+	PACL pSacl;
+	/* end of insides of descriptor */
+	DWORD error;
+	DWORD attributes;
+	HANDLE tokenHandle;
+	GENERIC_MAPPING genericMapping;
+	DWORD accessMask;
+	PRIVILEGE_SET PrivilegeSet;
+    DWORD dwPrivSetSize = sizeof( PRIVILEGE_SET );
+    BOOL fAccessGranted = FALSE;
+	DWORD dwAccessAllowed;
+  Extbyte *fnameext;
+
+#ifdef CYGWIN
+    cygwin_conv_to_full_win32_path(filename, filename_buffer);
+    filename = (Ibyte*)filename_buffer;
+#endif
+
+    C_STRING_TO_TSTR(filename, fnameext);
+	/* Win32 prototype lacks const. */
+	error = qxeGetNamedSecurityInfo(fnameext, SE_FILE_OBJECT, 
+		DACL_SECURITY_INFORMATION|GROUP_SECURITY_INFORMATION|OWNER_SECURITY_INFORMATION,
+		&psidOwner, &psidGroup, &pDacl, &pSacl, &pDesc);
+	if(error != ERROR_SUCCESS) { // FAT?
+		attributes = qxeGetFileAttributes((Extbyte *)filename);
+		return (attributes & FILE_ATTRIBUTE_DIRECTORY) || (0 == (attributes & FILE_ATTRIBUTE_READONLY));
+	}
+
+	genericMapping.GenericRead = FILE_GENERIC_READ;
+    genericMapping.GenericWrite = FILE_GENERIC_WRITE;
+    genericMapping.GenericExecute = FILE_GENERIC_EXECUTE;
+    genericMapping.GenericAll = FILE_ALL_ACCESS;
+
+	if(!ImpersonateSelf(SecurityDelegation)) {
+		return 0;
+	}
+	if(!OpenThreadToken(GetCurrentThread(), TOKEN_ALL_ACCESS, TRUE, &tokenHandle)) {
+		return 0;
+	}
+
+	accessMask = GENERIC_WRITE;
+	MapGenericMask(&accessMask, &genericMapping);
+
+	if(!AccessCheck(pDesc, tokenHandle, accessMask, &genericMapping,
+					&PrivilegeSet,       // receives privileges used in check
+					&dwPrivSetSize,      // size of PrivilegeSet buffer
+					&dwAccessAllowed,    // receives mask of allowed access rights
+					&fAccessGranted)) 
+	{
+		CloseHandle(tokenHandle);
+		RevertToSelf();
+		LocalFree(pDesc);
+		return 0;
+	}
+	CloseHandle(tokenHandle);
+	RevertToSelf();
+	LocalFree(pDesc);
+	return fAccessGranted == TRUE;
+#else
 #ifdef HAVE_EACCESS
   return (qxe_eaccess (filename, W_OK) >= 0);
 #else
@@ -2301,6 +2370,7 @@
      but would lose for directories.  */
   return (qxe_access (filename, W_OK) >= 0);
 #endif
+#endif
 }
 
 DEFUN ("file-exists-p", Ffile_exists_p, 1, 1, 0, /*
--- a/src/intl-auto-encap-win32.c	Fri Dec 08 02:17:16 2006 +0000
+++ b/src/intl-auto-encap-win32.c	Fri Dec 08 02:22:02 2006 +0000
@@ -13,121 +13,6 @@
 
 
 /*----------------------------------------------------------------------*/
-/*                       Processing file WINCON.H                       */
-/*----------------------------------------------------------------------*/
-
-BOOL
-qxePeekConsoleInput (HANDLE hConsoleInput, PINPUT_RECORD lpBuffer, DWORD nLength, LPDWORD lpNumberOfEventsRead)
-{
-  if (XEUNICODE_P)
-    return PeekConsoleInputW (hConsoleInput, lpBuffer, nLength, lpNumberOfEventsRead);
-  else
-    return PeekConsoleInputA (hConsoleInput, lpBuffer, nLength, lpNumberOfEventsRead);
-}
-
-BOOL
-qxeReadConsoleInput (HANDLE hConsoleInput, PINPUT_RECORD lpBuffer, DWORD nLength, LPDWORD lpNumberOfEventsRead)
-{
-  if (XEUNICODE_P)
-    return ReadConsoleInputW (hConsoleInput, lpBuffer, nLength, lpNumberOfEventsRead);
-  else
-    return ReadConsoleInputA (hConsoleInput, lpBuffer, nLength, lpNumberOfEventsRead);
-}
-
-BOOL
-qxeWriteConsoleInput (HANDLE hConsoleInput, CONST INPUT_RECORD * lpBuffer, DWORD nLength, LPDWORD lpNumberOfEventsWritten)
-{
-  if (XEUNICODE_P)
-    return WriteConsoleInputW (hConsoleInput, lpBuffer, nLength, lpNumberOfEventsWritten);
-  else
-    return WriteConsoleInputA (hConsoleInput, lpBuffer, nLength, lpNumberOfEventsWritten);
-}
-
-BOOL
-qxeReadConsoleOutput (HANDLE hConsoleOutput, PCHAR_INFO lpBuffer, COORD dwBufferSize, COORD dwBufferCoord, PSMALL_RECT lpReadRegion)
-{
-  if (XEUNICODE_P)
-    return ReadConsoleOutputW (hConsoleOutput, lpBuffer, dwBufferSize, dwBufferCoord, lpReadRegion);
-  else
-    return ReadConsoleOutputA (hConsoleOutput, lpBuffer, dwBufferSize, dwBufferCoord, lpReadRegion);
-}
-
-BOOL
-qxeWriteConsoleOutput (HANDLE hConsoleOutput, CONST CHAR_INFO * lpBuffer, COORD dwBufferSize, COORD dwBufferCoord, PSMALL_RECT lpWriteRegion)
-{
-  if (XEUNICODE_P)
-    return WriteConsoleOutputW (hConsoleOutput, lpBuffer, dwBufferSize, dwBufferCoord, lpWriteRegion);
-  else
-    return WriteConsoleOutputA (hConsoleOutput, lpBuffer, dwBufferSize, dwBufferCoord, lpWriteRegion);
-}
-
-BOOL
-qxeReadConsoleOutputCharacter (HANDLE hConsoleOutput, Extbyte * lpCharacter, DWORD nLength, COORD dwReadCoord, LPDWORD lpNumberOfCharsRead)
-{
-  if (XEUNICODE_P)
-    return ReadConsoleOutputCharacterW (hConsoleOutput, (LPWSTR) lpCharacter, nLength, dwReadCoord, lpNumberOfCharsRead);
-  else
-    return ReadConsoleOutputCharacterA (hConsoleOutput, (LPSTR) lpCharacter, nLength, dwReadCoord, lpNumberOfCharsRead);
-}
-
-BOOL
-qxeWriteConsoleOutputCharacter (HANDLE hConsoleOutput, const Extbyte * lpCharacter, DWORD nLength, COORD dwWriteCoord, LPDWORD lpNumberOfCharsWritten)
-{
-  if (XEUNICODE_P)
-    return WriteConsoleOutputCharacterW (hConsoleOutput, (LPCWSTR) lpCharacter, nLength, dwWriteCoord, lpNumberOfCharsWritten);
-  else
-    return WriteConsoleOutputCharacterA (hConsoleOutput, (LPCSTR) lpCharacter, nLength, dwWriteCoord, lpNumberOfCharsWritten);
-}
-
-/* Error if FillConsoleOutputCharacter used: split CHAR */
-
-BOOL
-qxeScrollConsoleScreenBuffer (HANDLE hConsoleOutput, CONST SMALL_RECT * lpScrollRectangle, CONST SMALL_RECT * lpClipRectangle, COORD dwDestinationOrigin, CONST CHAR_INFO * lpFill)
-{
-  if (XEUNICODE_P)
-    return ScrollConsoleScreenBufferW (hConsoleOutput, lpScrollRectangle, lpClipRectangle, dwDestinationOrigin, lpFill);
-  else
-    return ScrollConsoleScreenBufferA (hConsoleOutput, lpScrollRectangle, lpClipRectangle, dwDestinationOrigin, lpFill);
-}
-
-DWORD
-qxeGetConsoleTitle (Extbyte * lpConsoleTitle, DWORD nSize)
-{
-  if (XEUNICODE_P)
-    return GetConsoleTitleW ((LPWSTR) lpConsoleTitle, nSize);
-  else
-    return GetConsoleTitleA ((LPSTR) lpConsoleTitle, nSize);
-}
-
-BOOL
-qxeSetConsoleTitle (const Extbyte * lpConsoleTitle)
-{
-  if (XEUNICODE_P)
-    return SetConsoleTitleW ((LPCWSTR) lpConsoleTitle);
-  else
-    return SetConsoleTitleA ((LPCSTR) lpConsoleTitle);
-}
-
-BOOL
-qxeReadConsole (HANDLE hConsoleInput, LPVOID lpBuffer, DWORD nNumberOfCharsToRead, LPDWORD lpNumberOfCharsRead, LPVOID lpReserved)
-{
-  if (XEUNICODE_P)
-    return ReadConsoleW (hConsoleInput, lpBuffer, nNumberOfCharsToRead, lpNumberOfCharsRead, lpReserved);
-  else
-    return ReadConsoleA (hConsoleInput, lpBuffer, nNumberOfCharsToRead, lpNumberOfCharsRead, lpReserved);
-}
-
-BOOL
-qxeWriteConsole (HANDLE hConsoleOutput, CONST VOID * lpBuffer, DWORD nNumberOfCharsToWrite, LPDWORD lpNumberOfCharsWritten, LPVOID lpReserved)
-{
-  if (XEUNICODE_P)
-    return WriteConsoleW (hConsoleOutput, lpBuffer, nNumberOfCharsToWrite, lpNumberOfCharsWritten, lpReserved);
-  else
-    return WriteConsoleA (hConsoleOutput, lpBuffer, nNumberOfCharsToWrite, lpNumberOfCharsWritten, lpReserved);
-}
-
-
-/*----------------------------------------------------------------------*/
 /*                      Processing file SHELLAPI.H                      */
 /*----------------------------------------------------------------------*/
 
@@ -658,233 +543,6 @@
 
 
 /*----------------------------------------------------------------------*/
-/*                      Processing file WINNETWK.H                      */
-/*----------------------------------------------------------------------*/
-
-#if defined (HAVE_MS_WINDOWS)
-
-DWORD 
-qxeWNetAddConnection (const Extbyte * lpRemoteName, const Extbyte * lpPassword, const Extbyte * lpLocalName)
-{
-  if (XEUNICODE_P)
-    return WNetAddConnectionW ((LPCWSTR) lpRemoteName, (LPCWSTR) lpPassword, (LPCWSTR) lpLocalName);
-  else
-    return WNetAddConnectionA ((LPCSTR) lpRemoteName, (LPCSTR) lpPassword, (LPCSTR) lpLocalName);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-DWORD 
-qxeWNetAddConnection2 (LPNETRESOURCEW lpNetResource, const Extbyte * lpPassword, const Extbyte * lpUserName, DWORD dwFlags)
-{
-  if (XEUNICODE_P)
-    return WNetAddConnection2W (lpNetResource, (LPCWSTR) lpPassword, (LPCWSTR) lpUserName, dwFlags);
-  else
-    return WNetAddConnection2A ((LPNETRESOURCEA) lpNetResource, (LPCSTR) lpPassword, (LPCSTR) lpUserName, dwFlags);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-DWORD 
-qxeWNetAddConnection3 (HWND hwndOwner, LPNETRESOURCEW lpNetResource, const Extbyte * lpPassword, const Extbyte * lpUserName, DWORD dwFlags)
-{
-  if (XEUNICODE_P)
-    return WNetAddConnection3W (hwndOwner, lpNetResource, (LPCWSTR) lpPassword, (LPCWSTR) lpUserName, dwFlags);
-  else
-    return WNetAddConnection3A (hwndOwner, (LPNETRESOURCEA) lpNetResource, (LPCSTR) lpPassword, (LPCSTR) lpUserName, dwFlags);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-DWORD 
-qxeWNetCancelConnection (const Extbyte * lpName, BOOL fForce)
-{
-  if (XEUNICODE_P)
-    return WNetCancelConnectionW ((LPCWSTR) lpName, fForce);
-  else
-    return WNetCancelConnectionA ((LPCSTR) lpName, fForce);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-DWORD 
-qxeWNetCancelConnection2 (const Extbyte * lpName, DWORD dwFlags, BOOL fForce)
-{
-  if (XEUNICODE_P)
-    return WNetCancelConnection2W ((LPCWSTR) lpName, dwFlags, fForce);
-  else
-    return WNetCancelConnection2A ((LPCSTR) lpName, dwFlags, fForce);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-DWORD 
-qxeWNetGetConnection (const Extbyte * lpLocalName, Extbyte * lpRemoteName, LPDWORD lpnLength)
-{
-  if (XEUNICODE_P)
-    return WNetGetConnectionW ((LPCWSTR) lpLocalName, (LPWSTR) lpRemoteName, lpnLength);
-  else
-    return WNetGetConnectionA ((LPCSTR) lpLocalName, (LPSTR) lpRemoteName, lpnLength);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-DWORD 
-qxeWNetUseConnection (HWND hwndOwner, LPNETRESOURCEW lpNetResource, const Extbyte * lpUserID, const Extbyte * lpPassword, DWORD dwFlags, Extbyte * lpAccessName, LPDWORD lpBufferSize, LPDWORD lpResult)
-{
-  if (XEUNICODE_P)
-    return WNetUseConnectionW (hwndOwner, lpNetResource, (LPCWSTR) lpUserID, (LPCWSTR) lpPassword, dwFlags, (LPWSTR) lpAccessName, lpBufferSize, lpResult);
-  else
-    return WNetUseConnectionA (hwndOwner, (LPNETRESOURCEA) lpNetResource, (LPCSTR) lpUserID, (LPCSTR) lpPassword, dwFlags, (LPSTR) lpAccessName, lpBufferSize, lpResult);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-/* NOTE: contains split-simple LPNETRESOURCE */
-DWORD 
-qxeWNetConnectionDialog1 (LPCONNECTDLGSTRUCTW lpConnDlgStruct)
-{
-  if (XEUNICODE_P)
-    return WNetConnectionDialog1W (lpConnDlgStruct);
-  else
-    return WNetConnectionDialog1A ((LPCONNECTDLGSTRUCTA) lpConnDlgStruct);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-DWORD 
-qxeWNetDisconnectDialog1 (LPDISCDLGSTRUCTW lpConnDlgStruct)
-{
-  if (XEUNICODE_P)
-    return WNetDisconnectDialog1W (lpConnDlgStruct);
-  else
-    return WNetDisconnectDialog1A ((LPDISCDLGSTRUCTA) lpConnDlgStruct);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-DWORD 
-qxeWNetOpenEnum (DWORD dwScope, DWORD dwType, DWORD dwUsage, LPNETRESOURCEW lpNetResource, LPHANDLE lphEnum)
-{
-  if (XEUNICODE_P)
-    return WNetOpenEnumW (dwScope, dwType, dwUsage, lpNetResource, lphEnum);
-  else
-    return WNetOpenEnumA (dwScope, dwType, dwUsage, (LPNETRESOURCEA) lpNetResource, lphEnum);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-DWORD 
-qxeWNetEnumResource (HANDLE hEnum, LPDWORD lpcCount, LPVOID lpBuffer, LPDWORD lpBufferSize)
-{
-  if (XEUNICODE_P)
-    return WNetEnumResourceW (hEnum, lpcCount, lpBuffer, lpBufferSize);
-  else
-    return WNetEnumResourceA (hEnum, lpcCount, lpBuffer, lpBufferSize);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-DWORD 
-qxeWNetGetUniversalName (const Extbyte * lpLocalPath, DWORD dwInfoLevel, LPVOID lpBuffer, LPDWORD lpBufferSize)
-{
-  if (XEUNICODE_P)
-    return WNetGetUniversalNameW ((LPCWSTR) lpLocalPath, dwInfoLevel, lpBuffer, lpBufferSize);
-  else
-    return WNetGetUniversalNameA ((LPCSTR) lpLocalPath, dwInfoLevel, lpBuffer, lpBufferSize);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-DWORD 
-qxeWNetGetUser (const Extbyte * lpName, Extbyte * lpUserName, LPDWORD lpnLength)
-{
-  if (XEUNICODE_P)
-    return WNetGetUserW ((LPCWSTR) lpName, (LPWSTR) lpUserName, lpnLength);
-  else
-    return WNetGetUserA ((LPCSTR) lpName, (LPSTR) lpUserName, lpnLength);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-DWORD 
-qxeWNetGetProviderName (DWORD dwNetType, Extbyte * lpProviderName, LPDWORD lpBufferSize)
-{
-  if (XEUNICODE_P)
-    return WNetGetProviderNameW (dwNetType, (LPWSTR) lpProviderName, lpBufferSize);
-  else
-    return WNetGetProviderNameA (dwNetType, (LPSTR) lpProviderName, lpBufferSize);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-DWORD 
-qxeWNetGetNetworkInformation (const Extbyte * lpProvider, LPNETINFOSTRUCT lpNetInfoStruct)
-{
-  if (XEUNICODE_P)
-    return WNetGetNetworkInformationW ((LPCWSTR) lpProvider, lpNetInfoStruct);
-  else
-    return WNetGetNetworkInformationA ((LPCSTR) lpProvider, lpNetInfoStruct);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-DWORD 
-qxeWNetGetLastError (LPDWORD lpError, Extbyte * lpErrorBuf, DWORD nErrorBufSize, Extbyte * lpNameBuf, DWORD nNameBufSize)
-{
-  if (XEUNICODE_P)
-    return WNetGetLastErrorW (lpError, (LPWSTR) lpErrorBuf, nErrorBufSize, (LPWSTR) lpNameBuf, nNameBufSize);
-  else
-    return WNetGetLastErrorA (lpError, (LPSTR) lpErrorBuf, nErrorBufSize, (LPSTR) lpNameBuf, nNameBufSize);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-DWORD 
-qxeMultinetGetConnectionPerformance (LPNETRESOURCEW lpNetResource, LPNETCONNECTINFOSTRUCT lpNetConnectInfoStruct)
-{
-  if (XEUNICODE_P)
-    return MultinetGetConnectionPerformanceW (lpNetResource, lpNetConnectInfoStruct);
-  else
-    return MultinetGetConnectionPerformanceA ((LPNETRESOURCEA) lpNetResource, lpNetConnectInfoStruct);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-
-/*----------------------------------------------------------------------*/
 /*                      Processing file WINUSER.H                       */
 /*----------------------------------------------------------------------*/
 
@@ -1858,6 +1516,731 @@
 
 
 /*----------------------------------------------------------------------*/
+/*                        Processing file IME.H                         */
+/*----------------------------------------------------------------------*/
+
+/* Error if SendIMEMessageEx used: obsolete, no docs available */
+
+
+/*----------------------------------------------------------------------*/
+/*                        Processing file IMM.H                         */
+/*----------------------------------------------------------------------*/
+
+#if defined (HAVE_MS_WINDOWS)
+
+HKL
+qxeImmInstallIME (const Extbyte * lpszIMEFileName, const Extbyte * lpszLayoutText)
+{
+  if (XEUNICODE_P)
+    return ImmInstallIMEW ((LPCWSTR) lpszIMEFileName, (LPCWSTR) lpszLayoutText);
+  else
+    return ImmInstallIMEA ((LPCSTR) lpszIMEFileName, (LPCSTR) lpszLayoutText);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+UINT
+qxeImmGetDescription (HKL arg1, Extbyte * arg2, UINT uBufLen)
+{
+  if (XEUNICODE_P)
+    return ImmGetDescriptionW (arg1, (LPWSTR) arg2, uBufLen);
+  else
+    return ImmGetDescriptionA (arg1, (LPSTR) arg2, uBufLen);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+UINT
+qxeImmGetIMEFileName (HKL arg1, Extbyte * arg2, UINT uBufLen)
+{
+  if (XEUNICODE_P)
+    return ImmGetIMEFileNameW (arg1, (LPWSTR) arg2, uBufLen);
+  else
+    return ImmGetIMEFileNameA (arg1, (LPSTR) arg2, uBufLen);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+LONG
+qxeImmGetCompositionString (HIMC arg1, DWORD arg2, LPVOID arg3, DWORD arg4)
+{
+  if (XEUNICODE_P)
+    return ImmGetCompositionStringW (arg1, arg2, arg3, arg4);
+  else
+    return ImmGetCompositionStringA (arg1, arg2, arg3, arg4);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+/* Skipping ImmSetCompositionString because different prototypes in VC6 and VC7 */
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+DWORD
+qxeImmGetCandidateListCount (HIMC arg1, LPDWORD lpdwListCount)
+{
+  if (XEUNICODE_P)
+    return ImmGetCandidateListCountW (arg1, lpdwListCount);
+  else
+    return ImmGetCandidateListCountA (arg1, lpdwListCount);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+DWORD
+qxeImmGetCandidateList (HIMC arg1, DWORD deIndex, LPCANDIDATELIST arg3, DWORD dwBufLen)
+{
+  if (XEUNICODE_P)
+    return ImmGetCandidateListW (arg1, deIndex, arg3, dwBufLen);
+  else
+    return ImmGetCandidateListA (arg1, deIndex, arg3, dwBufLen);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+DWORD
+qxeImmGetGuideLine (HIMC arg1, DWORD dwIndex, Extbyte * arg3, DWORD dwBufLen)
+{
+  if (XEUNICODE_P)
+    return ImmGetGuideLineW (arg1, dwIndex, (LPWSTR) arg3, dwBufLen);
+  else
+    return ImmGetGuideLineA (arg1, dwIndex, (LPSTR) arg3, dwBufLen);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+/* Skipping ImmGetCompositionFont because split-sized LOGFONT */
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+/* Skipping ImmSetCompositionFont because split-sized LOGFONT */
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+/* NOTE: // split-simple REGISTERWORD */
+BOOL
+qxeImmConfigureIME (HKL arg1, HWND arg2, DWORD arg3, LPVOID arg4)
+{
+  if (XEUNICODE_P)
+    return ImmConfigureIMEW (arg1, arg2, arg3, arg4);
+  else
+    return ImmConfigureIMEA (arg1, arg2, arg3, arg4);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+/* NOTE: // strings of various sorts */
+LRESULT
+qxeImmEscape (HKL arg1, HIMC arg2, UINT arg3, LPVOID arg4)
+{
+  if (XEUNICODE_P)
+    return ImmEscapeW (arg1, arg2, arg3, arg4);
+  else
+    return ImmEscapeA (arg1, arg2, arg3, arg4);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+DWORD
+qxeImmGetConversionList (HKL arg1, HIMC arg2, const Extbyte * arg3, LPCANDIDATELIST arg4, DWORD dwBufLen, UINT uFlag)
+{
+  if (XEUNICODE_P)
+    return ImmGetConversionListW (arg1, arg2, (LPCWSTR) arg3, arg4, dwBufLen, uFlag);
+  else
+    return ImmGetConversionListA (arg1, arg2, (LPCSTR) arg3, arg4, dwBufLen, uFlag);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+BOOL
+qxeImmIsUIMessage (HWND arg1, UINT arg2, WPARAM arg3, LPARAM arg4)
+{
+  if (XEUNICODE_P)
+    return ImmIsUIMessageW (arg1, arg2, arg3, arg4);
+  else
+    return ImmIsUIMessageA (arg1, arg2, arg3, arg4);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+BOOL
+qxeImmRegisterWord (HKL arg1, const Extbyte * lpszReading, DWORD arg3, const Extbyte * lpszRegister)
+{
+  if (XEUNICODE_P)
+    return ImmRegisterWordW (arg1, (LPCWSTR) lpszReading, arg3, (LPCWSTR) lpszRegister);
+  else
+    return ImmRegisterWordA (arg1, (LPCSTR) lpszReading, arg3, (LPCSTR) lpszRegister);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+BOOL
+qxeImmUnregisterWord (HKL arg1, const Extbyte * lpszReading, DWORD arg3, const Extbyte * lpszUnregister)
+{
+  if (XEUNICODE_P)
+    return ImmUnregisterWordW (arg1, (LPCWSTR) lpszReading, arg3, (LPCWSTR) lpszUnregister);
+  else
+    return ImmUnregisterWordA (arg1, (LPCSTR) lpszReading, arg3, (LPCSTR) lpszUnregister);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+/* Error if ImmGetRegisterWordStyle used: split-sized STYLEBUF */
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+UINT
+qxeImmEnumRegisterWord (HKL arg1, REGISTERWORDENUMPROCW arg2, const Extbyte * lpszReading, DWORD arg4, const Extbyte * lpszRegister, LPVOID arg6)
+{
+  if (XEUNICODE_P)
+    return ImmEnumRegisterWordW (arg1, arg2, (LPCWSTR) lpszReading, arg4, (LPCWSTR) lpszRegister, arg6);
+  else
+    return ImmEnumRegisterWordA (arg1, (REGISTERWORDENUMPROCA) arg2, (LPCSTR) lpszReading, arg4, (LPCSTR) lpszRegister, arg6);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+/* Error if ImmGetImeMenuItems used: split-sized IMEMENUITEMINFO */
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+
+/*----------------------------------------------------------------------*/
+/*                      Processing file MMSYSTEM.H                      */
+/*----------------------------------------------------------------------*/
+
+BOOL
+qxesndPlaySound (const Extbyte * pszSound, UINT fuSound)
+{
+  if (XEUNICODE_P)
+    return sndPlaySoundW ((LPCWSTR) pszSound, fuSound);
+  else
+    return sndPlaySoundA ((LPCSTR) pszSound, fuSound);
+}
+
+BOOL
+qxePlaySound (const Extbyte * pszSound, HMODULE hmod, DWORD fdwSound)
+{
+  if (XEUNICODE_P)
+    return PlaySoundW ((LPCWSTR) pszSound, hmod, fdwSound);
+  else
+    return PlaySoundA ((LPCSTR) pszSound, hmod, fdwSound);
+}
+
+/* Error if waveOutGetDevCaps used: split-sized LPWAVEOUTCAPS */
+
+MMRESULT
+qxewaveOutGetErrorText (MMRESULT mmrError, Extbyte * pszText, UINT cchText)
+{
+  if (XEUNICODE_P)
+    return waveOutGetErrorTextW (mmrError, (LPWSTR) pszText, cchText);
+  else
+    return waveOutGetErrorTextA (mmrError, (LPSTR) pszText, cchText);
+}
+
+/* Error if waveInGetDevCaps used: split-sized LPWAVEINCAPS */
+
+MMRESULT
+qxewaveInGetErrorText (MMRESULT mmrError, Extbyte * pszText, UINT cchText)
+{
+  if (XEUNICODE_P)
+    return waveInGetErrorTextW (mmrError, (LPWSTR) pszText, cchText);
+  else
+    return waveInGetErrorTextA (mmrError, (LPSTR) pszText, cchText);
+}
+
+/* Error if midiOutGetDevCaps used: split-sized LPMIDIOUTCAPS */
+
+MMRESULT
+qxemidiOutGetErrorText (MMRESULT mmrError, Extbyte * pszText, UINT cchText)
+{
+  if (XEUNICODE_P)
+    return midiOutGetErrorTextW (mmrError, (LPWSTR) pszText, cchText);
+  else
+    return midiOutGetErrorTextA (mmrError, (LPSTR) pszText, cchText);
+}
+
+/* Error if midiInGetDevCaps used: split-sized LPMIDIOUTCAPS */
+
+MMRESULT
+qxemidiInGetErrorText (MMRESULT mmrError, Extbyte * pszText, UINT cchText)
+{
+  if (XEUNICODE_P)
+    return midiInGetErrorTextW (mmrError, (LPWSTR) pszText, cchText);
+  else
+    return midiInGetErrorTextA (mmrError, (LPSTR) pszText, cchText);
+}
+
+/* Error if auxGetDevCaps used: split-sized LPAUXCAPS */
+
+/* Error if mixerGetDevCaps used: split-sized LPMIXERCAPS */
+
+/* Error if mixerGetLineInfo used: split-sized LPMIXERLINE */
+
+/* Error if mixerGetLineControls used: split-sized LPMIXERCONTROL */
+
+/* Error if mixerGetControlDetails used: split-sized LPMIXERCONTROL in LPMIXERLINECONTROLS in LPMIXERCONTROLDETAILS */
+
+/* Error if joyGetDevCaps used: split-sized LPJOYCAPS */
+
+FOURCC
+qxemmioStringToFOURCC (const Extbyte * sz, UINT uFlags)
+{
+  if (XEUNICODE_P)
+    return mmioStringToFOURCCW ((LPCWSTR) sz, uFlags);
+  else
+    return mmioStringToFOURCCA ((LPCSTR) sz, uFlags);
+}
+
+LPMMIOPROC
+qxemmioInstallIOProc (FOURCC fccIOProc, LPMMIOPROC pIOProc, DWORD dwFlags)
+{
+  if (XEUNICODE_P)
+    return mmioInstallIOProcW (fccIOProc, pIOProc, dwFlags);
+  else
+    return mmioInstallIOProcA (fccIOProc, pIOProc, dwFlags);
+}
+
+HMMIO
+qxemmioOpen (Extbyte * pszFileName, LPMMIOINFO pmmioinfo, DWORD fdwOpen)
+{
+  if (XEUNICODE_P)
+    return mmioOpenW ((LPWSTR) pszFileName, pmmioinfo, fdwOpen);
+  else
+    return mmioOpenA ((LPSTR) pszFileName, pmmioinfo, fdwOpen);
+}
+
+MMRESULT
+qxemmioRename (const Extbyte * pszFileName, const Extbyte * pszNewFileName, LPCMMIOINFO pmmioinfo, DWORD fdwRename)
+{
+  if (XEUNICODE_P)
+    return mmioRenameW ((LPCWSTR) pszFileName, (LPCWSTR) pszNewFileName, pmmioinfo, fdwRename);
+  else
+    return mmioRenameA ((LPCSTR) pszFileName, (LPCSTR) pszNewFileName, pmmioinfo, fdwRename);
+}
+
+MCIERROR
+qxemciSendCommand (MCIDEVICEID mciId, UINT uMsg, DWORD dwParam1, DWORD dwParam2)
+{
+  if (XEUNICODE_P)
+    return mciSendCommandW (mciId, uMsg, dwParam1, dwParam2);
+  else
+    return mciSendCommandA (mciId, uMsg, dwParam1, dwParam2);
+}
+
+MCIERROR
+qxemciSendString (const Extbyte * lpstrCommand, Extbyte * lpstrReturnString, UINT uReturnLength, HWND hwndCallback)
+{
+  if (XEUNICODE_P)
+    return mciSendStringW ((LPCWSTR) lpstrCommand, (LPWSTR) lpstrReturnString, uReturnLength, hwndCallback);
+  else
+    return mciSendStringA ((LPCSTR) lpstrCommand, (LPSTR) lpstrReturnString, uReturnLength, hwndCallback);
+}
+
+MCIDEVICEID
+qxemciGetDeviceID (const Extbyte * pszDevice)
+{
+  if (XEUNICODE_P)
+    return mciGetDeviceIDW ((LPCWSTR) pszDevice);
+  else
+    return mciGetDeviceIDA ((LPCSTR) pszDevice);
+}
+
+#if !defined (MINGW)
+
+/* Error if mciGetDeviceIDFromElementID used: missing from Win98se version of ADVAPI32.dll */
+
+#endif /* !defined (MINGW) */
+
+BOOL
+qxemciGetErrorString (MCIERROR mcierr, Extbyte * pszText, UINT cchText)
+{
+  if (XEUNICODE_P)
+    return mciGetErrorStringW (mcierr, (LPWSTR) pszText, cchText);
+  else
+    return mciGetErrorStringA (mcierr, (LPSTR) pszText, cchText);
+}
+
+
+/*----------------------------------------------------------------------*/
+/*                       Processing file WINCON.H                       */
+/*----------------------------------------------------------------------*/
+
+BOOL
+qxePeekConsoleInput (HANDLE hConsoleInput, PINPUT_RECORD lpBuffer, DWORD nLength, LPDWORD lpNumberOfEventsRead)
+{
+  if (XEUNICODE_P)
+    return PeekConsoleInputW (hConsoleInput, lpBuffer, nLength, lpNumberOfEventsRead);
+  else
+    return PeekConsoleInputA (hConsoleInput, lpBuffer, nLength, lpNumberOfEventsRead);
+}
+
+BOOL
+qxeReadConsoleInput (HANDLE hConsoleInput, PINPUT_RECORD lpBuffer, DWORD nLength, LPDWORD lpNumberOfEventsRead)
+{
+  if (XEUNICODE_P)
+    return ReadConsoleInputW (hConsoleInput, lpBuffer, nLength, lpNumberOfEventsRead);
+  else
+    return ReadConsoleInputA (hConsoleInput, lpBuffer, nLength, lpNumberOfEventsRead);
+}
+
+BOOL
+qxeWriteConsoleInput (HANDLE hConsoleInput, CONST INPUT_RECORD * lpBuffer, DWORD nLength, LPDWORD lpNumberOfEventsWritten)
+{
+  if (XEUNICODE_P)
+    return WriteConsoleInputW (hConsoleInput, lpBuffer, nLength, lpNumberOfEventsWritten);
+  else
+    return WriteConsoleInputA (hConsoleInput, lpBuffer, nLength, lpNumberOfEventsWritten);
+}
+
+BOOL
+qxeReadConsoleOutput (HANDLE hConsoleOutput, PCHAR_INFO lpBuffer, COORD dwBufferSize, COORD dwBufferCoord, PSMALL_RECT lpReadRegion)
+{
+  if (XEUNICODE_P)
+    return ReadConsoleOutputW (hConsoleOutput, lpBuffer, dwBufferSize, dwBufferCoord, lpReadRegion);
+  else
+    return ReadConsoleOutputA (hConsoleOutput, lpBuffer, dwBufferSize, dwBufferCoord, lpReadRegion);
+}
+
+BOOL
+qxeWriteConsoleOutput (HANDLE hConsoleOutput, CONST CHAR_INFO * lpBuffer, COORD dwBufferSize, COORD dwBufferCoord, PSMALL_RECT lpWriteRegion)
+{
+  if (XEUNICODE_P)
+    return WriteConsoleOutputW (hConsoleOutput, lpBuffer, dwBufferSize, dwBufferCoord, lpWriteRegion);
+  else
+    return WriteConsoleOutputA (hConsoleOutput, lpBuffer, dwBufferSize, dwBufferCoord, lpWriteRegion);
+}
+
+BOOL
+qxeReadConsoleOutputCharacter (HANDLE hConsoleOutput, Extbyte * lpCharacter, DWORD nLength, COORD dwReadCoord, LPDWORD lpNumberOfCharsRead)
+{
+  if (XEUNICODE_P)
+    return ReadConsoleOutputCharacterW (hConsoleOutput, (LPWSTR) lpCharacter, nLength, dwReadCoord, lpNumberOfCharsRead);
+  else
+    return ReadConsoleOutputCharacterA (hConsoleOutput, (LPSTR) lpCharacter, nLength, dwReadCoord, lpNumberOfCharsRead);
+}
+
+BOOL
+qxeWriteConsoleOutputCharacter (HANDLE hConsoleOutput, const Extbyte * lpCharacter, DWORD nLength, COORD dwWriteCoord, LPDWORD lpNumberOfCharsWritten)
+{
+  if (XEUNICODE_P)
+    return WriteConsoleOutputCharacterW (hConsoleOutput, (LPCWSTR) lpCharacter, nLength, dwWriteCoord, lpNumberOfCharsWritten);
+  else
+    return WriteConsoleOutputCharacterA (hConsoleOutput, (LPCSTR) lpCharacter, nLength, dwWriteCoord, lpNumberOfCharsWritten);
+}
+
+/* Error if FillConsoleOutputCharacter used: split CHAR */
+
+BOOL
+qxeScrollConsoleScreenBuffer (HANDLE hConsoleOutput, CONST SMALL_RECT * lpScrollRectangle, CONST SMALL_RECT * lpClipRectangle, COORD dwDestinationOrigin, CONST CHAR_INFO * lpFill)
+{
+  if (XEUNICODE_P)
+    return ScrollConsoleScreenBufferW (hConsoleOutput, lpScrollRectangle, lpClipRectangle, dwDestinationOrigin, lpFill);
+  else
+    return ScrollConsoleScreenBufferA (hConsoleOutput, lpScrollRectangle, lpClipRectangle, dwDestinationOrigin, lpFill);
+}
+
+DWORD
+qxeGetConsoleTitle (Extbyte * lpConsoleTitle, DWORD nSize)
+{
+  if (XEUNICODE_P)
+    return GetConsoleTitleW ((LPWSTR) lpConsoleTitle, nSize);
+  else
+    return GetConsoleTitleA ((LPSTR) lpConsoleTitle, nSize);
+}
+
+BOOL
+qxeSetConsoleTitle (const Extbyte * lpConsoleTitle)
+{
+  if (XEUNICODE_P)
+    return SetConsoleTitleW ((LPCWSTR) lpConsoleTitle);
+  else
+    return SetConsoleTitleA ((LPCSTR) lpConsoleTitle);
+}
+
+BOOL
+qxeReadConsole (HANDLE hConsoleInput, LPVOID lpBuffer, DWORD nNumberOfCharsToRead, LPDWORD lpNumberOfCharsRead, LPVOID lpReserved)
+{
+  if (XEUNICODE_P)
+    return ReadConsoleW (hConsoleInput, lpBuffer, nNumberOfCharsToRead, lpNumberOfCharsRead, lpReserved);
+  else
+    return ReadConsoleA (hConsoleInput, lpBuffer, nNumberOfCharsToRead, lpNumberOfCharsRead, lpReserved);
+}
+
+BOOL
+qxeWriteConsole (HANDLE hConsoleOutput, CONST VOID * lpBuffer, DWORD nNumberOfCharsToWrite, LPDWORD lpNumberOfCharsWritten, LPVOID lpReserved)
+{
+  if (XEUNICODE_P)
+    return WriteConsoleW (hConsoleOutput, lpBuffer, nNumberOfCharsToWrite, lpNumberOfCharsWritten, lpReserved);
+  else
+    return WriteConsoleA (hConsoleOutput, lpBuffer, nNumberOfCharsToWrite, lpNumberOfCharsWritten, lpReserved);
+}
+
+
+/*----------------------------------------------------------------------*/
+/*                      Processing file WINNETWK.H                      */
+/*----------------------------------------------------------------------*/
+
+#if defined (HAVE_MS_WINDOWS)
+
+DWORD 
+qxeWNetAddConnection (const Extbyte * lpRemoteName, const Extbyte * lpPassword, const Extbyte * lpLocalName)
+{
+  if (XEUNICODE_P)
+    return WNetAddConnectionW ((LPCWSTR) lpRemoteName, (LPCWSTR) lpPassword, (LPCWSTR) lpLocalName);
+  else
+    return WNetAddConnectionA ((LPCSTR) lpRemoteName, (LPCSTR) lpPassword, (LPCSTR) lpLocalName);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+DWORD 
+qxeWNetAddConnection2 (LPNETRESOURCEW lpNetResource, const Extbyte * lpPassword, const Extbyte * lpUserName, DWORD dwFlags)
+{
+  if (XEUNICODE_P)
+    return WNetAddConnection2W (lpNetResource, (LPCWSTR) lpPassword, (LPCWSTR) lpUserName, dwFlags);
+  else
+    return WNetAddConnection2A ((LPNETRESOURCEA) lpNetResource, (LPCSTR) lpPassword, (LPCSTR) lpUserName, dwFlags);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+DWORD 
+qxeWNetAddConnection3 (HWND hwndOwner, LPNETRESOURCEW lpNetResource, const Extbyte * lpPassword, const Extbyte * lpUserName, DWORD dwFlags)
+{
+  if (XEUNICODE_P)
+    return WNetAddConnection3W (hwndOwner, lpNetResource, (LPCWSTR) lpPassword, (LPCWSTR) lpUserName, dwFlags);
+  else
+    return WNetAddConnection3A (hwndOwner, (LPNETRESOURCEA) lpNetResource, (LPCSTR) lpPassword, (LPCSTR) lpUserName, dwFlags);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+DWORD 
+qxeWNetCancelConnection (const Extbyte * lpName, BOOL fForce)
+{
+  if (XEUNICODE_P)
+    return WNetCancelConnectionW ((LPCWSTR) lpName, fForce);
+  else
+    return WNetCancelConnectionA ((LPCSTR) lpName, fForce);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+DWORD 
+qxeWNetCancelConnection2 (const Extbyte * lpName, DWORD dwFlags, BOOL fForce)
+{
+  if (XEUNICODE_P)
+    return WNetCancelConnection2W ((LPCWSTR) lpName, dwFlags, fForce);
+  else
+    return WNetCancelConnection2A ((LPCSTR) lpName, dwFlags, fForce);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+DWORD 
+qxeWNetGetConnection (const Extbyte * lpLocalName, Extbyte * lpRemoteName, LPDWORD lpnLength)
+{
+  if (XEUNICODE_P)
+    return WNetGetConnectionW ((LPCWSTR) lpLocalName, (LPWSTR) lpRemoteName, lpnLength);
+  else
+    return WNetGetConnectionA ((LPCSTR) lpLocalName, (LPSTR) lpRemoteName, lpnLength);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+DWORD 
+qxeWNetUseConnection (HWND hwndOwner, LPNETRESOURCEW lpNetResource, const Extbyte * lpUserID, const Extbyte * lpPassword, DWORD dwFlags, Extbyte * lpAccessName, LPDWORD lpBufferSize, LPDWORD lpResult)
+{
+  if (XEUNICODE_P)
+    return WNetUseConnectionW (hwndOwner, lpNetResource, (LPCWSTR) lpUserID, (LPCWSTR) lpPassword, dwFlags, (LPWSTR) lpAccessName, lpBufferSize, lpResult);
+  else
+    return WNetUseConnectionA (hwndOwner, (LPNETRESOURCEA) lpNetResource, (LPCSTR) lpUserID, (LPCSTR) lpPassword, dwFlags, (LPSTR) lpAccessName, lpBufferSize, lpResult);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+/* NOTE: contains split-simple LPNETRESOURCE */
+DWORD 
+qxeWNetConnectionDialog1 (LPCONNECTDLGSTRUCTW lpConnDlgStruct)
+{
+  if (XEUNICODE_P)
+    return WNetConnectionDialog1W (lpConnDlgStruct);
+  else
+    return WNetConnectionDialog1A ((LPCONNECTDLGSTRUCTA) lpConnDlgStruct);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+DWORD 
+qxeWNetDisconnectDialog1 (LPDISCDLGSTRUCTW lpConnDlgStruct)
+{
+  if (XEUNICODE_P)
+    return WNetDisconnectDialog1W (lpConnDlgStruct);
+  else
+    return WNetDisconnectDialog1A ((LPDISCDLGSTRUCTA) lpConnDlgStruct);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+DWORD 
+qxeWNetOpenEnum (DWORD dwScope, DWORD dwType, DWORD dwUsage, LPNETRESOURCEW lpNetResource, LPHANDLE lphEnum)
+{
+  if (XEUNICODE_P)
+    return WNetOpenEnumW (dwScope, dwType, dwUsage, lpNetResource, lphEnum);
+  else
+    return WNetOpenEnumA (dwScope, dwType, dwUsage, (LPNETRESOURCEA) lpNetResource, lphEnum);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+DWORD 
+qxeWNetEnumResource (HANDLE hEnum, LPDWORD lpcCount, LPVOID lpBuffer, LPDWORD lpBufferSize)
+{
+  if (XEUNICODE_P)
+    return WNetEnumResourceW (hEnum, lpcCount, lpBuffer, lpBufferSize);
+  else
+    return WNetEnumResourceA (hEnum, lpcCount, lpBuffer, lpBufferSize);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+DWORD 
+qxeWNetGetUniversalName (const Extbyte * lpLocalPath, DWORD dwInfoLevel, LPVOID lpBuffer, LPDWORD lpBufferSize)
+{
+  if (XEUNICODE_P)
+    return WNetGetUniversalNameW ((LPCWSTR) lpLocalPath, dwInfoLevel, lpBuffer, lpBufferSize);
+  else
+    return WNetGetUniversalNameA ((LPCSTR) lpLocalPath, dwInfoLevel, lpBuffer, lpBufferSize);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+DWORD 
+qxeWNetGetUser (const Extbyte * lpName, Extbyte * lpUserName, LPDWORD lpnLength)
+{
+  if (XEUNICODE_P)
+    return WNetGetUserW ((LPCWSTR) lpName, (LPWSTR) lpUserName, lpnLength);
+  else
+    return WNetGetUserA ((LPCSTR) lpName, (LPSTR) lpUserName, lpnLength);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+DWORD 
+qxeWNetGetProviderName (DWORD dwNetType, Extbyte * lpProviderName, LPDWORD lpBufferSize)
+{
+  if (XEUNICODE_P)
+    return WNetGetProviderNameW (dwNetType, (LPWSTR) lpProviderName, lpBufferSize);
+  else
+    return WNetGetProviderNameA (dwNetType, (LPSTR) lpProviderName, lpBufferSize);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+DWORD 
+qxeWNetGetNetworkInformation (const Extbyte * lpProvider, LPNETINFOSTRUCT lpNetInfoStruct)
+{
+  if (XEUNICODE_P)
+    return WNetGetNetworkInformationW ((LPCWSTR) lpProvider, lpNetInfoStruct);
+  else
+    return WNetGetNetworkInformationA ((LPCSTR) lpProvider, lpNetInfoStruct);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+DWORD 
+qxeWNetGetLastError (LPDWORD lpError, Extbyte * lpErrorBuf, DWORD nErrorBufSize, Extbyte * lpNameBuf, DWORD nNameBufSize)
+{
+  if (XEUNICODE_P)
+    return WNetGetLastErrorW (lpError, (LPWSTR) lpErrorBuf, nErrorBufSize, (LPWSTR) lpNameBuf, nNameBufSize);
+  else
+    return WNetGetLastErrorA (lpError, (LPSTR) lpErrorBuf, nErrorBufSize, (LPSTR) lpNameBuf, nNameBufSize);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+
+DWORD 
+qxeMultinetGetConnectionPerformance (LPNETRESOURCEW lpNetResource, LPNETCONNECTINFOSTRUCT lpNetConnectInfoStruct)
+{
+  if (XEUNICODE_P)
+    return MultinetGetConnectionPerformanceW (lpNetResource, lpNetConnectInfoStruct);
+  else
+    return MultinetGetConnectionPerformanceA ((LPNETRESOURCEA) lpNetResource, lpNetConnectInfoStruct);
+}
+
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+
+/*----------------------------------------------------------------------*/
 /*                       Processing file DDEML.H                        */
 /*----------------------------------------------------------------------*/
 
@@ -1883,297 +2266,6 @@
 
 
 /*----------------------------------------------------------------------*/
-/*                       Processing file WINREG.H                       */
-/*----------------------------------------------------------------------*/
-
-/* Skipping RegConnectRegistry because error in Cygwin prototype */
-
-LONG
-
-qxeRegCreateKey (HKEY hKey, const Extbyte * lpSubKey, PHKEY phkResult)
-{
-  if (XEUNICODE_P)
-    return RegCreateKeyW (hKey, (LPCWSTR) lpSubKey, phkResult);
-  else
-    return RegCreateKeyA (hKey, (LPCSTR) lpSubKey, phkResult);
-}
-
-LONG
-
-qxeRegCreateKeyEx (HKEY hKey, const Extbyte * lpSubKey, DWORD Reserved, Extbyte * lpClass, DWORD dwOptions, REGSAM samDesired, LPSECURITY_ATTRIBUTES lpSecurityAttributes, PHKEY phkResult, LPDWORD lpdwDisposition)
-{
-  if (XEUNICODE_P)
-    return RegCreateKeyExW (hKey, (LPCWSTR) lpSubKey, Reserved, (LPWSTR) lpClass, dwOptions, samDesired, lpSecurityAttributes, phkResult, lpdwDisposition);
-  else
-    return RegCreateKeyExA (hKey, (LPCSTR) lpSubKey, Reserved, (LPSTR) lpClass, dwOptions, samDesired, lpSecurityAttributes, phkResult, lpdwDisposition);
-}
-
-LONG
-
-qxeRegDeleteKey (HKEY hKey, const Extbyte * lpSubKey)
-{
-  if (XEUNICODE_P)
-    return RegDeleteKeyW (hKey, (LPCWSTR) lpSubKey);
-  else
-    return RegDeleteKeyA (hKey, (LPCSTR) lpSubKey);
-}
-
-LONG
-
-qxeRegDeleteValue (HKEY hKey, const Extbyte * lpValueName)
-{
-  if (XEUNICODE_P)
-    return RegDeleteValueW (hKey, (LPCWSTR) lpValueName);
-  else
-    return RegDeleteValueA (hKey, (LPCSTR) lpValueName);
-}
-
-LONG
-
-qxeRegEnumKey (HKEY hKey, DWORD dwIndex, Extbyte * lpName, DWORD cbName)
-{
-  if (XEUNICODE_P)
-    return RegEnumKeyW (hKey, dwIndex, (LPWSTR) lpName, cbName);
-  else
-    return RegEnumKeyA (hKey, dwIndex, (LPSTR) lpName, cbName);
-}
-
-LONG
-
-qxeRegEnumKeyEx (HKEY hKey, DWORD dwIndex, Extbyte * lpName, LPDWORD lpcbName, LPDWORD lpReserved, Extbyte * lpClass, LPDWORD lpcbClass, PFILETIME lpftLastWriteTime)
-{
-  if (XEUNICODE_P)
-    return RegEnumKeyExW (hKey, dwIndex, (LPWSTR) lpName, lpcbName, lpReserved, (LPWSTR) lpClass, lpcbClass, lpftLastWriteTime);
-  else
-    return RegEnumKeyExA (hKey, dwIndex, (LPSTR) lpName, lpcbName, lpReserved, (LPSTR) lpClass, lpcbClass, lpftLastWriteTime);
-}
-
-LONG
-
-qxeRegEnumValue (HKEY hKey, DWORD dwIndex, Extbyte * lpValueName, LPDWORD lpcbValueName, LPDWORD lpReserved, LPDWORD lpType, LPBYTE lpData, LPDWORD lpcbData)
-{
-  if (XEUNICODE_P)
-    return RegEnumValueW (hKey, dwIndex, (LPWSTR) lpValueName, lpcbValueName, lpReserved, lpType, lpData, lpcbData);
-  else
-    return RegEnumValueA (hKey, dwIndex, (LPSTR) lpValueName, lpcbValueName, lpReserved, lpType, lpData, lpcbData);
-}
-
-LONG
-
-qxeRegLoadKey (HKEY hKey, const Extbyte * lpSubKey, const Extbyte * lpFile)
-{
-  if (XEUNICODE_P)
-    return RegLoadKeyW (hKey, (LPCWSTR) lpSubKey, (LPCWSTR) lpFile);
-  else
-    return RegLoadKeyA (hKey, (LPCSTR) lpSubKey, (LPCSTR) lpFile);
-}
-
-LONG
-
-qxeRegOpenKey (HKEY hKey, const Extbyte * lpSubKey, PHKEY phkResult)
-{
-  if (XEUNICODE_P)
-    return RegOpenKeyW (hKey, (LPCWSTR) lpSubKey, phkResult);
-  else
-    return RegOpenKeyA (hKey, (LPCSTR) lpSubKey, phkResult);
-}
-
-LONG
-
-qxeRegOpenKeyEx (HKEY hKey, const Extbyte * lpSubKey, DWORD ulOptions, REGSAM samDesired, PHKEY phkResult)
-{
-  if (XEUNICODE_P)
-    return RegOpenKeyExW (hKey, (LPCWSTR) lpSubKey, ulOptions, samDesired, phkResult);
-  else
-    return RegOpenKeyExA (hKey, (LPCSTR) lpSubKey, ulOptions, samDesired, phkResult);
-}
-
-LONG
-
-qxeRegQueryInfoKey (HKEY hKey, Extbyte * lpClass, LPDWORD lpcbClass, LPDWORD lpReserved, LPDWORD lpcSubKeys, LPDWORD lpcbMaxSubKeyLen, LPDWORD lpcbMaxClassLen, LPDWORD lpcValues, LPDWORD lpcbMaxValueNameLen, LPDWORD lpcbMaxValueLen, LPDWORD lpcbSecurityDescriptor, PFILETIME lpftLastWriteTime)
-{
-  if (XEUNICODE_P)
-    return RegQueryInfoKeyW (hKey, (LPWSTR) lpClass, lpcbClass, lpReserved, lpcSubKeys, lpcbMaxSubKeyLen, lpcbMaxClassLen, lpcValues, lpcbMaxValueNameLen, lpcbMaxValueLen, lpcbSecurityDescriptor, lpftLastWriteTime);
-  else
-    return RegQueryInfoKeyA (hKey, (LPSTR) lpClass, lpcbClass, lpReserved, lpcSubKeys, lpcbMaxSubKeyLen, lpcbMaxClassLen, lpcValues, lpcbMaxValueNameLen, lpcbMaxValueLen, lpcbSecurityDescriptor, lpftLastWriteTime);
-}
-
-LONG
-
-qxeRegQueryValue (HKEY hKey, const Extbyte * lpSubKey, Extbyte * lpValue, PLONG lpcbValue)
-{
-  if (XEUNICODE_P)
-    return RegQueryValueW (hKey, (LPCWSTR) lpSubKey, (LPWSTR) lpValue, lpcbValue);
-  else
-    return RegQueryValueA (hKey, (LPCSTR) lpSubKey, (LPSTR) lpValue, lpcbValue);
-}
-
-LONG
-
-qxeRegQueryMultipleValues (HKEY hKey, PVALENTW val_list, DWORD num_vals, Extbyte * lpValueBuf, LPDWORD ldwTotsize)
-{
-  if (XEUNICODE_P)
-    return RegQueryMultipleValuesW (hKey, val_list, num_vals, (LPWSTR) lpValueBuf, ldwTotsize);
-  else
-    return RegQueryMultipleValuesA (hKey, (PVALENTA) val_list, num_vals, (LPSTR) lpValueBuf, ldwTotsize);
-}
-
-LONG
-
-qxeRegQueryValueEx (HKEY hKey, const Extbyte * lpValueName, LPDWORD lpReserved, LPDWORD lpType, LPBYTE lpData, LPDWORD lpcbData)
-{
-  if (XEUNICODE_P)
-    return RegQueryValueExW (hKey, (LPCWSTR) lpValueName, lpReserved, lpType, lpData, lpcbData);
-  else
-    return RegQueryValueExA (hKey, (LPCSTR) lpValueName, lpReserved, lpType, lpData, lpcbData);
-}
-
-LONG
-
-qxeRegReplaceKey (HKEY hKey, const Extbyte * lpSubKey, const Extbyte * lpNewFile, const Extbyte * lpOldFile)
-{
-  if (XEUNICODE_P)
-    return RegReplaceKeyW (hKey, (LPCWSTR) lpSubKey, (LPCWSTR) lpNewFile, (LPCWSTR) lpOldFile);
-  else
-    return RegReplaceKeyA (hKey, (LPCSTR) lpSubKey, (LPCSTR) lpNewFile, (LPCSTR) lpOldFile);
-}
-
-LONG
-
-qxeRegRestoreKey (HKEY hKey, const Extbyte * lpFile, DWORD dwFlags)
-{
-  if (XEUNICODE_P)
-    return RegRestoreKeyW (hKey, (LPCWSTR) lpFile, dwFlags);
-  else
-    return RegRestoreKeyA (hKey, (LPCSTR) lpFile, dwFlags);
-}
-
-LONG
-
-qxeRegSaveKey (HKEY hKey, const Extbyte * lpFile, LPSECURITY_ATTRIBUTES lpSecurityAttributes)
-{
-  if (XEUNICODE_P)
-    return RegSaveKeyW (hKey, (LPCWSTR) lpFile, lpSecurityAttributes);
-  else
-    return RegSaveKeyA (hKey, (LPCSTR) lpFile, lpSecurityAttributes);
-}
-
-LONG
-
-qxeRegSetValue (HKEY hKey, const Extbyte * lpSubKey, DWORD dwType, const Extbyte * lpData, DWORD cbData)
-{
-  if (XEUNICODE_P)
-    return RegSetValueW (hKey, (LPCWSTR) lpSubKey, dwType, (LPCWSTR) lpData, cbData);
-  else
-    return RegSetValueA (hKey, (LPCSTR) lpSubKey, dwType, (LPCSTR) lpData, cbData);
-}
-
-LONG
-
-qxeRegSetValueEx (HKEY hKey, const Extbyte * lpValueName, DWORD Reserved, DWORD dwType, CONST BYTE* lpData, DWORD cbData)
-{
-  if (XEUNICODE_P)
-    return RegSetValueExW (hKey, (LPCWSTR) lpValueName, Reserved, dwType, lpData, cbData);
-  else
-    return RegSetValueExA (hKey, (LPCSTR) lpValueName, Reserved, dwType, lpData, cbData);
-}
-
-LONG
-
-qxeRegUnLoadKey (HKEY hKey, const Extbyte * lpSubKey)
-{
-  if (XEUNICODE_P)
-    return RegUnLoadKeyW (hKey, (LPCWSTR) lpSubKey);
-  else
-    return RegUnLoadKeyA (hKey, (LPCSTR) lpSubKey);
-}
-
-BOOL
-
-qxeInitiateSystemShutdown (Extbyte * lpMachineName, Extbyte * lpMessage, DWORD dwTimeout, BOOL bForceAppsClosed, BOOL bRebootAfterShutdown)
-{
-  if (XEUNICODE_P)
-    return InitiateSystemShutdownW ((LPWSTR) lpMachineName, (LPWSTR) lpMessage, dwTimeout, bForceAppsClosed, bRebootAfterShutdown);
-  else
-    return InitiateSystemShutdownA ((LPSTR) lpMachineName, (LPSTR) lpMessage, dwTimeout, bForceAppsClosed, bRebootAfterShutdown);
-}
-
-BOOL
-
-qxeAbortSystemShutdown (Extbyte * lpMachineName)
-{
-  if (XEUNICODE_P)
-    return AbortSystemShutdownW ((LPWSTR) lpMachineName);
-  else
-    return AbortSystemShutdownA ((LPSTR) lpMachineName);
-}
-
-
-/*----------------------------------------------------------------------*/
-/*                       Processing file WINNLS.H                       */
-/*----------------------------------------------------------------------*/
-
-/* Error if GetCPInfoEx used: not used, not examined yet */
-
-/* Error if CompareString used: not used, not examined yet */
-
-/* Error if LCMapString used: not used, not examined yet */
-
-int
-qxeGetLocaleInfo (LCID Locale, LCTYPE LCType, Extbyte * lpLCData, int cchData)
-{
-  if (XEUNICODE_P)
-    return GetLocaleInfoW (Locale, LCType, (LPWSTR) lpLCData, cchData);
-  else
-    return GetLocaleInfoA (Locale, LCType, (LPSTR) lpLCData, cchData);
-}
-
-BOOL
-qxeSetLocaleInfo (LCID Locale, LCTYPE LCType, const Extbyte * lpLCData)
-{
-  if (XEUNICODE_P)
-    return SetLocaleInfoW (Locale, LCType, (LPCWSTR) lpLCData);
-  else
-    return SetLocaleInfoA (Locale, LCType, (LPCSTR) lpLCData);
-}
-
-/* Error if GetTimeFormat used: not used, not examined yet */
-
-/* Error if GetDateFormat used: not used, not examined yet */
-
-/* Error if GetNumberFormat used: not used, not examined yet */
-
-/* Error if GetCurrencyFormat used: not used, not examined yet */
-
-/* Error if EnumCalendarInfo used: not used, not examined yet */
-
-/* Error if EnumCalendarInfoEx used: not used, not examined yet */
-
-/* Error if EnumTimeFormats used: not used, not examined yet */
-
-/* Error if EnumDateFormats used: not used, not examined yet */
-
-/* Error if EnumDateFormatsEx used: not used, not examined yet */
-
-/* Error if GetStringTypeEx used: not used, not examined yet */
-
-/* Error if GetStringType used: no such fun; A and W versions have different nos. of args */
-
-/* Error if FoldString used: not used, not examined yet */
-
-/* Error if EnumSystemLocales used: not used, not examined yet */
-
-/* Error if EnumSystemCodePages used: not used, not examined yet */
-
-
-/*----------------------------------------------------------------------*/
-/*                        Processing file IME.H                         */
-/*----------------------------------------------------------------------*/
-
-/* Error if SendIMEMessageEx used: obsolete, no docs available */
-
-
-/*----------------------------------------------------------------------*/
 /*                       Processing file WINGDI.H                       */
 /*----------------------------------------------------------------------*/
 
@@ -2485,23 +2577,287 @@
 
 
 /*----------------------------------------------------------------------*/
-/*                       Processing file SHLOBJ.H                       */
+/*                       Processing file WINNLS.H                       */
 /*----------------------------------------------------------------------*/
 
+/* Error if GetCPInfoEx used: not used, not examined yet */
+
+/* Error if CompareString used: not used, not examined yet */
+
+/* Error if LCMapString used: not used, not examined yet */
+
+int
+qxeGetLocaleInfo (LCID Locale, LCTYPE LCType, Extbyte * lpLCData, int cchData)
+{
+  if (XEUNICODE_P)
+    return GetLocaleInfoW (Locale, LCType, (LPWSTR) lpLCData, cchData);
+  else
+    return GetLocaleInfoA (Locale, LCType, (LPSTR) lpLCData, cchData);
+}
+
 BOOL
-qxeSHGetPathFromIDList (LPCITEMIDLIST pidl, Extbyte * pszPath)
-{
-  if (XEUNICODE_P)
-    return SHGetPathFromIDListW (pidl, (LPWSTR) pszPath);
-  else
-    return SHGetPathFromIDListA (pidl, (LPSTR) pszPath);
-}
-
-/* Skipping SHGetSpecialFolderPath because error in Cygwin prototype, missing from Cygwin libraries */
-
-/* Skipping SHBrowseForFolder because need to intercept callback for SendMessage */
-
-/* Skipping SHGetDataFromIDList because split-sized WIN32_FIND_DATA or split-simple NETRESOURCE, missing from Cygwin libraries */
+qxeSetLocaleInfo (LCID Locale, LCTYPE LCType, const Extbyte * lpLCData)
+{
+  if (XEUNICODE_P)
+    return SetLocaleInfoW (Locale, LCType, (LPCWSTR) lpLCData);
+  else
+    return SetLocaleInfoA (Locale, LCType, (LPCSTR) lpLCData);
+}
+
+/* Error if GetTimeFormat used: not used, not examined yet */
+
+/* Error if GetDateFormat used: not used, not examined yet */
+
+/* Error if GetNumberFormat used: not used, not examined yet */
+
+/* Error if GetCurrencyFormat used: not used, not examined yet */
+
+/* Error if EnumCalendarInfo used: not used, not examined yet */
+
+/* Error if EnumCalendarInfoEx used: not used, not examined yet */
+
+/* Error if EnumTimeFormats used: not used, not examined yet */
+
+/* Error if EnumDateFormats used: not used, not examined yet */
+
+/* Error if EnumDateFormatsEx used: not used, not examined yet */
+
+/* Error if GetStringTypeEx used: not used, not examined yet */
+
+/* Error if GetStringType used: no such fun; A and W versions have different nos. of args */
+
+/* Error if FoldString used: not used, not examined yet */
+
+/* Error if EnumSystemLocales used: not used, not examined yet */
+
+/* Error if EnumSystemCodePages used: not used, not examined yet */
+
+
+/*----------------------------------------------------------------------*/
+/*                       Processing file WINREG.H                       */
+/*----------------------------------------------------------------------*/
+
+/* Skipping RegConnectRegistry because error in Cygwin prototype */
+
+LONG
+
+qxeRegCreateKey (HKEY hKey, const Extbyte * lpSubKey, PHKEY phkResult)
+{
+  if (XEUNICODE_P)
+    return RegCreateKeyW (hKey, (LPCWSTR) lpSubKey, phkResult);
+  else
+    return RegCreateKeyA (hKey, (LPCSTR) lpSubKey, phkResult);
+}
+
+LONG
+
+qxeRegCreateKeyEx (HKEY hKey, const Extbyte * lpSubKey, DWORD Reserved, Extbyte * lpClass, DWORD dwOptions, REGSAM samDesired, LPSECURITY_ATTRIBUTES lpSecurityAttributes, PHKEY phkResult, LPDWORD lpdwDisposition)
+{
+  if (XEUNICODE_P)
+    return RegCreateKeyExW (hKey, (LPCWSTR) lpSubKey, Reserved, (LPWSTR) lpClass, dwOptions, samDesired, lpSecurityAttributes, phkResult, lpdwDisposition);
+  else
+    return RegCreateKeyExA (hKey, (LPCSTR) lpSubKey, Reserved, (LPSTR) lpClass, dwOptions, samDesired, lpSecurityAttributes, phkResult, lpdwDisposition);
+}
+
+LONG
+
+qxeRegDeleteKey (HKEY hKey, const Extbyte * lpSubKey)
+{
+  if (XEUNICODE_P)
+    return RegDeleteKeyW (hKey, (LPCWSTR) lpSubKey);
+  else
+    return RegDeleteKeyA (hKey, (LPCSTR) lpSubKey);
+}
+
+LONG
+
+qxeRegDeleteValue (HKEY hKey, const Extbyte * lpValueName)
+{
+  if (XEUNICODE_P)
+    return RegDeleteValueW (hKey, (LPCWSTR) lpValueName);
+  else
+    return RegDeleteValueA (hKey, (LPCSTR) lpValueName);
+}
+
+LONG
+
+qxeRegEnumKey (HKEY hKey, DWORD dwIndex, Extbyte * lpName, DWORD cbName)
+{
+  if (XEUNICODE_P)
+    return RegEnumKeyW (hKey, dwIndex, (LPWSTR) lpName, cbName);
+  else
+    return RegEnumKeyA (hKey, dwIndex, (LPSTR) lpName, cbName);
+}
+
+LONG
+
+qxeRegEnumKeyEx (HKEY hKey, DWORD dwIndex, Extbyte * lpName, LPDWORD lpcbName, LPDWORD lpReserved, Extbyte * lpClass, LPDWORD lpcbClass, PFILETIME lpftLastWriteTime)
+{
+  if (XEUNICODE_P)
+    return RegEnumKeyExW (hKey, dwIndex, (LPWSTR) lpName, lpcbName, lpReserved, (LPWSTR) lpClass, lpcbClass, lpftLastWriteTime);
+  else
+    return RegEnumKeyExA (hKey, dwIndex, (LPSTR) lpName, lpcbName, lpReserved, (LPSTR) lpClass, lpcbClass, lpftLastWriteTime);
+}
+
+LONG
+
+qxeRegEnumValue (HKEY hKey, DWORD dwIndex, Extbyte * lpValueName, LPDWORD lpcbValueName, LPDWORD lpReserved, LPDWORD lpType, LPBYTE lpData, LPDWORD lpcbData)
+{
+  if (XEUNICODE_P)
+    return RegEnumValueW (hKey, dwIndex, (LPWSTR) lpValueName, lpcbValueName, lpReserved, lpType, lpData, lpcbData);
+  else
+    return RegEnumValueA (hKey, dwIndex, (LPSTR) lpValueName, lpcbValueName, lpReserved, lpType, lpData, lpcbData);
+}
+
+LONG
+
+qxeRegLoadKey (HKEY hKey, const Extbyte * lpSubKey, const Extbyte * lpFile)
+{
+  if (XEUNICODE_P)
+    return RegLoadKeyW (hKey, (LPCWSTR) lpSubKey, (LPCWSTR) lpFile);
+  else
+    return RegLoadKeyA (hKey, (LPCSTR) lpSubKey, (LPCSTR) lpFile);
+}
+
+LONG
+
+qxeRegOpenKey (HKEY hKey, const Extbyte * lpSubKey, PHKEY phkResult)
+{
+  if (XEUNICODE_P)
+    return RegOpenKeyW (hKey, (LPCWSTR) lpSubKey, phkResult);
+  else
+    return RegOpenKeyA (hKey, (LPCSTR) lpSubKey, phkResult);
+}
+
+LONG
+
+qxeRegOpenKeyEx (HKEY hKey, const Extbyte * lpSubKey, DWORD ulOptions, REGSAM samDesired, PHKEY phkResult)
+{
+  if (XEUNICODE_P)
+    return RegOpenKeyExW (hKey, (LPCWSTR) lpSubKey, ulOptions, samDesired, phkResult);
+  else
+    return RegOpenKeyExA (hKey, (LPCSTR) lpSubKey, ulOptions, samDesired, phkResult);
+}
+
+LONG
+
+qxeRegQueryInfoKey (HKEY hKey, Extbyte * lpClass, LPDWORD lpcbClass, LPDWORD lpReserved, LPDWORD lpcSubKeys, LPDWORD lpcbMaxSubKeyLen, LPDWORD lpcbMaxClassLen, LPDWORD lpcValues, LPDWORD lpcbMaxValueNameLen, LPDWORD lpcbMaxValueLen, LPDWORD lpcbSecurityDescriptor, PFILETIME lpftLastWriteTime)
+{
+  if (XEUNICODE_P)
+    return RegQueryInfoKeyW (hKey, (LPWSTR) lpClass, lpcbClass, lpReserved, lpcSubKeys, lpcbMaxSubKeyLen, lpcbMaxClassLen, lpcValues, lpcbMaxValueNameLen, lpcbMaxValueLen, lpcbSecurityDescriptor, lpftLastWriteTime);
+  else
+    return RegQueryInfoKeyA (hKey, (LPSTR) lpClass, lpcbClass, lpReserved, lpcSubKeys, lpcbMaxSubKeyLen, lpcbMaxClassLen, lpcValues, lpcbMaxValueNameLen, lpcbMaxValueLen, lpcbSecurityDescriptor, lpftLastWriteTime);
+}
+
+LONG
+
+qxeRegQueryValue (HKEY hKey, const Extbyte * lpSubKey, Extbyte * lpValue, PLONG lpcbValue)
+{
+  if (XEUNICODE_P)
+    return RegQueryValueW (hKey, (LPCWSTR) lpSubKey, (LPWSTR) lpValue, lpcbValue);
+  else
+    return RegQueryValueA (hKey, (LPCSTR) lpSubKey, (LPSTR) lpValue, lpcbValue);
+}
+
+LONG
+
+qxeRegQueryMultipleValues (HKEY hKey, PVALENTW val_list, DWORD num_vals, Extbyte * lpValueBuf, LPDWORD ldwTotsize)
+{
+  if (XEUNICODE_P)
+    return RegQueryMultipleValuesW (hKey, val_list, num_vals, (LPWSTR) lpValueBuf, ldwTotsize);
+  else
+    return RegQueryMultipleValuesA (hKey, (PVALENTA) val_list, num_vals, (LPSTR) lpValueBuf, ldwTotsize);
+}
+
+LONG
+
+qxeRegQueryValueEx (HKEY hKey, const Extbyte * lpValueName, LPDWORD lpReserved, LPDWORD lpType, LPBYTE lpData, LPDWORD lpcbData)
+{
+  if (XEUNICODE_P)
+    return RegQueryValueExW (hKey, (LPCWSTR) lpValueName, lpReserved, lpType, lpData, lpcbData);
+  else
+    return RegQueryValueExA (hKey, (LPCSTR) lpValueName, lpReserved, lpType, lpData, lpcbData);
+}
+
+LONG
+
+qxeRegReplaceKey (HKEY hKey, const Extbyte * lpSubKey, const Extbyte * lpNewFile, const Extbyte * lpOldFile)
+{
+  if (XEUNICODE_P)
+    return RegReplaceKeyW (hKey, (LPCWSTR) lpSubKey, (LPCWSTR) lpNewFile, (LPCWSTR) lpOldFile);
+  else
+    return RegReplaceKeyA (hKey, (LPCSTR) lpSubKey, (LPCSTR) lpNewFile, (LPCSTR) lpOldFile);
+}
+
+LONG
+
+qxeRegRestoreKey (HKEY hKey, const Extbyte * lpFile, DWORD dwFlags)
+{
+  if (XEUNICODE_P)
+    return RegRestoreKeyW (hKey, (LPCWSTR) lpFile, dwFlags);
+  else
+    return RegRestoreKeyA (hKey, (LPCSTR) lpFile, dwFlags);
+}
+
+LONG
+
+qxeRegSaveKey (HKEY hKey, const Extbyte * lpFile, LPSECURITY_ATTRIBUTES lpSecurityAttributes)
+{
+  if (XEUNICODE_P)
+    return RegSaveKeyW (hKey, (LPCWSTR) lpFile, lpSecurityAttributes);
+  else
+    return RegSaveKeyA (hKey, (LPCSTR) lpFile, lpSecurityAttributes);
+}
+
+LONG
+
+qxeRegSetValue (HKEY hKey, const Extbyte * lpSubKey, DWORD dwType, const Extbyte * lpData, DWORD cbData)
+{
+  if (XEUNICODE_P)
+    return RegSetValueW (hKey, (LPCWSTR) lpSubKey, dwType, (LPCWSTR) lpData, cbData);
+  else
+    return RegSetValueA (hKey, (LPCSTR) lpSubKey, dwType, (LPCSTR) lpData, cbData);
+}
+
+LONG
+
+qxeRegSetValueEx (HKEY hKey, const Extbyte * lpValueName, DWORD Reserved, DWORD dwType, CONST BYTE* lpData, DWORD cbData)
+{
+  if (XEUNICODE_P)
+    return RegSetValueExW (hKey, (LPCWSTR) lpValueName, Reserved, dwType, lpData, cbData);
+  else
+    return RegSetValueExA (hKey, (LPCSTR) lpValueName, Reserved, dwType, lpData, cbData);
+}
+
+LONG
+
+qxeRegUnLoadKey (HKEY hKey, const Extbyte * lpSubKey)
+{
+  if (XEUNICODE_P)
+    return RegUnLoadKeyW (hKey, (LPCWSTR) lpSubKey);
+  else
+    return RegUnLoadKeyA (hKey, (LPCSTR) lpSubKey);
+}
+
+BOOL
+
+qxeInitiateSystemShutdown (Extbyte * lpMachineName, Extbyte * lpMessage, DWORD dwTimeout, BOOL bForceAppsClosed, BOOL bRebootAfterShutdown)
+{
+  if (XEUNICODE_P)
+    return InitiateSystemShutdownW ((LPWSTR) lpMachineName, (LPWSTR) lpMessage, dwTimeout, bForceAppsClosed, bRebootAfterShutdown);
+  else
+    return InitiateSystemShutdownA ((LPSTR) lpMachineName, (LPSTR) lpMessage, dwTimeout, bForceAppsClosed, bRebootAfterShutdown);
+}
+
+BOOL
+
+qxeAbortSystemShutdown (Extbyte * lpMachineName)
+{
+  if (XEUNICODE_P)
+    return AbortSystemShutdownW ((LPWSTR) lpMachineName);
+  else
+    return AbortSystemShutdownA ((LPSTR) lpMachineName);
+}
 
 
 /*----------------------------------------------------------------------*/
@@ -2572,216 +2928,23 @@
 
 
 /*----------------------------------------------------------------------*/
-/*                        Processing file IMM.H                         */
+/*                       Processing file SHLOBJ.H                       */
 /*----------------------------------------------------------------------*/
 
-#if defined (HAVE_MS_WINDOWS)
-
-HKL
-qxeImmInstallIME (const Extbyte * lpszIMEFileName, const Extbyte * lpszLayoutText)
-{
-  if (XEUNICODE_P)
-    return ImmInstallIMEW ((LPCWSTR) lpszIMEFileName, (LPCWSTR) lpszLayoutText);
-  else
-    return ImmInstallIMEA ((LPCSTR) lpszIMEFileName, (LPCSTR) lpszLayoutText);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-UINT
-qxeImmGetDescription (HKL arg1, Extbyte * arg2, UINT uBufLen)
-{
-  if (XEUNICODE_P)
-    return ImmGetDescriptionW (arg1, (LPWSTR) arg2, uBufLen);
-  else
-    return ImmGetDescriptionA (arg1, (LPSTR) arg2, uBufLen);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-UINT
-qxeImmGetIMEFileName (HKL arg1, Extbyte * arg2, UINT uBufLen)
-{
-  if (XEUNICODE_P)
-    return ImmGetIMEFileNameW (arg1, (LPWSTR) arg2, uBufLen);
-  else
-    return ImmGetIMEFileNameA (arg1, (LPSTR) arg2, uBufLen);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-LONG
-qxeImmGetCompositionString (HIMC arg1, DWORD arg2, LPVOID arg3, DWORD arg4)
-{
-  if (XEUNICODE_P)
-    return ImmGetCompositionStringW (arg1, arg2, arg3, arg4);
-  else
-    return ImmGetCompositionStringA (arg1, arg2, arg3, arg4);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-DWORD
-qxeImmGetCandidateListCount (HIMC arg1, LPDWORD lpdwListCount)
-{
-  if (XEUNICODE_P)
-    return ImmGetCandidateListCountW (arg1, lpdwListCount);
-  else
-    return ImmGetCandidateListCountA (arg1, lpdwListCount);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-DWORD
-qxeImmGetCandidateList (HIMC arg1, DWORD deIndex, LPCANDIDATELIST arg3, DWORD dwBufLen)
-{
-  if (XEUNICODE_P)
-    return ImmGetCandidateListW (arg1, deIndex, arg3, dwBufLen);
-  else
-    return ImmGetCandidateListA (arg1, deIndex, arg3, dwBufLen);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-DWORD
-qxeImmGetGuideLine (HIMC arg1, DWORD dwIndex, Extbyte * arg3, DWORD dwBufLen)
-{
-  if (XEUNICODE_P)
-    return ImmGetGuideLineW (arg1, dwIndex, (LPWSTR) arg3, dwBufLen);
-  else
-    return ImmGetGuideLineA (arg1, dwIndex, (LPSTR) arg3, dwBufLen);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-/* Skipping ImmGetCompositionFont because split-sized LOGFONT */
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-/* Skipping ImmSetCompositionFont because split-sized LOGFONT */
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-/* NOTE: // split-simple REGISTERWORD */
-BOOL
-qxeImmConfigureIME (HKL arg1, HWND arg2, DWORD arg3, LPVOID arg4)
-{
-  if (XEUNICODE_P)
-    return ImmConfigureIMEW (arg1, arg2, arg3, arg4);
-  else
-    return ImmConfigureIMEA (arg1, arg2, arg3, arg4);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-/* NOTE: // strings of various sorts */
-LRESULT
-qxeImmEscape (HKL arg1, HIMC arg2, UINT arg3, LPVOID arg4)
-{
-  if (XEUNICODE_P)
-    return ImmEscapeW (arg1, arg2, arg3, arg4);
-  else
-    return ImmEscapeA (arg1, arg2, arg3, arg4);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-DWORD
-qxeImmGetConversionList (HKL arg1, HIMC arg2, const Extbyte * arg3, LPCANDIDATELIST arg4, DWORD dwBufLen, UINT uFlag)
-{
-  if (XEUNICODE_P)
-    return ImmGetConversionListW (arg1, arg2, (LPCWSTR) arg3, arg4, dwBufLen, uFlag);
-  else
-    return ImmGetConversionListA (arg1, arg2, (LPCSTR) arg3, arg4, dwBufLen, uFlag);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
 BOOL
-qxeImmIsUIMessage (HWND arg1, UINT arg2, WPARAM arg3, LPARAM arg4)
-{
-  if (XEUNICODE_P)
-    return ImmIsUIMessageW (arg1, arg2, arg3, arg4);
-  else
-    return ImmIsUIMessageA (arg1, arg2, arg3, arg4);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-BOOL
-qxeImmRegisterWord (HKL arg1, const Extbyte * lpszReading, DWORD arg3, const Extbyte * lpszRegister)
-{
-  if (XEUNICODE_P)
-    return ImmRegisterWordW (arg1, (LPCWSTR) lpszReading, arg3, (LPCWSTR) lpszRegister);
-  else
-    return ImmRegisterWordA (arg1, (LPCSTR) lpszReading, arg3, (LPCSTR) lpszRegister);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-BOOL
-qxeImmUnregisterWord (HKL arg1, const Extbyte * lpszReading, DWORD arg3, const Extbyte * lpszUnregister)
-{
-  if (XEUNICODE_P)
-    return ImmUnregisterWordW (arg1, (LPCWSTR) lpszReading, arg3, (LPCWSTR) lpszUnregister);
-  else
-    return ImmUnregisterWordA (arg1, (LPCSTR) lpszReading, arg3, (LPCSTR) lpszUnregister);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-/* Error if ImmGetRegisterWordStyle used: split-sized STYLEBUF */
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-UINT
-qxeImmEnumRegisterWord (HKL arg1, REGISTERWORDENUMPROCW arg2, const Extbyte * lpszReading, DWORD arg4, const Extbyte * lpszRegister, LPVOID arg6)
-{
-  if (XEUNICODE_P)
-    return ImmEnumRegisterWordW (arg1, arg2, (LPCWSTR) lpszReading, arg4, (LPCWSTR) lpszRegister, arg6);
-  else
-    return ImmEnumRegisterWordA (arg1, (REGISTERWORDENUMPROCA) arg2, (LPCSTR) lpszReading, arg4, (LPCSTR) lpszRegister, arg6);
-}
-
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-
-/* Error if ImmGetImeMenuItems used: split-sized IMEMENUITEMINFO */
-
-#endif /* defined (HAVE_MS_WINDOWS) */
+qxeSHGetPathFromIDList (LPCITEMIDLIST pidl, Extbyte * pszPath)
+{
+  if (XEUNICODE_P)
+    return SHGetPathFromIDListW (pidl, (LPWSTR) pszPath);
+  else
+    return SHGetPathFromIDListA (pidl, (LPSTR) pszPath);
+}
+
+/* Skipping SHGetSpecialFolderPath because error in Cygwin prototype, missing from Cygwin libraries */
+
+/* Skipping SHBrowseForFolder because need to intercept callback for SendMessage */
+
+/* Skipping SHGetDataFromIDList because split-sized WIN32_FIND_DATA or split-simple NETRESOURCE, missing from Cygwin libraries */
 
 
 /*----------------------------------------------------------------------*/
@@ -3132,6 +3295,12 @@
     return FindResourceExA (hModule, (LPCSTR) lpType, (LPCSTR) lpName, wLanguage);
 }
 
+/* Skipping EnumResourceTypes because different prototypes in VC6 and VC7 */
+
+/* Skipping EnumResourceNames because different prototypes in VC6 and VC7 */
+
+/* Skipping EnumResourceLanguages because different prototypes in VC6 and VC7 */
+
 HANDLE
 qxeBeginUpdateResource (const Extbyte * pFileName, BOOL bDeleteExistingResources)
 {
@@ -3933,158 +4102,15 @@
 
 
 /*----------------------------------------------------------------------*/
-/*                      Processing file MMSYSTEM.H                      */
+/*                       Processing file ACLAPI.h                       */
 /*----------------------------------------------------------------------*/
 
-BOOL
-qxesndPlaySound (const Extbyte * pszSound, UINT fuSound)
-{
-  if (XEUNICODE_P)
-    return sndPlaySoundW ((LPCWSTR) pszSound, fuSound);
-  else
-    return sndPlaySoundA ((LPCSTR) pszSound, fuSound);
-}
-
-BOOL
-qxePlaySound (const Extbyte * pszSound, HMODULE hmod, DWORD fdwSound)
-{
-  if (XEUNICODE_P)
-    return PlaySoundW ((LPCWSTR) pszSound, hmod, fdwSound);
-  else
-    return PlaySoundA ((LPCSTR) pszSound, hmod, fdwSound);
-}
-
-/* Error if waveOutGetDevCaps used: split-sized LPWAVEOUTCAPS */
-
-MMRESULT
-qxewaveOutGetErrorText (MMRESULT mmrError, Extbyte * pszText, UINT cchText)
-{
-  if (XEUNICODE_P)
-    return waveOutGetErrorTextW (mmrError, (LPWSTR) pszText, cchText);
-  else
-    return waveOutGetErrorTextA (mmrError, (LPSTR) pszText, cchText);
-}
-
-/* Error if waveInGetDevCaps used: split-sized LPWAVEINCAPS */
-
-MMRESULT
-qxewaveInGetErrorText (MMRESULT mmrError, Extbyte * pszText, UINT cchText)
-{
-  if (XEUNICODE_P)
-    return waveInGetErrorTextW (mmrError, (LPWSTR) pszText, cchText);
-  else
-    return waveInGetErrorTextA (mmrError, (LPSTR) pszText, cchText);
-}
-
-/* Error if midiOutGetDevCaps used: split-sized LPMIDIOUTCAPS */
-
-MMRESULT
-qxemidiOutGetErrorText (MMRESULT mmrError, Extbyte * pszText, UINT cchText)
-{
-  if (XEUNICODE_P)
-    return midiOutGetErrorTextW (mmrError, (LPWSTR) pszText, cchText);
-  else
-    return midiOutGetErrorTextA (mmrError, (LPSTR) pszText, cchText);
-}
-
-/* Error if midiInGetDevCaps used: split-sized LPMIDIOUTCAPS */
-
-MMRESULT
-qxemidiInGetErrorText (MMRESULT mmrError, Extbyte * pszText, UINT cchText)
-{
-  if (XEUNICODE_P)
-    return midiInGetErrorTextW (mmrError, (LPWSTR) pszText, cchText);
-  else
-    return midiInGetErrorTextA (mmrError, (LPSTR) pszText, cchText);
-}
-
-/* Error if auxGetDevCaps used: split-sized LPAUXCAPS */
-
-/* Error if mixerGetDevCaps used: split-sized LPMIXERCAPS */
-
-/* Error if mixerGetLineInfo used: split-sized LPMIXERLINE */
-
-/* Error if mixerGetLineControls used: split-sized LPMIXERCONTROL */
-
-/* Error if mixerGetControlDetails used: split-sized LPMIXERCONTROL in LPMIXERLINECONTROLS in LPMIXERCONTROLDETAILS */
-
-/* Error if joyGetDevCaps used: split-sized LPJOYCAPS */
-
-FOURCC
-qxemmioStringToFOURCC (const Extbyte * sz, UINT uFlags)
-{
-  if (XEUNICODE_P)
-    return mmioStringToFOURCCW ((LPCWSTR) sz, uFlags);
-  else
-    return mmioStringToFOURCCA ((LPCSTR) sz, uFlags);
-}
-
-LPMMIOPROC
-qxemmioInstallIOProc (FOURCC fccIOProc, LPMMIOPROC pIOProc, DWORD dwFlags)
-{
-  if (XEUNICODE_P)
-    return mmioInstallIOProcW (fccIOProc, pIOProc, dwFlags);
-  else
-    return mmioInstallIOProcA (fccIOProc, pIOProc, dwFlags);
-}
-
-HMMIO
-qxemmioOpen (Extbyte * pszFileName, LPMMIOINFO pmmioinfo, DWORD fdwOpen)
-{
-  if (XEUNICODE_P)
-    return mmioOpenW ((LPWSTR) pszFileName, pmmioinfo, fdwOpen);
-  else
-    return mmioOpenA ((LPSTR) pszFileName, pmmioinfo, fdwOpen);
-}
-
-MMRESULT
-qxemmioRename (const Extbyte * pszFileName, const Extbyte * pszNewFileName, LPCMMIOINFO pmmioinfo, DWORD fdwRename)
-{
-  if (XEUNICODE_P)
-    return mmioRenameW ((LPCWSTR) pszFileName, (LPCWSTR) pszNewFileName, pmmioinfo, fdwRename);
-  else
-    return mmioRenameA ((LPCSTR) pszFileName, (LPCSTR) pszNewFileName, pmmioinfo, fdwRename);
-}
-
-MCIERROR
-qxemciSendCommand (MCIDEVICEID mciId, UINT uMsg, DWORD dwParam1, DWORD dwParam2)
-{
-  if (XEUNICODE_P)
-    return mciSendCommandW (mciId, uMsg, dwParam1, dwParam2);
-  else
-    return mciSendCommandA (mciId, uMsg, dwParam1, dwParam2);
-}
-
-MCIERROR
-qxemciSendString (const Extbyte * lpstrCommand, Extbyte * lpstrReturnString, UINT uReturnLength, HWND hwndCallback)
-{
-  if (XEUNICODE_P)
-    return mciSendStringW ((LPCWSTR) lpstrCommand, (LPWSTR) lpstrReturnString, uReturnLength, hwndCallback);
-  else
-    return mciSendStringA ((LPCSTR) lpstrCommand, (LPSTR) lpstrReturnString, uReturnLength, hwndCallback);
-}
-
-MCIDEVICEID
-qxemciGetDeviceID (const Extbyte * pszDevice)
-{
-  if (XEUNICODE_P)
-    return mciGetDeviceIDW ((LPCWSTR) pszDevice);
-  else
-    return mciGetDeviceIDA ((LPCSTR) pszDevice);
-}
-
-#if !defined (MINGW)
-
-/* Error if mciGetDeviceIDFromElementID used: missing from Win98se version of ADVAPI32.dll */
-
-#endif /* !defined (MINGW) */
-
-BOOL
-qxemciGetErrorString (MCIERROR mcierr, Extbyte * pszText, UINT cchText)
-{
-  if (XEUNICODE_P)
-    return mciGetErrorStringW (mcierr, (LPWSTR) pszText, cchText);
-  else
-    return mciGetErrorStringA (mcierr, (LPSTR) pszText, cchText);
-}
-
+DWORD
+qxeGetNamedSecurityInfo (IN  Extbyte * pObjectName, IN  SE_OBJECT_TYPE ObjectType, IN  SECURITY_INFORMATION SecurityInfo, OUT PSID                 * ppsidOowner, OUT PSID                 * ppsidGroup, OUT PACL                 * ppDacl, OUT PACL                 * ppSacl, OUT PSECURITY_DESCRIPTOR * ppSecurityDescriptor)
+{
+  if (XEUNICODE_P)
+    return GetNamedSecurityInfoW ((IN  LPWSTR) pObjectName, ObjectType, SecurityInfo, ppsidOowner, ppsidGroup, ppDacl, ppSacl, ppSecurityDescriptor);
+  else
+    return GetNamedSecurityInfoA ((IN  LPSTR) pObjectName, ObjectType, SecurityInfo, ppsidOowner, ppsidGroup, ppDacl, ppSacl, ppSecurityDescriptor);
+}
+
--- a/src/intl-auto-encap-win32.h	Fri Dec 08 02:17:16 2006 +0000
+++ b/src/intl-auto-encap-win32.h	Fri Dec 08 02:22:02 2006 +0000
@@ -3,84 +3,6 @@
 */
 
 
-/* Processing file WINCON.H */
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef PeekConsoleInput
-#define PeekConsoleInput error_use_qxePeekConsoleInput_or_PeekConsoleInputA_and_PeekConsoleInputW
-#endif
-BOOL qxePeekConsoleInput (HANDLE hConsoleInput, PINPUT_RECORD lpBuffer, DWORD nLength, LPDWORD lpNumberOfEventsRead);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef ReadConsoleInput
-#define ReadConsoleInput error_use_qxeReadConsoleInput_or_ReadConsoleInputA_and_ReadConsoleInputW
-#endif
-BOOL qxeReadConsoleInput (HANDLE hConsoleInput, PINPUT_RECORD lpBuffer, DWORD nLength, LPDWORD lpNumberOfEventsRead);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef WriteConsoleInput
-#define WriteConsoleInput error_use_qxeWriteConsoleInput_or_WriteConsoleInputA_and_WriteConsoleInputW
-#endif
-BOOL qxeWriteConsoleInput (HANDLE hConsoleInput, CONST INPUT_RECORD * lpBuffer, DWORD nLength, LPDWORD lpNumberOfEventsWritten);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef ReadConsoleOutput
-#define ReadConsoleOutput error_use_qxeReadConsoleOutput_or_ReadConsoleOutputA_and_ReadConsoleOutputW
-#endif
-BOOL qxeReadConsoleOutput (HANDLE hConsoleOutput, PCHAR_INFO lpBuffer, COORD dwBufferSize, COORD dwBufferCoord, PSMALL_RECT lpReadRegion);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef WriteConsoleOutput
-#define WriteConsoleOutput error_use_qxeWriteConsoleOutput_or_WriteConsoleOutputA_and_WriteConsoleOutputW
-#endif
-BOOL qxeWriteConsoleOutput (HANDLE hConsoleOutput, CONST CHAR_INFO * lpBuffer, COORD dwBufferSize, COORD dwBufferCoord, PSMALL_RECT lpWriteRegion);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef ReadConsoleOutputCharacter
-#define ReadConsoleOutputCharacter error_use_qxeReadConsoleOutputCharacter_or_ReadConsoleOutputCharacterA_and_ReadConsoleOutputCharacterW
-#endif
-BOOL qxeReadConsoleOutputCharacter (HANDLE hConsoleOutput, Extbyte * lpCharacter, DWORD nLength, COORD dwReadCoord, LPDWORD lpNumberOfCharsRead);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef WriteConsoleOutputCharacter
-#define WriteConsoleOutputCharacter error_use_qxeWriteConsoleOutputCharacter_or_WriteConsoleOutputCharacterA_and_WriteConsoleOutputCharacterW
-#endif
-BOOL qxeWriteConsoleOutputCharacter (HANDLE hConsoleOutput, const Extbyte * lpCharacter, DWORD nLength, COORD dwWriteCoord, LPDWORD lpNumberOfCharsWritten);
-
-#undef FillConsoleOutputCharacter
-#define FillConsoleOutputCharacter error_split_CHAR
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef ScrollConsoleScreenBuffer
-#define ScrollConsoleScreenBuffer error_use_qxeScrollConsoleScreenBuffer_or_ScrollConsoleScreenBufferA_and_ScrollConsoleScreenBufferW
-#endif
-BOOL qxeScrollConsoleScreenBuffer (HANDLE hConsoleOutput, CONST SMALL_RECT * lpScrollRectangle, CONST SMALL_RECT * lpClipRectangle, COORD dwDestinationOrigin, CONST CHAR_INFO * lpFill);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef GetConsoleTitle
-#define GetConsoleTitle error_use_qxeGetConsoleTitle_or_GetConsoleTitleA_and_GetConsoleTitleW
-#endif
-DWORD qxeGetConsoleTitle (Extbyte * lpConsoleTitle, DWORD nSize);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef SetConsoleTitle
-#define SetConsoleTitle error_use_qxeSetConsoleTitle_or_SetConsoleTitleA_and_SetConsoleTitleW
-#endif
-BOOL qxeSetConsoleTitle (const Extbyte * lpConsoleTitle);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef ReadConsole
-#define ReadConsole error_use_qxeReadConsole_or_ReadConsoleA_and_ReadConsoleW
-#endif
-BOOL qxeReadConsole (HANDLE hConsoleInput, LPVOID lpBuffer, DWORD nNumberOfCharsToRead, LPDWORD lpNumberOfCharsRead, LPVOID lpReserved);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef WriteConsole
-#define WriteConsole error_use_qxeWriteConsole_or_WriteConsoleA_and_WriteConsoleW
-#endif
-BOOL qxeWriteConsole (HANDLE hConsoleOutput, CONST VOID * lpBuffer, DWORD nNumberOfCharsToWrite, LPDWORD lpNumberOfCharsWritten, LPVOID lpReserved);
-
-
 /* Processing file SHELLAPI.H */
 
 #ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
@@ -490,145 +412,6 @@
 #endif /* defined (HAVE_MS_WINDOWS) */
 
 
-/* Processing file WINNETWK.H */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef WNetAddConnection
-#define WNetAddConnection error_use_qxeWNetAddConnection_or_WNetAddConnectionA_and_WNetAddConnectionW
-#endif
-DWORD  qxeWNetAddConnection (const Extbyte * lpRemoteName, const Extbyte * lpPassword, const Extbyte * lpLocalName);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef WNetAddConnection2
-#define WNetAddConnection2 error_use_qxeWNetAddConnection2_or_WNetAddConnection2A_and_WNetAddConnection2W
-#endif
-DWORD  qxeWNetAddConnection2 (LPNETRESOURCEW lpNetResource, const Extbyte * lpPassword, const Extbyte * lpUserName, DWORD dwFlags);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef WNetAddConnection3
-#define WNetAddConnection3 error_use_qxeWNetAddConnection3_or_WNetAddConnection3A_and_WNetAddConnection3W
-#endif
-DWORD  qxeWNetAddConnection3 (HWND hwndOwner, LPNETRESOURCEW lpNetResource, const Extbyte * lpPassword, const Extbyte * lpUserName, DWORD dwFlags);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef WNetCancelConnection
-#define WNetCancelConnection error_use_qxeWNetCancelConnection_or_WNetCancelConnectionA_and_WNetCancelConnectionW
-#endif
-DWORD  qxeWNetCancelConnection (const Extbyte * lpName, BOOL fForce);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef WNetCancelConnection2
-#define WNetCancelConnection2 error_use_qxeWNetCancelConnection2_or_WNetCancelConnection2A_and_WNetCancelConnection2W
-#endif
-DWORD  qxeWNetCancelConnection2 (const Extbyte * lpName, DWORD dwFlags, BOOL fForce);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef WNetGetConnection
-#define WNetGetConnection error_use_qxeWNetGetConnection_or_WNetGetConnectionA_and_WNetGetConnectionW
-#endif
-DWORD  qxeWNetGetConnection (const Extbyte * lpLocalName, Extbyte * lpRemoteName, LPDWORD lpnLength);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef WNetUseConnection
-#define WNetUseConnection error_use_qxeWNetUseConnection_or_WNetUseConnectionA_and_WNetUseConnectionW
-#endif
-DWORD  qxeWNetUseConnection (HWND hwndOwner, LPNETRESOURCEW lpNetResource, const Extbyte * lpUserID, const Extbyte * lpPassword, DWORD dwFlags, Extbyte * lpAccessName, LPDWORD lpBufferSize, LPDWORD lpResult);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef WNetConnectionDialog1
-#define WNetConnectionDialog1 error_use_qxeWNetConnectionDialog1_or_WNetConnectionDialog1A_and_WNetConnectionDialog1W
-#endif
-DWORD  qxeWNetConnectionDialog1 (LPCONNECTDLGSTRUCTW lpConnDlgStruct);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef WNetDisconnectDialog1
-#define WNetDisconnectDialog1 error_use_qxeWNetDisconnectDialog1_or_WNetDisconnectDialog1A_and_WNetDisconnectDialog1W
-#endif
-DWORD  qxeWNetDisconnectDialog1 (LPDISCDLGSTRUCTW lpConnDlgStruct);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef WNetOpenEnum
-#define WNetOpenEnum error_use_qxeWNetOpenEnum_or_WNetOpenEnumA_and_WNetOpenEnumW
-#endif
-DWORD  qxeWNetOpenEnum (DWORD dwScope, DWORD dwType, DWORD dwUsage, LPNETRESOURCEW lpNetResource, LPHANDLE lphEnum);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef WNetEnumResource
-#define WNetEnumResource error_use_qxeWNetEnumResource_or_WNetEnumResourceA_and_WNetEnumResourceW
-#endif
-DWORD  qxeWNetEnumResource (HANDLE hEnum, LPDWORD lpcCount, LPVOID lpBuffer, LPDWORD lpBufferSize);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef WNetGetUniversalName
-#define WNetGetUniversalName error_use_qxeWNetGetUniversalName_or_WNetGetUniversalNameA_and_WNetGetUniversalNameW
-#endif
-DWORD  qxeWNetGetUniversalName (const Extbyte * lpLocalPath, DWORD dwInfoLevel, LPVOID lpBuffer, LPDWORD lpBufferSize);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef WNetGetUser
-#define WNetGetUser error_use_qxeWNetGetUser_or_WNetGetUserA_and_WNetGetUserW
-#endif
-DWORD  qxeWNetGetUser (const Extbyte * lpName, Extbyte * lpUserName, LPDWORD lpnLength);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef WNetGetProviderName
-#define WNetGetProviderName error_use_qxeWNetGetProviderName_or_WNetGetProviderNameA_and_WNetGetProviderNameW
-#endif
-DWORD  qxeWNetGetProviderName (DWORD dwNetType, Extbyte * lpProviderName, LPDWORD lpBufferSize);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef WNetGetNetworkInformation
-#define WNetGetNetworkInformation error_use_qxeWNetGetNetworkInformation_or_WNetGetNetworkInformationA_and_WNetGetNetworkInformationW
-#endif
-DWORD  qxeWNetGetNetworkInformation (const Extbyte * lpProvider, LPNETINFOSTRUCT lpNetInfoStruct);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef WNetGetLastError
-#define WNetGetLastError error_use_qxeWNetGetLastError_or_WNetGetLastErrorA_and_WNetGetLastErrorW
-#endif
-DWORD  qxeWNetGetLastError (LPDWORD lpError, Extbyte * lpErrorBuf, DWORD nErrorBufSize, Extbyte * lpNameBuf, DWORD nNameBufSize);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef MultinetGetConnectionPerformance
-#define MultinetGetConnectionPerformance error_use_qxeMultinetGetConnectionPerformance_or_MultinetGetConnectionPerformanceA_and_MultinetGetConnectionPerformanceW
-#endif
-DWORD  qxeMultinetGetConnectionPerformance (LPNETRESOURCEW lpNetResource, LPNETCONNECTINFOSTRUCT lpNetConnectInfoStruct);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-
 /* Processing file WINUSER.H */
 
 #ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
@@ -1306,6 +1089,488 @@
 #define GetAltTabInfo error_NT_5_0__only
 
 
+/* Processing file IME.H */
+
+#undef SendIMEMessageEx
+#define SendIMEMessageEx error_obsolete__no_docs_available
+
+
+/* Processing file IMM.H */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef ImmInstallIME
+#define ImmInstallIME error_use_qxeImmInstallIME_or_ImmInstallIMEA_and_ImmInstallIMEW
+#endif
+HKL qxeImmInstallIME (const Extbyte * lpszIMEFileName, const Extbyte * lpszLayoutText);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef ImmGetDescription
+#define ImmGetDescription error_use_qxeImmGetDescription_or_ImmGetDescriptionA_and_ImmGetDescriptionW
+#endif
+UINT qxeImmGetDescription (HKL arg1, Extbyte * arg2, UINT uBufLen);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef ImmGetIMEFileName
+#define ImmGetIMEFileName error_use_qxeImmGetIMEFileName_or_ImmGetIMEFileNameA_and_ImmGetIMEFileNameW
+#endif
+UINT qxeImmGetIMEFileName (HKL arg1, Extbyte * arg2, UINT uBufLen);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef ImmGetCompositionString
+#define ImmGetCompositionString error_use_qxeImmGetCompositionString_or_ImmGetCompositionStringA_and_ImmGetCompositionStringW
+#endif
+LONG qxeImmGetCompositionString (HIMC arg1, DWORD arg2, LPVOID arg3, DWORD arg4);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+/* Skipping ImmSetCompositionString because different prototypes in VC6 and VC7 */
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef ImmGetCandidateListCount
+#define ImmGetCandidateListCount error_use_qxeImmGetCandidateListCount_or_ImmGetCandidateListCountA_and_ImmGetCandidateListCountW
+#endif
+DWORD qxeImmGetCandidateListCount (HIMC arg1, LPDWORD lpdwListCount);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef ImmGetCandidateList
+#define ImmGetCandidateList error_use_qxeImmGetCandidateList_or_ImmGetCandidateListA_and_ImmGetCandidateListW
+#endif
+DWORD qxeImmGetCandidateList (HIMC arg1, DWORD deIndex, LPCANDIDATELIST arg3, DWORD dwBufLen);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef ImmGetGuideLine
+#define ImmGetGuideLine error_use_qxeImmGetGuideLine_or_ImmGetGuideLineA_and_ImmGetGuideLineW
+#endif
+DWORD qxeImmGetGuideLine (HIMC arg1, DWORD dwIndex, Extbyte * arg3, DWORD dwBufLen);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+/* Skipping ImmGetCompositionFont because split-sized LOGFONT */
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+/* Skipping ImmSetCompositionFont because split-sized LOGFONT */
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef ImmConfigureIME
+#define ImmConfigureIME error_use_qxeImmConfigureIME_or_ImmConfigureIMEA_and_ImmConfigureIMEW
+#endif
+BOOL qxeImmConfigureIME (HKL arg1, HWND arg2, DWORD arg3, LPVOID arg4);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef ImmEscape
+#define ImmEscape error_use_qxeImmEscape_or_ImmEscapeA_and_ImmEscapeW
+#endif
+LRESULT qxeImmEscape (HKL arg1, HIMC arg2, UINT arg3, LPVOID arg4);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef ImmGetConversionList
+#define ImmGetConversionList error_use_qxeImmGetConversionList_or_ImmGetConversionListA_and_ImmGetConversionListW
+#endif
+DWORD qxeImmGetConversionList (HKL arg1, HIMC arg2, const Extbyte * arg3, LPCANDIDATELIST arg4, DWORD dwBufLen, UINT uFlag);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef ImmIsUIMessage
+#define ImmIsUIMessage error_use_qxeImmIsUIMessage_or_ImmIsUIMessageA_and_ImmIsUIMessageW
+#endif
+BOOL qxeImmIsUIMessage (HWND arg1, UINT arg2, WPARAM arg3, LPARAM arg4);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef ImmRegisterWord
+#define ImmRegisterWord error_use_qxeImmRegisterWord_or_ImmRegisterWordA_and_ImmRegisterWordW
+#endif
+BOOL qxeImmRegisterWord (HKL arg1, const Extbyte * lpszReading, DWORD arg3, const Extbyte * lpszRegister);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef ImmUnregisterWord
+#define ImmUnregisterWord error_use_qxeImmUnregisterWord_or_ImmUnregisterWordA_and_ImmUnregisterWordW
+#endif
+BOOL qxeImmUnregisterWord (HKL arg1, const Extbyte * lpszReading, DWORD arg3, const Extbyte * lpszUnregister);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#undef ImmGetRegisterWordStyle
+#define ImmGetRegisterWordStyle error_split_sized_STYLEBUF
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef ImmEnumRegisterWord
+#define ImmEnumRegisterWord error_use_qxeImmEnumRegisterWord_or_ImmEnumRegisterWordA_and_ImmEnumRegisterWordW
+#endif
+UINT qxeImmEnumRegisterWord (HKL arg1, REGISTERWORDENUMPROCW arg2, const Extbyte * lpszReading, DWORD arg4, const Extbyte * lpszRegister, LPVOID arg6);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#undef ImmGetImeMenuItems
+#define ImmGetImeMenuItems error_split_sized_IMEMENUITEMINFO
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+
+/* Processing file MMSYSTEM.H */
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef sndPlaySound
+#define sndPlaySound error_use_qxesndPlaySound_or_sndPlaySoundA_and_sndPlaySoundW
+#endif
+BOOL qxesndPlaySound (const Extbyte * pszSound, UINT fuSound);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef PlaySound
+#define PlaySound error_use_qxePlaySound_or_PlaySoundA_and_PlaySoundW
+#endif
+BOOL qxePlaySound (const Extbyte * pszSound, HMODULE hmod, DWORD fdwSound);
+
+#undef waveOutGetDevCaps
+#define waveOutGetDevCaps error_split_sized_LPWAVEOUTCAPS
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef waveOutGetErrorText
+#define waveOutGetErrorText error_use_qxewaveOutGetErrorText_or_waveOutGetErrorTextA_and_waveOutGetErrorTextW
+#endif
+MMRESULT qxewaveOutGetErrorText (MMRESULT mmrError, Extbyte * pszText, UINT cchText);
+
+#undef waveInGetDevCaps
+#define waveInGetDevCaps error_split_sized_LPWAVEINCAPS
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef waveInGetErrorText
+#define waveInGetErrorText error_use_qxewaveInGetErrorText_or_waveInGetErrorTextA_and_waveInGetErrorTextW
+#endif
+MMRESULT qxewaveInGetErrorText (MMRESULT mmrError, Extbyte * pszText, UINT cchText);
+
+#undef midiOutGetDevCaps
+#define midiOutGetDevCaps error_split_sized_LPMIDIOUTCAPS
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef midiOutGetErrorText
+#define midiOutGetErrorText error_use_qxemidiOutGetErrorText_or_midiOutGetErrorTextA_and_midiOutGetErrorTextW
+#endif
+MMRESULT qxemidiOutGetErrorText (MMRESULT mmrError, Extbyte * pszText, UINT cchText);
+
+#undef midiInGetDevCaps
+#define midiInGetDevCaps error_split_sized_LPMIDIOUTCAPS
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef midiInGetErrorText
+#define midiInGetErrorText error_use_qxemidiInGetErrorText_or_midiInGetErrorTextA_and_midiInGetErrorTextW
+#endif
+MMRESULT qxemidiInGetErrorText (MMRESULT mmrError, Extbyte * pszText, UINT cchText);
+
+#undef auxGetDevCaps
+#define auxGetDevCaps error_split_sized_LPAUXCAPS
+
+#undef mixerGetDevCaps
+#define mixerGetDevCaps error_split_sized_LPMIXERCAPS
+
+#undef mixerGetLineInfo
+#define mixerGetLineInfo error_split_sized_LPMIXERLINE
+
+#undef mixerGetLineControls
+#define mixerGetLineControls error_split_sized_LPMIXERCONTROL
+
+#undef mixerGetControlDetails
+#define mixerGetControlDetails error_split_sized_LPMIXERCONTROL_in_LPMIXERLINECONTROLS_in_LPMIXERCONTROLDETAILS
+
+#undef joyGetDevCaps
+#define joyGetDevCaps error_split_sized_LPJOYCAPS
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef mmioStringToFOURCC
+#define mmioStringToFOURCC error_use_qxemmioStringToFOURCC_or_mmioStringToFOURCCA_and_mmioStringToFOURCCW
+#endif
+FOURCC qxemmioStringToFOURCC (const Extbyte * sz, UINT uFlags);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef mmioInstallIOProc
+#define mmioInstallIOProc error_use_qxemmioInstallIOProc_or_mmioInstallIOProcA_and_mmioInstallIOProcW
+#endif
+LPMMIOPROC qxemmioInstallIOProc (FOURCC fccIOProc, LPMMIOPROC pIOProc, DWORD dwFlags);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef mmioOpen
+#define mmioOpen error_use_qxemmioOpen_or_mmioOpenA_and_mmioOpenW
+#endif
+HMMIO qxemmioOpen (Extbyte * pszFileName, LPMMIOINFO pmmioinfo, DWORD fdwOpen);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef mmioRename
+#define mmioRename error_use_qxemmioRename_or_mmioRenameA_and_mmioRenameW
+#endif
+MMRESULT qxemmioRename (const Extbyte * pszFileName, const Extbyte * pszNewFileName, LPCMMIOINFO pmmioinfo, DWORD fdwRename);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef mciSendCommand
+#define mciSendCommand error_use_qxemciSendCommand_or_mciSendCommandA_and_mciSendCommandW
+#endif
+MCIERROR qxemciSendCommand (MCIDEVICEID mciId, UINT uMsg, DWORD dwParam1, DWORD dwParam2);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef mciSendString
+#define mciSendString error_use_qxemciSendString_or_mciSendStringA_and_mciSendStringW
+#endif
+MCIERROR qxemciSendString (const Extbyte * lpstrCommand, Extbyte * lpstrReturnString, UINT uReturnLength, HWND hwndCallback);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef mciGetDeviceID
+#define mciGetDeviceID error_use_qxemciGetDeviceID_or_mciGetDeviceIDA_and_mciGetDeviceIDW
+#endif
+MCIDEVICEID qxemciGetDeviceID (const Extbyte * pszDevice);
+
+#if !defined (MINGW)
+#undef mciGetDeviceIDFromElementID
+#define mciGetDeviceIDFromElementID error_missing_from_Win98se_version_of_ADVAPI32_dll
+#endif /* !defined (MINGW) */
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef mciGetErrorString
+#define mciGetErrorString error_use_qxemciGetErrorString_or_mciGetErrorStringA_and_mciGetErrorStringW
+#endif
+BOOL qxemciGetErrorString (MCIERROR mcierr, Extbyte * pszText, UINT cchText);
+
+
+/* Processing file WINCON.H */
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef PeekConsoleInput
+#define PeekConsoleInput error_use_qxePeekConsoleInput_or_PeekConsoleInputA_and_PeekConsoleInputW
+#endif
+BOOL qxePeekConsoleInput (HANDLE hConsoleInput, PINPUT_RECORD lpBuffer, DWORD nLength, LPDWORD lpNumberOfEventsRead);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef ReadConsoleInput
+#define ReadConsoleInput error_use_qxeReadConsoleInput_or_ReadConsoleInputA_and_ReadConsoleInputW
+#endif
+BOOL qxeReadConsoleInput (HANDLE hConsoleInput, PINPUT_RECORD lpBuffer, DWORD nLength, LPDWORD lpNumberOfEventsRead);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef WriteConsoleInput
+#define WriteConsoleInput error_use_qxeWriteConsoleInput_or_WriteConsoleInputA_and_WriteConsoleInputW
+#endif
+BOOL qxeWriteConsoleInput (HANDLE hConsoleInput, CONST INPUT_RECORD * lpBuffer, DWORD nLength, LPDWORD lpNumberOfEventsWritten);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef ReadConsoleOutput
+#define ReadConsoleOutput error_use_qxeReadConsoleOutput_or_ReadConsoleOutputA_and_ReadConsoleOutputW
+#endif
+BOOL qxeReadConsoleOutput (HANDLE hConsoleOutput, PCHAR_INFO lpBuffer, COORD dwBufferSize, COORD dwBufferCoord, PSMALL_RECT lpReadRegion);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef WriteConsoleOutput
+#define WriteConsoleOutput error_use_qxeWriteConsoleOutput_or_WriteConsoleOutputA_and_WriteConsoleOutputW
+#endif
+BOOL qxeWriteConsoleOutput (HANDLE hConsoleOutput, CONST CHAR_INFO * lpBuffer, COORD dwBufferSize, COORD dwBufferCoord, PSMALL_RECT lpWriteRegion);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef ReadConsoleOutputCharacter
+#define ReadConsoleOutputCharacter error_use_qxeReadConsoleOutputCharacter_or_ReadConsoleOutputCharacterA_and_ReadConsoleOutputCharacterW
+#endif
+BOOL qxeReadConsoleOutputCharacter (HANDLE hConsoleOutput, Extbyte * lpCharacter, DWORD nLength, COORD dwReadCoord, LPDWORD lpNumberOfCharsRead);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef WriteConsoleOutputCharacter
+#define WriteConsoleOutputCharacter error_use_qxeWriteConsoleOutputCharacter_or_WriteConsoleOutputCharacterA_and_WriteConsoleOutputCharacterW
+#endif
+BOOL qxeWriteConsoleOutputCharacter (HANDLE hConsoleOutput, const Extbyte * lpCharacter, DWORD nLength, COORD dwWriteCoord, LPDWORD lpNumberOfCharsWritten);
+
+#undef FillConsoleOutputCharacter
+#define FillConsoleOutputCharacter error_split_CHAR
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef ScrollConsoleScreenBuffer
+#define ScrollConsoleScreenBuffer error_use_qxeScrollConsoleScreenBuffer_or_ScrollConsoleScreenBufferA_and_ScrollConsoleScreenBufferW
+#endif
+BOOL qxeScrollConsoleScreenBuffer (HANDLE hConsoleOutput, CONST SMALL_RECT * lpScrollRectangle, CONST SMALL_RECT * lpClipRectangle, COORD dwDestinationOrigin, CONST CHAR_INFO * lpFill);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef GetConsoleTitle
+#define GetConsoleTitle error_use_qxeGetConsoleTitle_or_GetConsoleTitleA_and_GetConsoleTitleW
+#endif
+DWORD qxeGetConsoleTitle (Extbyte * lpConsoleTitle, DWORD nSize);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef SetConsoleTitle
+#define SetConsoleTitle error_use_qxeSetConsoleTitle_or_SetConsoleTitleA_and_SetConsoleTitleW
+#endif
+BOOL qxeSetConsoleTitle (const Extbyte * lpConsoleTitle);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef ReadConsole
+#define ReadConsole error_use_qxeReadConsole_or_ReadConsoleA_and_ReadConsoleW
+#endif
+BOOL qxeReadConsole (HANDLE hConsoleInput, LPVOID lpBuffer, DWORD nNumberOfCharsToRead, LPDWORD lpNumberOfCharsRead, LPVOID lpReserved);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef WriteConsole
+#define WriteConsole error_use_qxeWriteConsole_or_WriteConsoleA_and_WriteConsoleW
+#endif
+BOOL qxeWriteConsole (HANDLE hConsoleOutput, CONST VOID * lpBuffer, DWORD nNumberOfCharsToWrite, LPDWORD lpNumberOfCharsWritten, LPVOID lpReserved);
+
+
+/* Processing file WINNETWK.H */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef WNetAddConnection
+#define WNetAddConnection error_use_qxeWNetAddConnection_or_WNetAddConnectionA_and_WNetAddConnectionW
+#endif
+DWORD  qxeWNetAddConnection (const Extbyte * lpRemoteName, const Extbyte * lpPassword, const Extbyte * lpLocalName);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef WNetAddConnection2
+#define WNetAddConnection2 error_use_qxeWNetAddConnection2_or_WNetAddConnection2A_and_WNetAddConnection2W
+#endif
+DWORD  qxeWNetAddConnection2 (LPNETRESOURCEW lpNetResource, const Extbyte * lpPassword, const Extbyte * lpUserName, DWORD dwFlags);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef WNetAddConnection3
+#define WNetAddConnection3 error_use_qxeWNetAddConnection3_or_WNetAddConnection3A_and_WNetAddConnection3W
+#endif
+DWORD  qxeWNetAddConnection3 (HWND hwndOwner, LPNETRESOURCEW lpNetResource, const Extbyte * lpPassword, const Extbyte * lpUserName, DWORD dwFlags);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef WNetCancelConnection
+#define WNetCancelConnection error_use_qxeWNetCancelConnection_or_WNetCancelConnectionA_and_WNetCancelConnectionW
+#endif
+DWORD  qxeWNetCancelConnection (const Extbyte * lpName, BOOL fForce);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef WNetCancelConnection2
+#define WNetCancelConnection2 error_use_qxeWNetCancelConnection2_or_WNetCancelConnection2A_and_WNetCancelConnection2W
+#endif
+DWORD  qxeWNetCancelConnection2 (const Extbyte * lpName, DWORD dwFlags, BOOL fForce);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef WNetGetConnection
+#define WNetGetConnection error_use_qxeWNetGetConnection_or_WNetGetConnectionA_and_WNetGetConnectionW
+#endif
+DWORD  qxeWNetGetConnection (const Extbyte * lpLocalName, Extbyte * lpRemoteName, LPDWORD lpnLength);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef WNetUseConnection
+#define WNetUseConnection error_use_qxeWNetUseConnection_or_WNetUseConnectionA_and_WNetUseConnectionW
+#endif
+DWORD  qxeWNetUseConnection (HWND hwndOwner, LPNETRESOURCEW lpNetResource, const Extbyte * lpUserID, const Extbyte * lpPassword, DWORD dwFlags, Extbyte * lpAccessName, LPDWORD lpBufferSize, LPDWORD lpResult);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef WNetConnectionDialog1
+#define WNetConnectionDialog1 error_use_qxeWNetConnectionDialog1_or_WNetConnectionDialog1A_and_WNetConnectionDialog1W
+#endif
+DWORD  qxeWNetConnectionDialog1 (LPCONNECTDLGSTRUCTW lpConnDlgStruct);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef WNetDisconnectDialog1
+#define WNetDisconnectDialog1 error_use_qxeWNetDisconnectDialog1_or_WNetDisconnectDialog1A_and_WNetDisconnectDialog1W
+#endif
+DWORD  qxeWNetDisconnectDialog1 (LPDISCDLGSTRUCTW lpConnDlgStruct);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef WNetOpenEnum
+#define WNetOpenEnum error_use_qxeWNetOpenEnum_or_WNetOpenEnumA_and_WNetOpenEnumW
+#endif
+DWORD  qxeWNetOpenEnum (DWORD dwScope, DWORD dwType, DWORD dwUsage, LPNETRESOURCEW lpNetResource, LPHANDLE lphEnum);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef WNetEnumResource
+#define WNetEnumResource error_use_qxeWNetEnumResource_or_WNetEnumResourceA_and_WNetEnumResourceW
+#endif
+DWORD  qxeWNetEnumResource (HANDLE hEnum, LPDWORD lpcCount, LPVOID lpBuffer, LPDWORD lpBufferSize);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef WNetGetUniversalName
+#define WNetGetUniversalName error_use_qxeWNetGetUniversalName_or_WNetGetUniversalNameA_and_WNetGetUniversalNameW
+#endif
+DWORD  qxeWNetGetUniversalName (const Extbyte * lpLocalPath, DWORD dwInfoLevel, LPVOID lpBuffer, LPDWORD lpBufferSize);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef WNetGetUser
+#define WNetGetUser error_use_qxeWNetGetUser_or_WNetGetUserA_and_WNetGetUserW
+#endif
+DWORD  qxeWNetGetUser (const Extbyte * lpName, Extbyte * lpUserName, LPDWORD lpnLength);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef WNetGetProviderName
+#define WNetGetProviderName error_use_qxeWNetGetProviderName_or_WNetGetProviderNameA_and_WNetGetProviderNameW
+#endif
+DWORD  qxeWNetGetProviderName (DWORD dwNetType, Extbyte * lpProviderName, LPDWORD lpBufferSize);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef WNetGetNetworkInformation
+#define WNetGetNetworkInformation error_use_qxeWNetGetNetworkInformation_or_WNetGetNetworkInformationA_and_WNetGetNetworkInformationW
+#endif
+DWORD  qxeWNetGetNetworkInformation (const Extbyte * lpProvider, LPNETINFOSTRUCT lpNetInfoStruct);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef WNetGetLastError
+#define WNetGetLastError error_use_qxeWNetGetLastError_or_WNetGetLastErrorA_and_WNetGetLastErrorW
+#endif
+DWORD  qxeWNetGetLastError (LPDWORD lpError, Extbyte * lpErrorBuf, DWORD nErrorBufSize, Extbyte * lpNameBuf, DWORD nNameBufSize);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+#if defined (HAVE_MS_WINDOWS)
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef MultinetGetConnectionPerformance
+#define MultinetGetConnectionPerformance error_use_qxeMultinetGetConnectionPerformance_or_MultinetGetConnectionPerformanceA_and_MultinetGetConnectionPerformanceW
+#endif
+DWORD  qxeMultinetGetConnectionPerformance (LPNETRESOURCEW lpNetResource, LPNETCONNECTINFOSTRUCT lpNetConnectInfoStruct);
+#endif /* defined (HAVE_MS_WINDOWS) */
+
+
 /* Processing file DDEML.H */
 
 #ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
@@ -1323,237 +1588,6 @@
 DWORD qxeDdeQueryString (DWORD idInst, HSZ hsz, Extbyte * psz, DWORD cchMax, int iCodePage);
 
 
-/* Processing file WINREG.H */
-
-/* Skipping RegConnectRegistry because error in Cygwin prototype */
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef RegCreateKey
-#define RegCreateKey error_use_qxeRegCreateKey_or_RegCreateKeyA_and_RegCreateKeyW
-#endif
-LONG
- qxeRegCreateKey (HKEY hKey, const Extbyte * lpSubKey, PHKEY phkResult);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef RegCreateKeyEx
-#define RegCreateKeyEx error_use_qxeRegCreateKeyEx_or_RegCreateKeyExA_and_RegCreateKeyExW
-#endif
-LONG
- qxeRegCreateKeyEx (HKEY hKey, const Extbyte * lpSubKey, DWORD Reserved, Extbyte * lpClass, DWORD dwOptions, REGSAM samDesired, LPSECURITY_ATTRIBUTES lpSecurityAttributes, PHKEY phkResult, LPDWORD lpdwDisposition);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef RegDeleteKey
-#define RegDeleteKey error_use_qxeRegDeleteKey_or_RegDeleteKeyA_and_RegDeleteKeyW
-#endif
-LONG
- qxeRegDeleteKey (HKEY hKey, const Extbyte * lpSubKey);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef RegDeleteValue
-#define RegDeleteValue error_use_qxeRegDeleteValue_or_RegDeleteValueA_and_RegDeleteValueW
-#endif
-LONG
- qxeRegDeleteValue (HKEY hKey, const Extbyte * lpValueName);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef RegEnumKey
-#define RegEnumKey error_use_qxeRegEnumKey_or_RegEnumKeyA_and_RegEnumKeyW
-#endif
-LONG
- qxeRegEnumKey (HKEY hKey, DWORD dwIndex, Extbyte * lpName, DWORD cbName);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef RegEnumKeyEx
-#define RegEnumKeyEx error_use_qxeRegEnumKeyEx_or_RegEnumKeyExA_and_RegEnumKeyExW
-#endif
-LONG
- qxeRegEnumKeyEx (HKEY hKey, DWORD dwIndex, Extbyte * lpName, LPDWORD lpcbName, LPDWORD lpReserved, Extbyte * lpClass, LPDWORD lpcbClass, PFILETIME lpftLastWriteTime);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef RegEnumValue
-#define RegEnumValue error_use_qxeRegEnumValue_or_RegEnumValueA_and_RegEnumValueW
-#endif
-LONG
- qxeRegEnumValue (HKEY hKey, DWORD dwIndex, Extbyte * lpValueName, LPDWORD lpcbValueName, LPDWORD lpReserved, LPDWORD lpType, LPBYTE lpData, LPDWORD lpcbData);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef RegLoadKey
-#define RegLoadKey error_use_qxeRegLoadKey_or_RegLoadKeyA_and_RegLoadKeyW
-#endif
-LONG
- qxeRegLoadKey (HKEY hKey, const Extbyte * lpSubKey, const Extbyte * lpFile);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef RegOpenKey
-#define RegOpenKey error_use_qxeRegOpenKey_or_RegOpenKeyA_and_RegOpenKeyW
-#endif
-LONG
- qxeRegOpenKey (HKEY hKey, const Extbyte * lpSubKey, PHKEY phkResult);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef RegOpenKeyEx
-#define RegOpenKeyEx error_use_qxeRegOpenKeyEx_or_RegOpenKeyExA_and_RegOpenKeyExW
-#endif
-LONG
- qxeRegOpenKeyEx (HKEY hKey, const Extbyte * lpSubKey, DWORD ulOptions, REGSAM samDesired, PHKEY phkResult);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef RegQueryInfoKey
-#define RegQueryInfoKey error_use_qxeRegQueryInfoKey_or_RegQueryInfoKeyA_and_RegQueryInfoKeyW
-#endif
-LONG
- qxeRegQueryInfoKey (HKEY hKey, Extbyte * lpClass, LPDWORD lpcbClass, LPDWORD lpReserved, LPDWORD lpcSubKeys, LPDWORD lpcbMaxSubKeyLen, LPDWORD lpcbMaxClassLen, LPDWORD lpcValues, LPDWORD lpcbMaxValueNameLen, LPDWORD lpcbMaxValueLen, LPDWORD lpcbSecurityDescriptor, PFILETIME lpftLastWriteTime);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef RegQueryValue
-#define RegQueryValue error_use_qxeRegQueryValue_or_RegQueryValueA_and_RegQueryValueW
-#endif
-LONG
- qxeRegQueryValue (HKEY hKey, const Extbyte * lpSubKey, Extbyte * lpValue, PLONG lpcbValue);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef RegQueryMultipleValues
-#define RegQueryMultipleValues error_use_qxeRegQueryMultipleValues_or_RegQueryMultipleValuesA_and_RegQueryMultipleValuesW
-#endif
-LONG
- qxeRegQueryMultipleValues (HKEY hKey, PVALENTW val_list, DWORD num_vals, Extbyte * lpValueBuf, LPDWORD ldwTotsize);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef RegQueryValueEx
-#define RegQueryValueEx error_use_qxeRegQueryValueEx_or_RegQueryValueExA_and_RegQueryValueExW
-#endif
-LONG
- qxeRegQueryValueEx (HKEY hKey, const Extbyte * lpValueName, LPDWORD lpReserved, LPDWORD lpType, LPBYTE lpData, LPDWORD lpcbData);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef RegReplaceKey
-#define RegReplaceKey error_use_qxeRegReplaceKey_or_RegReplaceKeyA_and_RegReplaceKeyW
-#endif
-LONG
- qxeRegReplaceKey (HKEY hKey, const Extbyte * lpSubKey, const Extbyte * lpNewFile, const Extbyte * lpOldFile);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef RegRestoreKey
-#define RegRestoreKey error_use_qxeRegRestoreKey_or_RegRestoreKeyA_and_RegRestoreKeyW
-#endif
-LONG
- qxeRegRestoreKey (HKEY hKey, const Extbyte * lpFile, DWORD dwFlags);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef RegSaveKey
-#define RegSaveKey error_use_qxeRegSaveKey_or_RegSaveKeyA_and_RegSaveKeyW
-#endif
-LONG
- qxeRegSaveKey (HKEY hKey, const Extbyte * lpFile, LPSECURITY_ATTRIBUTES lpSecurityAttributes);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef RegSetValue
-#define RegSetValue error_use_qxeRegSetValue_or_RegSetValueA_and_RegSetValueW
-#endif
-LONG
- qxeRegSetValue (HKEY hKey, const Extbyte * lpSubKey, DWORD dwType, const Extbyte * lpData, DWORD cbData);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef RegSetValueEx
-#define RegSetValueEx error_use_qxeRegSetValueEx_or_RegSetValueExA_and_RegSetValueExW
-#endif
-LONG
- qxeRegSetValueEx (HKEY hKey, const Extbyte * lpValueName, DWORD Reserved, DWORD dwType, CONST BYTE* lpData, DWORD cbData);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef RegUnLoadKey
-#define RegUnLoadKey error_use_qxeRegUnLoadKey_or_RegUnLoadKeyA_and_RegUnLoadKeyW
-#endif
-LONG
- qxeRegUnLoadKey (HKEY hKey, const Extbyte * lpSubKey);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef InitiateSystemShutdown
-#define InitiateSystemShutdown error_use_qxeInitiateSystemShutdown_or_InitiateSystemShutdownA_and_InitiateSystemShutdownW
-#endif
-BOOL
- qxeInitiateSystemShutdown (Extbyte * lpMachineName, Extbyte * lpMessage, DWORD dwTimeout, BOOL bForceAppsClosed, BOOL bRebootAfterShutdown);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef AbortSystemShutdown
-#define AbortSystemShutdown error_use_qxeAbortSystemShutdown_or_AbortSystemShutdownA_and_AbortSystemShutdownW
-#endif
-BOOL
- qxeAbortSystemShutdown (Extbyte * lpMachineName);
-
-
-/* Processing file WINNLS.H */
-
-#undef GetCPInfoEx
-#define GetCPInfoEx error_not_used__not_examined_yet
-
-#undef CompareString
-#define CompareString error_not_used__not_examined_yet
-
-#undef LCMapString
-#define LCMapString error_not_used__not_examined_yet
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef GetLocaleInfo
-#define GetLocaleInfo error_use_qxeGetLocaleInfo_or_GetLocaleInfoA_and_GetLocaleInfoW
-#endif
-int qxeGetLocaleInfo (LCID Locale, LCTYPE LCType, Extbyte * lpLCData, int cchData);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef SetLocaleInfo
-#define SetLocaleInfo error_use_qxeSetLocaleInfo_or_SetLocaleInfoA_and_SetLocaleInfoW
-#endif
-BOOL qxeSetLocaleInfo (LCID Locale, LCTYPE LCType, const Extbyte * lpLCData);
-
-#undef GetTimeFormat
-#define GetTimeFormat error_not_used__not_examined_yet
-
-#undef GetDateFormat
-#define GetDateFormat error_not_used__not_examined_yet
-
-#undef GetNumberFormat
-#define GetNumberFormat error_not_used__not_examined_yet
-
-#undef GetCurrencyFormat
-#define GetCurrencyFormat error_not_used__not_examined_yet
-
-#undef EnumCalendarInfo
-#define EnumCalendarInfo error_not_used__not_examined_yet
-
-#undef EnumCalendarInfoEx
-#define EnumCalendarInfoEx error_not_used__not_examined_yet
-
-#undef EnumTimeFormats
-#define EnumTimeFormats error_not_used__not_examined_yet
-
-#undef EnumDateFormats
-#define EnumDateFormats error_not_used__not_examined_yet
-
-#undef EnumDateFormatsEx
-#define EnumDateFormatsEx error_not_used__not_examined_yet
-
-#undef GetStringTypeEx
-#define GetStringTypeEx error_not_used__not_examined_yet
-
-#undef GetStringType
-#define GetStringType error_no_such_fun__A_and_W_versions_have_different_nos__of_args
-
-#undef FoldString
-#define FoldString error_not_used__not_examined_yet
-
-#undef EnumSystemLocales
-#define EnumSystemLocales error_not_used__not_examined_yet
-
-#undef EnumSystemCodePages
-#define EnumSystemCodePages error_not_used__not_examined_yet
-
-
-/* Processing file IME.H */
-
-#undef SendIMEMessageEx
-#define SendIMEMessageEx error_obsolete__no_docs_available
-
-
 /* Processing file WINGDI.H */
 
 #ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
@@ -1784,19 +1818,229 @@
 #define wglUseFontOutlines error_causes_link_error
 
 
-/* Processing file SHLOBJ.H */
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef SHGetPathFromIDList
-#define SHGetPathFromIDList error_use_qxeSHGetPathFromIDList_or_SHGetPathFromIDListA_and_SHGetPathFromIDListW
-#endif
-BOOL qxeSHGetPathFromIDList (LPCITEMIDLIST pidl, Extbyte * pszPath);
-
-/* Skipping SHGetSpecialFolderPath because error in Cygwin prototype, missing from Cygwin libraries */
-
-/* Skipping SHBrowseForFolder because need to intercept callback for SendMessage */
-
-/* Skipping SHGetDataFromIDList because split-sized WIN32_FIND_DATA or split-simple NETRESOURCE, missing from Cygwin libraries */
+/* Processing file WINNLS.H */
+
+#undef GetCPInfoEx
+#define GetCPInfoEx error_not_used__not_examined_yet
+
+#undef CompareString
+#define CompareString error_not_used__not_examined_yet
+
+#undef LCMapString
+#define LCMapString error_not_used__not_examined_yet
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef GetLocaleInfo
+#define GetLocaleInfo error_use_qxeGetLocaleInfo_or_GetLocaleInfoA_and_GetLocaleInfoW
+#endif
+int qxeGetLocaleInfo (LCID Locale, LCTYPE LCType, Extbyte * lpLCData, int cchData);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef SetLocaleInfo
+#define SetLocaleInfo error_use_qxeSetLocaleInfo_or_SetLocaleInfoA_and_SetLocaleInfoW
+#endif
+BOOL qxeSetLocaleInfo (LCID Locale, LCTYPE LCType, const Extbyte * lpLCData);
+
+#undef GetTimeFormat
+#define GetTimeFormat error_not_used__not_examined_yet
+
+#undef GetDateFormat
+#define GetDateFormat error_not_used__not_examined_yet
+
+#undef GetNumberFormat
+#define GetNumberFormat error_not_used__not_examined_yet
+
+#undef GetCurrencyFormat
+#define GetCurrencyFormat error_not_used__not_examined_yet
+
+#undef EnumCalendarInfo
+#define EnumCalendarInfo error_not_used__not_examined_yet
+
+#undef EnumCalendarInfoEx
+#define EnumCalendarInfoEx error_not_used__not_examined_yet
+
+#undef EnumTimeFormats
+#define EnumTimeFormats error_not_used__not_examined_yet
+
+#undef EnumDateFormats
+#define EnumDateFormats error_not_used__not_examined_yet
+
+#undef EnumDateFormatsEx
+#define EnumDateFormatsEx error_not_used__not_examined_yet
+
+#undef GetStringTypeEx
+#define GetStringTypeEx error_not_used__not_examined_yet
+
+#undef GetStringType
+#define GetStringType error_no_such_fun__A_and_W_versions_have_different_nos__of_args
+
+#undef FoldString
+#define FoldString error_not_used__not_examined_yet
+
+#undef EnumSystemLocales
+#define EnumSystemLocales error_not_used__not_examined_yet
+
+#undef EnumSystemCodePages
+#define EnumSystemCodePages error_not_used__not_examined_yet
+
+
+/* Processing file WINREG.H */
+
+/* Skipping RegConnectRegistry because error in Cygwin prototype */
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef RegCreateKey
+#define RegCreateKey error_use_qxeRegCreateKey_or_RegCreateKeyA_and_RegCreateKeyW
+#endif
+LONG
+ qxeRegCreateKey (HKEY hKey, const Extbyte * lpSubKey, PHKEY phkResult);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef RegCreateKeyEx
+#define RegCreateKeyEx error_use_qxeRegCreateKeyEx_or_RegCreateKeyExA_and_RegCreateKeyExW
+#endif
+LONG
+ qxeRegCreateKeyEx (HKEY hKey, const Extbyte * lpSubKey, DWORD Reserved, Extbyte * lpClass, DWORD dwOptions, REGSAM samDesired, LPSECURITY_ATTRIBUTES lpSecurityAttributes, PHKEY phkResult, LPDWORD lpdwDisposition);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef RegDeleteKey
+#define RegDeleteKey error_use_qxeRegDeleteKey_or_RegDeleteKeyA_and_RegDeleteKeyW
+#endif
+LONG
+ qxeRegDeleteKey (HKEY hKey, const Extbyte * lpSubKey);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef RegDeleteValue
+#define RegDeleteValue error_use_qxeRegDeleteValue_or_RegDeleteValueA_and_RegDeleteValueW
+#endif
+LONG
+ qxeRegDeleteValue (HKEY hKey, const Extbyte * lpValueName);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef RegEnumKey
+#define RegEnumKey error_use_qxeRegEnumKey_or_RegEnumKeyA_and_RegEnumKeyW
+#endif
+LONG
+ qxeRegEnumKey (HKEY hKey, DWORD dwIndex, Extbyte * lpName, DWORD cbName);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef RegEnumKeyEx
+#define RegEnumKeyEx error_use_qxeRegEnumKeyEx_or_RegEnumKeyExA_and_RegEnumKeyExW
+#endif
+LONG
+ qxeRegEnumKeyEx (HKEY hKey, DWORD dwIndex, Extbyte * lpName, LPDWORD lpcbName, LPDWORD lpReserved, Extbyte * lpClass, LPDWORD lpcbClass, PFILETIME lpftLastWriteTime);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef RegEnumValue
+#define RegEnumValue error_use_qxeRegEnumValue_or_RegEnumValueA_and_RegEnumValueW
+#endif
+LONG
+ qxeRegEnumValue (HKEY hKey, DWORD dwIndex, Extbyte * lpValueName, LPDWORD lpcbValueName, LPDWORD lpReserved, LPDWORD lpType, LPBYTE lpData, LPDWORD lpcbData);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef RegLoadKey
+#define RegLoadKey error_use_qxeRegLoadKey_or_RegLoadKeyA_and_RegLoadKeyW
+#endif
+LONG
+ qxeRegLoadKey (HKEY hKey, const Extbyte * lpSubKey, const Extbyte * lpFile);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef RegOpenKey
+#define RegOpenKey error_use_qxeRegOpenKey_or_RegOpenKeyA_and_RegOpenKeyW
+#endif
+LONG
+ qxeRegOpenKey (HKEY hKey, const Extbyte * lpSubKey, PHKEY phkResult);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef RegOpenKeyEx
+#define RegOpenKeyEx error_use_qxeRegOpenKeyEx_or_RegOpenKeyExA_and_RegOpenKeyExW
+#endif
+LONG
+ qxeRegOpenKeyEx (HKEY hKey, const Extbyte * lpSubKey, DWORD ulOptions, REGSAM samDesired, PHKEY phkResult);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef RegQueryInfoKey
+#define RegQueryInfoKey error_use_qxeRegQueryInfoKey_or_RegQueryInfoKeyA_and_RegQueryInfoKeyW
+#endif
+LONG
+ qxeRegQueryInfoKey (HKEY hKey, Extbyte * lpClass, LPDWORD lpcbClass, LPDWORD lpReserved, LPDWORD lpcSubKeys, LPDWORD lpcbMaxSubKeyLen, LPDWORD lpcbMaxClassLen, LPDWORD lpcValues, LPDWORD lpcbMaxValueNameLen, LPDWORD lpcbMaxValueLen, LPDWORD lpcbSecurityDescriptor, PFILETIME lpftLastWriteTime);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef RegQueryValue
+#define RegQueryValue error_use_qxeRegQueryValue_or_RegQueryValueA_and_RegQueryValueW
+#endif
+LONG
+ qxeRegQueryValue (HKEY hKey, const Extbyte * lpSubKey, Extbyte * lpValue, PLONG lpcbValue);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef RegQueryMultipleValues
+#define RegQueryMultipleValues error_use_qxeRegQueryMultipleValues_or_RegQueryMultipleValuesA_and_RegQueryMultipleValuesW
+#endif
+LONG
+ qxeRegQueryMultipleValues (HKEY hKey, PVALENTW val_list, DWORD num_vals, Extbyte * lpValueBuf, LPDWORD ldwTotsize);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef RegQueryValueEx
+#define RegQueryValueEx error_use_qxeRegQueryValueEx_or_RegQueryValueExA_and_RegQueryValueExW
+#endif
+LONG
+ qxeRegQueryValueEx (HKEY hKey, const Extbyte * lpValueName, LPDWORD lpReserved, LPDWORD lpType, LPBYTE lpData, LPDWORD lpcbData);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef RegReplaceKey
+#define RegReplaceKey error_use_qxeRegReplaceKey_or_RegReplaceKeyA_and_RegReplaceKeyW
+#endif
+LONG
+ qxeRegReplaceKey (HKEY hKey, const Extbyte * lpSubKey, const Extbyte * lpNewFile, const Extbyte * lpOldFile);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef RegRestoreKey
+#define RegRestoreKey error_use_qxeRegRestoreKey_or_RegRestoreKeyA_and_RegRestoreKeyW
+#endif
+LONG
+ qxeRegRestoreKey (HKEY hKey, const Extbyte * lpFile, DWORD dwFlags);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef RegSaveKey
+#define RegSaveKey error_use_qxeRegSaveKey_or_RegSaveKeyA_and_RegSaveKeyW
+#endif
+LONG
+ qxeRegSaveKey (HKEY hKey, const Extbyte * lpFile, LPSECURITY_ATTRIBUTES lpSecurityAttributes);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef RegSetValue
+#define RegSetValue error_use_qxeRegSetValue_or_RegSetValueA_and_RegSetValueW
+#endif
+LONG
+ qxeRegSetValue (HKEY hKey, const Extbyte * lpSubKey, DWORD dwType, const Extbyte * lpData, DWORD cbData);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef RegSetValueEx
+#define RegSetValueEx error_use_qxeRegSetValueEx_or_RegSetValueExA_and_RegSetValueExW
+#endif
+LONG
+ qxeRegSetValueEx (HKEY hKey, const Extbyte * lpValueName, DWORD Reserved, DWORD dwType, CONST BYTE* lpData, DWORD cbData);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef RegUnLoadKey
+#define RegUnLoadKey error_use_qxeRegUnLoadKey_or_RegUnLoadKeyA_and_RegUnLoadKeyW
+#endif
+LONG
+ qxeRegUnLoadKey (HKEY hKey, const Extbyte * lpSubKey);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef InitiateSystemShutdown
+#define InitiateSystemShutdown error_use_qxeInitiateSystemShutdown_or_InitiateSystemShutdownA_and_InitiateSystemShutdownW
+#endif
+BOOL
+ qxeInitiateSystemShutdown (Extbyte * lpMachineName, Extbyte * lpMessage, DWORD dwTimeout, BOOL bForceAppsClosed, BOOL bRebootAfterShutdown);
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef AbortSystemShutdown
+#define AbortSystemShutdown error_use_qxeAbortSystemShutdown_or_AbortSystemShutdownA_and_AbortSystemShutdownW
+#endif
+BOOL
+ qxeAbortSystemShutdown (Extbyte * lpMachineName);
 
 
 /* Processing file COMMDLG.H */
@@ -1848,137 +2092,19 @@
 /* Skipping PageSetupDlg because LPPAGESETUPDLG with split-sized DEVMODE handle */
 
 
-/* Processing file IMM.H */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef ImmInstallIME
-#define ImmInstallIME error_use_qxeImmInstallIME_or_ImmInstallIMEA_and_ImmInstallIMEW
-#endif
-HKL qxeImmInstallIME (const Extbyte * lpszIMEFileName, const Extbyte * lpszLayoutText);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef ImmGetDescription
-#define ImmGetDescription error_use_qxeImmGetDescription_or_ImmGetDescriptionA_and_ImmGetDescriptionW
-#endif
-UINT qxeImmGetDescription (HKL arg1, Extbyte * arg2, UINT uBufLen);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef ImmGetIMEFileName
-#define ImmGetIMEFileName error_use_qxeImmGetIMEFileName_or_ImmGetIMEFileNameA_and_ImmGetIMEFileNameW
-#endif
-UINT qxeImmGetIMEFileName (HKL arg1, Extbyte * arg2, UINT uBufLen);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef ImmGetCompositionString
-#define ImmGetCompositionString error_use_qxeImmGetCompositionString_or_ImmGetCompositionStringA_and_ImmGetCompositionStringW
-#endif
-LONG qxeImmGetCompositionString (HIMC arg1, DWORD arg2, LPVOID arg3, DWORD arg4);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef ImmGetCandidateListCount
-#define ImmGetCandidateListCount error_use_qxeImmGetCandidateListCount_or_ImmGetCandidateListCountA_and_ImmGetCandidateListCountW
-#endif
-DWORD qxeImmGetCandidateListCount (HIMC arg1, LPDWORD lpdwListCount);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef ImmGetCandidateList
-#define ImmGetCandidateList error_use_qxeImmGetCandidateList_or_ImmGetCandidateListA_and_ImmGetCandidateListW
-#endif
-DWORD qxeImmGetCandidateList (HIMC arg1, DWORD deIndex, LPCANDIDATELIST arg3, DWORD dwBufLen);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef ImmGetGuideLine
-#define ImmGetGuideLine error_use_qxeImmGetGuideLine_or_ImmGetGuideLineA_and_ImmGetGuideLineW
-#endif
-DWORD qxeImmGetGuideLine (HIMC arg1, DWORD dwIndex, Extbyte * arg3, DWORD dwBufLen);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-/* Skipping ImmGetCompositionFont because split-sized LOGFONT */
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-/* Skipping ImmSetCompositionFont because split-sized LOGFONT */
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef ImmConfigureIME
-#define ImmConfigureIME error_use_qxeImmConfigureIME_or_ImmConfigureIMEA_and_ImmConfigureIMEW
-#endif
-BOOL qxeImmConfigureIME (HKL arg1, HWND arg2, DWORD arg3, LPVOID arg4);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef ImmEscape
-#define ImmEscape error_use_qxeImmEscape_or_ImmEscapeA_and_ImmEscapeW
-#endif
-LRESULT qxeImmEscape (HKL arg1, HIMC arg2, UINT arg3, LPVOID arg4);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef ImmGetConversionList
-#define ImmGetConversionList error_use_qxeImmGetConversionList_or_ImmGetConversionListA_and_ImmGetConversionListW
-#endif
-DWORD qxeImmGetConversionList (HKL arg1, HIMC arg2, const Extbyte * arg3, LPCANDIDATELIST arg4, DWORD dwBufLen, UINT uFlag);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef ImmIsUIMessage
-#define ImmIsUIMessage error_use_qxeImmIsUIMessage_or_ImmIsUIMessageA_and_ImmIsUIMessageW
-#endif
-BOOL qxeImmIsUIMessage (HWND arg1, UINT arg2, WPARAM arg3, LPARAM arg4);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef ImmRegisterWord
-#define ImmRegisterWord error_use_qxeImmRegisterWord_or_ImmRegisterWordA_and_ImmRegisterWordW
-#endif
-BOOL qxeImmRegisterWord (HKL arg1, const Extbyte * lpszReading, DWORD arg3, const Extbyte * lpszRegister);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef ImmUnregisterWord
-#define ImmUnregisterWord error_use_qxeImmUnregisterWord_or_ImmUnregisterWordA_and_ImmUnregisterWordW
-#endif
-BOOL qxeImmUnregisterWord (HKL arg1, const Extbyte * lpszReading, DWORD arg3, const Extbyte * lpszUnregister);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#undef ImmGetRegisterWordStyle
-#define ImmGetRegisterWordStyle error_split_sized_STYLEBUF
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef ImmEnumRegisterWord
-#define ImmEnumRegisterWord error_use_qxeImmEnumRegisterWord_or_ImmEnumRegisterWordA_and_ImmEnumRegisterWordW
-#endif
-UINT qxeImmEnumRegisterWord (HKL arg1, REGISTERWORDENUMPROCW arg2, const Extbyte * lpszReading, DWORD arg4, const Extbyte * lpszRegister, LPVOID arg6);
-#endif /* defined (HAVE_MS_WINDOWS) */
-
-#if defined (HAVE_MS_WINDOWS)
-#undef ImmGetImeMenuItems
-#define ImmGetImeMenuItems error_split_sized_IMEMENUITEMINFO
-#endif /* defined (HAVE_MS_WINDOWS) */
+/* Processing file SHLOBJ.H */
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef SHGetPathFromIDList
+#define SHGetPathFromIDList error_use_qxeSHGetPathFromIDList_or_SHGetPathFromIDListA_and_SHGetPathFromIDListW
+#endif
+BOOL qxeSHGetPathFromIDList (LPCITEMIDLIST pidl, Extbyte * pszPath);
+
+/* Skipping SHGetSpecialFolderPath because error in Cygwin prototype, missing from Cygwin libraries */
+
+/* Skipping SHBrowseForFolder because need to intercept callback for SendMessage */
+
+/* Skipping SHGetDataFromIDList because split-sized WIN32_FIND_DATA or split-simple NETRESOURCE, missing from Cygwin libraries */
 
 
 /* Processing file WINBASE.H */
@@ -2220,6 +2346,12 @@
 #endif
 HRSRC qxeFindResourceEx (HMODULE hModule, const Extbyte * lpType, const Extbyte * lpName, WORD wLanguage);
 
+/* Skipping EnumResourceTypes because different prototypes in VC6 and VC7 */
+
+/* Skipping EnumResourceNames because different prototypes in VC6 and VC7 */
+
+/* Skipping EnumResourceLanguages because different prototypes in VC6 and VC7 */
+
 #ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
 #undef BeginUpdateResource
 #define BeginUpdateResource error_use_qxeBeginUpdateResource_or_BeginUpdateResourceA_and_BeginUpdateResourceW
@@ -2771,124 +2903,11 @@
 #define OpenJobObject error_NT_5_0__only
 
 
-/* Processing file MMSYSTEM.H */
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef sndPlaySound
-#define sndPlaySound error_use_qxesndPlaySound_or_sndPlaySoundA_and_sndPlaySoundW
-#endif
-BOOL qxesndPlaySound (const Extbyte * pszSound, UINT fuSound);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef PlaySound
-#define PlaySound error_use_qxePlaySound_or_PlaySoundA_and_PlaySoundW
-#endif
-BOOL qxePlaySound (const Extbyte * pszSound, HMODULE hmod, DWORD fdwSound);
-
-#undef waveOutGetDevCaps
-#define waveOutGetDevCaps error_split_sized_LPWAVEOUTCAPS
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef waveOutGetErrorText
-#define waveOutGetErrorText error_use_qxewaveOutGetErrorText_or_waveOutGetErrorTextA_and_waveOutGetErrorTextW
-#endif
-MMRESULT qxewaveOutGetErrorText (MMRESULT mmrError, Extbyte * pszText, UINT cchText);
-
-#undef waveInGetDevCaps
-#define waveInGetDevCaps error_split_sized_LPWAVEINCAPS
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef waveInGetErrorText
-#define waveInGetErrorText error_use_qxewaveInGetErrorText_or_waveInGetErrorTextA_and_waveInGetErrorTextW
-#endif
-MMRESULT qxewaveInGetErrorText (MMRESULT mmrError, Extbyte * pszText, UINT cchText);
-
-#undef midiOutGetDevCaps
-#define midiOutGetDevCaps error_split_sized_LPMIDIOUTCAPS
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef midiOutGetErrorText
-#define midiOutGetErrorText error_use_qxemidiOutGetErrorText_or_midiOutGetErrorTextA_and_midiOutGetErrorTextW
-#endif
-MMRESULT qxemidiOutGetErrorText (MMRESULT mmrError, Extbyte * pszText, UINT cchText);
-
-#undef midiInGetDevCaps
-#define midiInGetDevCaps error_split_sized_LPMIDIOUTCAPS
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef midiInGetErrorText
-#define midiInGetErrorText error_use_qxemidiInGetErrorText_or_midiInGetErrorTextA_and_midiInGetErrorTextW
-#endif
-MMRESULT qxemidiInGetErrorText (MMRESULT mmrError, Extbyte * pszText, UINT cchText);
-
-#undef auxGetDevCaps
-#define auxGetDevCaps error_split_sized_LPAUXCAPS
-
-#undef mixerGetDevCaps
-#define mixerGetDevCaps error_split_sized_LPMIXERCAPS
-
-#undef mixerGetLineInfo
-#define mixerGetLineInfo error_split_sized_LPMIXERLINE
-
-#undef mixerGetLineControls
-#define mixerGetLineControls error_split_sized_LPMIXERCONTROL
-
-#undef mixerGetControlDetails
-#define mixerGetControlDetails error_split_sized_LPMIXERCONTROL_in_LPMIXERLINECONTROLS_in_LPMIXERCONTROLDETAILS
-
-#undef joyGetDevCaps
-#define joyGetDevCaps error_split_sized_LPJOYCAPS
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef mmioStringToFOURCC
-#define mmioStringToFOURCC error_use_qxemmioStringToFOURCC_or_mmioStringToFOURCCA_and_mmioStringToFOURCCW
-#endif
-FOURCC qxemmioStringToFOURCC (const Extbyte * sz, UINT uFlags);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef mmioInstallIOProc
-#define mmioInstallIOProc error_use_qxemmioInstallIOProc_or_mmioInstallIOProcA_and_mmioInstallIOProcW
-#endif
-LPMMIOPROC qxemmioInstallIOProc (FOURCC fccIOProc, LPMMIOPROC pIOProc, DWORD dwFlags);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef mmioOpen
-#define mmioOpen error_use_qxemmioOpen_or_mmioOpenA_and_mmioOpenW
-#endif
-HMMIO qxemmioOpen (Extbyte * pszFileName, LPMMIOINFO pmmioinfo, DWORD fdwOpen);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef mmioRename
-#define mmioRename error_use_qxemmioRename_or_mmioRenameA_and_mmioRenameW
-#endif
-MMRESULT qxemmioRename (const Extbyte * pszFileName, const Extbyte * pszNewFileName, LPCMMIOINFO pmmioinfo, DWORD fdwRename);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef mciSendCommand
-#define mciSendCommand error_use_qxemciSendCommand_or_mciSendCommandA_and_mciSendCommandW
-#endif
-MCIERROR qxemciSendCommand (MCIDEVICEID mciId, UINT uMsg, DWORD dwParam1, DWORD dwParam2);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef mciSendString
-#define mciSendString error_use_qxemciSendString_or_mciSendStringA_and_mciSendStringW
-#endif
-MCIERROR qxemciSendString (const Extbyte * lpstrCommand, Extbyte * lpstrReturnString, UINT uReturnLength, HWND hwndCallback);
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef mciGetDeviceID
-#define mciGetDeviceID error_use_qxemciGetDeviceID_or_mciGetDeviceIDA_and_mciGetDeviceIDW
-#endif
-MCIDEVICEID qxemciGetDeviceID (const Extbyte * pszDevice);
-
-#if !defined (MINGW)
-#undef mciGetDeviceIDFromElementID
-#define mciGetDeviceIDFromElementID error_missing_from_Win98se_version_of_ADVAPI32_dll
-#endif /* !defined (MINGW) */
-
-#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
-#undef mciGetErrorString
-#define mciGetErrorString error_use_qxemciGetErrorString_or_mciGetErrorStringA_and_mciGetErrorStringW
-#endif
-BOOL qxemciGetErrorString (MCIERROR mcierr, Extbyte * pszText, UINT cchText);
-
+/* Processing file ACLAPI.h */
+
+#ifdef ERROR_WHEN_NONINTERCEPTED_FUNS_USED
+#undef GetNamedSecurityInfo
+#define GetNamedSecurityInfo error_use_qxeGetNamedSecurityInfo_or_GetNamedSecurityInfoA_and_GetNamedSecurityInfoW
+#endif
+DWORD qxeGetNamedSecurityInfo (IN  Extbyte * pObjectName, IN  SE_OBJECT_TYPE ObjectType, IN  SECURITY_INFORMATION SecurityInfo, OUT PSID                 * ppsidOowner, OUT PSID                 * ppsidGroup, OUT PACL                 * ppDacl, OUT PACL                 * ppSacl, OUT PSECURITY_DESCRIPTOR * ppSecurityDescriptor);
+
--- a/src/intl-encap-win32.c	Fri Dec 08 02:17:16 2006 +0000
+++ b/src/intl-encap-win32.c	Fri Dec 08 02:22:02 2006 +0000
@@ -100,6 +100,10 @@
 
 // dir c:\Program Files\Microsoft Visual Studio\VC98\Include\
 
+file ACLAPI.h
+
+yes GetNamedSecurityInfo
+
 file WINBASE.H
 
 yes GetBinaryType
--- a/src/syswindows.h	Fri Dec 08 02:17:16 2006 +0000
+++ b/src/syswindows.h	Fri Dec 08 02:22:02 2006 +0000
@@ -88,6 +88,8 @@
 #define OEMRESOURCE /* Define OCR_ and friend constants */
 #include <windows.h>
 
+#include <aclapi.h>
+
 #if defined (WIN32_LEAN_AND_MEAN)
 # ifdef HAVE_X_WINDOWS
 /* Christ almighty.  The problems you get when combining two large code bases,
@@ -932,6 +934,7 @@
 int cygwin_win32_to_posix_path_list_buf_size (const char *);
 void cygwin_posix_to_win32_path_list (const char *, char *);
 int cygwin_posix_to_win32_path_list_buf_size (const char *);
+extern int cygwin_conv_to_full_win32_path (const char *, char *);
 
 END_C_DECLS