title: Java format GUI output
body: <p>If I want to format output in a GUI (specifically having only 2 decimal places for a number), would I use the <code>DecimalFormat</code> class along with the <code>printf()</code> method, or is there another way of doing this?</p>