Member variable XbpTreeViewItem():image Foundation

Resource ID, XbpBitmap or XbpIcon object of the bitmap or icon which indicates the normal state.

Attribute: EXPORTED
Data type: Numeric | Object (-1)
Description

The resource ID of a BITMAP resource (Windows Bitmap file format) or icon can be assigned to the instance variable :image to visualize the normal state of an XbpTreeViewItem object (not marked and not expanded). Resource IDs must be defined in a resource file which is linked to the EXE file using the resource compiler. Instead of a resource ID, an object of the XbpBitmap or XbpIcon classes can be assigned. Assigning a XbpBitmap object allows the usage of images defined in various image file formats (.BMP/.JPG/.PNG). Furthermore, if a transparent color has been defined for the bitmap object, transparent areas within the image are automatically replaced with the background color defined for the XbpTreeView object.

If method :create() of the tree view item has been executed, assigning a new icon or bitmap :image changes the image displayed by the item. This can be used to change a tree view item's image dynamically while it is being displayed. See method :setImage() for further information.

If an XbpBitmap or XbpIcon object is assigned to the :imageinstance variable, one of the methods :load() or :loadFile() must have previously been called. For bitmaps constructed in memory, method :make() must have been used. Moreover, it is discouraged to use the XbpBitmap or XbpIcon object to load or define a different image as long as it is assigned to the treeview item. Instead, a new object should be created for each different image.

Feedback

If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.