UniGetUI icon indicating copy to clipboard operation
UniGetUI copied to clipboard

[ENHANCEMENT] Define fallback languages for when translations are only partial

Open yrjarv opened this issue 1 year ago • 6 comments

Please confirm these before moving forward

  • [X] I have searched for my feature proposal and not found a work-in-progress/duplicate/resolved/discarded issue.
  • [X] This improvements refers to an existing feature. If you want to suggest a new feature, please use this template
  • [X] This improvements is not a bug. If you want to report a bug, please use this template

Describe the improvement

I have no clue how difficult or easy this would be to implement, but I suggest that we could define certain languages in the source code that would take over when another language is not fully translated. One example of that would be that until I'm done translating Norwegian Nynorsk (it's gonna take a while...) the missing strings can be shown with the Norwegian Bokmål translation instead of the English original string.

Of course, this would only be viable for languages that are pretty much identical (I'm guessing that applies to a few of the Spanish versions?), but it would certainly be a small quality of life improvement for users who are not fluent in English or just want a language they know for every string.

Describe how this improvement could help users.

This would help users to read languages know and that are similar to the one they chose as the app language.

yrjarv avatar Jan 29 '24 10:01 yrjarv

Would you mind giving me a little pointer on where the loading of the translations happens, so that I can maybe have a chance of fixing it myself? I can't really find much other than the translation files... @marticliment

yrjarv avatar Jan 29 '24 13:01 yrjarv

They are loaded on the wingetui\Core\tools.py file

marticliment avatar Jan 29 '24 14:01 marticliment

I think I have a solution, but how do I run it to make sure it works? And do you want me to add e.g. Catalan and Spanish as fallbacks for each other?

yrjarv avatar Jan 30 '24 07:01 yrjarv

how do I run it to make sure it works?

You can temporarily set two notoriously different languages one as fallback of each other and see if the missing strings on the first language are set to the secondary one.

I maybe thought this would work better not by having WingetUI choose which languages to show when a string is missing, but rather using Windows Settings language preferences to choose the fallback languages: image

marticliment avatar Jan 30 '24 10:01 marticliment

I see. I was more wondering how to run my version of WingetUI, because I have no clue how do do that... I'll look into the possibility of choosing fallbacks from language preferences in Windows.

yrjarv avatar Jan 30 '24 10:01 yrjarv

Ah, you can find a guide here: https://marticliment.com/wingetui/help/build-overview/

marticliment avatar Jan 30 '24 10:01 marticliment