kiwix-desktop icon indicating copy to clipboard operation
kiwix-desktop copied to clipboard

Buttons in toolbar drawn incorrectly in right-to-left layout

Open asashnov opened this issue 3 years ago • 10 comments

Found on current 'master' (ca776b46)

Steps to reproduce:

  1. Run Kiwix application with right-to-left interface layout by adding -reverse CLI option
  2. See the buttons in toolbar
  3. Open any .zim file from library
  4. See the buttons in toolbar again

Actual result:

Screenshot from 2021-02-12 20-10-29

Screenshot from 2021-02-12 20-10-38

Expected result:

Graphical items in toolbar should not overwrite each other, no duplicate drawings.

Additional info

There is another issue about Back/Forward buttons order: #595

asashnov avatar Feb 12 '21 13:02 asashnov

@asashnov and the icons should be on the right!!!

kelson42 avatar Feb 12 '21 13:02 kelson42

@kelson42 Which icons did you ment in your previous comment?

Icons inside tab headers (close button and the content web page icon) are reverted- that's right, this is a standard behaviour of QTabbar. At least, on my Linux.

On Windows it can be different, need to check with Kiwix.

One of the example I manage to find on the Internet with Arabic interface is ESET:

web_phishing_zoom75

Source: https://help.eset.com/ees/6/ar-EG/index.html?idh_config_antiphish.htm

asashnov avatar Feb 12 '21 17:02 asashnov

Qt manual says (https://doc.qt.io/qt-5/qtquick-positioning-righttoleft.html):

The general rule of thumb is that content (like photos, videos and maps) is not mirrored, but positioning of the content (like application layouts and the flow of visual elements) is mirrored. ... Also, there are some special cases you may need to take into account where right-to-left language speakers are used to left-to-right positioning, for example when using number dialers in phones and media play, pause, rewind and forward buttons in music players.

But it says nothing clearly about tabs header.

So I'm confused here. I think we can rely on the default behaviour of QTabbar now, and may setLayoutDirection(Qt::LeftToRight); in Tabbar constructor if users ask us about it:

Screenshot from 2021-02-13 00-47-23

asashnov avatar Feb 12 '21 17:02 asashnov

This issue has been automatically marked as stale because it has not had recent activity. It will be now be reviewed manually. Thank you for your contributions.

stale[bot] avatar Jun 02 '21 16:06 stale[bot]

@asashnov One #525 is fixed, we shoukd really fix this one.

kelson42 avatar Dec 04 '21 04:12 kelson42

@asashnov Sorry for my lack of feedback. I did not meant the tab headers. I meant the context of the search box:

  • The text should be aligned right (like the suggestions)
  • Any magnify logo should be on the right as well

kelson42 avatar Feb 25 '22 12:02 kelson42

This issue has been automatically marked as stale because it has not had recent activity. It will be now be reviewed manually. Thank you for your contributions.

stale[bot] avatar May 02 '22 14:05 stale[bot]