public static final void makeSameSize(JComponent[] comps) {
        if (comps.length == 0) {
            return;
        }

        int max = 0;
        for (int i = 0; i < comps.length; i++) {
            int w = comps[i].getPreferredSize().width;
            max = Math.max(w, max);
        }

        Dimension dim = new Dimension(max, comps[0].getPreferredSize().height);
        for (int i = 0; i < comps.length; i++) {
            comps[i].setPreferredSize(dim);
        }
    }
Loads an {@link Image} named <code>imageName</code> as a resource
relative to the Class <code>cls</code>.  If the <code>Image</code> can
not be loaded, then <code>null</code> is returned.  Images loaded here
will be added to an internal cache based upon the full {@link URL} to
their location.
<p>
<em>This method replaces legacy code from JDeveloper 3.x and earlier.</em></p>

@param imageName the name of the image
@param cls the class relative to the which the image resource should be obtained
@return the image

@see Class#getResource(String)
@see Toolkit#createImage(URL)
starter/src/main/java/org/jivesoftware/openfire/launcher/GraphicUtils.java