Bug 187036 - [Workbench] TVT33:TCT[Workbench] 159: ar: 13.001120 Tool tips text does not have RTL reading order
Summary: [Workbench] TVT33:TCT[Workbench] 159: ar: 13.001120 Tool tips text does not h...
Status: RESOLVED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 3.3   Edit
Hardware: PC Windows XP
: P3 major (vote)
Target Milestone: 3.4   Edit
Assignee: Felipe Heidrich CLA
QA Contact:
URL: 159
Whiteboard: 3.3.1 deferred
Keywords: needinfo
Depends on:
Blocks:
 
Reported: 2007-05-15 11:51 EDT by CDE Administration CLA
Modified: 2008-04-10 17:17 EDT (History)
10 users (show)

See Also:


Attachments
13.001120-Wrong_Hover_order.jpg (31.62 KB, image/jpeg)
2007-05-15 11:51 EDT, CDE Administration CLA
no flags Details
13.001120-Correct_Hover_order.jpg (31.68 KB, image/jpeg)
2007-05-15 11:51 EDT, CDE Administration CLA
no flags Details
CDT icons (6.64 KB, image/gif)
2007-05-15 16:39 EDT, Vivian Kong CLA
no flags Details
09.001440.jpg (203.00 KB, image/jpeg)
2007-06-04 15:16 EDT, CDE Administration CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description CDE Administration CLA 2007-05-15 11:51:02 EDT
OS: Windows
Build date: 05112007
Component Name: CDT
Blocking: No
Tester Name: Noha
Steps to recreate the problem: Create a new workspace. Switch to the C/C++ Perspective: from the main menu go to Window -> Open Perspective -> Other and select C/C++
Problem description:
The tool tips text such as 'New C/C++ Project' does not have RTL reading order, however when I click anywhere else such as clicking on any of the main menus and then go back to the tool tips they become RTL enabled.

As discussed, this is probably a Platform/Base problem.

Thanks!
Vivian

Hi,
Updating with screen shots.

