Migration Guide : E. Features Introduced in OpenROAD 6.2 : Changes to Existing Features : FormField.UpdBackground Method Gets New Parameters for Active Field Background Bitmaps
 
Share this page          
FormField.UpdBackground Method Gets New Parameters for Active Field Background Bitmaps
The FormField class's UpdBackground method now takes four new parameters that you may use to manipulate the background images of active fields. These special parameters apply only to fields that have their BgDisplayPolicy attributes set to one of the "outline" settings: BDP_BORDERED, BDP_BORDEREDSCALED, or BDP_CORNERED—see FormField.BgDisplayPolicy Attribute Gets New Border Settings (see page FormField.BgDisplayPolicy Attribute Gets New Border Settings).
The method now has the following syntax for active fields:
FormField.UpdBackground(imageindex = integer, cornerradius = integer,
    opacity = float, spritemap = StringObject)
You may call this method if you are applying special parameters to an active field background or loading a different image into the same BitmapObject already pointed to by the BgBitmap attribute. For example:
field(personaldata.name).BgBitmap.FileHandle = 'c:\windows\honey.bmp';
field(personaldata.name).UpdBackground();
The new parameters are:
imageindex
Specifies the index of the image to use in bitmaps that contain multiple images
cornerradius
Specifies the rounding radius, in pixels, for the corners of the background bitmap being applied
opacity
Specifies the opacity of the field's background: 0.01 is fully transparent; 0.99 is fully opaque
spritemap
Specifies the pattern of embedded sprites (icons) to display over the field's background
For complete information and examples, see the FormField UpdBackground Method in the Language Reference Guide. See also the FormField BgDisplayPolicy Attribute and BgDisplayPolicy Settings in the Language Reference Guide.