[Q] Plz help, citrix in webtop won't launch - Atrix 4G Q&A, Help & Troubleshooting

(process:2418): Gtk-WARNING **: Locale not supported by C library.
Using the fallback 'C' locale.
Warning: locale not supported by C library, locale unchanged
Warning: locale not supported by Xlib, locale set to C
Warning: X locale modifiers not supported, using default
Warning: Unable to load any usable fontset
Error: Aborting: no fontset found
I set my phone locale to Chinese, and use webtop2sd.

Related

[Q] Tasker - changing system language / shell command?

Hey,
I would like to make a task, which would change system language to x, then - on exit task to y. I was searching a bit, but I haven't found any plugin which could do that - but maby it's possible to change sys language by using shell command, which can be executed by tasker?
ty
I'm looking for the same thing, still no luck?
Found! https://play.google.com/store/apps/details?id=com.intangibleobject.securesettings.plugin&hl=en
Tasker/Locale plugin which allows you to change the system language.

Locales not showing up in Settings even though they are installed

Hi everyone,
I'm working on an AOSP device which has a limited set of locales, and I wanted to add Portuguese to the device. I did this by modifying device/qcom/common/common.mk and adding in pt_PT to PRODUCT_LOCALES. With the image that this build produces, I can successfully set the language to Portuguese through the setprop persist.sys.language settings, but if I go to Settings -> Language and Input -> Language, Portuguese is not on the list.
Does anyone have any ideas on how I can add a language to the languages list in Settings?
Thank you.

If a website supports multiple languages, can the web page be displayed in the system

In the onInit() method of the quick app lifecycle, the quick app device API is used to obtain the system language and load the HTML5 page in the obtained language.
For example, if the system language of a mobile phone is Japanese, HTML5 pages are displayed in Japanese. The sample code is as follows:
onInit: function () {
const device=require("@system.device")
const res=device.getInfoSync();
let local=res.language; //system language
let region=res.region; //system region
console.info('onInit :localole= ' + local+", region="+region);
if(local==='zh'){
if(region==="CN"){
this.loadUrl="https://transit.navitime.com/zh-cn/";
}else if(region==="TW"){
this.loadUrl="https://transit.navitime.com/zh-tw/";
}
}else if(local==='ja'){
this.loadUrl="https://transit.navitime.com/ja/?from=huawei.quickapp";
}else{
//Other languages can use the default language H5
this.loadUrl="https://transit.navitime.com/en";
}
},
Click to expand...
Click to collapse

Changing Android locale works in debug version of app, but only updates to English or Spanish in release version, no other Locales work

So I wanted to create a way for a user to change between 6 different languages within my Android app. Currently, I have string resource files for English (default), Spanish, German, French, Japanese, and Russian. When I run the code on my emulator, or on my phone through debug, everything works perfectly. The app updates when I select a language, and runs great.
However, when I change to the release version, generate a signed app bundle and upload it to the play store for internal testing, and I download the app from there, the only language options that work is English and Spanish. All my other language options revert to English, despite my logs stating that the locale of the configuration properly changed to the specific locale I want.
My guess is that maybe there's some sort of phone specific setting that's preventing me from seeing the additional languages? But I'm unsure how to work around that, and I'm also confused why, if that's the case, Spanish would be working but no other languages.
Here is the OnClick that sets the locale and calls my UpdateLocale method (These correspond to buttons I've added within an alert dialog box for language selection):
Java:
public void onClick(DialogInterface dialog, int which) {
switch (which) {
case 0:
Locale usLocale = new Locale("en");
editor.putString("Locale", "en");
editor.apply();
updateLocale(usLocale);
dialog.dismiss();
break;// english
case 1:
Locale esLocale = new Locale("es");
editor.putString("Locale", "es");
editor.apply();
updateLocale(esLocale);
dialog.dismiss();
break;// spanish
case 2:
Locale deLocale = new Locale("de");
editor.putString("Locale", "de");
editor.apply();
updateLocale(deLocale);
dialog.dismiss();
break;// german
case 3:
Locale frLocale = new Locale("fr");
editor.putString("Locale", "fr");
editor.apply();
updateLocale(frLocale);
dialog.dismiss();
break;// french
case 4:
Locale jaLocale = new Locale("ja");
editor.putString("Locale", "ja");
editor.apply();
updateLocale(jaLocale);
dialog.dismiss();
break;// japanese
case 5:
Locale ruLocale = new Locale("ru");
editor.putString("Locale", "ru");
editor.apply();
updateLocale(ruLocale);
dialog.dismiss();
break;// russian
}
recreate();
}
And here is the UpdateLocale method itself:
Java:
public void updateLocale(Locale locale) {
Resources res = getResources();
Locale.setDefault(locale);
Configuration configuration = res.getConfiguration();
if (Integer.parseInt(android.os.Build.VERSION.SDK) >= 24) {
LocaleList localeList = new LocaleList(locale);
LocaleList.setDefault(localeList);
configuration.setLocales(localeList);
configuration.setLocale(locale);
} else if (Integer.parseInt(android.os.Build.VERSION.SDK) >= 17){
configuration.setLocale(locale);
} else {
configuration.locale = locale;
}
res.updateConfiguration(configuration, res.getDisplayMetrics());
}
I have already added the locales I want to my build.gradle file
Code:
resConfigs "en", "de", "es", "fr", "ja", "ru"
And I have added the following to all activities within my android manifest
Code:
android:configChanges="locale"
If anyone knows what I might be doing wrong, or what I might be able to look for to figure out why there's a disconnect between my Debug and Release versions, I'd be eternally grateful.
After some cursory googling, I've tried checking the libraries I'm using to see if I need to add anything to the proguard-rules.pro file, as that has rules that get applied when you generate a release version of an app, however none of the libraries I'm using are being used in this specific context to change the locale, so I don't think that's my problem.

How can I read a Macrodroid variable from another machine using command line?

Hello,
I have a Macrodroid string variable that contains a port number. I need to use it for connection purposes when running a windows batch file to connect with it.
Let's say the variable name is X and the value currently stored there is: 12345.
Is there a command I can run in command line such as:
localhost:777/macrodroid/get-variable/x
that would result in 12345 result so rather than manually entering the port number into a text file based on the new value each time, and then read it in a batch variable as I do now:
set /p port=<C:\port.txt
I could do this:
set /p port=<localhost.macrodroid.private/get-variable/x
So I guess for this, I need Macrodroid to host like a small local servlet (server) that would basically just expose the single variable that I need? Or is there an alternative android app server that would give me this functionality where I could store a string variable and then read from it? I'm not sure this could be done with Macrodroid webhook as it's more for invoking triggers, not reading variables, and it's using Macrodroid public server and not hosting a local server?
Thank you.

Categories

Resources