Pdf XFA: Render issue, missing text |
||||||||
Issue descriptionVersion: 7c1c27414ff9e29a88fec8f717b4c157363bfae6 What steps will reproduce the problem? (1) View the form at http://www.cic.gc.ca/english/pdf/kits/forms/IMM5257E.pdf or attached (2) Look at the page count in the top right of the rendered page What is the expected output? What do you see instead? I expect to see "PAGE 1 OF 5" in the top right corner. I see "PAGE 1 OF" instead. See attached screenshots. Please use labels and text to provide additional information.
,
Mar 7 2016
,
Oct 17 2016
,
Oct 17 2016
I believe this is fixed, but the blocking bug causes a crash when rendering the file. Reverting V8 to prior to the crash shows the page numbers appearing. I'm leaving this open until we can verify on ToT but it looks fixed.
,
Oct 17 2016
,
Sep 19 2017
,
Apr 3 2018
Just checked, it's still there, showing "PAGE 1 OF".
,
Jul 19
The piece of XML in question is:
<value>
<exData contentType="text/html" maxLength="0">
<body xmlns="http://www.w3.org/1999/xhtml" xmlns:xfa="http://www.xfa.org/schema/xfa-data/1.0/">
<p style="letter-spacing:0in">
PAGE
<span style="xfa-spacerun:yes">Â </span>
<span xfa:embedType="uri" xfa:embedMode="raw" xfa:embed="#floatingField000041" />
OF
<span style="xfa-spacerun:yes">Â </span>
<span xfa:embedType="uri" xfa:embedMode="raw" xfa:embed="#floatingField018467" />
</p>
</body>
</exData>
</value>
"floatingField018467" is defined here:
<field h="7.5mm" name="PageCount" presence="hidden" w="55mm" x="136.958mm" y="12.809mm" access="readOnly" id="floatingField018467">
<ui>
<numericEdit>
<border>
<edge stroke="lowered" />
</border>
<margin />
</numericEdit>
</ui>
<font typeface="Myriad Pro" size="7pt" />
<margin bottomInset="1mm" leftInset="1mm" rightInset="1mm" topInset="1mm" />
<para vAlign="middle" />
<caption reserve="20mm">
<para vAlign="middle" />
<value>
<text>Text Field</text>
</value>
</caption>
<calculate override="error" />
<event name="event__layout_ready" activity="ready" ref="$layout">
<script contentType="application/x-javascript">this.rawValue = xfa.layout.pageCount();</script>
</event>
<?templateDesigner floatingFieldPlaceholder ##?>
<bind match="none" />
</field>
CJX_LayoutPseudoModel::pageCount() returns a CJS_Return with HasError()=false, HasReturn()=true and value 5, so that part is working.
,
Jul 19
Ryan pointed out it's being cropped. Reducing the font size in the PDF shows this to be the case, see screenshot.
,
Jul 20
,
Jul 20
The font is Myriad Pro, and it's not embedded. It's being replaced by Arial, which is a bit wider, causing the text span is cropped by the margin. I talked to npm@ and one idea is to scale characters in the availale font (Arial) to take the same width as the font substituted out (Myriad Pro). This should fix a lot of the other jank we see in this document, for example the "* Yes" string wrapping to two lines.
,
Oct 12
|
||||||||
►
Sign in to add a comment |
||||||||
Comment 1 by aval...@chromium.org
, Mar 7 2016