Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Localization: Polish #22

Open
waydabber opened this issue Jan 31, 2024 · 34 comments
Open

Localization: Polish #22

waydabber opened this issue Jan 31, 2024 · 34 comments
Assignees

Comments

@waydabber
Copy link
Owner

This is the thread for the Polish localization.

@marcinkardas
Copy link

Hi @waydabber. I will take care of the Polish translation and it will be available soon. :)

@waydabber
Copy link
Owner Author

Thank you! :)

@MStankiewiczOfficial
Copy link
Contributor

Hi, can I help with the Polish translation? :)

@waydabber
Copy link
Owner Author

Hi @MStankiewiczOfficial - of course! Thank you!

You can simply download the localization file from the repo and attach the updated xcloc file so I can process it. Alternatively, you can fork the repo, work on it as your time allows and then do a Pull Request.

Let me know if you need any assistance or have questions! :)

@MStankiewiczOfficial
Copy link
Contributor

MStankiewiczOfficial commented Jun 27, 2024

Ok, I have already started the translation, but I ran into a small problem.
In Polish, it often happens that we conjugate differently the nouns that occur after the numeral. And I have a bit of a problem with %lld pixels HiDPI (%lld pixels LoDPI), %lld Trial Days Left and %u bits per sample because the translation for different numbers will be different:
for %lld pixels HiDPI (%lld pixels LoDPI):

  • 0 - "0 pikseli" ("0 pixels")
  • 1 - "1 piksel" ("1 pixel")
  • 2-4 - "2 piksele" ("2 pixels")
  • 5-21 (yes, that's not a mistake) - "5 pikseli" ("5 pixels")
  • 22-24 - "22 piksele" ("22 pixels")
  • 25-31 - "25 pikseli" ("25 pixels") etc.

Same for %lld Trial Days Left:

  • 0 - "Pozostało 0 dni okresu próbnego" ("0 Trial Days Left")
  • 1 - "Pozostał 1 dzień okresu próbnego" ("1 Trial Day Left")
  • 2-4 - "Pozostały 2 dni okresu próbnego" ("2 Trial Days Left")
  • 5-21 - "Pozostało 5 dni okresu próbnego" ("5 Trial Days Left")
  • 22-24 - "Pozostały 22 dni okresu próbnego" ("22 Trial Days Left")
  • 25-31 - "Pozostało 25 dni okresu próbnego" ("25 Trial Days Left") etc.

If you'd like, I can translate everything as for most numbers (5-21, 25-31, 35-41 etc.), but I warn that this is usually perceived by users as unprofessional as it sounds like it is translated automatically.

And btw, I suggest in such strings as %@mm x %@mm or %@x%@ to replace x with × symbol so that it is %@mm × %@mm or %@×%@ - in all languages :)"

@waydabber
Copy link
Owner Author

Is it possible to translate it differently like "x number of pixels LoDPI", or something like that so you don't have to conjugate the "pixels" word itself? I am not sure if such tricks work in Polish.

An other way would be to use XCode's vary by plural feature for the translation. This should let you define different strings for different numerals like this:

Screenshot 2024-06-27 at 22 06 17

The problem is that the xcloc format does not support this, only xcstrings which is a completely different format and XCode does not support exporting localizations for translators in that. I can provide an xcstrings file which contains all translations combined, but I am not sure how will I be able to import that back to the app easily. And when we add this new feature to the translation, I won't be able to export the translation in xcloc ever again. So this would require a complete rethinking of how to do translations and impact every translator. It would still be possible, but in this case everybody must work on a single shared xcstrings file in this repo and interact with it by forking and doing pull requests, adapting more flexibly when the source text changes.

@marcinkardas
Copy link

Hi, can I help with the Polish translation? :)

Cześć! Czy mógłbyś przejrzeć moje tłumaczenie i sprawdzić ewentualne błędy? Jest to trochę skomplikowany temat do tłumaczenia i niektóre rzeczy specjalnie pominąłem, bo nie rozumiałem kontekstu.

Możemy podzielić się elementami do przetłumaczenia - nie zdawałem sobie sprawy z tego ile w tej aplikacji jest linii do tłumaczenia i trochę mnie to przerosło, stąd ostatnio brak progresu. 👀

@MStankiewiczOfficial
Copy link
Contributor

MStankiewiczOfficial commented Jun 28, 2024

Hi @waydabber!

Is it possible to translate it differently like "x number of pixels LoDPI", or something like that so you don't have to conjugate the "pixels" word itself? I am not sure if such tricks work in Polish.

Yes, I know this trick, but there is a problem — it doesn't work with all sentences and when I would like to use it, sentences would be very long.

