public class Label
  Comment     Returned-by     Constructor-argument     Method-argument     Field-type     Type-bound     Links  

A Label object is a component for placing text in a container. A label displays a single line of read-only text. The text can be changed by the application, but a user cannot edit it directly.

For example, the code . . .


 setLayout(new FlowLayout(FlowLayout.CENTER, 10, 10));
 add(new Label("Hi There!"));
 add(new Label("Another Label"));
 

produces the following labels:

Two labels: 'Hi There!' and 'Another label'

extends Component implements Accessible

Since:  1.0