y=
y= sets the y-coordinate of every node in the region named by dom to the value of an expression, evaluated at that node.
Syntax
y= expression
y = expression
expression: as for x=, which states every rule the six equations share: the variables, the order, the blanks around the=, the line’s end,∧.
What it does
At every node of the region that an active element uses, James evaluates the expression and stores the result as the node’s y-coordinate: the angle in degrees of a cylinder part. The rules of x= apply unchanged.
When James applies it
Step 20 of the hierarchy, once, after the part’s last pass, as x= says. Legal only in the Part phase.
Diagnostics
- E0221, E0412, E1500, E1501, E1503: as for x=.
- E1502: a coordinate that is not finite after the equation.
Example
The script tests/corpus/261-swap-xy-p279/input.tg, which make test runs:
c the swap of Vol. 1, p. 279: the x- and y-coordinates exchanged through t1
block 1 3 5;1 2;1 2;0 1 2 0 1 0 1
t1 = x
x = y
y = t1
endpart
The swap of the manual’s page: t1 keeps x while x takes y, then y takes the kept value, the three equations running in input order over the whole part.