diff options
author | Bogdan Gheorghe <gheorghe> | 2007-12-03 20:38:23 +0000 |
---|---|---|
committer | Bogdan Gheorghe <gheorghe> | 2007-12-03 20:38:23 +0000 |
commit | 0d47a69d8138a3f8cf8a1ac8edbc9cb5fbe494ec (patch) | |
tree | 148fd0ae554fb30e98ad0c785ff9cc14f24f81d1 /bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/MenuItem.java | |
parent | f21ad18a7d573aacd9bffb0c931c9379021fdb2b (diff) | |
download | eclipse.platform.swt-0d47a69d8138a3f8cf8a1ac8edbc9cb5fbe494ec.tar.gz eclipse.platform.swt-0d47a69d8138a3f8cf8a1ac8edbc9cb5fbe494ec.tar.xz eclipse.platform.swt-0d47a69d8138a3f8cf8a1ac8edbc9cb5fbe494ec.zip |
208427 GTK-BIDI: RTL support in MenuItems
Diffstat (limited to 'bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/MenuItem.java')
-rw-r--r-- | bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/MenuItem.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/MenuItem.java b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/MenuItem.java index e5d2675698..6713fe7d3d 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/MenuItem.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/MenuItem.java @@ -832,7 +832,8 @@ public void setText (String string) { String accelString = ""; int index = string.indexOf ('\t'); if (index != -1) { - accelString = string.substring (index, string.length()); + boolean isRTL = (parent.style & SWT.RIGHT_TO_LEFT) != 0; + accelString = (isRTL? "" : " ") + string.substring (index+1, string.length()) + (isRTL? " " : ""); string = string.substring (0, index); } char [] chars = fixMnemonic (string); |