Arabic and Hebrew languages bidirectional support for Silverlight 2.0 beta 2
Those days, I’m, together with guys from Microsoft Egypt and Santeon, finishing development of bidirectional input and output support for Silverlight. I want you to take part in alpha testing of this solution. Please see the test form here and try it.
Also, you can download latest development build or compiled binary version with debug symbols and try it yourself. Please, if you’re in any issue, report it, by using issue tracker in CodePlex.
In order to use it, all you have to do is to use custom namespace within your project and then, you’ll be able to get almost all controls, you know, but with Arabic and Hebrew RTL and LTR support. You have to set one property: FlowDirection to change the rendering method (exactly as in WPF). Here an example of usage.
<UserControl x:Class=”BidiTest2.Page”
xmlns=”http://schemas.microsoft.com/winfx/2006/xaml/presentation”
xmlns:x=”http://schemas.microsoft.com/winfx/2006/xaml”
xmlns:l=”clr-namespace:System.Windows.BidiControls;assembly=BidiControls”>
…
<l:TextBlock FlowDirection=”LeftToRight” Text=”שלום עולם”/><l:TextBox FlowDirection=”RightToLeft” Text=”{Binding Text, Mode=TwoWay}”/>
That’s all. Thank you for your cooperation.

You may also be interested with:
July 16th, 2008 · Comments (19)
19 Responses to “Arabic and Hebrew languages bidirectional support for Silverlight 2.0 beta 2”
Leave a Reply
Discover other tags
My tools
- .NET Framework Detector
- Duplicate images finder
- Exchange Security Policy for Windows Mobile Devices Fix
- Gas Price Windows Vista SideBar gadget
- Israel Traffic Information Windows Vista SideBar gadget
- Localization fix for SAP ES Explorer for Visual Studio
- LocTester
- RTL and LTR in Windows Live Writer
- Silverlight controls library
- Snipping tool integration plugin for WLW
- USB FM receiver library
- Vista Battery Saver
- WebCam control for WPF
- Windows Live SkyDrive attachment for Windows Live Writer
- Wireless Migrator
- WPF Virtual Keyboard




