2
0.0014 Tc 0.0433 Tw 1.9352 -1.153 Td
[(In his )6(first y)9(ear of tradin)5(g he bought)6( 2000 radio)5(s)-1(, of which)5( )6(1000 were shipped to h)5(i)5(s agent Su)5(mit )]TJ
0.0015 Tc -0.0005 Tw 0 -1.153 TD

This is a snippet from a PDF file I want to read, for purposes. I understand the first and last line, and most of the second line, which is just showing the text on the page. The PDF syntax for a string is the text placed within brackets " () ", which it is. On line 2 the text is in an array, which I understand. What I do not understand is what the integers are right after the strings. Such as 6, 9, 5 placed right after the strings on line 2, without even a space, which would normally be the separator for objects in an array. I'd appreciate it if someone could specify what these numbers do right after a string.

BrickleRex
  • 84
  • 9
  • 1
    *"without even a space, which would normally be the separator for objects in an array"* - pdf only requires space separators if it otherwise was not clear that the previous item had ended. But as the closing bracket clearly ended the string there is no need for a space between it and the following numeric array element. – mkl Feb 19 '21 at 06:12

1 Answers1

2

What I do not understand is what the integers are right after the strings.

See the TJ operator, where each number adjusts (subtracts) from the text matrix. For example, this syntax can be used to do Kerning on the text runs.

See Table 109 page 258 (numbered at the bottom 250 here : https://www.adobe.com/content/dam/acom/en/devnet/pdf/pdfs/PDF32000_2008.pdf

rogerdpack
  • 62,887
  • 36
  • 269
  • 388
Ryan
  • 2,473
  • 1
  • 11
  • 14