up Inquisit Language Reference

dropPosition attribute

The dropPosition attribute indicates the screen location where stimuli are positioned after being dragged and dropped onto a valid drop target.

Member of

<button> <clock> <html> <picture> <shape> <text> <video>

Syntax

/ dropPosition = (x, y)

or

/ dropPosition = (xposition, yposition)

or

/ dropPosition = (xexpression, yexpression)

Parameters

Name Type Description
xposition xpositionenum
ValueDescription
anywhereAnywhere on a visual stimulus.
centerCenter of a visual stimulus.
leftLeft half of a visual stimulus.
rightRight half of a visual stimulus.
yposition ypositionenum
ValueDescription
anywhereAnywhere on a visual stimulus
bottomBottom half of a visual stimulus.
centerCenter of a visual stimulus.
topTop half of a visual stimulus.
x extent The horizontal canvas coordinate in pixels, percent(default), or points.
y extent The vertical canvas coordinate in pixels, percent(default), or points.
xexpression value An expression resolving to the horizontal canvas coordinate in pixels, percent(default), or points.
yexpression value An expression resolving to the vertical canvas coordinate in pixels, percent(default), or points.

Remarks

Horizontal dropPosition is relative to the left side of the canvas. 0% is the left edge of the canvas and 100% is the right edge. Vertical dropPosition is relative to the top of the canvas, with 0% placing the dropped item at the top and 100% placing it at the bottom edge. Percentages may be specified as decimals (e.g., 52.968) for increased precision. The default dropPosition is the middle of the stimulus.

Examples

The following sets the dropPosition of the text to the lower left corner of the canvas:

<text myText>
/ items = ("ipsum")
/ dropPosition = (0, 100)
</text>

The following sets the dropPosition of the text to the middle of the canvas with 800 X 600 pixels:

<text myText>
/ items = ("ipsum")
/ dropPosition = (400px, 300px)
</text>

The following sets the dropPosition based on the trial number:

<text myText>
/ items = ("ipsum")
/ dropPosition = (trial.myTrial.currentTrialNumber * 5, trial.myTrial.currentTrialNumber * 5)
</text>

Copyright Millisecond Software, LLC. All rights reserved.