A SERVICE OF

logo

EN
HP-GL/2 Commands and Syntax
17-7
Figure 17-1 Typical HP-GL/2 Command
z
Mnemonic
--The two-letter mnemonic reminds you of the
command’s function. The mnemonic can be uppercase or
lowercase.
z
Parameter(s)
--Some commands have no parameters; for those
commands which have them, parameters can be either required
or optional (as indicated in the description of that command).
z
Separator(s)
--When you use parameters, you must separate
them with a comma or space, or in the case of a numeric
parameter, with a + or - sign. (Commas are recommended
because some computers eliminate spaces, especially when
sending variables.)
z
Terminator
--All commands require a terminator. Most HP-GL/2
commands are terminated by a semicolon or the first letter of the
next mnemonic, a white space, or a tab (exceptions: LB uses a
user-defined terminator; PE cannot use the first letter of the next
mnemonic). The last command prior to exiting HP-GL/2 mode
must
be terminated with a semicolon.
The following illustration shows the flexibility of the syntax. Each
variation of the two-command sequence is permissible; however, the
method shown on the left is recommended in most instances. The
recommended method uses the first letter of the next mnemonic to
terminate commands, uses no space between the mnemonic and its
parameters, and separates parameters with a comma. (For clarity,
examples in this HP-GL/2 section of the manual use semicolons as
terminators, as shown in the middle example below.)
Figure 17-2 Illustration of Syntax Flexibility