How to use enable pseudo-locale in Windows for testing?

前端 未结 4 1553
礼貌的吻别
礼貌的吻别 2020-12-01 00:35

Windows Vista introduced the concept of three pseudo-locales:

Pseudo Locale        Locale Name  LCID           
===================  ===========  ======
Base         


        
4条回答
  •  不知归路
    2020-12-01 00:51

    Windows 10 1803

    Unfortunately, as of Windows 10 1803, it appears to no longer be possible to enable these locales:

    For Windows 10, version 1803, editing the Windows Registry like this has no effect. But you can still call the non-enumerating NLS APIs with the names of the pseudo-locales (see the code examples above) to populate your user interface (UI).

    According to https://social.technet.microsoft.com/Forums/office/en-US/88de942e-7967-4419-b1fb-23d200c75fe3/unable-to-use-psuedo-locales-after-1803-win-10-update?forum=win10itprogeneral,

    Note that they still work as they are built-in to Windows, “just” that they don't show up in the enumeration - so they don't show up in the drop down - so that makes them a bit trickier to use. I'm working to find a workaround.

    Basically, if you copy the registry values from Computer\HKEY_CURRENT_USER\Control Panel\International (not the subkeys) from a machine using the appropriate pseudo locale, then that should be used for further processes, even if it is not enumerated.

    Registry values for manual config

    Here are the exported values from a 1607 system. They can be put into a .reg file for easy import.

    If using a .reg file, the following header is required:

    Windows Registry Editor Version 5.00
    

    Pseudo (Pseudo) [qps-ploc]

    [HKEY_CURRENT_USER\Control Panel\International]
    "Locale"="00000501"
    "LocaleName"="qps-ploc"
    "s1159"="АΜ"
    "s2359"="P̰̃M]"
    "sCountry"="Pseudo"
    "sCurrency"="$"
    "sDate"="/"
    "sDecimal"="."
    "sGrouping"="4;0"
    "sLanguage"="ENU"
    "sList"=",,"
    "sLongDate"="ffffdd, d 'ōf' MMMM 'ōf' yyyy"
    "sMonDecimalSep"="."
    "sMonGrouping"="4;0"
    "sMonThousandSep"=",,"
    "sNativeDigits"="0123456789"
    "sNegativeSign"="-"
    "sPositiveSign"="++"
    "sShortDate"="d/MM/yy"
    "sThousand"=",,"
    "sTime"=":"
    "sTimeFormat"="H:mm:ss"
    "sShortTime"="h:mm tt"
    "sYearMonth"="MMMM yyyy"
    "iCalendarType"="1"
    "iCountry"="61"
    "iCurrDigits"="3"
    "iCurrency"="0"
    "iDate"="1"
    "iDigits"="3"
    "NumShape"="1"
    "iFirstDayOfWeek"="0"
    "iFirstWeekOfYear"="0"
    "iLZero"="1"
    "iMeasure"="1"
    "iNegCurr"="1"
    "iNegNumber"="1"
    "iPaperSize"="1"
    "iTime"="1"
    "iTimePrefix"="0"
    "iTLZero"="0"
    

    Pseudo (Pseudo Asia) [qps-ploca]

    [HKEY_CURRENT_USER\Control Panel\International]
    "Locale"="000005FE"
    "LocaleName"="qps-ploca"
    "s1159"="午前"
    "s2359"="午後"
    "sCountry"="Pseudo Asia"
    "sCurrency"="¥"
    "sDate"="/"
    "sDecimal"="."
    "sGrouping"="3;0"
    "sLanguage"="JPN"
    "sList"=","
    "sLongDate"="yyyy'年'M'月'd'日'"
    "sMonDecimalSep"="."
    "sMonGrouping"="3;0"
    "sMonThousandSep"=","
    "sNativeDigits"="0123456789"
    "sNegativeSign"="-"
    "sPositiveSign"=""
    "sShortDate"="yyyy/MM/dd"
    "sThousand"=","
    "sTime"=":"
    "sTimeFormat"="H:mm:ss"
    "sShortTime"="H:mm"
    "sYearMonth"="yyyy'年'M'月'"
    "iCalendarType"="1"
    "iCountry"="81"
    "iCurrDigits"="0"
    "iCurrency"="0"
    "iDate"="2"
    "iDigits"="2"
    "NumShape"="1"
    "iFirstDayOfWeek"="6"
    "iFirstWeekOfYear"="0"
    "iLZero"="1"
    "iMeasure"="0"
    "iNegCurr"="1"
    "iNegNumber"="1"
    "iPaperSize"="9"
    "iTime"="1"
    "iTimePrefix"="0"
    "iTLZero"="0"
    

    Pseudo (Pseudo Mirrored) [qps-plocm]

    [HKEY_CURRENT_USER\Control Panel\International]
    "Locale"="000009FF"
    "LocaleName"="qps-plocm"
    "s1159"="ص"
    "s2359"="م"
    "sCountry"="Pseudo Mirrored"
    "sCurrency"="ر.س.‏"
    "sDate"="/"
    "sDecimal"="."
    "sGrouping"="3;0"
    "sLanguage"="ARA"
    "sList"=";"
    "sLongDate"="dd/MMMM/yyyy"
    "sMonDecimalSep"="."
    "sMonGrouping"="3;0"
    "sMonThousandSep"=","
    "sNativeDigits"="٠١٢٣٤٥٦٧٨٩"
    "sNegativeSign"="-"
    "sPositiveSign"=""
    "sShortDate"="dd/MM/yy"
    "sThousand"=","
    "sTime"=":"
    "sTimeFormat"="hh:mm:ss tt"
    "sShortTime"="hh:mm tt"
    "sYearMonth"="MMMM, yyyy"
    "iCalendarType"="23"
    "iCountry"="966"
    "iCurrDigits"="2"
    "iCurrency"="2"
    "iDate"="1"
    "iDigits"="2"
    "NumShape"="0"
    "iFirstDayOfWeek"="5"
    "iFirstWeekOfYear"="0"
    "iLZero"="1"
    "iMeasure"="0"
    "iNegCurr"="3"
    "iNegNumber"="3"
    "iPaperSize"="9"
    "iTime"="0"
    "iTimePrefix"="0"
    "iTLZero"="1"
    

    Pseudo (Pseudo Selfhost) [qps-Latn-x-sh]

    [HKEY_CURRENT_USER\Control Panel\International]
    "Locale"="00000901"
    "LocaleName"="qps-Latn-x-sh"
    "s1159"="AM"
    "s2359"="PM"
    "sCountry"="Pseudo Selfhost"
    "sCurrency"="J$"
    "sDate"="/"
    "sDecimal"="."
    "sGrouping"="3;0"
    "sLanguage"="ENJ"
    "sList"=","
    "sLongDate"="dd MMMM, yyyy"
    "sMonDecimalSep"="."
    "sMonGrouping"="3;0"
    "sMonThousandSep"=","
    "sNativeDigits"="0123456789"
    "sNegativeSign"="-"
    "sPositiveSign"=""
    "sShortDate"="dd/MM/yyyy"
    "sThousand"=","
    "sTime"=":"
    "sTimeFormat"="HH:mm:ss"
    "sShortTime"="HH:mm"
    "sYearMonth"="MMMM, yyyy"
    "iCalendarType"="1"
    "iCountry"="1"
    "iCurrDigits"="2"
    "iCurrency"="0"
    "iDate"="1"
    "iDigits"="2"
    "NumShape"="1"
    "iFirstDayOfWeek"="6"
    "iFirstWeekOfYear"="0"
    "iLZero"="1"
    "iMeasure"="0"
    "iNegCurr"="1"
    "iNegNumber"="1"
    "iPaperSize"="1"
    "iTime"="1"
    "iTimePrefix"="0"
    "iTLZero"="1"
    

提交回复
热议问题