Wednesday, February 09, 2005

Globalization Workshop

I finished conducted the first software globalization and localization workshop yesterday. The presentations, lab walkthroughs and code samples used during the workshop can be found here.

One addendum to the above content is designing WinForms application for Middle-Eastern market (for use with BiDi scripts). To fully support RTL (Right To Left) locales such as Arabic, you need to set the RightToLeft property of your form to Yes. In addition you need to enable "mirroring". Unfortunately there is no System.Windows.Forms property that corresponds to mirroring. But you can easily achieve it by overriding the CreateParams property:

Protected Overrides ReadOnly Property CreateParams()As
        'Retrieve the CreateParams class to change the style
        Dim CP As System.Windows.Forms.CreateParams
        CP = MyBase.CreateParams
        'If the control needs RTL add these styles
        If _Mirrored Then
            CP.ExStyle = CP.ExStyle Or &H400000 Or &H100000
        End If
        Return CP
    End Get
End Property

In C# you do the same as:

protected override CreateParams CreateParams
  CreateParams cp = base.CreateParams;
    CreateParams cp = base.CreateParams;
    cp.ExStyle = cp.ExStyle | 0x400000 | 0x100000;
 return cp;

*minor modifications made to the code on 6 May 05, thanks Anonymous!

This is what your form would appear like once it is "mirroring" correctly:


Here some links that are must visit if software globalization/localization is your cup of tea:

Thursday, February 03, 2005

Search for a Notepad replacement

Without commenting on merits or demerits of Notepad, I'll simply state that I am badly looking for a free Notepad replacement. I've checked Notepad2 and NoteTab Light, but both of them balked when it came to full Unicode and complex script support. Even when these editors claim Unicode support, they don’t work with Indic/Far-Eastern IMEs (I get ???? when typing).

Right click in Notepad and pay attention to the last 3 menu items - Right to left reading order, Show Unicode control characters and Insert Unicode control characters. These options are important to me!

Sriram pointed me today to Syn. While it doesn't do Unicode and doesn't claim to be a Notepad replacement it does show some promise of being my long overdue XEmacs replacement ;-).

So folks, any ideas? What is that lean, mean, fast notepad replacement that you use (it must satisfy my somewhat esoteric requirements that the original notepad handles so well)?