Arabic interface

HMG Unicode versions 3.1.x related

Moderator: Rathinagiri

Post Reply
hmgaams57
Posts: 129
Joined: Mon Feb 27, 2017 10:00 am

Arabic interface

Post by hmgaams57 »

Hi all,

I have an application written using hmg extended whose interface is in French. I translate it to hmg 3.4.3
It's more interesting for me because with hmg 3.4.3 I have the ability to use unicode. I have turned the interface into Arabic but I do not know how to display, for example, dropdown menus, browses ..., from right to left. Any help would be welcome. Thank you in advance
User avatar
srvet_claudio
Posts: 2193
Joined: Thu Feb 25, 2010 8:43 pm
Location: Uruguay
Contact:

Re: Arabic interface

Post by srvet_claudio »

Try with:

Code: Select all

#include "hmg.ch"
Function Main
   ...
   HMG_SetLayoutRTL( .T. )  // put at the beginning of the main function, before creating any window
   ...
   Define Window ...
   ....
   ....
Return


#pragma BEGINDUMP
#include <windows.h>
#include "hbapi.h"

HB_FUNC ( HMG_SETLAYOUTRTL ) 
{
   DWORD nDefaultLayout = hb_parl( 1 ) ? LAYOUT_RTL : 0;
   hb_retl( SetProcessDefaultLayout (  nDefaultLayout ) );
}

#pragma ENDDUMP
See: https://msdn.microsoft.com/en-us/globalization/mt691881
Best regards.
Dr. Claudio Soto
(from Uruguay)
http://srvet.blogspot.com
hmgaams57
Posts: 129
Joined: Mon Feb 27, 2017 10:00 am

Re: Arabic interface

Post by hmgaams57 »

Thank you very much Claudio. It works like a charm.
Post Reply