 <p>you can use this</p> <pre><code>@Override public void paintComponents(Graphics g) { super.paintComponents(g); g.drawString("Hello", 0, 0); } </code></pre> <p>or use jTextField</p> <pre><code> jTextField1.setText("Hello"); </code></pre>