GithubHelp home page GithubHelp logo

akhilkedia / alltrans Goto Github PK

View Code? Open in Web Editor NEW
391.0 11.0 32.0 11.23 MB

Completely Translate Android apps in-place aka Google translate in Chrome

License: Other

Java 97.38% HTML 0.83% Python 1.80%
xposed android-apps automatic-translation microsoft-translator-api yandex-translate

alltrans's Introduction

AllTransAllTrans™ - Completely Translate Apps

Like Chrome's translation of webpages, but for Android apps. It replaces ALL TEXT IN AN APP from one language to another at runtime.

Say for example an app is in German. A user selects the app name, and the required language conversion (say German to English). Then whenever the user uses the required app, all the text, ANYWHERE in the app, are replaced by their English equivalents. This is something similar to the way Google Translate works in Chrome.

Works with Android 13!

LicenseGPLv3 Donate GitHub All Releases Play

Download the latest release from github releases or from LSPosed modules!

Table of Contents

What AllTrans does

It replaces all text in an app in a language from one language to another at runtime.

Say for example an app is in German. A user selects the app name, and the required language conversion (say German to English).

Then whenever the user uses the required app, all the text, ANYWHERE in the app, are replaced by their English equivalents.

This is something similar to the way Google Translate works in Chrome.

Note - Due to a technical limitation, this won't work with many games. Nothing can be done about this.

ScreenShots and Videos

Below are some screenshots of AllTrans translating apps from Korean to English

Below are some of the screenshots of AllTrans app

Videos

A video (in English) showing how to use AllTrans by Gadget Hacks on Youtube https://www.youtube.com/watch?v=sKDtkmISi6k. This video is for an older version of the app, you no longer need API keys.

Alt text

How to install AllTrans

  1. This application requires android version 4.4 or later. You probably already have it. (Android KitKat or later - so far Kitkat, Lollipop, MarshMallow, Nougat, Oreo, Pie, Q, R.).
  2. Make sure you have Xposed Framework installed and running.
    • LSPosed and EdXposed are recommended.
    • If you do not have an unlocked bootloader or Magisk, AllTrans is now fully compatible with VirtualXposed and Taichi, so AllTrans can now be used on all devices!!! No need of unlocked bootloader, no need of Magisk, etc.!
  3. Install the latest version of AllTrans from Google Play Store. You can alternatively download the apk from Xposed Module Repository or from LSPosed Repository inside LSPosed app.
  4. Reboot your phone.

How to use AllTrans

  1. Make sure "AllTrans" app is enabled in "Xposed Installer -> Modules".
  2. Launch "AllTrans" app.
  3. Choose the "Translate from Language" and "Translate to Language".
  4. In the "Apps to Translate" tab, find the app you want to translate, click the checkbox next to it.
  5. Close and restart the app you want translated - it should be translated!

Note - If you are using VirtualXposed or Taichi

  • This application will only work for apps installed inside Taichi or VirtualXposed, not for other apps. This means it will not work for any system apps. - Sometimes some apps will fail to install/run inside Taichi/VirtualXposed. This is not a problem of AllTrans, just some limitations of Taichi/VirtualXposed.
  • Some apps work on Taichi, some work on VirtualXposed, some on neither. I recommend you try using both if some app does not install/open inside VirtualXposed/Taichi.

How to get Microsoft Azure Translate Key

