.topic widget.imagebutton .title ImageButton .toc 1 ImageButton .index ImageButton .index wgtImageButton .index wgtImageButtonFromFile .index wgtImageButtonSetData .index wgtImageButtonLoadFile .h2 ImageButton A clickable button that displays an image instead of text. Has press/release visual feedback like a regular button. Can be created from raw pixel data or a BMP file. Header: widgets/widgetImageButton.h .h3 Creation .table Macro Description ----- ----------- wgtImageButton(parent, data, w, h, pitch) Create an image button from raw pixel data. wgtImageButtonFromFile(parent, path) Create an image button by loading a BMP file. .endtable .h3 Methods .table Macro Description ----- ----------- wgtImageButtonSetData(w, data, imgW, imgH, pitch) Replace the image with new raw pixel data. wgtImageButtonLoadFile(w, path) Replace the image by loading a new file. .endtable .h3 Events .table Callback Description -------- ----------- onClick Fires when the image button is clicked (press + release). .endtable .h3 Properties (BASIC Interface) .table Property Type Access Description -------- ---- ------ ----------- Picture String Write-only Load an image from a file path. ImageWidth Integer Read-only Width of the currently loaded image in pixels. ImageHeight Integer Read-only Height of the currently loaded image in pixels. .endtable .hr