* the text of the image
* @return the created node
*/
public static BoostedNode createImage(BoostedNode parent,
Component graphic, String text) throws Exception {
BoostedNode div = createDiv(parent);
RenderedImage image = GuiBoostUtils.createScreenshot(graphic);
byte[] imageBytes = GuiBoostUtils.writeImageToBytes(image,
GuiBoostUtils.FORMAT_PNG);
createImageNode(div, imageBytes, GuiBoostUtils.FORMAT_PNG, "image");
// TODO: better name than image