2022 Developer Survey is open! Take survey.

Questions tagged [svg]

SVG, short for Scalable Vector Graphics, is a language used for describing two-dimensional vector graphics.

Filter by
Sorted by
Tagged with
0 votes
0 answers
45 views

Convert LaTeX PDF page to SVG

I would like to convert a PDF page created with LaTeX to SVG, in a scriptable fashion (like command line). I used inkscape on command line, and this partly worked, but I lost the fonts. I guess I need ...
user avatar
1 vote
1 answer
32 views

dvisvgm won't create text, only paths, no matter what option

Hope you're all doing well. I'm sorry if this isn't the right place for this, but I'm creating a piece of software and it requires an SVG to work, but the user must input a PDF. I am trying to use ...
user avatar
0 votes
1 answer
79 views

Arrowheads are wrong color in svg graphic

I have created a svg graphic with inkscape and use it in my LaTeX document. The graphic has a couple colorful lines with corresponding colorful arrowheads. Unfortunately pdflatex seems to arbitrarily ...
user avatar
  • 471
0 votes
1 answer
87 views

SVG drawn in Inkscape is not usable in overleaf with svg package

I created an SVG drawing using Inkscape locally. I then uploaded the created file to overleaf and wanted to include it. I validated the correct setup with an svg file I had used before. Not working ...
user avatar
  • 38
1 vote
0 answers
45 views

Issue with inserting an SVG inside a table cell

I'm trying to create a table that has merged rows and columns, images, and an SVG. I successfully included the images but I'm struggling with the SVG, somehow, it doesn't want to fit into the ...
user avatar
  • 111
0 votes
1 answer
59 views

Text spacing on latex svg screwed when embedded

I have been trying to import svg images into my latex document, but latex seems to screw up the text spacing. I produce the SVG files using pyplot in python. The images look fine inkscape with proper ...
user avatar
  • 21
1 vote
1 answer
257 views

Including svg file in sharelatex (overleaf)

I was working with the online version of overleaf and the below code to include svg images worked perfectly fine. \begin{figure} \centering \includesvg[width = 5cm]{FIGURES/Example.svg} \...
user avatar
0 votes
0 answers
35 views

Embed a SVG file in a tex source file

I would like to generate latex documents containing SVG pictures with a specific document generator. For specific reasons, I would like to embed these pictures directly inside the latex source file to ...
user avatar
  • 621
0 votes
0 answers
139 views

How to include SVG documents into LaTeX document in VSCode with LaTeX Workshop plugin?

