#define X 50
#define Y 50
#define WIDTH 100
#define HEIGHT 40
screen.resolution.set (512,384)
sprite.display ("avo\logo.spr",X/2,Y/2)
menulist.color.select (COLOR_TRANSPARENCY)
menulist.backcolor.select (COLOR_GRAY)
@list=menulist.create (WIDTH,HEIGHT,menu.manager)
menulist.item.add (@list,"Open")
menulist.item.add (@list,"Load")
menulist.item.add (@list,"Save")
menulist.item.add (@list,"Save as...")
menulist.item.add (@list,"Print")
menulist.item.add (@list,"Quit")
menulist.display (@list,X,Y)
screen.set (BACK)
pattern.display ("avo\bubble.gif")
screen.end ()
text.display ("Press RETURN to set the transparency. Then press ESCAPE to exit.",CENTER,350)
keyboard.wait (KEY_ESCAPE)
script.stop ()
procedure menu.manager (@event,%status,%index)
if (%flag)
menulist.transparency.set (@event,TRUE)
else ()
menulist.transparency.set (@event,FALSE)
endif()
%flag^=TRUE
%data=menulist.transparency.get (@event)
text.display (" The transparency of the menulist is : " + STR (%data)+" ",CENTER,10)
end procedure