Skip to content

Commit d6e7e70

Browse files
authored
fix(latex): address further issues regarding math escaping (rafamadriz#476)
1 parent e1f7015 commit d6e7e70

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

snippets/latex/vscode-latex-snippets.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@
224224
"\tcolor=${3:blue},",
225225
"\t]",
226226
"\t{${4:x^2 + 2*x + 1}};",
227-
"\\addlegendentry{$${5:x^2 + 2x + 1}$}",
227+
"\\addlegendentry{\\$${5:x^2 + 2x + 1}\\$}",
228228
"$0"
229229
],
230230
"description": "Plot a 2D Graph in the 2D graph environment, noted that this can also be used in the 3D environment."
@@ -238,7 +238,7 @@
238238
"\tcolor=${4:blue},",
239239
"\t]",
240240
"\t({${1:r}*cos(t)+${2:a}},{${1:r}*sin(t)+${3:b}});",
241-
"\\addlegendentry{$(x-${2:a})^2+(y-${3:b})^2=${1:r}^2$}$0"
241+
"\\addlegendentry{\\$(x-${2:a})^2+(y-${3:b})^2=${1:r}^2\\$}$0"
242242
],
243243
"description": "Plot a 2D Circle in the 2D graph environment, noted that this can also be used in the 3D environment."
244244
},
@@ -251,7 +251,7 @@
251251
"\tcolor=${3:blue},",
252252
"\t]",
253253
"\t{${1:a}*x+${2:b}};",
254-
"\\addlegendentry{$ y=${1:a}x+${2:b}$}$0"
254+
"\\addlegendentry{\\$ y=${1:a}x+${2:b}\\$}$0"
255255
],
256256
"description": "Plot a 2D Line in the 2D graph environment, noted that this can also be used in the 3D environment."
257257
},
@@ -264,7 +264,7 @@
264264
"\tcolor=${5:blue},",
265265
"\t]",
266266
"\t({${1:a}*cos(t)+${3:x}},{${2:b}*sin(t)+${4:y}});",
267-
"\\addlegendentry{$\\frac{(x-${3:x})^2}{${1:a}^2}+\\frac{(y-${4:y})^2}{${2:b}^2}=1$}$0"
267+
"\\addlegendentry{\\$\\frac{(x-${3:x})^2}{${1:a}^2}+\\frac{(y-${4:y})^2}{${2:b}^2}=1\\$}$0"
268268
],
269269
"description": "Plot a 2D Ellipse in the 2D graph environment, noted that this can also be used in the 3D environment."
270270
},
@@ -280,7 +280,7 @@
280280
"\tcolor=${6:blue},",
281281
"\t]",
282282
"\t{${1:a}*(x-${2:m})*(x-${2:m})+${3:b}};",
283-
"\\addlegendentry{$ y=${1:a}(x-${2:m})^2+${3:b}$}$0"
283+
"\\addlegendentry{\\$ y=${1:a}(x-${2:m})^2+${3:b}\\$}$0"
284284
],
285285
"description": "Plot a 2D graph of a quadratic function in the 2D graph environment by the given extrema, noted that this can also be used in the 3D environment."
286286
},

0 commit comments

Comments
 (0)