HMG 3.1.4

HMG Unicode versions 3.1.x related

Moderator: Rathinagiri

User avatar
Rathinagiri
Posts: 5471
Joined: Tue Jul 29, 2008 6:30 pm
DBs Used: MariaDB, SQLite, SQLCipher and MySQL
Location: Sivakasi, India
Contact:

Re: HMG 3.1.4 (Test)

Post by Rathinagiri »

I meant to replace in the programming and not in HMG itself. It would be a better indication (like always on 'ToolTip' for the user). Tooltip can't be done away with because cuebanner works only for TextBox control.

I don't have XP. Can somebody check and report?
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
Carlos Britos
Posts: 245
Joined: Sat Aug 02, 2008 5:03 pm

Re: HMG 3.1.4 (Test)

Post by Carlos Britos »

Rathinagiri wrote:I meant to replace in the programming and not in HMG itself. It would be a better indication (like always on 'ToolTip' for the user). Tooltip can't be done away with because cuebanner works only for TextBox control.

I don't have XP. Can somebody check and report?
Hi
I don´t have at this moment the last HMG release, but I´ve using this code in XP and works fine, on textbox, combobox (edit part) and spinner. Don´t works on editbox, richeditbox. You can compare the HMG code with this one. It was not tested on Hmg, is an adaptation.

Code: Select all

HB_FUNC( SETCUEBANNER )   // ( editHandle, cMsg ) -> nil
{
   #ifdef IGH_UNICODE
      LPWSTR lpWCStr = HMG_parc(2) ;
   #else
      LPWSTR lpWCStr = (LPCWSTR) ( hb_parc(2) == NULL ) ? NULL : hb_mbtowc( (const char *) hb_parc(2) ) ;
   #endif
   SendMessage( (HWND) hb_parnl(1), EM_SETCUEBANNER, (WPARAM) 0, (LPARAM) (LPCWSTR) lpWCStr ) ;
   SysFreeString( lpWCStr );
}
Regards/Saludos, Carlos (bcd12a)
User avatar
Pablo César
Posts: 4059
Joined: Wed Sep 08, 2010 1:18 pm
Location: Curitiba - Brasil

HMG 3.1.4 (Test)

Post by Pablo César »

Hi Carlos, your example is not working with HMG in XP, in Win 7 yes but different than Rathi example. The differance (in win7) from your sample and Rathi is that in Rathi example cuebanner text only disapear when start typing and your example disapear initially with prompted.

Any way both example is not working in XP yet. I have seen many VB examples and same behaviour and in most of them talks some about of comctl32.dll version. I am not sure but probably our problem is from MINGW compiler.

Carlos, what do you mean about #ifdef IGH_UNICODE (here in red is it something wrong ?)
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
User avatar
srvet_claudio
Posts: 2193
Joined: Thu Feb 25, 2010 8:43 pm
Location: Uruguay
Contact:

Re: HMG 3.1.4 (Test)

Post by srvet_claudio »

Carlos Britos wrote:
Rathinagiri wrote:I meant to replace in the programming and not in HMG itself. It would be a better indication (like always on 'ToolTip' for the user). Tooltip can't be done away with because cuebanner works only for TextBox control.

I don't have XP. Can somebody check and report?
Hi
I don´t have at this moment the last HMG release, but I´ve using this code in XP and works fine, on textbox, combobox (edit part) and spinner. Don´t works on editbox, richeditbox. You can compare the HMG code with this one. It was not tested on Hmg, is an adaptation.

Code: Select all

HB_FUNC( SETCUEBANNER )   // ( editHandle, cMsg ) -> nil
{
   #ifdef IGH_UNICODE
      LPWSTR lpWCStr = HMG_parc(2) ;
   #else
      LPWSTR lpWCStr = (LPCWSTR) ( hb_parc(2) == NULL ) ? NULL : hb_mbtowc( (const char *) hb_parc(2) ) ;
   #endif
   SendMessage( (HWND) hb_parnl(1), EM_SETCUEBANNER, (WPARAM) 0, (LPARAM) (LPCWSTR) lpWCStr ) ;
   SysFreeString( lpWCStr );
}
Wow Carlos, very clean and nice code!!! :D
SETCUEBANNER of the HMG.3.1.4, works also in ANSI because this portion of the code is forced to compile always in Unicode. But the use of MultiByteToWideChar() function in ANSI version is more accurate.
Best regards,
Claudio.
Best regards.
Dr. Claudio Soto
(from Uruguay)
http://srvet.blogspot.com
User avatar
srvet_claudio
Posts: 2193
Joined: Thu Feb 25, 2010 8:43 pm
Location: Uruguay
Contact:

