diff --git a/src/main/display.cc b/src/main/display.cc index f5cd59ffd..a4fd05f72 100644 --- a/src/main/display.cc +++ b/src/main/display.cc @@ -139,18 +139,20 @@ using namespace std; // user annotation cache filling. // -#define NUM_REPLACE 4 +#define NUM_REPLACE 6 struct replace { gchar c; gchar *s; } replacement[NUM_REPLACE] = { - // < and > must be first. + // & must be first to avoid double-encoding + {'&', (gchar *)"&"}, {'<', (gchar *)"<"}, {'>', (gchar *)">"}, {'\n', (gchar *)"
"}, {'"', (gchar *)"""}, + {'\'', (gchar *)"'"}, }; // a macro to substitute the visually ugly presentation below.