From fa32f291bce388baaedc0676d22c0dbfcc0cd14b Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Thu, 8 Oct 2020 16:37:18 +0100 Subject: [PATCH] Escape parens when outputting PDF text. Fixes https://gitlab.com/kicad/code/kicad/issues/5917 --- common/plotters/PDF_plotter.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/common/plotters/PDF_plotter.cpp b/common/plotters/PDF_plotter.cpp index 6382c98e30..6bb8cd8f0f 100644 --- a/common/plotters/PDF_plotter.cpp +++ b/common/plotters/PDF_plotter.cpp @@ -71,7 +71,8 @@ std::string PDF_PLOTTER::encodeStringForPlotter( const wxString& aText ) // These characters must be escaped switch( code ) { - // se if '(' and ')' must be escaped. + case '(': + case ')': case '\\': result += '\\'; KI_FALLTHROUGH;