Previous Up Next

26.3.3  Commands for global display features

Adding a legend.

The legend command creates a legend on the screen.

Example

To put “hello” to the upper left of the point (1,1):

legend(1+i,"hello",quadrant3)

or:

legend(1+i,quadrant3,"hello")
Changing various features.

The display or color command changes the properties of graphics; the same properties that can also be changed with the display and color parameters (see Section 26.3.2).

The display or color command draws objects with specified properties.

Examples

display(1+i/2,2+i,1/2+2i,red)

or:

triangle(1+i/2,2+i,1/2+2i,display=red)
triangle(0,1,1+i,display=filled)

or:

display(triangle(0,1,1+i),filled)

By default, if a geometric object is named, the drawing is labeled.

Triangle:=triangle(0,1,1+i)

Creating the object with the display command and the hidden_name argument will draw it without the label.

display(Triangle,hidden_name)

Previous Up Next