HTBasic Help
×
Menu
Index

DIGITIZE

Inputs digitized X and Y coordinates.
 
 DIGITIZE x, y [, string-name$]
 
Usage:
DIGITIZE Xcoor,Ycoor,Stat$
IF Ready THEN DIGITIZE X,Y
 
Example: DIGITIZE.BAS
 
Description:
A point is digitized from the GRAPHICS INPUT IS device and the coordinates of the point are assigned to the variables. The coordinates are in default units or the units defined in a WINDOW or SHOW statement. A DIGITIZE may be completed on the keyboard (if GRAPHICS INPUT IS is from the keyboard) by pressing CONTINUE or ENTER. The DIGITIZE statement may optionally specify a status string variable. This 8 byte status variable inputs the status of the GRAPHICS INPUT IS device. The 8 byte status string variable is defined as follows:
 
Byte
Meaning
1
Indicates End of Stream for a device supporting continuous point stream digitizing. Byte 1 may be used as the pen control value in a PLOT. It is "0" if it is the last of a continuous point stream. It is "1" otherwise, including points from a device supporting only single point digitizing.
2
Comma delimiter character.
3
Clip Indicator - If the character is a "0", then the point is outside the hard-clip limits. If a "1", the point is inside the hard-clip limits, but outside the soft-clip limits (see CLIP). If a "2" then it is inside the soft-clip limits.
4
Comma delimiter character.
5
Tracking ON/OFF - If the character is a "0", then tracking is off; if a "1", then tracking is on.
6
Comma delimiter character.
7-8
Button Positions. If S$ is the status string and B is the button number you wish to test, then BIT(VAL(S$[7,8]),B-1) returns one if B is down and zero if B is up.
 
See Also: