SVG to Word #8
Unanswered
klaszczych
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hello. About month ago I asked on original calcpad github about reason for problem in exporting SVG images to word. Examples that come with calcpad used to generate svg images - specifically "I section with drawing.cpd" from "Structural Design/Steel" and "TT Panel.cpd" from "Demos". TT panel worked fine, but I section didn't create image in Word. With help frome Claude, I was able to find solution.
Main reason was that parameters "height" and "width" was in "<svg..." part of code, where it should be in "style = ..." part of code.
This is original code
'<svg width="'B + 80'pt" height="'H + 80'pt" viewBox="'-b/2 - 50/k' '-50/k' 'b + 100/k' 'h + 100/k'" style="font-size:'9/k'pt;" xmlns="http://www.w3.org/2000/svg">This is updated code that works well in exporting to Word:
'<svg viewBox="'-b/2 - 50/k' '-50/k' 'b + 100/k' 'h + 100/k'" style="width:'B + 80'pt; height:'H + 80'pt; font-size:'9/k'pt;" xmlns="http://www.w3.org/2000/svg">Hope it helps someone.
Beta Was this translation helpful? Give feedback.
All reactions