Retrieving the current print position in device unitsΒΆ

getprintxy()

Retrieve current print position in device units


SYNTAX

getprintxy(xpos, ypos)

Retrieves the x and y co-ordinates of the current print position in device units, and stores them in the fields xpos and ypos. This enables draw operations to be mixed easily with Sculptor print commands, because values retrieved can then be used to determine suitable co-ordinates to use with a drawing function.

The current print position is the position on the page at which the output of the next print[h] command would commence. It is updated every time a print[h] command is executed.

xpos, ypos

These must be the identifiers of numeric fields.

Note

The Sculptor system variable sys.Unit should be set to 0 (device units) before this function is called; its behaviour with other units is undefined. 0 is the default value for sys.Unit, so it is only necessary to reset it if a non-default value has been set.


RELATED TOPICS

Reports

setprintxy()

print[h]

Draw operations

Device units

sys.Unit