Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

30 lines
460 B

  1. /*++
  2. Copyright (c) 2001, Microsoft Corporation
  3. Module Name:
  4. misc.cpp
  5. Abstract:
  6. Author:
  7. Revision History:
  8. Notes:
  9. --*/
  10. #include "private.h"
  11. #pragma warning(disable: 4005)
  12. #include <wingdip.h>
  13. extern "C" BYTE GetCharsetFromLangId(LCID lcid)
  14. {
  15. CHARSETINFO csInfo;
  16. if (!TranslateCharsetInfo((DWORD *)(ULONG_PTR)lcid, &csInfo, TCI_SRCLOCALE))
  17. return DEFAULT_CHARSET;
  18. return (BYTE) csInfo.ciCharset;
  19. }