This article applies to:
This sample illustrates how to draw basic shapes with the Canvas object's drawing commands.
The Canvas object is a scripting object that has no graphical user interface (GUI) or property pages. All properties and methods are accessible only through user-written script.
The sample experiment is a basic luminance task. The InLine object contains E-Basic script that creates a Canvas, sets the PenColor, PenWidth, and FillColor properties, draws the appropriate shape, and then increments the changing color for the next drawing. The time at which both shapes were the same color, and the time of the subject's response is recorded and presented as feedback.
NOTE: In the E-Prime 2.0 and 3.0 versions, an offscreen canvas is drawn to then flipped on-screen. This is because Windows 8 and beyond requires display flipping to be enabled. For more information, see INFO: DisplayDevice.FlippingEnabled .
For more information about the Canvas object, please refer to the E-Prime Command Reference (https://pstnet.com/ecr).