This is a general problem for all tooltips (including workbench toolbar buttons and view's local toolbar buttons). The switching reading order behavior happens to all strings with Engish mixed in Bidi words. Platform UI please take a look.

This article was reassigned from Category:''TVT Testcases''.
Comment 1 CDE Administration CLA 2007-05-15 11:51:19 EDT
Created attachment 67263 [details]
13.001120-Wrong_Hover_order.jpg
Comment 2 CDE Administration CLA 2007-05-15 11:51:23 EDT
Created attachment 67264 [details]
13.001120-Correct_Hover_order.jpg
Comment 3 CDE Administration CLA 2007-05-15 11:51:30 EDT
<cde:tctdetail>
Testcase: 
Project: WSW33
Component: CDE - Platform/UI
Priority: 2
Subject: ar: 13.001120 Tool tips text does not have RTL reading order
Article ID: 159
Originator: husseinn@eg.ibm.com
</cde:tctdetail>
Comment 4 Kim Horne CLA 2007-05-15 15:21:04 EDT
Not sure where to dump this one Tod...
Comment 5 Tod Creasey CLA 2007-05-15 16:21:45 EDT
CDT needs to TextProcess thier Tooltips
Comment 6 Cam-Thu Le CLA 2007-05-15 16:28:19 EDT
Vivian, according to Platform, it's a CDT bug.
Comment 7 Vivian Kong CLA 2007-05-15 16:39:47 EDT
Created attachment 67314 [details]
CDT icons

Ravi, can you please take a look?

The problematic tooltips are found on these C/C++ icons in the C/C++ Perspective.  Please see the attached screenshot.
Comment 8 CDE Administration CLA 2007-05-15 16:51:41 EDT
Warning: Unable to attach CDT_icons due to lack of extension on the filename.
Comment 9 Vivian Kong CLA 2007-05-16 11:32:19 EDT
The tooltips are loaded from the plugin.properties file and that's not handled by CDT.  We're seeing similar problems with the tooltips for plain Eclipse as well.  I'm not sure which component this belongs to so I'm going to assign it to Platform for now.  Please feel free to change it.
Comment 10 CDE Administration CLA 2007-05-16 11:52:42 EDT
Warning: Unable to attach CDT_icons due to lack of extension on the filename.
Comment 11 CDE Administration CLA 2007-05-16 20:51:59 EDT
Warning: Unable to attach CDT_icons due to lack of extension on the filename.
Comment 12 CDE Administration CLA 2007-05-17 05:53:57 EDT
Warning: Unable to attach CDT_icons due to lack of extension on the filename.
Comment 13 Tod Creasey CLA 2007-05-22 08:59:01 EDT
Is this also an issue on Windows?
Comment 14 Kit Lo CLA 2007-05-22 09:22:26 EDT
Yes, the problem was reported on Windows.
Comment 15 CDE Administration CLA 2007-05-22 09:51:35 EDT
Warning: Unable to attach CDT_icons due to lack of extension on the filename.
Warning: Unable to attach CDT_icons due to lack of extension on the filename.
Comment 16 CDE Administration CLA 2007-06-04 15:16:29 EDT
This problem was found again in TPTP component, testcase 09.001440. But in this case, the tooltip text permanently had incorrect reading order. Clicking anywhere else and returning back to this tooltip still displays incorrect reading order.
Comment 17 CDE Administration CLA 2007-06-04 15:16:32 EDT
Created attachment 70018 [details]
09.001440.jpg
Comment 18 CDE Administration CLA 2007-06-15 12:12:50 EDT
This is a high priority must-fix problem for Arabic.
I need screen shots to be sent to verify this problem.
Comment 19 Tod Creasey CLA 2007-07-30 09:43:01 EDT
We have set the orientation on the parent of the ToolBar (the Composite) as you can see in the screenshot. This is a general SWT issue in the processing of Tooltips.

Having said that this was this tested on a machine with an Arabic install? If not then you will get OS behaviour I would expect.
Comment 20 Felipe Heidrich CLA 2007-07-30 10:46:55 EDT
Why is this problem assigned against Linux-GTK ?
According to comments #0 and #14 and all screenshots this is a Windows problem.
Comment 21 Felipe Heidrich CLA 2007-08-14 12:18:51 EDT
Tod:
1) Can you confirm that the ToolBar is RTL (or by inherence or directly set)
2) Can you give the string that is being set in the tooltip (so I can make sure it doesn't have bidi control characters).

Reporder, please reply Tod last question:
"Having said that this was this tested on a machine with an Arabic install?"

Note: if the machine doesn't have Arabic installed you can't expect RTL reading order to work on it.

This works for me in a simple snippet.

public class PR196791 {
public static void main(String[] args) {
	 Display display = new Display();
     Shell shell = new Shell(display, SWT.SHELL_TRIM | SWT.RIGHT_TO_LEFT);
     ToolBar bar = new ToolBar(shell, SWT.NONE);
     ToolItem item = new ToolItem(bar, SWT.NONE);
     item.setText("ToolItem.");
     item.setToolTipText("ToolItem tip.");
     bar.setBounds(10, 10, 100, 26);
     shell.setSize(300, 300);
     shell.open ();
     while (!shell.isDisposed()) {
             if (!display.readAndDispatch()) display.sleep();
     }
     display.dispose();
}
}
Comment 22 Felipe Heidrich CLA 2007-08-14 12:21:32 EDT
Tod, please modify the snippet to show the problem. Send it back to SWT when you are done. Thanks
Comment 23 Kim Horne CLA 2007-08-31 09:29:58 EDT
This one fell through the cracks.  I will remove the 3.3.1 target and we will talk about putting a fix in before the build next week.
Comment 24 Tod Creasey CLA 2008-04-10 10:16:36 EDT
Embed an Arabic character to give mixed text in each to see the difference

package org.eclipse.jface.snippets.dialogs;

import org.eclipse.swt.SWT;
import org.eclipse.swt.widgets.Display;
import org.eclipse.swt.widgets.Shell;
import org.eclipse.swt.widgets.ToolBar;
import org.eclipse.swt.widgets.ToolItem;

public class PR196791 {
public static void main(String[] args) {
         Display display = new Display();
     Shell shell = new Shell(display, SWT.SHELL_TRIM | SWT.RIGHT_TO_LEFT);
     ToolBar bar = new ToolBar(shell, SWT.NONE);
     ToolItem item = new ToolItem(bar, SWT.NONE);
     item.setText("Tool\u0751Item.");
     item.setToolTipText("Tool\u0751Item tip.");
     bar.setBounds(10, 10, 100, 26);
     shell.setSize(300, 300);
     shell.open ();
     while (!shell.isDisposed()) {
             if (!display.readAndDispatch()) display.sleep();
     }
     display.dispose();
}
}
Comment 25 Felipe Heidrich CLA 2008-04-10 17:17:07 EDT
Interesting test case Tod.
In my machine I don't need the arabic char to reproduce the problem.
The reading order in the tooltip changes every time the mouse enters the toolbar from the top edge. Go figure.

Fixed in HEAD > 20080410