Page 2 of 3

Re: HMG 3.0.44

Posted: Mon Sep 03, 2012 8:37 pm
by srvet_claudio
Hi Rathi.
My bug in the function INVALIDATERECT (source file: c_windows.c) was not corrected.
The correct code in line 1776 is:

Code: Select all

if (hb_arrayLen (pArrayRect) == 4)
Regards,
Claudio.

Re: HMG 3.0.44

Posted: Tue Sep 04, 2012 8:21 pm
by kurowskic
HMG 3.0.44 - please revise path in following files:
hfcl\Resources\hfcl.rc;
hfcl\Samples\AutoFill\config.hbc;
hfcl\Samples\ComboSearchBox\main.hbc
hfcl\Samples\GridPrint\config.hbc;
hfcl\Samples\GridPrintPreFormat\main.hbc;

Add build.bat into:
hfcl\Samples\GridEx

HMG 3.0.44

Posted: Sun Sep 09, 2012 1:47 am
by Pablo César
rathinagiri wrote:Hi Ronaldo,

Can you show me where can I find the proper language codes?
Chacal.GO wrote:After Set Local language/CodePage, Just call: Set ( _SET_LANGUAGE )
Just in followin this trail...

I am needing to SET LANGUAGE TO (cVariable), is this possible ? How I can get without any error ?

Re: HMG 3.0.44

Posted: Mon Sep 10, 2012 5:03 pm
by IMATECH
Hi Pablo !

A simple call to "hb_UserLang()" Will be an easy way for Language detection and translations... then you can use the same logic as HMG

hb_UserLang() will return:

Code: Select all

         "af"         
         "af-ZA"      
         "sq"         
         "sq-AL"      
         "ar"         
         "ar-DZ"      
         "ar-BH"      
         "ar-EG"      
         "ar-IQ"      
         "ar-JO"      
         "ar-KW"      
         "ar-LB"      
         "ar-LY"      
         "ar-MA"      
         "ar-OM"      
         "ar-QA"      
         "ar-SA"      
         "ar-SY"      
         "ar-TN"      
         "ar-AE"      
         "ar-YE"      
         "hy"         
         "hy-AM"      
         "az"         
         "az-AZ-Cyrl" 
         "az-AZ-Latn" 
         "eu"         
         "eu-ES"      
         "be"         
         "be-BY"      
         "bg"         
         "bg-BG"      
         "ca"         
         "ca-ES"      
         "cy-GB"      
         "zh-HK"      
         "zh-MO"      
         "zh-CN"      
         "zh-CHS"     
         "zh-SG"      
         "zh-TW"      
         "zh-CHT"     
         "hr"         
         "hr-HR"      
         "cs"         
         "cs-CZ"      
         "da"         
         "da-DK"      
         "div"        
         "div-MV"     
         "nl"         
         "nl-BE"      
         "nl-NL"      
         "en"         
         "en-AU"      
         "en-BZ"      
         "en-CA"      
         "en-CB"      
         "en-IE"      
         "en-JM"      
         "en-NZ"      
         "en-PH"      
         "en-ZA"      
         "en-TT"      
         "en-GB"      
         "en-US"      
         "en-ZW"      
         "et"         
         "et-EE"      
         "fo"         
         "fo-FO"      
         "fa"         
         "fa-IR"      
         "fi"         
         "fi-FI"      
         "fr"         
         "fr-BE"      
         "fr-CA"      
         "fr-FR"      
         "fr-LU"      
         "fr-MC"      
         "fr-CH"      
         "gl"         
         "gl-ES"      
         "ka"         
         "ka-GE"      
         "de"         
         "de-AT"      
         "de-DE"      
         "de-LI"      
         "de-LU"      
         "de-CH"      
         "el"         
         "el-GR"      
         "gu"         
         "gu-IN"      
         "he"         
         "he-IL"      
         "hi"         
         "hi-IN"      
         "hu"         
         "hu-HU"      
         "is"         
         "is-IS"      
         "id"         
         "id-ID"      
         "it"         
         "it-IT"      
         "it-CH"      
         "ja"         
         "ja-JP"      
         "kn"         
         "kn-IN"      
         "kk"         
         "kk-KZ"      
         "kok"        
         "kok-IN"     
         "ko"         
         "ko-KR"      
         "ky"         
         "ky-KZ"      
         "lv"         
         "lv-LV"      
         "lt"         
         "lt-LT"      
         "mk"         
         "mk-MK"      
         "ms"         
         "ms-BN"      
         "ms-MY"      
         "mr"         
         "mr-IN"      
         "mn"         
         "mn-MN"      
         "no"         
         "nb-NO"      
         "nn-NO"      
         "pl"         
         "pl-PL"      
         "pt"         
         "pt-BR"      
         "pt-PT"      
         "pa"         
         "pa-IN"      
         "ro"         
         "ro-RO"      
         "ru"         
         "ru-RU"      
         "sa"         
         "sa-IN"      
         "sr-SP-Cyrl" 
         "sr-SP-Latn" 
         "sk"         
         "sk-SK"      
         "sl"         
         "sl-SI"      
         "es"         
         "es-AR"      
         "es-BO"      
         "es-CL"      
         "es-CO"      
         "es-CR"      
         "es-DO"      
         "es-EC"      
         "es-SV"      
         "es-GT"      
         "es-HN"      
         "es-MX"      
         "es-NI"      
         "es-PA"      
         "es-PY"      
         "es-PE"      
         "es-PR"      
         "es-ES"      
         "es-UY"      
         "es-VE"      
         "sw"         
         "sw-KE"      
         "sv"         
         "sv-FI"      
         "sv-SE"      
         "syr"        
         "syr-SY"     
         "ta"         
         "ta-IN"      
         "tt"         
         "tt-RU"      
         "te"         
         "te-IN"      
         "th"         
         "th-TH"      
         "tr"         
         "tr-TR"      
         "uk"         
         "uk-UA"      
         "ur"         
         "ur-PK"      
         "uz"         
         "uz-UZ-Cyrl" 
         "uz-UZ-Latn" 
         "vi"         
         "vi-VN"      
         NULL         