If you use Microsoft Translate instead of Google, you need you to sign up for free a key from Microsoft Translate. See instructions below on how to get the keys. Microsoft Translate requires a credit card to sign up. (But don't worry, nothing will be charged.)

  1. Sign up for a Microsoft Azure account. If you don't already have an Azure account, sign up for a Microsoft Azure account.
  2. After you have an account, sign into the Azure Portal. Sign up for a subcription by following the steps below.
    1. Click "Subscriptions". It has a key icon.
    2. Click the "+ Add" at the top
    3. Choose a "pay-as-you-go" subscription. Will require a credit card, but don't worry, nothing will be charged.
    4. Verify your identity, add in the credit card information. You will not be charged.
    5. In "Add Technical Support", select "No technical support". You will have to pay if you select any other. Accept the "Agreement", and click "Sign up".
    6. Click "Home" at the top after you finish signing up.
  3. Add a translate API resource by following the steps below.
    1. Select the "+ Create a resource" option.
    2. In the search box saying "Search the Marketplace" type "translator" on the left, and select "Translator" from the search results.
    3. Click the blue "Create" button.
    4. Under the "Resource group" field, click "Create new", then type in any name, it does not matter.
    5. In the "Resource group region" field, select any region, it does not matter
    6. In the "Resource group" field, type in any name, it does not matter.
    7. In the "Region" Section, select "Global"
    8. Type in any name in "Name" field, type in any name, it does not matter.
    9. In the "Pricing Tier" section, select the "F0 (2M Up to 2M characters translated per month)". You will have to pay if you select any other.
    10. Click "Next: Tags", then click "Next: Review + Create", then click "Create".
    11. Wait 1 minute for Microsoft to process your request, then go to "Home".
  4. Copy your key from Microsoft and add it to AllTrans by following the steps below.
    1. Under the "Recent Resource" section, click the name of the resource you just created.
    2. Click "Keys and Endpoint" on the left. It has a key icon.
    3. Copy "KEY 1". This is the key you need to add to AllTrans.

The subscription key is something like "3d2c..." (some english numbers and alphabets).

Note - No New Yandex Translate Keys

A previous version of this application encouraged use of Yandex API keys. Yandex has stopped giving free translate API keys. If you already have a key, it may continue to work, it may not. It is recommended to shift to using a Microsoft API key.

TroubleShooting

No app is being translated in any app

  • If no app is being translated, check if "AllTrans" is enabled in "Xposed Installer -> Modules"
    • If you are using "LSPosed", make sure "System Framework" and "Settings Storage", and the to-be-translated-app is enabled in LSPosed for AllTrans.
    • If you are using "Taichi", check "AllTrans" is enabled in "+ -> Manage Modules".
    • If you are using "Taichi"/"VirtualXposed", also make sure the app to be translated in installed using "Taichi"/"VirtualXposed".
  • If you are using "Google" to translate (the default), make sure you have set "Translate From Langauge" and "Translate To Language" and downloaded the translation files.
  • If you are using "Microsoft" to translate, make sure "Microsoft Subscription Key" is correct, and the "Resource Region" setting is "Global" when you made the key.

Translated app is stuck in opening screen

  • If this is the first time you started translating this app, click on the app's name in "Apps to Translate" tab, and in "Other Settings" fill in "Delay Before Replcaing With Translated Text" to "2000".

The Translated app is "Force Close"

  • Click on the app's name in "Apps to Translate" tab, and in "Other Settings" fill in "Delay Before Replcaing With Translated Text" to "2000".
  • Click on the app's name in "Apps to translate" tab, and in "Other Settings" fill in "Delay Before Starting to Translate WebViews" to "2000".

Other apps are being translated, but some particular app is not

  • Click on the app's name in "Apps to translate" tab, and in "Other Settings" fill in "Delay Before Starting to Translate WebViews" to "2000".
  • If some parts of the app are still not being translated, click on the app's name in "Apps to translate" tab, and enable "Aggressive Mode".

A game app is not being translated

  • Due to technical limitations, "AllTrans" will not work with many games. Nothing can be done about this.

The app "Telegram" is not being translated

  • In "Apps to Translate", click on "Telegram", click "OverRide Global Settings", set "Translate From Langauge" and "Translate To Language", and Enable "Aggresive Mode"

If you still have problems like "Force Close" or parts of an app not being translated

Contact me for support. When you do, I will need atleast the following information -

  1. The name of the app, along with a link to download the app from some APK store like "Google Play Store", "CoolApk", etc.
  2. Your phone's Android version.
  3. A "logcat" of you trying to open the app which gives you problems. You can use apps freely available on the Play Store for this, such as This one

Once you have the above, contact me on the XDA support thread. You can also report issues on the Project's "Github".

Featured In

AllTrans has been featured by many outlets, in many languages. AllTrans has been covered in English by -

Donations

If you like this project, buy me a cup of coffee! :)