Re: HMG 3.1.4 (Test)

Post by srvet_claudio »

Pablo César wrote:Carlos, what do you mean about #ifdef IGH_UNICODE (here in red is it something wrong ?)
Pablo, change:

Code: Select all

#ifdef IGH_UNICODE
for:

Code: Select all

#ifdef UNICODE
Best regards.
Dr. Claudio Soto
(from Uruguay)
http://srvet.blogspot.com
User avatar
Pablo César
Posts: 4059
Joined: Wed Sep 08, 2010 1:18 pm
Location: Curitiba - Brasil

HMG 3.1.4 (Test)

Post by Pablo César »

srvet_claudio wrote:Pablo, change:

Code: Select all

#ifdef IGH_UNICODE
for:

Code: Select all

#ifdef UNICODE
Thank you Dr.
srvet_claudio wrote:SETCUEBANNER of the HMG.3.1.4, works
But please Claudio clarify if is working in XP. Because for me is not working in XP.
But the use of MultiByteToWideChar() function in ANSI version is more accurate.
And how it could be implemented in your opinion Claudio in Carlos source code ?
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
User avatar
danielmaximiliano
Posts: 2607
Joined: Fri Apr 09, 2010 4:53 pm
Location: Argentina
Contact:

Re: HMG 3.1.4 (Test)

Post by danielmaximiliano »

Claudio :
Resolvi el problema del IDE, configure el IDE Ansi con Crimsom como editor y Español como lenguaje, copie los 3 .ini
  • Language.ini
    Hmg.ini
    Editor.ini
los edite con Notepad++ y los conveti a UTF8 Without BOM, abri el IDE y se ejecuta sin ningun problema :mrgreen: , por algún problema el IDE no crea estos achivos en su formato de encoding ????

Windows 7 Home Premium 64 recien instalado y aplicado todos sus services pack , 4GB Ram.
*´¨)
¸.·´¸.·*´¨) ¸.·*¨)
(¸.·´. (¸.·` *
.·`. Harbour/HMG : It's magic !
(¸.·``··*

Saludos / Regards
DaNiElMaXiMiLiAnO

Whatsapp. := +54901169026142
Telegram Name := DaNiElMaXiMiLiAnO
User avatar
srvet_claudio
Posts: 2193
Joined: Thu Feb 25, 2010 8:43 pm
Location: Uruguay
Contact:

Re: HMG 3.1.4 (Test)

Post by srvet_claudio »

Pablo César wrote:
srvet_claudio wrote:SETCUEBANNER of the HMG.3.1.4, works
But please Claudio clarify if is working in XP. Because for me is not working in XP.
I not tried the Carlo's code, but the CueBanner of HMG.3.1.4 not work well in XP.
Best regards.
Dr. Claudio Soto
(from Uruguay)
http://srvet.blogspot.com
User avatar
Pablo César
Posts: 4059
Joined: Wed Sep 08, 2010 1:18 pm
Location: Curitiba - Brasil

Re: HMG 3.1.4 (Test)

Post by Pablo César »

danielmaximiliano wrote:Claudio :
Resolvi el problema del IDE, configure el IDE Ansi con Crimsom como editor y Español como lenguaje, copie los 3 .ini
  • Language.ini
    Hmg.ini
    Editor.ini
Congratulation, Daniel. Probably was not in UTF8 for spanish.
danielmaximiliano wrote:UTF8 Without BOM
I never use (without "BOM") option, simply "UTF-8" only.
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
User avatar
srvet_claudio
Posts: 2193
Joined: Thu Feb 25, 2010 8:43 pm
Location: Uruguay
Contact:

Re: HMG 3.1.4 (Test)

Post by srvet_claudio »

danielmaximiliano wrote:Claudio :
Resolvi el problema del IDE, configure el IDE Ansi con Crimsom como editor y Español como lenguaje, copie los 3 .ini
  • Language.ini
    Hmg.ini
    Editor.ini
los edite con Notepad++ y los conveti a UTF8 Without BOM, abri el IDE y se ejecuta sin ningun problema :mrgreen: , por algún problema el IDE no crea estos achivos en su formato de encoding ????

Windows 7 Home Premium 64 recien instalado y aplicado todos sus services pack , 4GB Ram.
Que extraño Daniel, verifique y a mi me crea el archivo Language.ini en UTF8.
Proba borrar el archivo Language.ini, cargar el IDE y cambiar el idioma a Español, tendría que crear automáticamente el archivo Language.ini en UTF8.
Best regards.
Dr. Claudio Soto
(from Uruguay)
http://srvet.blogspot.com
Post Reply