Specials - Sketch
Description: Sketch

Next: Sweeps, Previous: Polygons, Up: Drawables

#### 3.2.5 Specials

Syntax:

         special $raw_text$[options] arg_list

Here `$` can be any character and is used to delimit the start and end of raw_text. The command embeds raw_text in the `sketch` output after performing substitutions as follows.

- `#`i where i is a positive integer is replaced by the i'th value in arg_list. Point and vector arguments become two-dimensional points, which are the transformed 3d arguments projected onto the x-y plane. This allows two-dimentional output elements such as labels to be easily positioned with respect to three-dimensional features in the drawing. Scalar arguments are subsituted directly. No transformation is applied.
- `#{`i`}` is also replaced as above.
- `#`i`'2` is replaced as above for points or vectors. It is an error for the i'th argument to be a scalar.
- `#`i`'x`, `#`i`'y`, or `#`i`'z` is replaced, respectively, by the scalar x, y, or z-coordinate of the argument point or vector. It is an error for the i'th argument to be a scalar.
- `#`i`'3` is replaced by the three-dimensional transformed argument. Note that if a perspective transformation has been applied, the z-coordinate has little geometric significance, though it accurately indicates relative depth.
- `#`i`-`j where i and j are positive integers is replaced by a string `{`angle`}` where angle is the polar angle of a vector from the i'th point in point_list to the j'th point projected into the x-y plane. It is an error for the i'th or j'th argument to be a scalar or a vector.
- `#{`i`-`j`}` is also replaced as above.
- `##` is replaced with `#`.

The forms with braces { } are useful when the argument is immediately followed by a digit or a tick character that is part of the TeX code.

The only useful option of `special` is `lay`, which determines if the substitued raw text is emitted before, after, or using the first point in point_list as an indicator of depth. These occur, respectively, with `lay=under`, `lay=over`, and `lay=in`. See Special objects and TikZ/PGF user-defined styles for examples. See Internal options.