paypal

License

This program is AllTrans Copyright (C) 2017 Akhil Kedia

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.

alltrans's People

Contributors

akhilkedia avatar bethelmelesse avatar dependabot[bot] avatar tiann avatar wanlyg avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

alltrans's Issues

Translation doesn't fit defined character limit

In one app, the buttons display at most 6 characters. Hence, some translated words do not display correctly. Would it be possible to:
A) remove the character limit, and to prevent text being too long either:

  1. limit the text to reaching the outside of the borders of the box
  2. change the font size (dynamically?) to fit the new word into the space (in density independent pixels, dps) limit.

a limitation of translator

Screenshot_WeChat_20210107-194634
I cant translate the message of wechat. but the other txt in wechat can be translated.l really hope you can solve this technology problem.l will donate you for your help.thank you for reading.

Chinese app not translated QQ

I enabled the following settings for it, but it did not help. All applications are translated except QQ
I turned on Aggressive translation and overide global settings

Android S (12) compatibility / Twitter compatibility

I am having issues with this on Twitter (the only app I need it for) which I'm not sure if it's how Twitter works or if it's a change in Android S

Nothing happens when the app is selected and enabled, enabled agressive mode and still nothing.

More details can be provided if needed. Thanks!

Ridibooks not being translated

Ridibooks is korean webnovel platform. Alltrans was able to translate it previously (Android 11, Magisk 23.1) using both Google Translate and the Microsoft Azure Translator AP when I was in Pixel Experience 11. But now, it cannot translate in either of the translator option. Still on Android 11 but changed the OS to Havoc 14.3 OS.

Screenshot_20220220-201035_Magisk
Screenshot_20220220-201026_EdXposed_Manager
Screenshot_20220220-201021_EdXposed_Manager

Need Help Regarding Sharepreference

Actually i m making a module which have its data on preference.xml but as we knw we cant read sharepreference in above sdk 23 so any soloution for this i really appericate if you coul help me

Back akhilkedia

Your app is very important for a lot of people 😞
Some information verified by me.

