summaryrefslogtreecommitdiff
path: root/psdata.c
diff options
context:
space:
mode:
authorBen Harris <bjh21@bjh21.me.uk>2007-01-06 17:47:34 +0000
committerBen Harris <bjh21@bjh21.me.uk>2007-01-06 17:47:34 +0000
commitfb816f82ea8a90a1e92557dcc699cbcfe53f236c (patch)
treec885fffe93ec01e13788345aee1f5320593fa9cb /psdata.c
parent30ca2bdcde0675a2d52a9decf9dce73e57fdcee1 (diff)
downloadhalibut-fb816f82ea8a90a1e92557dcc699cbcfe53f236c.zip
halibut-fb816f82ea8a90a1e92557dcc699cbcfe53f236c.tar.gz
halibut-fb816f82ea8a90a1e92557dcc699cbcfe53f236c.tar.bz2
halibut-fb816f82ea8a90a1e92557dcc699cbcfe53f236c.tar.xz
Make ps_glyph_to_unicode() take a glyph index instead of a glyph name.
[originally from svn r7062]
Diffstat (limited to 'psdata.c')
-rw-r--r--psdata.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/psdata.c b/psdata.c
index 66354d3..af46099 100644
--- a/psdata.c
+++ b/psdata.c
@@ -1687,10 +1687,8 @@ static const unsigned short ps_codes_alphabetic[] = {
0xFF5A, 0x305E, 0x30BE, 0x24B5, 0x0290, 0x01B6, 0x305A, 0x30BA,
};
-wchar_t ps_glyph_to_unicode(char const *glyphname)
+wchar_t ps_glyph_to_unicode(glyph g)
{
- glyph g = glyph_intern(glyphname);
-
if (g == NOGLYPH) return 0xFFFF;
return ps_codes_alphabetic[g];
}
@@ -4486,7 +4484,7 @@ void init_std_fonts(void) {
w->glyph = glyph_intern(ps_std_glyphs[j]);
w->width = ps_std_fonts[i].widths[j];
add234(fi->widths, w);
- ucs = ps_glyph_to_unicode(ps_std_glyphs[j]);
+ ucs = ps_glyph_to_unicode(w->glyph);
assert(ucs != 0xFFFF);
fi->bmp[ucs] = w->glyph;
}