7.5

Table Of Contents
Command: Tells the document to:
')),0) tion of the data selection.
show(@(1,1,12)) Display the text that appears from columns 1 through 12 on line 1 of the current data page.
At this point you might want to introduce other commands into the code, or modify some commands and verify the changes
produce the result you expect. Or perhaps you want to create a new data selection that starts in the middle of the data page
and extends over several lines to see how PlanetPress Talk handles multi-line data selections.
PlanetPress Talk Terminology
What terms does the PlanetPress Talk Language Reference use?
The PlanetPress Talk Language Reference uses the following terms:
Term: Definition:
command A generic term that encompasses operators, functions, procedures, condition structures, and loop structures.
expression
A piece of PlanetPress Talk code used in a PlanetPress Talk-enabled input box, which will always return a value of
the type expected by that input box. For example:
=strtoint(@(1,1,4))
statement
A single line of PlanetPress Talk code. For example:
define(&max, integer, strtoint(@(1,1,4)))
script or
program
A sequence of one or more statements, executed sequentially. For example the following script draws a filled
shape:
moveto(1,1)
lineto(1.5,2)
curveto(1,1,1,3,0.5,2)
closepath()
stroke()
The Elements of PlanetPress Talk
What are the elements of the PlanetPress Talk scripting language?
PlanetPress Talk includes all of the features one expects in a scripting language. It has a defined set of data types (see "Data
Types" (page 222)) and the following categories of elements that you use to build scripts:
Category: Description:
Variables A variable is a value that changes over time. See "Variables" (page 224).
System
objects
An object is a set of related system variables. For example the physical system object contains the system var-
iables that describe the current x and y coordinates of the drawing pen on the physical page. You reference one of
the system variables in an object by prefixing the name of the system object to the name of the variable. For exam-
ple &physical.x references the x coordinate system variable in the physical system object.
Operators
and Oper-
ator func-
tions
An operator is a symbol that performs a common operation. For example, the + is an operator that adds two
numbers together or concatenates two strings. An operator function is an operator that does not use a symbol to
represent its operation. For example the add command is an operator function. Both operators and operator func-
tions operate on one or more operands. For example the add command operates on two measure or integer
values (the operands). See "Operators and Operator Functions" (page n) for a complete list of all operators and
operator functions available in PlanetPress Talk.
Procedures
A procedure performs an action. For example the curveto procedure draws a Bezier curve, the rectangle pro-
cedure draws a rectangle, and the setfillcolor procedure sets the fill color. Most procedures require arguments.
For example, the rectangle procedure requires six arguments: the x and y coordinates of the upper left hand
corner of the rectangle, the width and height of the rectangle, and whether it is filled and/or stroked.
©2010 Objectif Lune Inc - 219 -