Lsposed 1.8.6-6919
Use correct pkg name for system_server (#2580)
Allow hooking processes of android package besides system_server
system_server: uid=1000 pkg=system proc=system
ChooserActivity,ResolverActivity: uid=1000 pkg=android proc=android:ui,system:ui

After this update com.android.providers.settings For many, this package is not marked in lsposed

so now with previous versions it keeps checked I tested
1.9.6: A13: Lspatch working perfect, Lsposed only works with specific apps like Focus for Reddit, in another rom a13 not even Focus worked
1.9.5: A13: in this rom that 1.9.6 didn't work, this version worked but only in specific ones like focus

Android Q compatibility

Hi, I'm desperate to make the app work. I have Android Q and EdXposed installed (sandhook). I followed the instructions but the app doesn't translate. I have valid azure key (although I had to select different region than global as it was allowing to create the form when selecting it). Please, could you let me know what settings/EdXposed version you have been running during the tests?

can't translate Ozon.ru app

it used to be able to translate this app, but I am not sure why it stopped working, I was sing it on the same device maybe different android version but currently on A13, I have tried every different configuration possible with no luck, maybe you can take a look at the logcat provided here, while grabbing the logcat enabled the module, enable the app, downloaded both languages from RU to ENG, then opened the app, I this logcat can provide useful info.

logcat.txt

Support other app

Please support app for medicine like medscape or amboss or kindle

The module does not work in LSPosed

Enable the system framework in this and only that, but it seems to be that it does not work, is there anything I can do? I would appreciate if you could also explain how to do logs or tell me the information needed to provide it

Add Traditional Chinese

Traditional Chinese and Simplified Chinese are different
Retranslate and add Traditional Chinese Thanks

Chinese traditional

Can you add Chinese traditional to the settings “Translate to Language” ? please

Crash on launch

Generated by AppErrorsTracking 1.3(6)
Project URL: https://github.com/KitsunePie/AppErrorsTracking
===============
[Device Brand]: Xiaomi
[Device Model]: POCO F1
[Display]: TQ3A.230805.001 release-keys
[Android Version]: 13
[Android API Level]: 33
[System Locale]: en_CA
[Process ID]: 8069
[User ID]: 0
[CPU ABI]: arm64-v8a
[Package Name]: akhil.alltrans
[Version Name]: 1.9.6
[Version Code]: 196
[Target SDK]: 30
[Min SDK]: 19
[Error Type]: JVM
[Crash Time]: 2024-06-28T15:00:20.288
[Stack Trace]:
java.lang.SecurityException: Unknown calling package name 'akhil.alltrans'.
	at android.os.Parcel.createExceptionOrNull(Parcel.java:3011)
	at android.os.Parcel.createException(Parcel.java:2995)
	at android.os.Parcel.readException(Parcel.java:2978)
	at android.os.Parcel.readException(Parcel.java:2920)
	at com.google.android.gms.common.internal.zzac.getService(com.google.android.gms:play-services-basement@@18.0.0:9)
	at com.google.android.gms.common.internal.BaseGmsClient.getRemoteService(com.google.android.gms:play-services-basement@@18.0.0:14)
	at com.google.android.gms.common.internal.BaseGmsClient$LegacyClientCallbackAdapter.onReportServiceBinding(com.google.android.gms:play-services-basement@@18.0.0:2)
	at com.google.android.gms.common.internal.zzg.zzd(com.google.android.gms:play-services-basement@@18.0.0:1)
	at com.google.android.gms.common.internal.zza.zza(com.google.android.gms:play-services-basement@@18.0.0:4)
	at com.google.android.gms.common.internal.zzc.zze(com.google.android.gms:play-services-basement@@18.0.0:3)
	at com.google.android.gms.common.internal.zzb.handleMessage(com.google.android.gms:play-services-basement@@18.0.0:31)
	at android.os.Handler.dispatchMessage(Handler.java:106)
	at android.os.Looper.loopOnce(Looper.java:201)
	at android.os.Looper.loop(Looper.java:288)
	at android.app.ActivityThread.main(ActivityThread.java:7922)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:548)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:941)

Is Hebrew supported?

Hello, I've noticed that none of the Hebrew apps I've checked translate into other languages. Is it possible to fix this?

Not working on Android 10, different devices

Hello, I've been trying to get AllTrans to work on Android 10 without success.
I think errors are the same, I would appreciate it if you could take a look at the logs.

I have previously used AllTrans on Android 12 and it worked without issues.

Running version 1.9.5 and tried lower versions as well. Older versions didn't work either but didn't give any java errors in lsposed log. None of the apps worked.

2 devices that I tried it on with Android 10 were:
OnePlus 5, running OxygenOS 10.0.1
Sharp Aquos S2, running LineageOS 17.1
LSPosed_2022-11-15T16_20_48.499.zip
logcat_11-15-2022_16-19-59.txt
logcat_11-15-2022_16-19-53.txt
LSPosed_2022-11-15T16_21_07.237.zip

Android Q support?

This is an awesome super useful module. Please continue its development for Android Q. It doesn't work on Q right now

update android13

hello man, you've been missing without updating the app for new versions and I really like your app :/ any news on when a new update will come out? on a13 it doesn't work on all apps, just some google play

the translated app is stuck in opening screen

after installing and using the yandex key and marking the app(com.facebook.mlite), the app is stuck in opening screen. I restarted the phone and clear translation cache,but after that did not want to display the screen just a black screen.

xposed installer v3.1.5, all trans v1.40, framework 89,Android 5.1 (Lollipop, API 22),arm64
i've grab the error log.here it's.
com.facebook.mlite.log.txt

[Not issue, but question] Possibility to export strings that were translated?

This could be very exciting to combine with the Hanzi2Anki project:
https://github.com/danielt998/HanziToAnki.
Essentially, generating flashcards for studying Chinese from the vocab inside an app.

I got the impression that with AllTrans, strings were translated only when a new activity/screen in an app was loaded (and not in advance) - would this allow detected strings to be grouped (by activity name)?

