[lazarus] Bug in lcl resizing code and patch for win32

Karl Brandt pascalive at bol.com.br
Sat Jun 28 10:47:14 EDT 2003


Micha Nelissen wrote:

>Karl Brandt wrote:
>  
>
>>Sometime ago i sent a patch fixing the forms sizes under win32 and got
>>surprised to see that things were messed.
>>So i  did the  job again!
>>
>>Attached is a patch that makes the form sizes correct.
>>    
>>
>
>What was wrong? Those messages should send the same information as you
>retrieve via GetClientRect/GetWindowRect.
>  
>
In LCL, WindowSize = ClientSize while windows and VCL expect/returns 
diferent sizes, so is needed  some adjustments.

>Are the form sizes really correct for you? If I move the form the size is
>usually Left+Width instead of Width, etc.
>  
>
I didn't tested after the recent changes, but  when i fixed the first 
time it was OK.
I did a small prog to test the sizes of forms in win32. If interest you 
i can send it.

>  
>
>>But when we move or resize the window, strange effects occurs.
>>This happens because the LCL in TWinControl.InitializeWnd, sends a
>>LM_SETSIZE message with the Width and Height  parameters (which the
>>interface expect) while in TWinControl.RealizeBounds it sends the same
>>message with the Bottom-Right coordinates.
>>
>>I hope someone fix this.
>>    
>>
>
>Yes...this is the problem I'm having too (and trying to fix).
>
>Regards,
>
>Micha.
>
>_________________________________________________________________
>     To unsubscribe: mail lazarus-request at miraclec.com with
>                "unsubscribe" as the Subject
>   archives at http://www.lazarus.freepascal.org/mailarchives
>
>  
>







More information about the Lazarus mailing list