I am running my English application in Arabic Windows. It contains a property sheet UI (MFC). Everything seems to be fine (Left-To-Right or LTR), except the buttons (OK, Cancel, Apply, and Help) which are Right-To-Left or RTL. But how to make the buttons LTR?
I played around with the flag PSH_RTLREADING mentioned on MSDN but it only deals with the window caption, not the buttons.
Besides, I noticed this dicussion but there is not a good solution.
The answer is given by Raymond Chen [1] and another Microsoft employee [2]; you have to remove the WS_EX_LAYOUTRTL style from the buttons in the window created by your CDialog (aka CPropertySheet). You can either do this globally when you create your CMainFrame and inherit it to all child windows, or locally by changing the window style from GWL_EXSTYLE.
[1] http://blogs.msdn.com/b/oldnewthing/archive/2010/06/11/10023274.aspx
[2] http://social.msdn.microsoft.com/Forums/en/vcgeneral/thread/057612e7-6cd4-44cf-a746-6370ace5de09
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With