HMG 3.1.5

HMG Unicode versions 3.1.x related

Moderator: Rathinagiri

User avatar
andyglezl
Posts: 1461
Joined: Fri Oct 26, 2012 7:58 pm
Location: Guadalajara Jalisco, MX
Contact:

Re: HMG 3.1.5 (Test)

Post by andyglezl »

Gracias Dr. Claudio, con lo que indicó, ya no despliega el "warning".
Thanks Dr. Claudio, which stated, no longer displays the "warning".

Code: Select all

HB_FUNC( HDGETSERIAL)
    {
    hb_retnl( Get_SerialNumber((char *) hb_parc(1)) );
    }
---------------------------------------------------------------
Esto es lo que tengo:

Code: Select all

#pragma BEGINDUMP
    #define _WIN32_IE      0x0500  
    #define HB_OS_WIN_32_USED
    #define _WIN32_WINNT   0x0400    <-------------- Ya tengo un define 
    #define _WIN32_WINNT   0x0500    <-------------- si añado este otro, despliega lo siguiente

    #include <windows.h>
    #include <commctrl.h>
    #include "hbapi.h"
    #include "hbvm.h"
    #include "hbstack.h"
    #include "hbapiitm.h"
    #include "winreg.h"
    #include "tchar.h"
    #include <shlobj.h>
    #include <winuser.h>
    #include <vfw.h>
    #include <windowsx.h>
D:\RespaldosPCs\DiscoC\Trabajo\ConAd>C:\hmg.3.1.5\build conad
Harbour 3.2.0dev (r1307180024)
Copyright (c) 1999-2013, http ://harbour-project.org/
conad.prg:7980:0: warning: "_WIN32_WINNT" redefined [enabled by default]
conad.prg:7979:0: note: this is the location of the previous definition
conad.prg:8190:0: warning: "LWA_COLORKEY" redefined [enabled by default]
c:\hmg.3.1.5\mingw\bin\../lib/gcc/mingw32/4.6.2/../../../../include/winuser.h:2399:0: note: this is
the location of the previous definition
conad.prg:8191:0: warning: "LWA_ALPHA" redefined [enabled by default]
c:\hmg.3.1.5\mingw\bin\../lib/gcc/mingw32/4.6.2/../../../../include/winuser.h:2400:0: note: this is
the location of the previous definition
Si comento *#define _WIN32_WINNT 0x0400, me despliega muchos errores mas.
If I comment * # define _WIN32_WINNT 0x0400, displays many bugs more.
Andrés González López
Desde Guadalajara, Jalisco. México.
User avatar
srvet_claudio
Posts: 2220
Joined: Thu Feb 25, 2010 8:43 pm
Location: Uruguay
Contact:

Re: HMG 3.1.5 (Test)

Post by srvet_claudio »

andyglezl wrote: Esto es lo que tengo:

Code: Select all

#pragma BEGINDUMP
    #define _WIN32_IE      0x0500  
    #define HB_OS_WIN_32_USED
    #define _WIN32_WINNT   0x0400    <-------------- Ya tengo un define 
    #define _WIN32_WINNT   0x0500    <-------------- si añado este otro, despliega lo siguiente

    #include <windows.h>
    #include <commctrl.h>
    #include "hbapi.h"
    #include "hbvm.h"
    #include "hbstack.h"
    #include "hbapiitm.h"
    #include "winreg.h"
    #include "tchar.h"
    #include <shlobj.h>
    #include <winuser.h>
    #include <vfw.h>
    #include <windowsx.h>
D:\RespaldosPCs\DiscoC\Trabajo\ConAd>C:\hmg.3.1.5\build conad
Harbour 3.2.0dev (r1307180024)
Copyright (c) 1999-2013, http ://harbour-project.org/
conad.prg:7980:0: warning: "_WIN32_WINNT" redefined [enabled by default]
conad.prg:7979:0: note: this is the location of the previous definition
conad.prg:8190:0: warning: "LWA_COLORKEY" redefined [enabled by default]
c:\hmg.3.1.5\mingw\bin\../lib/gcc/mingw32/4.6.2/../../../../include/winuser.h:2399:0: note: this is
the location of the previous definition
conad.prg:8191:0: warning: "LWA_ALPHA" redefined [enabled by default]
c:\hmg.3.1.5\mingw\bin\../lib/gcc/mingw32/4.6.2/../../../../include/winuser.h:2400:0: note: this is
the location of the previous definition
Si comento *#define _WIN32_WINNT 0x0400, me despliega muchos errores mas.
If I comment * # define _WIN32_WINNT 0x0400, displays many bugs more.
Comentar en C así:

Code: Select all

//   #define _WIN32_WINNT   0x0400 
o así:

Code: Select all

/*  #define _WIN32_WINNT   0x0400 */ 
Best regards.
Dr. Claudio Soto
(from Uruguay)
http://srvet.blogspot.com
User avatar
andyglezl
Posts: 1461
Joined: Fri Oct 26, 2012 7:58 pm
Location: Guadalajara Jalisco, MX
Contact:

Re: HMG 3.1.5 (Test)

Post by andyglezl »

Hola, el siguiente ejemplo funciona en HMG 3.0.46, pero en HMG 3.1.5 no.
No cambia el tamaño del control IMAGE.
alguna idea ?, es BUG ?
------------------------------------------------------------------------
Hi, the following example works in HMG 3.0.46 but not HMG 3.1.5.
No resizes the control IMAGE.
any ideas?, is BUG?

Code: Select all

#include "HMG.CH"

