From b677c8d1b22fb2074cbcc3315af98160583a219b Mon Sep 17 00:00:00 2001 From: Maarten Bent Date: Fri, 2 Aug 2019 23:03:28 +0200 Subject: [PATCH] Add replacement for deprecated white-space tag in wxSVGFileDC output --- src/common/dcsvg.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/common/dcsvg.cpp b/src/common/dcsvg.cpp index 470c12ca22..770c8580bf 100644 --- a/src/common/dcsvg.cpp +++ b/src/common/dcsvg.cpp @@ -588,7 +588,11 @@ void wxSVGFileDCImpl::DoDrawRotatedText(const wxString& sText, wxCoord x, wxCoor style += wxString::Format(wxS("%s %s stroke-width:0; "), wxBrushString(m_textForegroundColour), wxPenString(m_textForegroundColour)); + style += wxS("white-space: pre;"); style += wxS("\""); + + // this is deprecated in favour of "white-space: pre", keep it for now to + // support SVG viewers that do not support the new tag style += wxS(" xml:space=\"preserve\""); // Draw all text line by line