private function calculateCharacterWith($fontName, $fontSize, $char)
    {
        if (isset($this->fonts[$fontName])) {
            $box = imageftbbox($fontSize, 0, $this->fonts[$fontName], str_repeat($char, 100));
            $width = abs($box[4] - $box[0]) / 6.73 / 100;
            return round($width, 3);
        }

        return 0.1 * $fontSize;
    }