HMG 3.0.44

Posted: Tue Sep 11, 2012 3:02 am
by Pablo César
Thank you Ronaldo for your return. But let me explain a bit more.

What I need is to SETUP the language, according a variable which will contains symbols returning from hb_UserLang(). Not only for detecting language, I need to setup language and I do not wish to mention:

Code: Select all

Do Case
   Case Upper(IDIOMA)="ENGLISH"
        SET LANGUAGE TO ENGLISH
   Case Upper(IDIOMA)="SPANISH"
        SET LANGUAGE TO SPANISH
   Case Upper(IDIOMA)="FRENCH"
        SET LANGUAGE TO FRENCH
   Case Upper(IDIOMA)="PORTUGUESE"
        SET LANGUAGE TO PORTUGUESE

so on...
Do you know if is possible to make something like this ?:

SET LANGUAGE TO (IDIOMA) // ??

Without making each option for each language ?

Re: HMG 3.0.44

Posted: Tue Sep 11, 2012 3:47 pm
by IMATECH
Hi Pablo !

No any magic for your request...

Like proposed, below a simple template for use (not tested)

Code: Select all


LOCAL cLang := hb_UserLang()

/* Language that exists in HMG: InitMessages() */
IF ( cLang in { "pl", "pl-PL" } )
  SET LANGUAGE TO POLISH
  SET CODEPAGE TO POLISH
  /* my translations */
ENDIF