FUNCTION MAIN( )
	PRIVATE cFileName := "demo.jpg"     //   Pon cualquier imagen  //  Put any image
	
    nAncImg := System.DesktopWidth
    nAltImg := System.DesktopHeight

        DEFINE WINDOW V_FotoGde AT 000,000 WIDTH 650 HEIGHT 466 VIRTUAL WIDTH nAncImg+10 VIRTUAL HEIGHT nAltImg+10 ;
				TITLE "DOCUMENTO: "+cFileName MAIN NOSIZE

            @ 000,000 IMAGE I_Imgpso PICTURE cFileName WIDTH nAncImg HEIGHT nAltImg
            ON KEY ESCAPE OF V_FotoGde ACTION ( V_FotoGde.Release )
            DEFINE CONTEXT MENU OF V_FotoGde
                   ITEM '  Reducir   -' ACTION SumRest( "-", cFileName )
                   ITEM '  Restaurar  ' ACTION SumRest( "R", cFileName )
                   SEPARATOR
            END MENU
        END WINDOW
        CENTER   WINDOW V_FotoGde
        ACTIVATE WINDOW V_FotoGde
RETURN( nil )
FUNCTION SumRest( cValx, cArch )
    IF cValx=="-" 
        nAnpso:=V_FotoGde.I_Imgpso.Width-200 
		nAlpso:=( nAnpso * V_FotoGde.I_Imgpso.Height ) / V_FotoGde.I_Imgpso.Width
        V_FotoGde.I_Imgpso.Width :=nAnpso
        V_FotoGde.I_Imgpso.Height:=nAlpso
    ELSE        
        V_FotoGde.I_Imgpso.Width :=nAncImg
        V_FotoGde.I_Imgpso.Height:=nAltImg
    ENDIF
    V_FotoGde.I_Imgpso.Picture:=cArch
    V_FotoGde.I_Imgpso.Refresh
RETURN( Nil )
Andrés González López
Desde Guadalajara, Jalisco. México.
User avatar
Pablo César
Posts: 4059
Joined: Wed Sep 08, 2010 1:18 pm
Location: Curitiba - Brasil

HMG 3.1.5 (Test)

Post by Pablo César »

Hola Andrés,

Bastaria comentar tu linea:

V_FotoGde.I_Imgpso.Picture:=cArch

Pues aqui estaria volviendo a cargar el archivo con las medidas que fueron definidas originalmente.
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
User avatar
andyglezl
Posts: 1461
Joined: Fri Oct 26, 2012 7:58 pm
Location: Guadalajara Jalisco, MX
Contact:

Re: HMG 3.1.5 (Test)

Post by andyglezl »

Hola Pablo Cesar, gracias.

Pero debió haber cambiado algo ya que si comento esa linea,
se invierte el problema, al compilarlo con 3.0.46 deja de funcionar.
---------------------------------------------------------------
Hi Pablo Cesar, thanks.

But he must have changed something because if I comment that line,
reverses the problem, to compile with 3.0.46 stops working.
Andrés González López
Desde Guadalajara, Jalisco. México.
User avatar
Pablo César
Posts: 4059
Joined: Wed Sep 08, 2010 1:18 pm
Location: Curitiba - Brasil

HMG 3.1.5 (Test)

Post by Pablo César »

andyglezl wrote:debió haber cambiado algo
Ya lo creo ! Bastante nuevas propiedades fueron implementadas en la funcion _DefineImage. Justamente _HMG_SYSDATA [ 31 ] y _HMG_SYSDATA [ 32 ] que trata de las propiedades Width y Height que antes simplesmente cargaba con valor cero. En mi opinion, está mucho mejor gracias a las grandes contribuciones del Dr. Soto.
andyglezl wrote:al compilarlo con 3.0.46 deja de funcionar
Creo que es una cuestion de limpiar la área que la imagen ocupaba. Si quieres mantener compatibilidad, al compienzo de la function SumRest, esconda la imagen:

V_FotoGde.I_Imgpso.Hide

Y en lugar que tenia:

V_FotoGde.I_Imgpso.Picture:=cArch

Subtituye por:

V_FotoGde.I_Imgpso.Show

Volviendo la imagen. Aqui me dió bien en la dos versiones.
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
User avatar
andyglezl
Posts: 1461
Joined: Fri Oct 26, 2012 7:58 pm
Location: Guadalajara Jalisco, MX
Contact:

Re: HMG 3.1.5 (Test)

Post by andyglezl »

Perfecto, problema resuelto, gracias Pablo César.
Andrés González López
Desde Guadalajara, Jalisco. México.
User avatar
srvet_claudio
Posts: 2220
Joined: Thu Feb 25, 2010 8:43 pm
Location: Uruguay
Contact:

Re: HMG 3.1.5 (Test)

Post by srvet_claudio »

Pablo César wrote:please accept improvement suggestions for IDE:
Hi Pablo, any idea is welcome.
At the moment I have no time to dedicate to the IDE.
Please, create a new topic only for post all the suggestions of the IDE for future updates.
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.5 (Test)

Post by Pablo César »

srvet_claudio wrote:
Pablo César wrote:please accept improvement suggestions for IDE:
Hi Pablo, any idea is welcome.
Thank you Claudio for the oportunitiy. :)

I have already move this suggestions messages in one of many existing topic about IDE suggestions and I compiled others suggestions from others colleagues just to keep in this topic/message always updated for you solving the IDE pendings for future updates.
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
User avatar
srvet_claudio
Posts: 2220
Joined: Thu Feb 25, 2010 8:43 pm
Location: Uruguay
Contact:

Re: HMG 3.1.5 (Test)

Post by srvet_claudio »

Pablo César wrote:I have already move this suggestions messages in one of many existing topic about IDE suggestions and I compiled others suggestions from others colleagues just to keep in this topic/message always updated for you solving the IDE pendings for future updates.
Thanks.
Best regards.
Dr. Claudio Soto
(from Uruguay)
http://srvet.blogspot.com
Post Reply