(function() { load("Koala") # create the application and ensure that the relevant C level # actions are installed for the application. X = XApplication("Koala") KInit(X) # Create an instance of the Koala Kanvas widget. k = Widget("l","Knvas",X) XRealize(X) d = as.Device(k) setDevice(d) # setCursor(as(k,"XWindow"), Cursor("X_cursor")) x = 1:100 y = rnorm(length(x)) + 10 KPlot(x,y, widget=k) return(list(X,k,d)) })()