Skip to content
This repository has been archived by the owner on Sep 28, 2023. It is now read-only.

Arabic lang #107

Closed
OmarAglan opened this issue Sep 19, 2018 · 19 comments
Closed

Arabic lang #107

OmarAglan opened this issue Sep 19, 2018 · 19 comments

Comments

@OmarAglan
Copy link

Hello i was playing this game for a while and have been asking can this game support arabic lang?
if its support It i will start working on adding arabic file

@raz0rknaif
Copy link
Contributor

Yes, it should support Arabic. We would need a font and to do stuff with the calendar and numbers tho. Please begin)

@the3dfxdude
Copy link
Owner

No that is not really true. If you want support, the written language must be able to support an 8-bit character encoding written left to right. Please identify a usable 8-bit character encoding that can be used left to right.

@raz0rknaif
Copy link
Contributor

raz0rknaif commented Sep 19, 2018

ISO/IEC 8859-6 ?

Ah OK. left to right... if I remember right, at the mosque there were books written from left to right in Arabic.

@raz0rknaif
Copy link
Contributor

Perhaps someone else has a better answer, but there are Unicode Bidirectional Formatting Codes such as 202D (LEFT-TO-RIGHT OVERRIDE (LRO) which causes an RTL script to be written LTR.

For example,

LTR Override

The &#x202D code will cause Hebrew to be written left to right until the end "pop" character ‬. The example text is the first four letters of the Hebrew alphabet which begins with the letter alef (א).

Normal RTL: אבגד
Code: ‭אבגד‬

Result: ‭אבגד‬

Here is an English example,

RTL Override

The &#x202E code will cause English to be written right to left until the end "pop" character ‬. The example text is "Hello World."

Code: ‮Hello World‬
Result: ‮Hello World‬

It is indeed "written in the other direction," but the letters are still written "normally." Dunno. Maybe there is a "backwards" Arabic font.

@the3dfxdude
Copy link
Owner

The po file ought to be encoded in UTF-8 for all practical purposes. When running the game, gettext will return messages encoded in the system encoding, which let's also say it's UTF-8 for practical purposes. But the game's font code only supports 8-bit character encodings (not multibyte). So we then convert from gettext (UTF-8) to 8-bit single code. We need to identify a code set that is compatible, where we can feed an array of 8-bit words into the render function and get out what we would need. Right now I don't see any code set that words. I think we can only do left to right, without any kind of special annotations.

@OmarAglan
Copy link
Author

OmarAglan commented Sep 20, 2018

i don't like it?
arabic works with rtl only.
i can reverse the words but it will not be good thing to do!

@the3dfxdude
Copy link
Owner

Nope. Reversing rtl purposely at any point seems like a failing solution.

Is it possible that latin characters ltr are appropriate in your locale? It's only a minor solution, but we need your feedback if it's even possible to consider.

Does ISO/IEC 8859-6 cover all the arabic characters in your locale? Note if we were to go this route, someone will need to update the Font code in the game to support rtl.

@OmarAglan
Copy link
Author

Is it possible that latin characters ltr are appropriate in your locale? It's only a minor solution, but we need your feedback if it's even possible to consider.

yes i would say it support it

Does ISO/IEC 8859-6 cover all the arabic characters in your locale? Note if we were to go this route, someone will need to update the Font code in the game to support rtl.

yes it does and it will be great way to start

@OmarAglan
Copy link
Author

also note i am not a programer so i can't help in any programing sadly :(

@the3dfxdude
Copy link
Owner

That's ok. No problem you are not a programmer.

I will accept a translation of arabic using latin script, if there is at least one more supporting opinion shared that this is acceptable to the arabic language community. Loki please note this means that the message file will be UTF-8, and should have latin character script when submitted. Omaranwa, feel free to contribute anything you could towards translating when Loki or I gives a go-ahead.

Supporting ISO 8859-6 is going to be a difficult project, so I won't accept a translation targeting that font/codeset until the details are worked out.

@OmarAglan
Copy link
Author

I will accept a translation of arabic using latin script, if there is at least one more supporting opinion shared that this is acceptable to the arabic language community. Loki please note this means that the message file will be UTF-8, and should have latin character script when submitted. Omaranwa, feel free to contribute anything you could towards translating when Loki or I gives a go-ahead.

ah, i'm sorry for this but i will not write arabic in latin character script, because its not the right way to do this.
also i will add arabic as it is and will wait for proper RTL support.

@OmarAglan
Copy link
Author

Supporting ISO 8859-6 is going to be a difficult project, so I won't accept a translation targeting that font/codeset until the details are worked out.

i can wait for it.

@the3dfxdude
Copy link
Owner

OK thanks for the clarification. I was trying to be doubly sure.

@raz0rknaif
Copy link
Contributor

Good evening gentlemen. Just my two cents:

I am also not a programmer, so from my perspective, I see no hinderance to submitting an arabic translation. I don't want to say, "let's do this work and let the programmers deal with the rest." I grealy admire the techinical skills involved in dev support for the multilingual support. But I think there is no harm in having an ar.po. in /po.

To be honest, I am very ethusisastic about people doing a translation. I am not checking in, I am just super curious and excited about progress to a translation lol. So I would prefer not waiting. I can wait for support in the code, but "I want the translation." I wouldn't deny someone the opportunity to submit a translation. I hope to work things out to get this .po file accepted. Even at the minimum, I would like to just read it myself to better understand how the English text is interpreted and translated.

On another note,

I don't like 8859-6 because it doesnt support Perisan and Urdu. I assume all Arabic dialects are supported by 8859-6, but it is so sub par in terms of languages using an Arabic script. I'm not sure of the technicalities, but I wouldn't want to add support for 8859-6 when a Persian (et cetera) translation is offered or submitted.

Personally, I would prefer to work on the Russian translations further, such as the graphics, audio, and remaining unmarked English text. Id est a complete translation.

@the3dfxdude
Copy link
Owner

No, there are issues with supporting something half-way. I'm not going to accept something we cannot properly support. We either plan to get it done right, or we simply say we can't do it now.

This user says ISO 8859-6 supports his locale. This must mean he is not from Persian or Urdu regions. If someone wants to have Persion or Urdu, then we need to ask again which 8-bit codesets would work. If there aren't any, then again the answer is simply we can't do it right now.

@raz0rknaif
Copy link
Contributor

raz0rknaif commented Sep 26, 2018 via email

@OmarAglan
Copy link
Author

@raz0rknaif i will add arabic and i will wait for proper rtl support

@raz0rknaif
Copy link
Contributor

raz0rknaif commented Sep 27, 2018 via email

@the3dfxdude
Copy link
Owner

This appears to be an offer for translation. Please work with raz0rknaif on how to work on the translation. Closing.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants