Flo354 / XposedAppLocale

An Xposed module to set language on a per-app basis
Apache License 2.0
38 stars 14 forks source link

Locale settings not being emulated #18

Open CaiMiao opened 6 years ago

CaiMiao commented 6 years ago

Hi, I rarely use this module, because it's not really changing "locale settings", but just displaying target language strings. Just an example, Play Store. You will still seeing English comments of an app if you set ja_JP with App Locale 2, because your locale settings of phone are still prioritizes en_US than ja_JP. Play Store attributes comments by locale, not store regions. If you are a CJK language user, you will find respective font will not be applying (e.g. zh_CN locale with ja_JP on App Locale) too. (Still Chinese font, cause regional-variant glyphs not presenting correctly).

In fact, App Settings did emulate locale, but it's permanently gone. I don't know much tech specs of you two module, but just tell me if it's possible to really emulates locale settings or not.

CJK language glyphs do have differences.

In some cases, glyphs based on an original ideograph might have as many as four regional variations. Source Han Serif covers all these variations with carefully-designed regional glyphs. Once you select the appropriate language-specific font or language-tag the text, you'll be all set with the correct glyph variations.

CaiMiao commented 6 years ago

I think #16 is same problem with this because locale settings is not being emulated.

HankAviator commented 6 years ago

Try changing settings for Google Play services and related apps too.

CaiMiao commented 6 years ago

doesn't seem to work

HankAviator commented 6 years ago

a global (system) language change may help, refer to the above issue which referenced this one. Try adding a secondary language in system language settings. If it doesn't help, this issue might be marked wontfix since the way Google acquires locale is not simply app-specific.

CaiMiao commented 6 years ago

secondary locale doesn't seem to be meaningful, because the primary is always at highest priority for well-internationalized apps. Also font sucks. Consider add locale emulation support as an option. That's what App Settings did by default.

HankAviator commented 6 years ago

If you meant locale emulation by tampering MCC, MNC, networkProvider and simProvider, XPrivacy was an ideal choice, XPrivacyLua may also do it but I ain't sure since purchase is needed for it. Otherwise, hooking the method above mentioned and return a custom value should work. It may be different from AssistUtils. If you can find which method it is, it'll be helpful. PS, so far it seems only Google apps do this way, thus adding this option will benefit very limited apps.

Flo354 commented 6 years ago

For me, the only apps which triggering an incorrect behavior like this one (app is in a language, but other things are in phone language) are the app which get some strings from native code.

Thus, we can't do anything for that. But my knowledge is limited on this field and may be I am wrong since you say that with App Settings it worked when it was maintained.

HankAviator commented 6 years ago

I guess the only difference could be some method hooks we missed ;)

RadarNyan commented 6 years ago

I've also noticed a difference between the xposed module "App Settings" and "App Locale 2", it doesn't change the locale as "complete" as App Settings.

For example, on my old phone where App Settings still works, if I change the locale of "Google Japanese IME", the android system dialog "Change keyboard" would change accordingly, showing:

image

But when I do the same on my new phone with App Locale 2, the Change keyboard dialog stays unchanged:

image

Also, the app name in launcher also stays unchanged. So there's definitely something that App Settings does missing from App Locale 2.