-
-
Notifications
You must be signed in to change notification settings - Fork 185
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
Few changes to allow the support of right to left languages #658
base: main
Are you sure you want to change the base?
Conversation
I added a function to indicate the language direction to be used in QML files
|
I'm a bit confused as to why you would want to mirror images in right-to-left scripts? And the solution of adding a translated string may not be very robust either. It would be better to get this from the metadata of the translation. I think |
@GhostKeep image mirroring is going to be for stuff like arrows as for metadata of the translation I will look into it |
I update it the i18nIsRightToLeft function to get the direction from language metadata |
The only directional arrows that we have are really the folding arrows in the setting category headers. But those are not really related to any text, are they? |
@@ -20,6 +21,7 @@ Item | |||
visible: false | |||
sourceSize.width: parent.width | |||
sourceSize.height: parent.height | |||
layer.enabled: true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll change this to layer.enabled: mirror
to save some rendering performance. These images are used a lot (e.g. with every setting) so performance is important.
I can't seem to be able to get this to work. I added this property to the Dutch translation .po files (all 4):
Alternatively I also tried without the newline and space, in case that mattered (though I think Gettext filters that out):
I then recompiled the .po files to .mo files and printed the
However it still returns Setting the mirror property works, but setting it to depend on being right-to-left never mirrors the image. |
This to makes it possible to flip the image in RecolorImage which is needed for some icons when translating Apps to support Right to Left languages