mirror of
https://github.com/jneug/zeichenmaschine.git
synced 2026-04-14 14:43:33 +02:00
30 lines
565 B
Java
30 lines
565 B
Java
import schule.ngb.zm.Drawable;
|
|
import schule.ngb.zm.DrawableLayer;
|
|
import schule.ngb.zm.Zeichenmaschine;
|
|
|
|
public class Leinwand {
|
|
|
|
private final Zeichenmaschine zm;
|
|
|
|
private final DrawableLayer zeichenflaeche;
|
|
|
|
public Leinwand() {
|
|
zm = new Zeichenmaschine(800, 800, "ZM: Shapes", false);
|
|
zeichenflaeche = new DrawableLayer();
|
|
zm.addLayer(zeichenflaeche);
|
|
}
|
|
|
|
public void anzeigen( Drawable pForm ) {
|
|
zeichenflaeche.add(pForm);
|
|
}
|
|
|
|
public void beenden() {
|
|
zm.exit();
|
|
}
|
|
|
|
public void zeichnen() {
|
|
zm.redraw();
|
|
}
|
|
|
|
}
|