1

Is there a way to get rid of the red boxenter image description here which appears in TexMaker immediately after building a PDF and disappears after a second or two. It is very annoying and disturbing to see red rectangles while typing LaTex.

I suppose there are some packages I need to include to prevent this from happening. I searched on stackoverflow for questions like "Latex - remove red box" and similar, but the only thing I found is the problem with permanent red boxes around links. That problem is not similar to this one, but I saw in answers of these questions that they solved their problem by including some package or reconfiguring some package.

So, which package I should include? Or maybe the problem is related to the tex editor I'm using (in particular TexMaker)? In the case of second, what should I opt in configurations to get rid of the annoying red box?

Thanks. Sorry for the bad english. Thank you in advance.

  • Pretty sure this is a TexMaker issue rather than a LaTeX issue. Is TexMaker highlighting stuff that you added since it last compiled or maybe highlighting where your cursor is when you compiled? – RagingRoosevelt Aug 24 '17 at 22:13

1 Answers1

3

The red box you actually experience here is from SyncTeX. In short, it provides synchronisation between editor and PDF view, so you're able to step through the PDF and see your editor following you. The highlighted box pops up just to indicate your actual position in the editor.

Building with SyncTeX support is default behavior in out-of-the-box installations of TexMaker and most do consider it a useful feature. However, if you want to get rid of this you can turn off SyncTeX. There's no harm in doing so and all your documents will happily compile. To turn it off, either remove pdflatex's -synctex switch, or set it to -synctex 0 (so you have a reminder that there's still a thing to switch on should you want it.)

You can do this in the configuration panel, see the screenshot below.

disabling synctex

yacc
  • 2,915
  • 4
  • 19
  • 33
  • 1
    Yeah, exactly what I was looking for. It is weird that it was so hard to find answer for it. Thank you for explaining. –  Aug 31 '17 at 02:13
  • How to include the red box? In my case, the redbox don't appers even being the same as yours (without removing the -synctex). – Guilherme Jun 25 '21 at 21:48