private static function loadFonts() { if (self::$fonts !== null) { return; } $directory = dirname(__FILE__) . '/font/'; self::$fonts = array(); foreach (new Gpf_Io_DirectoryIterator($directory, '.ttf') as $fullName => $file) { self::$fonts[$fullName] = $fullName; } }