We have template SVG drawings which have tags on the drawing to be replaced by text when the drawing is generated. Whenever it is generated as an SVG, it is ok, but when it is exported to a pdf, the text all shifts.
All of the tags in the SVG file were set to x='0', y='0', as there were problems in the formatting of text. When the file is generated as an SVG file there are no problems at all. I'm not sure how the PDF drawings are generated, I am assuming that they are generated as SVGs and then exported but I don't know.
Here is an example of how the text has shifted, and how it looks in the SVG drawing:
Reproducible Code:
<?xml version="1.0" encoding="utf-8"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg height="793.33331" id="svg10" inkscape:version="0.92.3 (2405546, 2018-03-11)" sodipodi:docname="1c E37 Face Electric Operation No No.svg" version="1.1" viewBox="0 0 1122.6667 793.33331" width="1122.6667" xml:space="preserve" xmlns="http://www.w3.org/2000/svg" xmlns:cc="http://creativecommons.org/ns#" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" xmlns:svg="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<metadata id="metadata16">
<rdf:RDF>
<cc:Work rdf:about="">
<dc:format>
image/svg+xml
</dc:format>
<dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage"/>
<dc:title/>
</cc:Work>
</rdf:RDF>
</metadata>
<sodipodi:namedview bordercolor="#666666" borderopacity="1" gridtolerance="10" guidetolerance="10" id="namedview12" inkscape:current-layer="g18" inkscape:cx="561.33337" inkscape:cy="396.66666" inkscape:pageopacity="0" inkscape:pageshadow="2" inkscape:window-height="2066" inkscape:window-maximized="1" inkscape:window-width="3840" inkscape:window-x="-11" inkscape:window-y="-11" inkscape:zoom="2.1646365" objecttolerance="10" pagecolor="#ffffff" showgrid="false"/>
<g id="g18" inkscape:groupmode="layer" inkscape:label="1c E37 Face Electric Operation No No" transform="matrix(0,-0.08,-0.08,0,1120,790.66666)">
<g id="g20">
<g clip-path="url(#clipPath26)" id="g22"/>
</g>
<g id="g28">
<g clip-path="url(#clipPath34)" id="g30"/>
</g>
<g id="g36">
<g clip-path="url(#clipPath42)" id="g38"/>
</g>
<g id="g44">
<g clip-path="url(#clipPath50)" id="g46"/>
</g>
<g>
<path d="m 7819,5214 -204,-182 v -17" id="path16964" inkscape:connector-curvature="0" style="fill:none;stroke:#000000;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"/>
<path d="M 2874,6382 V 5212" id="path16966" inkscape:connector-curvature="0" style="fill:none;stroke:#000000;stroke-width:12.5;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"/>
<text id="text16970" style="font-variant:normal;font-weight:normal;font-size:123.10199738px;font-family:Arial;-inkscape-font-specification:ArialMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none" transform="matrix(0,-1,-1,0,2900,6382)">
<tspan id="tspan16968" sodipodi:role="line" x="0" y="0">
TYPICAL THROUGH
</tspan>
</text>
</g>
</g>
</svg>