dmMaze / BallonsTranslator

深度学习辅助漫画翻译工具, 支持一键机翻和简单的图像/文本编辑 | Yet another computer-aided comic/manga translation tool powered by deeplearning
GNU General Public License v3.0
2.75k stars 182 forks source link

How to add another language translation? #346

Open WERvgdf opened 10 months ago

WERvgdf commented 10 months ago

Hi, i would like to add another language into this. how can i? I'm looking to add a translation English to (Malayalam, Tamil and Hindi). all these are Indian languages. can any one here please help me?

bropines commented 10 months ago

Hi, i would like to add another language into this. how can i? I'm looking to add a translation English to (Malayalam, Tamil and Hindi). all these are Indian languages. can any one here please help me?

Write to me the required language codes, I will add them to the list and make a pull request

WERvgdf commented 10 months ago

actually im not an expert in coding. image image image

i believe you asked about this code..

Hindi - hi Malayalam - ml Tamil - ta

dmMaze commented 10 months ago

The following example showcases how to add 'Thai':

First, add the language name that will be displayed in UI: https://github.com/dmMaze/BallonsTranslator/blob/5e3fa943903f5a653563e54806d6855395be33ad/modules/translators/base.py#L41

Then find the translator script (google translator here) and register its language code like this: https://github.com/dmMaze/BallonsTranslator/blob/5e3fa943903f5a653563e54806d6855395be33ad/modules/translators/trans_google.py#L305

You need to check the corresponding translator's document to find out the correct language code.

bropines commented 7 months ago

@WERvgdf completed. Close issue. Thanks