Rockbox

  • Status Closed
  • Percent Complete
    100%
  • Task Type Bugs
  • Category Rbutil
  • Assigned To No-one
  • Operating System All players
  • Severity Low
  • Priority Very Low
  • Reported Version Rbutil git
  • Due in Version Undecided
  • Due Date Undecided
  • Votes
  • Private
Attached to Project: Rockbox
Opened by tomers - 2010-04-07
Last edited by bluebrother - 2010-04-07

FS#11180 - On windows layout does is not aligned to the right when language is set to Hebrew

In main(), there’s the following code which automagically sets GUI layout to be aligned from right to left when the language is Hebrew (and in the future, Arabic):

  if(applang == "he")
      app.setLayoutDirection(Qt::RightToLeft);

When the application loads for the first time, there’s no configuration yet, and the application chooses the interface language according to the system settings. In Windows, it correctly detects that Hebrew is to be used, if that is the case, but it doesn’t sets the layout direction accordingly.
Only after the settings are saved (when the application is closed), it will set layout direction correctly upon application load.

Tested on rbutil r25471, taken from http://tinyurl.com/rbutil-dev/.

See attached screenshot.

Closed by  bluebrother
2010-04-07 18:10
Reason for closing:  Fixed

This doesn’t surprise me, looking at the code. I bet it’s caused by checking QLocale::system().name() to match “he”. However, the documentation for QLocale::name() says:

QString QLocale::name () const
Returns the language and country of this locale as a string of the form “language_country”, where language is a lowercase, two-letter ISO 639 language code, and country is an uppercase, two-letter ISO 3166 country code.

Rockbox Utility, however, stores the language as the same string the translation file uses. In case of hebrew this is “he”, so it does match after a restart. I never liked this special casing for hebrew.

Loading...

Available keyboard shortcuts

Tasklist

Task Details

Task Editing