1

Is there an option in PDFLaTeX to throw error/warning if any hidden text found in the output PDF that goes outside text area or clashes with the text inside the textarea as shown in the picture with red box.

enter image description here

\documentclass{book}

\usepackage{graphicx}

\begin{document}

This is the sample to find hidden text. This is the sample to find hidden text. This is the sample to find hidden text.This is the sample to find hidden text.

\begin{figure}
\includegraphics{tri.pdf}
\end{figure}
This is the sample to find hidden text. This is the sample to find hidden text. This is the sample to find hidden text.This is the sample to find hidden text.

\end{document}

Download: Tri.pdf https://we.tl/t-uqOUR0bxxk

Stefan Pinnow
  • 29,535
RampSmart
  • 103
  • 1
    What is hidden text in this context? – daleif Nov 24 '23 at 13:39
  • When we look the PDF the hidden text will not see through our eyes but click select all option in PDF you see some the text clip masked in the PDF that i have shown in the red box. – RampSmart Nov 24 '23 at 13:41
  • 2
    there are multiple ways to make text not visible, some will warn by defalt if overfull, some could warn and some would be rather hard to warn as the width is really removed. As you have shown no code, it's not really possible to suggest anything – David Carlisle Nov 24 '23 at 13:52
  • 2
    In case you are meaning text in a clipped \includegraphics: No I don't think that it possible to detect that the clipped part has some content. Clipping merely adds a clipping path, the rest is done by the pdf viewer. – Ulrike Fischer Nov 24 '23 at 13:58
  • 2
    Please add the code you used for the document in your screenshot, that would make it easier to understand what kind of 'hidden text' you are asking about. – Marijn Nov 24 '23 at 15:23
  • Yes, you are correct @Ulrike. I mean the clipping. – RampSmart Nov 25 '23 at 01:45
  • Since David and Marijn asked for code i have edited and included the code in my question. – RampSmart Nov 25 '23 at 01:52
  • We can't use your code to reproduce the output you show because we don't have tri.pdf. And it isn't at all obvious to me, at least, what connection that input has to the output shown. Nothing is getting hidden. – cfr Nov 25 '23 at 04:40
  • @cfr: I have included tri,pdf in my question you can download it for your assistance. Thanks. – RampSmart Nov 25 '23 at 04:55

0 Answers0