The polygon group – Brother HL-2170W User Manual

Page 176

Advertising
background image

CHAPTER 4 HP-GL/2 - 25

7.4.

The polygon group

Instruction Function
PM Polygon

Mode

EA

Edge Absolute Rectangle

ER

Edge Relative Rectangle

EP Edge

Polygon

EW Edge

Wedge

RA

Fill Absolute Rectangle

RR

Fill Relative Rectangle

WG Fill

Wedge

FP Fill

Polygon

PM - Polygon mode

PM [ ms ] [;]

This command is used for entering and leaving polygon mode, the mode that allows you to access the

polygon buffer.

When in polygon mode you can use any of the vector group commands to define the vertices of a polygon.

The following commands can be used;

DF, IN, AA, AR, AT, BR, BZ, CI, PA, PD, PE, PR, PU, RT

The polygon you have defined is not printed until you exit polygon mode and fill or edge the polygon.

ms, the mode status, can have the value 0, 1 or 2. If ms = 0 the command empties the polygon buffer and

enters polygon mode. A value of 1 closes the current polygon and remains in polygon mode. All
commands sent following a PM1 before a PM2 or a further PM1 are used to build one sub-polygon. A
value of 2 closes the current polygon or sub-polygon and exits polygon mode.

Having exited polygon mode you can use the EP and FP commands to edge or fill the polygons you have

defined.

The EP command only draws between points defined when the pen was in the down position.

The FP command fills the area between the polygon vertices irrespective of whether the pen was up or down

when the polygon was defined.

The first point in the polygon buffer is the pen position when the PM0 command was invoked.

The next pen position specified after a PM1 command becomes the first vertex of the next sub-polygon.

When plotting a polygon the pen always moves to the first point in the up position.

Using the command with no parameters clears the polygon buffer and enters polygon mode. This is

equivalent to the PM0; command.

If a DF or IN command is invoked in the polygon mode, the printer quits polygon mode, clears the

polygon buffer and executes the subsequent command.

If an ESC E reset command is invoked while the printer is in polygon mode, the printer quits polygon

mode, clears the polygon buffer, exits HP-GL/2 and ejects the page.

EA - Edge rectangle absolute

EA X, Y[;]

X ; X coordinate of opposite corner for the rectangle
Y ; Y coordinate of opposite corner for the rectangle

X and Y coordinates are absolute coordinates in current units.

Plots the rectangle formed by the current position and the opposite corner specified by X and Y.

After plotting, the cursor returns to its point of origin and pen up/down status remains as selected.

Plotting is performed whether the pen is up or down.

Advertising