Few changes to allow the support of right to left languages#658
Few changes to allow the support of right to left languages#658AmrBarghouthi wants to merge 3 commits intoUltimaker:mainfrom
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? |
| visible: false | ||
| sourceSize.width: parent.width | ||
| sourceSize.height: parent.height | ||
| layer.enabled: true |
There was a problem hiding this comment.
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