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.

66 lines
2.7 KiB

  1. /*****************************************************************************\
  2. FILE: fontfix.h
  3. DESCRIPTION:
  4. This file will implement an API: FixFontsOnLanguageChange().
  5. The USER32 or Regional Settings code should own this API. The fact that it's
  6. in the shell is a hack and it should be moved to USER32. This font will
  7. be called when the MUI language changes so the fonts in the system metrics
  8. can be changed to valid values for the language.
  9. This API should be called in three cases:
  10. a. When the user changes the language via the Regional Settings CPL UI.
  11. b. During a user login, USER32 should see if the language changed and
  12. call this API. This will handle the case where admins change the
  13. language via login screens and reboot. This is not currently implemented.
  14. c. The language is changed via some other method (admin login scripts most likely)
  15. and the user opens the display CPL. This method is a hack, especially
  16. since (b) isn't implemented.
  17. Contacts: EdwardP - International Font PM.
  18. Sankar ?/??/???? - Created for Win2k or before in desk.cpl.
  19. BryanSt 3/24/2000 - Make to be modular so it can be moved back into USER32.
  20. Made the code more robust. Removed creating custom appearance
  21. schemes in order to be compatible with new .theme and
  22. .msstyles support.
  23. Copyright (C) Microsoft Corp 2000-2000. All rights reserved.
  24. \*****************************************************************************/
  25. #ifndef _FONTFIX_H
  26. #define _FONTFIX_H
  27. /////////////////////////////////////////////////////////////////////
  28. // String Constants
  29. /////////////////////////////////////////////////////////////////////
  30. #define SYSTEM_LOCALE_CHARSET 0 //The first item in the array is always system locale charset.
  31. /////////////////////////////////////////////////////////////////////
  32. // Data Structures
  33. /////////////////////////////////////////////////////////////////////
  34. /////////////////////////////////////////////////////////////////////
  35. // Public Function
  36. /////////////////////////////////////////////////////////////////////
  37. // This API is used to fix fonts in case the language changed and we need to fix the CHARSET.
  38. STDAPI FixFontsOnLanguageChange(void);
  39. // These are used to filter out fonts not compatible with the current language.
  40. int CALLBACK Font_EnumValidCharsets(LPENUMLOGFONTEX lpelf, LPNEWTEXTMETRIC lpntm, DWORD Type, LPARAM lData);
  41. void Font_GetCurrentCharsets(UINT uiCharsets[], int iCount);
  42. void Font_GetUniqueCharsets(UINT uiCharsets[], UINT uiUniqueCharsets[], int iMaxCount, int *piCountUniqueCharsets);
  43. #endif // _FONTFIX_H