[tex-live] Making texts externally replaceable in PDFs, e.g. with sed(1)

Osipov, Michael michael.osipov at siemens.com
Sat Dec 15 00:59:47 CET 2018

Am 2018-12-15 um 00:31 schrieb Ulrike Fischer:
> Am Fri, 14 Dec 2018 22:56:18 +0100 schrieb Osipov, Michael:
>>> I don't understand this. Where is the difference between
>>> <0008002700320026002c00270008> and (%DOCID%)? Both is a quite unique
>>> string.
>> At first sight, yes, but I don't expect the char code to glyph mapping
>> to be stable as long as more and more glyphs are added to bfchar.
> Hm. Yes. But it shouldn't be so difficult to create a rather unique
> pattern. E.g. with four %%%%.

True, but the real problem isn't actually me, it is the target service 
which only knows PDF literal strings. Even if I say replace <HEX> with 
(LITERAL) that wouldn't work at the end :-(

>> I noticed that too, one would need to update the stream length and the
>> xref table. It is feasable to make the placeholder as long as the actual
>> content.
>> Thank your for the idea, but do you know how to enforce the main font
>> here while retaining WinAnsiEncoding?
> You could create a tfm and a type1 font from you font.

That would be a whole new ground for me. I need to discuss this with our 
project lead who is proficient in LaTeX and can tell whether this is 
worth the effort or not.

> Beside this: you could also store your text in a xform object
> instead of directly in the stream. With a suitable attribut it
> should be easy to find the object and replace the content.

Can you give me a pointer to a MWE? I guess you aren't talking about 
XHTML's XForms.



More information about the tex-live mailing list