@Override
    public Dimension getPreferredSize()
    {
        if(this.image == null) return new Dimension(600, 300);
        return new Dimension(this.image.getWidth() + 2*border, this.image.getHeight() + 2*border);
    }