January 1st, 2009 at 12:54 am
Blend crashes every time I load a project referencing the Bidi dll. does anyone here has a clue?
Thanks,
t.
January 1st, 2009 at 12:54 am
Hi Tamir,
Great work there…
Now that Silverlight 2 is RTMed – are you planning to update the code to the final release?
I am using the files with RTM version, and I receive an exception: Unable to cast system.windows.bidicontrols.textbox to system.windows.controls.textbox.
Can you help?
Thank,
Elad
January 1st, 2009 at 12:54 am
Hello,
many thanks for this beautiful library
but there is an issue for Arabic language
when you write
ال
it reflect the two second characters
like this
الرحمن
it types
ارلحمن
in that way it is impossible to use it in Arabic,
hope there is any solution very soon
Thank you,
January 1st, 2009 at 12:54 am
2.0 is released ………. We Need To Start Use SilverLight And We Need Hebrew !!!
Many Many Many Tahnks
January 1st, 2009 at 12:54 am
Now that 2.0 is released, are you adjusting the code (+demo) to fit?
January 1st, 2009 at 12:54 am
hi, Fred
Those days we are working on upgrading toward Rc0. Stay tuned
January 1st, 2009 at 12:54 am
Hi
I have some problems with the new version of SL2 RC0.
What I have to do in order to continue using your Bidi controls ?
Thanks
Fred
January 1st, 2009 at 12:54 am
Thanks! This is Great!
January 1st, 2009 at 12:54 am
Ver 2 Beta 2 is out and work can be done….
XAML’s on the way…
R E S P E C T for the bidirectional support efforts
Take your time.
We here can use images for now… XAML handles them goood
January 1st, 2009 at 12:54 am
please,i need some things on Bidirectional Visitors Counter
it is my project topic.kindly reply as soon as possible
January 1st, 2009 at 12:54 am
Hey Tamir,
Sounds like this will be a great solution for my project in Hebrew.
But I can’t figure out how to include this namespace into my project?
That is – which files do belong to the namespace and where I should put them and how reference to them.
Could you please help me with that?
Thanks in advance.
January 1st, 2009 at 12:54 am
Hi Tamir,
My due date for my project is 21/8 and I wonder whether to wait for your fixes or find another workaround for the hebrew textbox (what bothers me most is the mixed multiline issue) what do you think\recommend?
Thanks,
Tzahi.
January 1st, 2009 at 12:54 am
Tzahi, Background is core issue with Silverlight and has no connection to RTL controls. This will be fixed in RTM (you can use it as is, when RTM will be out, this start work)
Fred, Yes, this supported in RTL controls
Hosseingt, I get it absolutely right. You should use it within right side controls in this page
January 1st, 2009 at 12:54 am
Hi,
Do you reckon that you’ll fix the hebrew text mix issue anytime soon? and the background issues?
I’m just trying to figure out whether I could use it in my project…..
Thanks,
Tzahi
January 1st, 2009 at 12:54 am
Hi
is it possible to center a text in a textBox ?
if yes how ?
is it possible to change the FontFamily in a textBox as
for example textBox.FontFamily = new FontFamily("Narkisim"); ?
if yes which one is working in hebrew ?
thanks
Fred
May 17th, 2009 at 3:15 am
Silverlight 2 Arabic Support :
Excellent work, I have used BidiControls for displaying Arabic Text From XML and as till now its working fine.
For individual who want to use it, follow the following steps :
1) Download and reference the bidiControls.dll in your project
2)In XAML page enter the NameSpace in UserControl tag of the page.
xmlns:ar=”clr-namespace:System.Windows.BidiControls;assembly=BidiControls”>
3)To use the BidiControl for eg. Textbox would be :
Thats all it is. Thanks again to the team and individual who developed this Assembly.
Best Regards
Jaspal K.
June 28th, 2009 at 1:03 am
Hi Tamir
Been using this library for a while (as you can see in my site) but having a small problem… the text is not spread in the entire width of the textblock. Any idea why this happens ?
July 23rd, 2009 at 1:24 am
If you write Alif Lam and any letter, it reverse the Lam with the next letter
August 16th, 2009 at 2:35 am
Hi,
I came along and had al look at your bidi-support which proved to be useful and a good work.
The issue addressed by at least two people is a genuine one and decisive.
It is a failure when inputting data. Without your correction one would have to solve the problem programmatically with lot if effort as this could be needed in different ways.
It would be a good practice to get rid of the bug.
Thanks for the good work you have already done.
Sincerely yours
MY
I include a runtime error as an example for entering سلام !
It is a problem concerning the index used to manage the Input.
Laufzeitfehler in Microsoft JScript: Unhandled Error in Silverlight Application
Code: 4004
Category: ManagedRuntimeError
Message: System.ArgumentOutOfRangeException: Der Index lag außerhalb des Bereichs. Er muss nicht negativ und kleiner als die Auflistung sein.
Parametername: index
bei System.ThrowHelper.ThrowArgumentOutOfRangeException(ExceptionArgument argument, ExceptionResource resource)
bei System.ThrowHelper.ThrowArgumentOutOfRangeException()
bei System.Collections.Generic.List`1.get_Item(Int32 index)
bei NBidi.NBidi.Paragraph.InternalCompose(StringBuilder target, List`1 char_lengths)
bei NBidi.NBidi.Paragraph.NormalizeText()
bei NBidi.NBidi.Paragraph.set_Text(String value)
bei NBidi.NBidi.Paragraph..ctor(String text)
bei NBidi.NBidi.SplitStringToParagraphs(String logicalString)
bei NBidi.NBidi.LogicalToVisual(String logicalString, Int32[]& indexes, Int32[]& lengths)
bei NBidi.NBidi.VisualToLogicalPosition(String logicalOrigStringNoRLM, Int32 visualPosition)
bei System.Windows.BidiControls.TextBox.onInternalTextChanged(Object sender, TextChangedEventArgs e)
bei System.Windows.CoreInvokeHandler.InvokeEventHandler(Int32 typeIndex, Delegate handlerDelegate, Object sender, Object args)
bei MS.Internal.JoltHelper.FireEvent(IntPtr unmanagedObj, IntPtr unmanagedObjArgs, Int32 argsTypeIndex, String eventName)