- sprintf(buf, "%hu", sfnt_glyphtoindex(fe->font->info->fontfile,
- fe->vector[i]));
+ objstream(cmap, "begincidrange\n");
+ while (blk) {
+ if (ranges[i] > 1) {
+ sprintf(buf, "<%02X>", i);
+ objstream(cmap, buf);
+ sprintf(buf, "<%02X>", i + ranges[i] - 1);
+ objstream(cmap, buf);
+ sprintf(buf, "%hu\n",
+ (unsigned short)
+ sfnt_glyphtoindex(fe->font->info->fontfile,
+ fe->vector[i]));
+ objstream(cmap, buf);
+ blk--;
+ }
+ i++;
+ }
+ objstream(cmap, "endcidrange\n");
+ }
+ i = 0;
+ while (nchars) {
+ unsigned blk = nchars > 100 ? 100 : nchars;
+ nchars -= blk;
+ sprintf(buf, "%u ", blk);