> > >> ./ftview -e "" 20 cmr10.600gf > >> > >> only shows `A' glyphs. [...] > > > > Ok. Currently the GF's cmap is like, the first glyph in the file is > > indexed to 0, and so on. So in cmr10.600gf, `ABCD...' appear first > > so they are now indexed from `0,1,2..' > > This is correct. > > > what happened previously is the glyphs were indexed according to > > their charcode values extracted from the `char_loc' command and this > > was the order `ΓΔΘΛΞΠ...'. I have properly set the encoding values, > > Obviously not. > > > [...] Other options with `-e' except `-e "" ' are giving proper > > output. > > Not at all. They always show the font without any cmap applied, > because there isn't a cmap with the tag you are specifying at the > command line. As soon as you will have implemented a Unicode cmap, > `-e unic' will work also. > > > Any specific reason why `-e "" ' is failing so that I can fix it? > > Set a break point at `FT_Get_Char_Index' and check the return value. > For example, the function returns 0 if argument `charcode' is zero. > This is wrong, of course, since it should return value 52 (which is > the glyph index of glyph `Γ'). Character code 1 should be mapped to > glyph index 53, code 2 to index 54, etc., etc. >
After some debugging, I found out that, I was using binary search on the encodings array in the `char_index' function, although it wasn't sorted (so foolish of me :( ). Now, fixed! Thanks. Although there is one more error, i.e even after displaying all the glyphs in the font file `ftview' is displaying extra `AAA...'s, any reason why this is happening? Thank you Parth
_______________________________________________ Freetype-devel mailing list [email protected] https://lists.nongnu.org/mailman/listinfo/freetype-devel
