##- # Author: Brian Tiffin # Dedicated to the public domain # # Date: October 2016 # Modified: 2016-10-25/23:12-0400 ##+ # # window.icn, demontrate the &window keyword # procedure main() &window := open("default", "g", "size=90,60", "canvas=hidden") # all subsequent graphic functions default to using &window write("Colour depth (bits): ", WAttrib("depth"), " on device ", WAttrib("display"), " with window label ", image(WAttrib("windowlabel"))) Fg("vivid orange") FillRectangle(30, 30, 30, 20) Fg("medium cyan") FillRectangle(35, 35, 15, 8) # normally non graphic functions need to be told the window Fg("black") write(&window, "&window sample") WSync() WriteImage("../images/window.png") close(&window) end