diff options
author | Henry Stiles <henry.stiles@artifex.com> | 2010-01-23 00:41:48 +0000 |
---|---|---|
committer | Henry Stiles <henry.stiles@artifex.com> | 2010-01-23 00:41:48 +0000 |
commit | a50b7d225a7055b72a25855fd864698a3f03862d (patch) | |
tree | 461f99244998982c53c40f15da6b870931a0c218 /pl | |
parent | b3d66c083640cbe764b0f07feff84b534dc398e8 (diff) |
Change the UFST Line Printer font from unbound to bound and convert
the encoding from MSL to Unicode upon loading. Temporarily breaks
Line Printer output in the interest of keeping the commits small and
cohesive.
git-svn-id: http://svn.ghostscript.com/ghostscript/branches/pcl_font_mods@10636 a1074d23-0009-0410-80fe-cf8c14f379e6
Diffstat (limited to 'pl')
-rw-r--r-- | pl/pl.mak | 2 | ||||
-rw-r--r-- | pl/plulfont.c | 6 |
2 files changed, 5 insertions, 3 deletions
@@ -230,7 +230,7 @@ $(PLOBJ)plulfont.$(OBJ): $(PLSRC)plulfont.c $(pllfont_h) $(uconfig_h) $(AK)\ $(stdio__h) $(string__h) $(gserror_h)\ $(gpgetenv_h) $(gsmemory_h) $(gp_h) $(gstypes_h)\ $(plfont_h) $(pldict_h) $(pllfont_h) $(plvalue_h)\ - $(plftable_h) $(uconfig_h) + $(plftable_h) $(plvocab_h) $(uconfig_h) $(PLCCC) $(UFST_CFLAGS) $(UFST_INCLUDES) $(PLSRC)plulfont.c $(PLO_)plulfont.$(OBJ) # artifex font loading module. diff --git a/pl/plulfont.c b/pl/plulfont.c index 6be5dede3..41ed72b75 100644 --- a/pl/plulfont.c +++ b/pl/plulfont.c @@ -24,6 +24,7 @@ #include "pllfont.h" #include "plftable.h" #include "plvalue.h" +#include "plvocab.h" #include "gdebug.h" #include "gserror.h" #include "gsstate.h" @@ -408,7 +409,7 @@ pl_load_ufst_lineprinter(gs_memory_t *mem, pl_dict_t *pfontdict, gs_font_dir *pd pplfont->storage = storage; /* should be an internal font */ pplfont->data_are_permanent = true; pplfont->header = (byte *)header; - pplfont->font_type = plft_MSL; + pplfont->font_type = plft_8bit_printable; pplfont->scaling_technology = plfst_bitmap; pplfont->is_xl_format = false; pplfont->resolution.x = pplfont->resolution.y = 300; @@ -423,7 +424,8 @@ pl_load_ufst_lineprinter(gs_memory_t *mem, pl_dict_t *pfontdict, gs_font_dir *pd uint width = pl_get_uint16(char_data + 12); uint height = pl_get_uint16(char_data + 14); uint ccode_plus_header_plus_data = 2 + 16 + (((width + 7) >> 3) * height); - int code = pl_font_add_glyph(pplfont, pl_get_uint16(char_data), char_data + 2); + uint ucode = pl_map_MSL_to_Unicode(pl_get_uint16(char_data), 0); + int code = pl_font_add_glyph(pplfont, ucode, char_data + 2); if (code < 0) /* shouldn't happen */ return -1; |