public ImageComponent(String imageUrl) {
        super();

        URL url;
        try {
            url = new URL(imageUrl);
        } catch (MalformedURLException e) {
            e.printStackTrace();
            return;
        }

        try {
            image = ImageIO.read(url);
            System.out.println("width: " + image.getWidth() + ", height: " + image.getHeight());
            setPreferredSize(new Dimension(image.getWidth(), image.getHeight()));
            //setSize(image.getWidth(), image.getHeight());
        } catch (IOException e) {
            e.printStackTrace();
        }

    }