/* Language not exists in HMG */
IF ( cLang in { "ar", "ar-DZ", "ar-BH", "ar-EG", "ar-IQ", "ar-JO", "ar-KW", "ar-LB", "ar-LY", "ar-MA", "ar-OM", "ar-QA", "ar-SA", "ar-SY", "ar-TN", "ar-AE", "ar-YE" } )
  _HMG_SYSDATA \[ 211 \] := '  '
  REQUEST HB_LANG_AR
  HB_LANGSELECT( cLang, "ARISO" )
  InitMessages() /* HMG messages need updates to work properly */
  REQUEST HB_CODEPAGE_AR
  HB_CDPSELECT("ARISO")
  /* my translations */
ENDIF


HMG 3.0.44

Posted: Tue Sep 11, 2012 7:44 pm
by Pablo César
Creio que você não captou ainda o que estou precisando, se bem que em HMG tem algumas limitações sobre essa questão SET LANGUAGE TO... o que eu preciso é não ter que fazer nenhuma estrutura condicional, nem para cada grupo de países. Essa tabela já possuo conforme o que me retorna da função GetUserDefaultLangID em C da MSDN. Pois o que eu queria evitar é justamente o que você está indicando. Fazer opções condicionais e eu gostaria de aplicar o SET LANGUAGE TO <variavel_contendo_idioma>. Se isto (em negrito) for possível, gostaria de saber como fazer porque eu não conseguí. Entendeu Ronaldo ?

E pelo que estive vendo, ao fazer SET LANGUAGE TO PORTUGUESE (por exemplo), irá internamente chamar:
REQUEST HB_LANG_PT
REQUEST HB_CODEPAGE_PT850
HB_LANGSELECT('PT')
HB_CDPSELECT("PT850")
Então ao selecionar com SET LANGUAGE TO PORTUGUESE, bastaria. Inclsuive parece que não todos utilizam CODEPAGE ou não possuem.

---

I think you still did not get what I need, albeit at HMG has some limitations on this issue SET LANGUAGE TO ... what I need is not having to do any conditional structure, or for each group of countries. This table already own as I return from the C function GetUserDefaultLangID on MSDN. For what I wanted to avoid is exactly what you are indicating. Make conditional options and I would like to apply the SET LANGUAGE TO <variavel_contendo_idioma>. If this (in bold) is possible, I would like to know how to do because I could not. Ronaldo understood?

And from what I was seeing, doing SET TO ENGLISH LANGUAGE (for example) will internally call:
REQUEST HB_LANG_PT
REQUEST HB_CODEPAGE_PT850
HB_LANGSELECT ('PT')
HB_CDPSELECT ("PT850")
Then select with the SET LANGUAGE TO ENGLISH, would suffice. Inclsuive seems that not everyone uses CODEPAGE or do not have.

Re: HMG 3.0.44

Posted: Tue Sep 11, 2012 8:11 pm
by IMATECH
Hi Pablo !


Like I have said !

No any magic for your request...

HMG 3.0.44

Posted: Tue Sep 11, 2012 8:37 pm
by Pablo César
Ronaldo are you joking ?

I´m still not seeing satisfactory solution with at your indications. :roll:

But also understand that not all languages has your own Codepage, so I have to deal with it... :(

HMG 3.0.44

Posted: Wed Sep 12, 2012 2:38 am
by Pablo César
When I had made my own revise about STRU´s demands for languages resources, I noted some good changings and I wish to comment.
Chacal.GO wrote:Then I invite all user to help in HMG messages/translations using new Harbour features...

To do:
SPANISH
ENGLISH
FRENCH
PORTUGUESE -> Fixed
GERMAN
RUSSIAN
ITALIAN
POLISH
BASQUE
CROATIAN
SLOVENIAN
CZECH
FINNISH
DUTCH
See a sample at:
viewtopic.php?p=21498#p21498
You are right, Ronaldo. Other colleagues should manifest about behaviour of their local languages with HMG.

Thanks for having alerted and requested our friend Rathinagiri adaptation due. I am sure this change will be very good welcome and I hope others can collaborate for rest of languages.