Page 1 of 1
BITMAP 'SCALE' IN DCPUSHBUTTONXP
Posted: Mon Aug 15, 2011 1:41 pm
by pierredaou
Hi,
the Bitmap 'Scale' is not working in DCPUSHBUTTONXP, I tried different values in order to minimize the size proportionally, nothing has changed. Is there any other way to fit the picture proportionally in the size limits ? the picture background look awkward.
N.B. I am using a High Res .JPG file.
Regards
Pierre
Re: BITMAP 'SCALE' IN DCPUSHBUTTONXP
Posted: Mon Aug 15, 2011 5:08 pm
by rdonnay
Send me your sample program so I can see what you are trying to do.
Re: BITMAP 'SCALE' IN DCPUSHBUTTONXP
Posted: Mon Aug 15, 2011 9:44 pm
by pierredaou
Hi Roger,
I am using a 450x1060x24p size picture but it is very big to show it in the size of 400x550, so I scaled it to half the size ( proportional scaling ), is this what scale supposed to do ?
@ 215,100 DCPUSHBUTTONXP ;
SIZE 225,530 ;
pixel ;
BITMAP {|| HORSES->PHOTO1} scale .5
Regards,
Pierre
Re: BITMAP 'SCALE' IN DCPUSHBUTTONXP
Posted: Tue Aug 16, 2011 11:48 am
by rdonnay
Could you please send me your JPG file?
Re: BITMAP 'SCALE' IN DCPUSHBUTTONXP
Posted: Tue Aug 16, 2011 11:55 am
by pierredaou
sorry, Attached.
and by the way skipping the record to get another JPG file is not refreshing the background.
Regards
Re: BITMAP 'SCALE' IN DCPUSHBUTTONXP
Posted: Sat Aug 20, 2011 10:13 am
by rdonnay
Pierre -
I believe that I have fixed the problem.
The attached file contains a new _DCXBUTT.PRG.
Copy this file to your \exp19\source\dclipx directory and run build19_sl1.bat to rebuild DCLIPX.DLL.
Here is the test program I used (also included in the attached file).
Code: Select all
#INCLUDE "dcdialog.CH"
FUNCTION Main()
LOCAL GetList[0], n := 0
@ 215,100 DCPUSHBUTTONXP ;
SIZE 225,530 ;
pixel ;
BITMAP {||Horse(@n)} scale .5 ;
ACTION {|a,b,o|o:refresh()}
DCREAD GUI FIT
RETURN nil
* ---------
PROC appsys ; return
* ---------
STATIC FUNCTION Horse(n)
n++
IF n %2 = 0
RETURN 'RedHorse.Jpg'
ENDIF
RETURN 'Horse.Jpg'
Re: BITMAP 'SCALE' IN DCPUSHBUTTONXP
Posted: Wed Aug 24, 2011 10:39 am
by pierredaou
Thank You Roger, I will check it and get back to You.
Regards
Re: BITMAP 'SCALE' IN DCPUSHBUTTONXP
Posted: Thu Aug 25, 2011 3:35 am
by pierredaou
thanks again. It works.