Community
Participate
Working Groups
Created attachment 252572 [details] Bad layout_Prerefence Build ID: I20150408-1100 OS: RHEL 7.1 GTK Version: gtk2(2.24.22),gtk3(3.8.8) Steps to reproduce: 1.Click Windows -> Preference -> General -> Globalization 2.Set the "Graphical layout direction" and "Text direction" to "Right to left" 3.Restart the eclipse 4.Go to the Preference panel, Debug Configuration, Create New Project and Class Problem Description: After the setting, you could find below issues. 1.Bad layout could found on many panels, such as Preference,Debug Configuration 2.The GUI is partly mirrored 3.The Edit field Text direction didn't change to "RTL" Please refer to the attachments. Thanks.
Created attachment 252573 [details] Debug configuration
Created attachment 252574 [details] Edit field
Created attachment 252575 [details] Wrong display
Created attachment 252576 [details] Wrong icons display on Package Explorer view
Several observations: 1. I wouldn't suggest to focus on Linux platform for Bidi testing. In overwhelming cases customers using Eclipse UI are running on Windows platform. 2. GUI mirroring ("Graphical layout direction"), should work. You can alternatively run the Eclipse with -nl he or -nl ar or -dir rtl in the command line and see if you get the same results. If you get the same results and display is still not desirable, I would suggest to run the same test on Windows platform. 3. "Text direction" - controls all the contexts for which necessary API was called. Not all contexts should be affected by this property. Obviously all input fields showing plain text (i.e. name of the project) should be controlled. To enforce text direction in graphical control based on the preferences ("Text direction") one should use: org.eclipse.jface.util.BidiUtils as follows: In general: BidiUtils.applyTextDirection(graphicalWidgetOrControl, BidiUtils.BTD_DEFAULT); Several concrete examples: - org.eclipse.swt.widgets.Text BidiUtils.applyTextDirection(projectNameField, BidiUtils.BTD_DEFAULT); - org.eclipse.swt.widgets.ToolBar BidiUtils.applyTextDirection(psTB, BidiUtils.BTD_DEFAULT); - org.eclipse.jface.viewers.CheckboxTableViewer BidiUtils.applyTextDirection(fTableViewer.getControl(), BidiUtils.BTD_DEFAULT); - org.eclipse.jface.viewers.TreeViewer BidiUtils.applyTextDirection(treeViewer.getControl(), BidiUtils.BTD_DEFAULT); - org.eclipse.jface.viewers.CheckboxTableViewer BidiUtils.applyTextDirection(listViewer.getControl(), BidiUtils.BTD_DEFAULT); PS. Passing BidiUtils.BTD_DEFAULT means "take user preferences".
Mandy, can you check whether it looks better on Windows? Thanks.
(In reply to Dani Megert from comment #6) > Mandy, can you check whether it looks better on Windows? Thanks. Hi Daniel, On windows, the layout is good and GUI mirror could work on Windows. Thanks.
Some of the issues are already tracked by older bugs, e.g. bug 41474.
*** This bug has been marked as a duplicate of bug 41474 ***