From: sgimenez Date: Sat, 25 Nov 2006 17:28:28 +0000 (+0000) Subject: added user unit conversion to eqtexsvg extension X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=9c1083e3119c4bd5ec835cb275d4ecd49446e18b;p=inkscape.git added user unit conversion to eqtexsvg extension --- diff --git a/share/extensions/eqtexsvg.inx b/share/extensions/eqtexsvg.inx index 657594a9c..b9923f45b 100644 --- a/share/extensions/eqtexsvg.inx +++ b/share/extensions/eqtexsvg.inx @@ -6,7 +6,7 @@ latex dvips pstoedit - \[\frac{\pi^2}{6}=\lim_{n \to \infty}\sum_{k=1}^n \frac{1}{k^2}\] + \(\displaystyle\frac{\pi^2}{6}=\lim_{n \to \infty}\sum_{k=1}^n \frac{1}{k^2}\) all diff --git a/share/extensions/eqtexsvg.py b/share/extensions/eqtexsvg.py index 5b88febec..17a27337e 100644 --- a/share/extensions/eqtexsvg.py +++ b/share/extensions/eqtexsvg.py @@ -43,8 +43,8 @@ def create_equation_tex(filename, equation): tex.close() def svg_open(self,filename): - doc_width = float(self.document.documentElement.getAttribute('width')) - doc_height = float(self.document.documentElement.getAttribute('height')) + doc_width = inkex.unittouu(self.document.documentElement.getAttribute('width')) + doc_height = inkex.unittouu(self.document.documentElement.getAttribute('height')) doc_sizeH = min(doc_width,doc_height) doc_sizeW = max(doc_width,doc_height)