Conversion Toolslwarp and tikz

Information and discussion about output converters related to LaTeX (e.g. dvips, ps2pdf, ...)
Post Reply
janwillem
Posts: 1
Joined: Tue Jul 24, 2018 1:21 pm

lwarp and tikz

Post by janwillem »

I'm trying to get the grips on lwarp. I have a tikz figure in my document and I cannot get that shown in the html. I get the word "image" instead and """<span id="lateximage1" class="lateximagesource"><!--
--><img src="lateximages/lateximage-1.svg" alt="image" style="" class="lateximage"></span> <br />""" in the html and nothing in lateximages.
Something not understood here but what? please help,
Cheers, janwillem

The source:
\documentclass{book}
%
%use XeLaTeX
\usepackage{fontspec}
\usepackage[mathjax]{lwarp}
%
%\usepackage{tikz}
\usepackage{pgfplots}
\pgfplotsset{compat=newest}

\setlength\parindent{0pt}

\begin{document}
The equation: $ x = \sqrt{2} $ \\ \\

Figure embedded\\ \\
\begin{tikzpicture}[thick,scale=0.5, every node/.style={scale=0.5}]
\draw[green, fill=green]
(10.000000,2.688000) --
(7.273000,2.688000) --
(7.273000,3.883000) --
(5.758000,3.883000) --
(5.758000,2.688000) --
(4.243000,2.688000) --
(4.243000,3.883000) --
(2.727000,3.883000) --
(2.727000,2.688000) --
(0.000000,2.688000) --
(0.000000,1.195000) --
(2.727000,1.195000) --
(2.727000,0.000000) --
(4.243000,0.000000) --
(4.243000,1.195000) --
(5.758000,1.195000) --
(5.758000,0.000000) --
(7.273000,0.000000) --
(7.273000,1.195000) --
(10.000000,1.195000) --
(10.000000,2.688000) ;
\end{tikzpicture}\\
Figure shown

\end{document}

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org
LaTeX Beginner's Guide LaTeX Cookbook LaTeX TikZ graphics TikZによるLaTeXグラフィックス
Brian_D
Posts: 28
Joined: Thu Apr 23, 2015 12:01 pm

lwarp and tikz

Post by Brian_D »

Hi,

From the command line, enter "lwarpmk limages" to process the LaTeX images, then reload the web page to update the display.

If you remove the mathjax option, thus selecting SVG math images, then "lwarpmk html" followed by "lwarpmk limages" will create SVG images for the math as well. Recent versions use a hash function to reuse inline math where possible, and also process images in parallel.

Recent versions of the lwarpmk utility also can automate the processing of indexes and glossary, and batch convert the user's PDF figures into SVG images.

As of this writing lwarp has support for more than 300 packages. Many are nullified and provided only for source-level compatibility, but a large number of additional packages work as-is.

The next version supports asymptote, and dvi plus postscript may be coming some day as well.

Brian
Brian Dunn
BDTechConcepts.com
Brian_D
Posts: 28
Joined: Thu Apr 23, 2015 12:01 pm

lwarp and tikz

Post by Brian_D »

Later versions of lwarp have a nice tutorial, so if you have an older version without the tutorial then it would be worth it to download the latest version from CTAN. Also included are instructions for several ways to install lwarp.
Brian Dunn
BDTechConcepts.com
Post Reply