I try to insert a SVG file into my LaTeX document with this code: In my main file: \documentclass[12pt, twoside]{book} \usepackage{multicol} \usepackage{svg} \svgsetup{ inkscape=pdf, ...
user avatar
  • 133
0 votes
0 answers
102 views

Error using svg2tikz: AttributeError: 'TikZPathExporter' object has no attribute 'svg'?

I am trying to turn an .svg file to a LaTeX document. I cloned the github repo for avg2tikz and followed the installation instuctions. After not getting this to work with inkscape I tried to use it ...
user avatar
0 votes
1 answer
77 views

Remove extra space from image context converted from svg to pdf

I have a Context text with a svg image. As expected, Context converts the image to pdf and includes it, but leaves a lot of empty room in the exported pdf. How do I get rid of this empty space? mcve....
user avatar
  • 195
1 vote
1 answer
105 views

Latex equations inside inkscape figure (.svg) increase figure width/make figure too big [duplicate]

I have an image, let's use this one from my thesis: that I include in my document using: \begin{figure} \centering \includesvg[width=\textwidth]{zeeman} \caption{Caption} \label{fig:...
user avatar
1 vote
1 answer
33 views

Paper size when using svg package [duplicate]

My texlive debian is set to a4 paper size (paperconf -p a4). Using pdflatex on the following simple document \documentclass{article} %\usepackage{svg} \begin{document} test \end{document} I either ...
user avatar
1 vote
1 answer
58 views

insert a scalable graphic which doesn't affect file size to much

at the moment I've inserted graphics into my document using PNG. This works good but the graphics are to blurry. To avoid this I wanted to use a scalable file like .pdf pder .svg. Using .pdf results ...
user avatar
1 vote
1 answer
99 views

How to specify SVG classes with TikZ and graph drawing when converting to SVG?

I am trying to build upon this previous question. I can successfully specify node and edge SVG classes with dvisvgm specials when drawing a regular graph. With this MWE: \documentclass[tikz,dvisvgm]{...
user avatar
1 vote
0 answers
37 views

Simple way to include .svg images [duplicate]

I come to your rescue because I screwed up the only reference I had of an SVG file that I had successfully included in a document (somehow copied the file and it got deleted. Pretty sure I did not &...
user avatar
  • 11
0 votes
0 answers
82 views

How to convert a LateX code to Image using a vector template

I want to use illustrator to create a fancier look for my algorithm boxes. Is there any way that I can set a script (or any other way really) to take the algorithmic text on latex and convert it to ...
user avatar
1 vote
3 answers
123 views

tikz - curly bracket implementation

I would like to know details about tikz curly bracket implementation then wish to get a equivalent version with svg by d3.js. For example \documentclass{article} \usepackage{tikz, pgfplots} \begin{...
user avatar
  • 925
0 votes
1 answer
97 views

Inkscape's textext plugin unable to produce LaTeX symbol

Typesetting \[\LaTeX\] in textext extension/plugin of InScapes throws the following error. Question: Is something additional that needs to be done here, and/or, are there any workaround to resolve the ...
user avatar
  • 965
1 vote
1 answer
83 views

Scale SVG by text size

I have this file \documentclass{article} \usepackage{svg} \newcommand\mtg[1]{% \includesvg[height=8px]{#1.svg} } \begin{document} This magic card costs \mtg{R} mana \end{document} Where R.svg is: &...
user avatar
  • 309
0 votes
0 answers
88 views

Insert svg image in latex as figure: excessive spacing around it

Good afternoon, I have a problem related to insert .svg images in latex as a figure. I have tried to insert an image but it leaves too much spacing before the image, and it is not centered either. I ...
user avatar
1 vote
1 answer
268 views

Text in svg is not wrapping around a box

I am trying to include an sag image in Latex like the following. \begin{figure}[H] \centering \includesvg[inkscapelatex=false, width=0.7\pdfpagewidth]{figure.svg} \end{figure} <?xml version=&...
user avatar
  • 11
0 votes
1 answer
1k views

SVG text overflow, rendered with ellipsis

This is my SVG, drawn in draw.io. https://drive.google.com/file/d/1hVWrAL8CysF9wlDvZa3D3XfXwNy4Y3iV/view?usp=sharing A MWE, I use inkscapelatex=false to keep the font: \documentclass{report} \...
user avatar
1 vote
3 answers
684 views

Matplotlib, Inkscape, TeXStudio workflow SVG figures

When I create an SVG figure in matplotlib import numpy as np import matplotlib.pyplot as plt import matplotlib new_rc_params = {'text.usetex': False, "svg.fonttype": 'none' } matplotlib....
user avatar
1 vote
0 answers
120 views

\includesvg leads to overlapping elements in pdf [closed]

I include svg's like this: \begin{figure}[H] \centering \includesvg[inkscapelatex=false, width = \columnwidth]{batterie_normal_kw4} \caption{Verlauf von Batteriestand, Autarkie und Energieverbrauch ...
user avatar
0 votes
1 answer
147 views

SVG incorrectly rendered, but looks fine in Chrome & Inkscape

Can anyone check what is wrong with this svg? This is the file from a famous article, rendered correctly in both Chrome and Inkscape: My MWE in Overleaf: \documentclass{article} \usepackage{svg} \...
user avatar
0 votes
0 answers
46 views

About one error when I induced SVG figure

I tried to include SVG image into the LaTex. My code is as follows: \documentclass[a4paper,12pt]{book} \usepackage{svg} \begin{document} \begin{figure}[ht] \centering \includesvg[width=0.4\...
user avatar
  • 185
1 vote
1 answer
302 views

SVG package runs Inkscape with invalid command line args

There are many questions on \includesvg already, so yes, I have added --shell-escape to latexmk, lualatexmk and pdflatex in .vscode\settings.json. Alternatively I have also put set_tex_cmds( '--shell-...
user avatar
1 vote
2 answers
165 views

How to include SVG with dots in file name?

I'm trying to include SVG images with dots/periods in the file name. \documentclass{article} \usepackage{svg} \begin{document} \includesvg[width=\textwidth]{xgb.clf.output/Images/no.missing.data....
user avatar
  • 229
3 votes
0 answers
97 views

Very thick text when using svg

I'm using mathcha.io for create some figures. I exported them as svg. If I see on any browser looks perfect. But, if I render this svg at tex file, all text if so thick and I can't solve this, I ...
user avatar
0 votes
0 answers
41 views

Where to add shellescape in texstudio when using latexmk?

For using svg images in pdflatex, I have to enable shell-escape. I am using texstudio and latexmk. Where to set shell-escape?
user avatar
  • 300
1 vote
1 answer
71 views

ConTeXt: External SVG images using XML setups

Background Include an external SVG image from an HTML img element, using ConTeXt LMTX. Code Here's main.tex: \startbuffer[document] <body><img src="circle.svg"/></body> \...
user avatar
  • 10.9k
1 vote
0 answers
77 views

correctly scaling the output of svg2tikz for using in a tikzpicture

I am pretty new to tikz. I would like to use a simple external image inside a tikzpicture environment, like in the following mwe \documentclass[tikz,border=5]{standalone} \begin{document} \begin{...
user avatar
  • 11
0 votes
1 answer
173 views

Automatic pdf_tex export from svg via inkscape and svg package on Windows

I have the following code: \documentclass[12pt]{article} \usepackage{svg} \setsvg{inkscape=inkscape -z -D, inkscapeversion=1, svgpath=figures/} \begin{document} \begin{figure} \...
user avatar
2 votes
1 answer
103 views

Print as many images in a row as fit the page

I have a svg image for a tile in a board game. I want to print this 3 times so that I can print the page and cut out the tiles for my game. However, I cannot figure out how to print as many tiles next ...
user avatar
  • 195
1 vote
1 answer
172 views

Wrong SVG files are rendered in document

I am trying to display two figures, which both contain two SVG images in separate minipages each: \documentclass{article} \usepackage[utf8]{inputenc} \usepackage{graphicx} \usepackage{svg} \begin{...
user avatar
1 vote
1 answer
101 views

Handling subequations with make4ht

When compiling with make4ht and using svg parameter, the equation, drawn from subequation using align environment, is not converted into SVG. If I change to mathjax, the HTML displays the warning: ...
user avatar
  • 656
1 vote
2 answers
591 views

What is the best way to include matplotlib plots?

I work on both Windows and Linux. I already include SVG graphics that I create in Inkscape with \usepackage{svg}. For maintainablitly reasons I would welcome to re-use that for matplotlib plots, but I ...
user avatar
2 votes
1 answer
284 views

inkscape: PDF inclusion: required page does not exist <1>

Just like here Inkscape produces a pdf_tex file that contains higher page numbers then the generated PDF contains. Deleting the line in question in the file fixes the issue. User Martin Schröder ...
user avatar
1 vote
0 answers
424 views

Can't include SVG image in LuaLaTex (MikTeX)

I have problems including an .svg image into my document (I'm using MikTeX on Windows 10). I found relevant Q&As here and I think I know which steps I need to take in order to import svg images: ...
user avatar
  • 259
1 vote
1 answer
381 views

Inkscape svg converted to pdf, too much white space under figure

I made an svg file with Inkscape, which I saved as a pdf with the "Omit text in PDF and create LaTeX file" option. I also checked "Use exported Object's size". When using the ...
user avatar
  • 125
0 votes
0 answers
23 views

includesvg newly generates pfd_tex files every time it is executed

I'm using the svg package and includesvg to include svgs in my document. As I need so escape % signs in my pictures, I need to edit the .pfd_tex files in the svg-inkscape directory (as explained here)....
user avatar
  • 145
2 votes
1 answer
205 views

Intervals on the real line. How to construct the symbolic diagrams of real intervals on the real line?

I'm trying to elaborate on my student's exercises on interval notation on the number line. I tried using the LaTeX code of this response here to draw intervals on the number line identical to those in ...
user avatar
  • 2,710
0 votes
0 answers
190 views

Can't export SVG image to Tikz file from Inkscape 1.0.1 on Windows using Inkscape2Tikz extension

I am trying to export an image from Inkscape to a .tex file with the extension Inkscape2Tikz downloaded from GitHub, but it won't work. I managed to include the extension in Inkscape and when I try to ...
user avatar
  • 26
1 vote
1 answer
252 views

Problem when exporting .svg to TikZ code on MacOS

I'm trying to convert a svg file into tikz code using Inkscape and the svg2tikz extension downloaded from https://github.com/kjellmf/svg2tikz. I've done this before under Windows 10, but this time I'm ...
user avatar
  • 5,189
0 votes
1 answer
56 views

Genealogytree export to SVG file [duplicate]

I have a simple family tree defined in Latex and package genealogytree: \documentclass{article} \usepackage[all]{genealogytree} \begin{document} \begin{tikzpicture} \genealogytree[template=formal ...
user avatar
1 vote
0 answers
3k views

SVG Figure in Latex Overleaf [duplicate]

I am struggling to import a figure.SVG in Overleaf. I tried with \usepackage{svg} but it doesn't work. I read a few times about Inkscape, however I work on Overleaf and I have no idea how to install ...
user avatar
1 vote
0 answers
256 views

Trying to use mathjax in svg

I'm trying to make a svg gràfic in my web page. I want to write in it a LaTeX formula using mathjax but it doesn't work. Here is my code, althought I think it is not the problem. Can anyone help me? ...
user avatar
0 votes
0 answers
76 views

30 page document takes one hour to compile

I know that there are multiple questions of the kind "file takes too long to compile", but one whole hour for a 30-pages document seems abnormal to me. I'm using a custom LaTeX package, ...
user avatar
  • 11
0 votes
1 answer
224 views

svg package not rendering svg containing math

I have an svg file of an equation as follows <svg xmlns="http://www.w3.org/2000/svg" xmlns:wrs="http://www.wiris.com/xml/cvs-extension" height="29" width="85"...
user avatar

1
2 3 4 5
7