<pre><code>private JButton jBtnDrawCircle = new JButton("Circle");
private JButton jBtnDrawSquare = new JButton("Square");
private JButton jBtnDrawTriangle = new JButton("Triangle");
private JButton jBtnSelection = new JButton("Selection");
</code></pre>

<p>How do I add action listeners to these buttons, so that from a main method I can call <code>actionperformed</code> on them, so when they are clicked I can call them in my program?</p>

Your best bet is to review the
Java Swing tutorials
, specifically the
tutorial on Buttons
.
The short code snippet is:
```
```
jBtnDrawCircle.addActionListener( /*class that implements ActionListener*/ );
```
```