Copyright © 1998-2010 MultiMedia Soft

PictureCustom property

Previous pageReturn to chapter overviewNext page

Type

LPCTSTR for Visual C++

String for Visual Basic

 

 

Syntax

object.PictureCustom [=String]

 

 

Remarks

The filename or HTTP URL of the picture file used as a mask to render the shape of the button.

Supported bitmap formats are BMP, GIF, or PNG.

Applies only when the Shape property is set to SHAPE_CUSTOM (Custom).

If the filename is an HTTP URL you can use the proprietary compressed format AMZ.

If you need to download the file from an FTP URL you can use the SetPictureFromNet method.

The color of the picture's left top pixel is treated as transparent so every pixel containing this color will not be considered as part of the bitmap.

The example below shows how a black and white picture can be used as a mask for a button that will have the same shape of the white part of the picture.

3dabm_i000049

NOTE 1: from Version 3 of the control the mask picture can have more than one region.

NOTE 2: from Version 7 of the control you can use also color pictures and not only black and white pictures: this is very useful for implementing custom 3D rendering of the control surface.

 

 

Notes

When pictures or animations are set at design-time, you do not need to distribute the pictures or animations with your application. This is because they will be included in your program at compile-time. Redistribution of images is only necessary when the images on the button will be changing at run-time.