public static function fromString(
        $imageContent,
        $mimeType,
        $x = null,
        $y = null,
        $width = null,
        $height = null
    ) {
        return new self(
            sprintf(
                'data:%s;base64,%s',
                $mimeType,
                base64_encode($imageContent)
            ),
            $x,
            $y,
            $width,
            $height
        );
    }