Going one step further, would it be possible to do the same for the Android system? E. G. Grab the strings for the 1) settings menu, 2) quick access tiles (flashlight, wifi), etc.

I guess Android has to load these strings from a file though, and is open source - thus it should be possible to get all of these. Regardless, grouping words by activity/screen and exporting them would be fantastic.

Translation of numbers (in forced translation)

A text-input field has e.g. my phone number usually, and forced translation with AllTrans actually turns the numbers into words (so my phone number is like thirteen billion fifty two million.....).

Whilst it's quite amusing, it'd be great if there could be an option to omit numbers from translation (should they need translating, anyway?). Turning numbers into words means that the text-input breaks, so I have to disable AllTrans for that app and clear the cache to remember & input my number.

All trans font color issue. (Changes color from the original app text color to a dark text) making it unreadable

Please can you add the option to change the translated text color, all translate in some apps, changes the text to black instead of maintaining the original font color. This make the translated text unreadable. For example the original app has a white text font on black background. But Al translate shows the translated text in black.

Attached below are videos, logs, screenshots and link to the app
The Chinese Tik Tok app @akhilkedia @bethelmelesse

THE TRANSLATED TEXT
Screenshot_20230505-163811

THE NORMAL APP TEXT(UNTRANSLATED)
Screenshot_20230505-192145

Normally the app font color is white, no matter any live streaming background.

logcat_05-05-2023_17-20-50.txt
logcat_05-05-2023_17-01-36.txt

Texts Overlapping

Basically title.

The only part out of norm that I know of is that I'm unable to enable module for Settings Storage.

Aggressive Mode (Non-Aggressive only translates partly)
Android 13
MIUI Global 14.0.5
AllTrans 1.9.6
Magisk Kitsune 27001
LSposed 1.9.3_mod (7244) - Zygisk

Screenshot_2024-04-29-19-10-34-013_com dragon read

Translation is not working

Hi Akhil,
Thanks for developing such a useful application. I have just installed it yesterday but I could not able to make it work.
I want to translate TaoBao app . Following are platform details

  • OPPO Reno 2 Z / color OS 11.1 /Android 11
  • Download and install Taichi! 1100_10141326- release from virtualxposed
  • Installed AllTrans_19.5_1644577949132.apk from Ctfile site
  • Used google and microsoft azure translator
  • All trans is enabled in Taichi
  • TaoBao installed from within Taichi
    -Tested it with other chinese app from within Taichi! but didnt work

Can you please advise, is there anything i need to differently
Thanks, DK

I use redmi2 prime

I use redmi2 prime, i installed xposed & downloaded alltrans but it doesn't install..... it keep on showing installing.... what to do..... i have lolipop 5.1.1

4 new fracture request DeepL free api, floating bubble for translate, more alternative keys for engine, pick different engine per app

1️⃣Feature request:add DeepL API translator - it has free API version with limit 500k chars/mth and he is one of the best and beats google,Microsoft,Yandex etc by a head. Lots of tests prove it and it has a lot of potential.
DeepL get free api

2️⃣ Feature request:add some flying bubble for translate or show orginal text. This will help save API queries will give the ability to compare translated text and sometimes translated text destroys URL links that would fix this. It doesn't necessarily have to be a bubble, it could be a gesture, key or intent but a flying bubble would be the best option.

3️⃣feature request: the ability to add several alternate API keys for each engine and switch to them when the main/previous one reaches the limit.

4️⃣and last: the ability to choose different translation engines for each application. Example: for applications that require more accurate translations e.g. messengers,app interface (settings etc) I will use the better or paid one and for those that contain a lot of text and I don't care about a very good translation I will use the free ones e.g. forums,news.

Alternative

What's the current alternative since AllTrans' development is dead?

Inline links within text get changed to plaintext

Inline links within the text are changed to plaintext.
This happens during the translation step, when all links are lost.
Perhaps the links can be added at the end with some extra text?
Or perhaps translation should be split at link boundaries, translated separately, and then re-joined.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.