TextField with active rendering?

Any clue how I would go about making/using a TextField with active rendering?  I have tried creating a new TextField, then calling its .paint method and giving it my Graphics g object.  That paints nothing.  
 I have tried making a new class which Extends TextField and overrides it's paint method and paints the text / a rect where the TextField should be.  This paints stuff but i can't seem to figure out how to make it actually read keyboard events and what not.  Could someone explain to me why TextField.paint(g) will not produce anything?  isn't the paint method called from a parent component?

Also if someone could link me to some code for how to make my own TextField / button / something that can deal with user input / listeners

You have to put the TextField within a Frame or something and then use active rendering on the frame. The TextField doesn’t just magically work; it has to be used within an AWT gui.

You must be using a Frame somewhere just to have a graphical program. You draw the frame actively, and it draws everything itself. For the Frame, you should be overriding the paintComponent method, not the paint method. The paint method will paint all the components within the Frame.

You should probably use JTextFields and JFrames instead, but that probably isn’t necessary. If you’re trying to use a TextField within a JFrame, it won’t work (though that doesn’t sound like what’s happening). You can’t mix Swing and regular AWT components.

If you still have problems, you should probably post some code.

The book Developing Games in Java by David Brackeen explains how to mix Swing with drawing graphics pretty well.

Pulpcore has its own implementation of a non-AWT textfield, have a look at the source code. Pulpcore is here: http://www.interactivepulp.com/pulpcore/

If you ask the author of the library David Brackeen, a fellow JGO-er, he might let you use the code to adapt to your own game.

I think that’s the best way since active rendering with swing is a nightmare.

Cheers,
Keith