summaryrefslogtreecommitdiff
path: root/gs/base/gdevpdtt.c
diff options
context:
space:
mode:
authorKen Sharp <ken.sharp@artifex.com>2010-11-29 14:35:25 +0000
committerKen Sharp <ken.sharp@artifex.com>2010-11-29 14:35:25 +0000
commite518885c18d8495e794287a78d948fd41c28be9b (patch)
treefae5dabeb86ae41caee5b1daf7158e3869c9565d /gs/base/gdevpdtt.c
parent1e1118f76f7f1b4d8faa115a085a9d6773348041 (diff)
Fix (pdfwrite) : Type 3 font capture and charpath operations
Bug #691033 "Regression: 14-01.PS fails with pdfwrite" The first time a type 3 glyphis encountered we start a charproc accumulatiopn and exit to run the BuildChar/BuildGlyph. On return to the text processing, if the operation was a charpath, this would take precedence over closing the accumulator which would lead to significant later problems. Modified the code path to allow for the charproc accumulation to finish and if this is a charpath operation to rerun the operation using the newly captured glyph program. Note this can only occur if the first operation on a given glyph in a type 3 font is for a charpath. Expected differences None. git-svn-id: http://svn.ghostscript.com/ghostscript/trunk@11921 a1074d23-0009-0410-80fe-cf8c14f379e6
Diffstat (limited to 'gs/base/gdevpdtt.c')
-rw-r--r--gs/base/gdevpdtt.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/gs/base/gdevpdtt.c b/gs/base/gdevpdtt.c
index 732755aa0..c5b7c97e7 100644
--- a/gs/base/gdevpdtt.c
+++ b/gs/base/gdevpdtt.c
@@ -2578,6 +2578,7 @@ pdf_text_process(gs_text_enum_t *pte)
if (penum->current_font->FontType == ft_user_defined && (penum->text.operation & TEXT_DO_ANY_CHARPATH)
&& !pdev->type3charpath) {
pdev->type3charpath = true;
+ if (!penum->charproc_accum)
goto default_impl;
}
@@ -2632,7 +2633,10 @@ pdf_text_process(gs_text_enum_t *pte)
return code;
gs_text_release(pte_default, "pdf_text_process");
penum->pte_default = 0;
- goto top;
+ if (!pdev->type3charpath)
+ goto top;
+ else
+ goto default_impl;
}
pdev->pte = pte_default; /* CAUTION: See comment in gdevpdfx.h . */
code = gs_text_process(pte_default);