import java.awt.*;public class Foh extends Canvas{ public void paint (Garphics g) { g.drawString ("Test", 100,200); }}
import java.awt.*;public class Bla{ public static void main( String args[] ) { Bla b = new Bla(); b.tuwas(); } public void tuwas() { Frame f = new Frame (); f.getContentPane().add( new Foh() ); //jedenfalls bei JFrame.. f.setSize (300,400); f.setVisible (true); }}