Skip to content
Chris Petersen edited this page Oct 16, 2014 · 1 revision

glgui-sprite creates a sprite, with optional parameter arguments.

Parameter Description
g Graphical User Interface (GUI) for this widget
args Optional: Arguments, such as 'x, 'y, 'presscallback, 'releasecallback, and 'rendercallback

Example

Example1: Here is a real example from apps/uSquish/main.scm that generates a sprite with optional positions and call back procedures

(list (glgui-sprite gui 'x x 'y y0 'image stargrey.img))
(list (glgui-sprite gui 'rendercallback animal-animate 
       'presscallback animal-press 'releasecallback animal-release))
Clone this wiki locally