Community
Participate
Working Groups
Build Identifier: For quite a while I felt compelled to share a general view on Bidi functionality and related work being done in Eclipse. Below you will find such a summary. It is by all means not complete. However, it is a good start for those who want to understand the level of Bidi support in Eclipse and outstanding issues. 1. Mirroring of GUI ==================== 1.1. Windows specifics ----------------------- In most general terms except for very isolated problematic areas (see section Miscellaneous below) SWT provides very good level of mirroring support. Certain local application level issues may occur. For more details please see bug 132799 , bug 229044 and bug 224893 . 1.2 Linux specifics -------------------- In general Linux provides acceptable level of mirroring on SWT level (except for very isolated problematic areas - see section Miscellaneous below). Certain local application level issues may occur. For more details please see bug 225315 , bug 228251 , bug 226104 and bug 224367 . 1.3 Macintosh specifics ------------------------ Due to Cocoa limitation, mirroring is NOT supported on Mac platform. 1.4 Miscellaneous ------------------ 1.4.1 Icons implying directionality are not mirrored ..................................................... Icons which imply directionality should generally be mirrored when the user interface is mirrored. The most typical examples are the arrow-shaped icons for Forward and Backward; when the UI is mirrored, the icon for Forward should be a left-pointing arrow and the icon for Backward should be a right-pointing arrow. Currently Eclipse as a whole does not support mirroring of icons. Namely, de-facto none of icons having directionality appear mirrored on the mirrored GUI. For reference please see following defects: bug 268662 , bug 132858 , bug 273737 and bug 274131 . 1.4.2 “On the fly” mirroring of controls is not supported by SWT ................................................................. Change of widget / control orientation dynamically at runtime is supported by SWT only for Combo, Text and StyledText controls. For more details please see bug 29779 . This support is required for programs which have dynamically changing GUI. Classic examples are GUI editors such as BIRT report editor (http://www.eclipse.org/birt/phoenix/) or UI editor from Eclipse 4 (aka e4 Workbench Designer) - org.eclipse.e4.xwt.workbench (for info please see http://wiki.eclipse.org/E4/XWT and http://www.eclipse.org/e4/resources/e4-whitepaper.php#gui-model). Those editors allow control over orientation of specific control / panel and thus require dynamic support for change of controls orientation. 1.4.3 Mirroring / translation of OS dialogs / context menus on enabled Bidi platforms ........................................................................................ On enabled Windows platforms (not nationalized /localized ones) OS dialogs / context menu can't be mirrored / translated. By enabled platforms we refer to English version of OS with enabled Bidi support which allows proper entry and display of Bidi characters. For more information on File, Color, Font, Browse for folder OS standard dialogs on Windows platform please see bug 29764 and bug 224349 . A similar problem was resolved on Linux platform. For more details please see bug 51829 , bug 224121 and bug 222594 . 1.4.4 Partial translation to Hebrew .................................... Not all plugins have been translated to Hebrew. Thus it may occur that GUI will have some screens in Hebrew while others will appear in Hebrew. Moreover, it may occur that several elements of the same screen are translated to Hebrew, while others are not translated and thus appear in English. Mirroring of GUI is independent from presence of Bidi translation 1. Many screens which have not been translated to Bidi language appear mirrored 2. It is possible to load Eclipse with translated to Bidi language resources but in not mirrored mode. This behavior contradicts the ground rule of Bidi mirroring - GUI should be mirrored if and only if it is translated to language with Bidi script. This limitation is due to the difficulty to identify / trace the interrelation between a component, required translations and their installation status. The decision to mirror has nothing to do with whether or not the translations have been installed as we can't be sure if all of the ones required are installed for every component. For more details please see bug 223331 and bug 223352 . 2. Display / editing of Bidi text ================================== 2.1 Logical data ----------------- Majority of Bidi data shown in Eclipse is logical Bidi data (Bidi data stored in logical Bidi layout which is a standard Bidi layout for Windows platform). 2.1.1 Logic for invocation of Bidi support ........................................... Support for proper display of Bidi data is focused on so called end user originated data which as opposed to PII, is directly or indirectly introduced into the product by the end user. This support might be time consuming and thus should not be invoked by default. Thus there is a need for a switch on which this support will be conditioned. There is no attempt to condition/control Bidi support inherited by Eclipse from OS. The goal is to condition/control only Eclipse specific newly developed aspects of Bidi support. For examples please see next chapters. For more details please see bug 307307 2.1.2 Enforcement of base text direction independently from GUI orientation ............................................................................ Natural base text direction for Bidi text (even if it includes English words) is RTL. Natural base text direction for non Bidi text (even if it includes Arabic / Hebrew words) is LTR. If text is displayed with not natural to it base text direction it becomes incomprehensible. Display of Bidi and non-Bidi text is independent from GUI orientation (English text can appear on the mirrored GUI, while Bidi text can appear on not mirrored GUI). Program can’t automatically identify what text is introduced into it. Thus the control over base text direction independently from GUI orientation should be in the end user control. For more details please see bug 273198 . 2.1.3 Support for display of structured text (aka complex expressions) ...................................................................... The theory and design are covered in bug 179191 . The ground work for static cases is delivered via bug 183164 . Special case of messages with placeholders is handled in bug 306751 . Dynamic cases are handled via bug 230854 . Correlation between: GUI Orientation - Text Direction - Text Alignment - Complex expressions is handled via bug 274829 . 2.2 Visual data ---------------- Bidi data is represented on mainframe platform in Bidi visual layout. To properly work with this data on logical platform special tools need to be developed. Relevant components: DTP, BIRT. The approach based on normalization of Bidi data to common Bidi layout is discussed in bug 245136 . Development of tools capable of working with Bidi data in visual layout is discussed in bug 298392 . Integration of tools for editing visual Bidi data in DTP is discussed in bug 273722 . Currently support for working with visual data is based on StyledText enhancement (for more details please see bug 241482 ). Similar enhacement is going to be developed for standard input (platform based) text field ( for more details please see bug 230854 ). 3. National calendars ======================= Dates can appear in Eclipse in two contexts: 1. Date / Time stamps 2. Specification of dates via graphical date picker 3.1 Visual date pickers ------------------------- Visual date pickers is implemented in SWT via DateTime control. This control is based on the OS level control and has following limitations: Windows: Support for national calendars is possible only starting from Windows Vista Linux: No support for national calendars Carbon / Cocoa: Support for national calendars is present. For more information please see bug 273205 3.2 Time / date stamps ----------------------- Support for National calendar in time / date stamps was introduced via new command line configuration option (-nlExtensions) passed to ICU4J. Initialized this way, ICU4J should be leveraged by all components for generation of time / date stamps. For more information please see bug 224794 and bug 243270 . All components leveraging ICU4J for generation of time / date stamps automatically receive support for national calendars via mentioned above initialization. Unfortunately not all components are currently leveraging ICU4J for generation of time / date stamps. For example, PropertiesDialog & Properties view use ICU4J while LogEntry & LogViewLabelProvider don't use it. Such issues should be resolved on the case by case basis. For example please see bug 273729 . 4. Eclipse 4 specific items ============================ 4.1 List of Bidi properties / functions to be supported in Eclipse 4 --------------------------------------------------------------------- Bidi functionality in Eclipse is associated with: 1. Support for translation of GUI to Bidi language(s) – Mirroring of GUI 2. Basic Bidi support for proper display and editing of Bidi text – enforcement of base text direction, display of structured Bidi text (aka complex expressions). This functionality is controlled by Bidi properties. In Eclipse 4 following functionality is expected to be provided: a. Mirroring of individual controls (currently provided by SWT) b. Enforcement of base text direction (LTR, RTL, Contextual) c. Support for proper display of structured Bidi text (i.e. file paths, URL, SQL etc.) 4.2 Support for Bidi properties in XML UI for SWT (XWT) ------------------------------------------------------- XWT stands for eclipse XML Window Toolkit. It is a powerful and lightweight declarative UI framework designed for Eclipse, based on XML as markup language. XWT simplifies UI development by a physical separation of UI definition in XML from the run-time logic in programming language. XWT must allow storage / definition of Bidi properties which are used / configured by other agents (i.e. Renderer, Styling engine, E4 Workbench Designer) 4.2 Support for defining Bidi properties in e4 Workbench Designer / XWT Visual Designer ------------------------------------------------------------------------------ Eclipse e4 ships with a graphical UI designer (http://dev.eclipse.org/blogs/yvesyang/2009/11/02/xwt-designer/) . It is supposed to allow the user to maintain the Application.e4xmi via a graphical editor. In particular it should support configuration of Bidi properties supported by XWT. For example see Property Page section from following document: http://wiki.eclipse.org/E4/XWTDesigner . For more info please see bug 316267 4.3 Support for processing Bidi properties in Renderer ------------------------------------------------------- The e4 workbench model (XWT) is translated into widgets via a renderer. The workbench comes with a default renderer that instantiates the model as SWT widgets. Renderers are contributed at the level of individual model elements, rather than a single monolithic renderer for the entire application. A single renderer can supply rendering for one or more model elements, or conversely there can be multiple renderers available for a given model element. Bidi properties provided in the XWT model should be adequately mapped into SWT Bidi capabilities. 4.4 Support for processing of Bidi properties in Styling engine ---------------------------------------------------------------- While the basic translation of the workbench model into widgets is performed by the renderer, a pluggable styling engine is used to customize the fonts, colors, and other aspects of widget presentation. Bidi properties affecting widget behavior should be properly addressed by Styling engine. 4.5 Desktop to Web ------------------- SWT browser edition (SWT/BE), aims to provide a common platform for web UI programming just as it has done for traditional desktop programming. This potentially allows existing SWT applications to run on the web, and allows developers to build web UI applications without being locked into a single web technology. SWT/BE currently supports ActionScript/Flex as a prototype example of the technology, but ports to other web platforms such as JavaScript/Dojo, Silverlight, Java FX, etc, are also possible. 4.5.1 Proper mapping of Bidi properties from SWT/BE to various web technologies ............................................................................... Bidi capabilities of SWT should be adequately mapped into Bidi capabilities of [ActionScript/Flex, JavaScript /Dojo, Silverlight, Java FX] Reproducible: Always
Created attachment 173760 [details] The same original text in MS Word format. The subsequent updates can be delivered by posting an updated version of attached MS Word file.
API leveraging SegmentListener (added for Text widget via bug 230854 ) and parsers for structured text (developed via bug 183164 ) for handling structured text display (e.g. file path) and enforcement of base text direction are discussed in bug 381487 .
and bug 383185
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. If you have further information on the current state of the bug, please add it and remove the stalebug whiteboard tag. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant. --