The problem is that the xcloc format does not support this, only xcstrings which is a completely different format and XCode does not support exporting localizations for translators in that.

OK, I understand, but maybe you could just add some additional strings that will not be changing in other languages, but only in Polish and other languages that have that?


Cześć @marcinkardas!

Czy mógłbyś przejrzeć moje tłumaczenie i sprawdzić ewentualne błędy?

Oczywiście. Faktycznie zauważyłem kilka błędów, ale są to naprawdę drobnostki, które szybko się poprawi ;)
W ogóle myślałem, że powinniśmy sobie zrobić taki słownik, jaki jest na niemiecki, żebyśmy wiedzieli jakich słów używać dla konkretnych funkcji.

Możemy podzielić się elementami do przetłumaczenia

Myślę, że to świetny pomysł. Czy możemy to obgadać na jakimś komunikatorze? Masz może Matrixa lub Discorda?

@waydabber
Copy link
Owner Author

OK, I understand, but maybe you could just add some additional strings that will not be changing in other languages, but only in Polish and other languages that have that?

The localization and string substitution is entirely transparent so the app and the code actually does not deal with the language variants at all.

But as a test I added a one-few-many-other variant to a Polish string and then tried exporting the xcloc. It seems like the xcloc can actually accommodate the variants properly. The problem is you can't add the variants in the xcloc file, only me.

What we should do is this: you should send me your current progress (a zipped xcloc file) - I'll import it into the app and export an xcstrings file with which you can continue working and add variants as well. When you are done, I'll extract the Polish text from the xcstrings file with some tricks afterwards (it's pure json so it is possible), import it into the project and then can even export an xcloc file which now will have the variants (for existing strings). For future new strings I can add plural variants when needed myself as a placeholder.

As a test, I attached an xcstrings file (this contains all translations). Just open it, select Polish and try to add plural variants and see if it works (right click + Vary by Plural).

Localizable.xcstrings.zip

@MStankiewiczOfficial
Copy link
Contributor

MStankiewiczOfficial commented Jul 3, 2024

@waydabber maybe it would be easier if you just add these strings as a new lines and named them e.g. a, b, c etc. for the different forms? I'm afraid that by the time I translate these sentences, there will already be a new commit and this file will be out of date 😅

@waydabber
Copy link
Owner Author

No worries, I can import outdated files quite well, the Swift build process will take the file and maybe discard or flag outdated items which I can fix manually if needed.

But I am now deep into refactoring stuff, improving and consolidating internals + doing technology update (as I'll drop Monterey support, I can now update/rewrite some legacy code), so I am not focusing on adding new features (changing localized texts). No new releases are to be expected for a while now during summer (aside from service releases if there is some serious bug discovered or pre-release versions).

@MStankiewiczOfficial
Copy link
Contributor

Ok, in that case you can provide me with the proper file that I should translate, I will only make the changes that are related to noun and adjective conjugations based on numerals and I will send it to you by email. Then I will get down to further translation :)

@waydabber
Copy link
Owner Author

Well, if there is no change in Polish translations (in xcloc) at your end since I attached the xcstrings file, you can go ahead and work in that. When done, just attach the result here so I can process it.

@MStankiewiczOfficial
Copy link
Contributor

Hi, these are probably all the strings that needed several versions added. You can download them from here.

@waydabber
Copy link
Owner Author

Thank you @MStankiewiczOfficial! I imported this into the project and updated the GitHub repo accordingly. Sorry for the delay!

@MStankiewiczOfficial
Copy link
Contributor

I have a kind request - as if you were to publish some update, and you knew about it two days before, please let me know because I would like to see some of the new translations in the next update - then I will do a commit.
I would appreciate it.

@waydabber
Copy link
Owner Author

Hi there, I can build a version with the translations added any time for review. If you reached a certain level of completion and would like a build, let me know.

I am not sure when the next version will be out as I am doing fundamental technological upgrades during the summer (all internal things, rewrite, refactoring, future-proofing etc).

@MStankiewiczOfficial
Copy link
Contributor

Hi. If you could please build a new version. It contains the most important translations, as well as the fixes I wrote about in the pull request. I think that next month there will be ready the most important translations, and by the end of September the whole application will be translated. At the moment I am focusing on the names of the options, and only later I will deal with their descriptions.

@waydabber
Copy link
Owner Author

@MStankiewiczOfficial - here is a build with the latest translations: https://github.com/waydabber/BetterDisplay/releases/download/v2.0.0-pre-release/BetterDisplay-v2.3.10-b31323-pre.zip

@MStankiewiczOfficial
Copy link
Contributor

MStankiewiczOfficial commented Jul 23, 2024

Thank you very much. Conclusion very important: test before releasing because if I didn't test, it would go with such an bug 😂
SCR-20240723-kvih


I have already solved this problem, while there is another - the text does not fit in these buttons (screenshot below), and it is not possible to shorten it. Is it possible to somehow change the layout of these buttons in the next version?
obraz
obraz

@waydabber
Copy link
Owner Author

Hmm. The problem seems to be with those buttons is that there is no more room for the auto-layout to expand the buttons horizontally. But if you resize the window, the contents should be visible. With a small window size even the English version gets truncated, so I think this is normal/tolerable.

Screenshot 2024-07-23 at 14 49 58

@waydabber
Copy link
Owner Author

waydabber commented Jul 23, 2024

Note: simpliciations that preserve the core meaning is fully acceptable in this case. Instead of "Reset App Settings" you can either use "Reset App" or "Reset Settings", instead of "Restart App" you can simply use "Restart", "Quit App" can be "Quit", "Reset Warning Dismissals" can be "Restore Warnings" for example. So if you have space constraints (it is very hard to avoid in any of the languages in some cases), just find a creative alternative that points the user to the right direction.

@enormous-rat
Copy link
Contributor

@waydabber
Hey guys, could you take a look at PR #52 I just created? It's a tiny fix for annoying translation of "(Empty string)".

@waydabber
Copy link
Owner Author

Of course @enormous-rat - thank you! Also, feel free to contribute more, it would be great to reach 100% with Polish. I was considering removing localizations from the app below 60% as I am not sure how good it is to have a very mixed UI. Polish now stands at 34%. No decision about this yet though. Let me know what you guys think!

@waydabber
Copy link
Owner Author

I added the fix to the app. The next release will not have this issue (you can switch to internal pre-releases under Settings/Application/Updates to get the fixed release sooner - for sure there will be one in the coming days).

@MStankiewiczOfficial
Copy link
Contributor

Of course @enormous-rat - thank you! Also, feel free to contribute more, it would be great to reach 100% with Polish. I was considering removing localizations from the app below 60% as I am not sure how good it is to have a very mixed UI. Polish now stands at 34%. No decision about this yet though. Let me know what you guys think!

I think that while the removal of less translated languages is a good move, I would very much like to leave the Polish language, as I am in the process of translating it. At this point I have about 60% of the strings translated on my computer, and more are coming in all the time.

@enormous-rat
Copy link
Contributor

Hi @MStankiewiczOfficial, that’s great news. Let me know if you need an extra pair of hands for translating the remaining strings - maybe I could help.

@waydabber
Copy link
Owner Author

That's great progess @MStankiewiczOfficial! From time to time you might want to post an update or a zip file here so I can import the completed parts! :)

@MStankiewiczOfficial
Copy link
Contributor

Hi @MStankiewiczOfficial, that’s great news. Let me know if you need an extra pair of hands for translating the remaining strings - maybe I could help.

Cześć @enormous-rat! Byłbym wdzięczny, jakbyś zajął się tłumaczeniem opisów/szczegółów poszczególnych funkcji :)

That's great progess @MStankiewiczOfficial! From time to time you might want to post an update or a zip file here so I can import the completed parts! :)

Sure @waydabber, I'll upload a pull request soon ;)

@MStankiewiczOfficial
Copy link
Contributor

MStankiewiczOfficial commented Sep 3, 2024

Hey @waydabber, could you please build me a new version of app with the translation I uploaded recently?

And by the way - have you thought about uploading the translation to some translation platform, such as Codeberg Translate?

@waydabber
Copy link
Owner Author

@MStankiewiczOfficial - it's already in the v3.0.5 version: https://github.com/waydabber/BetterDisplay/releases 😄

We've been trying to use Crowdin for a while but did not really work out. Everybody likes his own platform it seems. Simply providing the .xcloc file (which has both .xcliff and .xcstrings embedded) seems to be the best way + using GitHub fits naturally to the development process.

@waydabber
Copy link
Owner Author

(but I don't know how Codeberg translate works and what are the benefits so it might work better than Crowdin).

@MStankiewiczOfficial
Copy link
Contributor

Thanks for the information. In that case, I'm just reporting that for some reason my app doesn't see this update - I'm on 3.0.4 all the time and even when I click "Check for updates" it shows that I have the latest version.

@waydabber
Copy link
Owner Author

Auto-update is still happening to pre-release subscribers only (set it under Settings/Application/Updates). If there are no serious issues, I will initiate the full rollout. :)

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

No branches or pull requests

4 participants