diff options
Diffstat (limited to 'build')
-rw-r--r-- | build/preamble.tex | 7 | ||||
-rw-r--r-- | build/preview/preview.sty.do | 2 | ||||
-rwxr-xr-x | build/tex-filter.hs | 7 |
3 files changed, 12 insertions, 4 deletions
diff --git a/build/preamble.tex b/build/preamble.tex index 01c8146..cf3623b 100644 --- a/build/preamble.tex +++ b/build/preamble.tex | |||
@@ -4,6 +4,8 @@ | |||
4 | \usepackage{amsmath} | 4 | \usepackage{amsmath} |
5 | \usepackage{etoolbox} | 5 | \usepackage{etoolbox} |
6 | \usepackage{xspace} | 6 | \usepackage{xspace} |
7 | \usepackage{mathrsfs} | ||
8 | \usepackage{xifthen} | ||
7 | 9 | ||
8 | \usepackage{tikz} | 10 | \usepackage{tikz} |
9 | \usetikzlibrary{arrows,decorations.markings,chains,calc,matrix} | 11 | \usetikzlibrary{arrows,decorations.markings,chains,calc,matrix} |
@@ -38,6 +40,8 @@ | |||
38 | \DeclareMathOperator{\thom}{\textnormal{Th}} | 40 | \DeclareMathOperator{\thom}{\textnormal{Th}} |
39 | \DeclareMathOperator{\Bl}{\textnormal{Bl}} | 41 | \DeclareMathOperator{\Bl}{\textnormal{Bl}} |
40 | \DeclareMathOperator{\Stab}{\textnormal{Stab}} | 42 | \DeclareMathOperator{\Stab}{\textnormal{Stab}} |
43 | \DeclareMathOperator{\Grp}{\textnormal{\textsf{Grp}}} | ||
44 | \DeclareMathOperator{\Set}{\textnormal{\textsf{Set}}} | ||
41 | 45 | ||
42 | \newcommand*{\alg}[1]{\ensuremath{\overline{#1}}\xspace} | 46 | \newcommand*{\alg}[1]{\ensuremath{\overline{#1}}\xspace} |
43 | \newcommand*{\sep}[1]{\ensuremath{#1^{\textnormal{sep}}}\xspace} | 47 | \newcommand*{\sep}[1]{\ensuremath{#1^{\textnormal{sep}}}\xspace} |
@@ -214,7 +218,7 @@ | |||
214 | \newcommand*{\Alg}{\operatorname{\textnormal{\textsf{Alg}}}} | 218 | \newcommand*{\Alg}{\operatorname{\textnormal{\textsf{Alg}}}} |
215 | \newcommand*{\Disc}{\operatorname{\textnormal{\textsf{Disc}}}} | 219 | \newcommand*{\Disc}{\operatorname{\textnormal{\textsf{Disc}}}} |
216 | \newcommand*{\mfd}{\operatorname{\textnormal{\textsf{Mfd}}}} | 220 | \newcommand*{\mfd}{\operatorname{\textnormal{\textsf{Mfd}}}} |
217 | \newcommand*{\sm}[1][k]{\mathop{\textnormal{\textsf{Sm}}/k}} | 221 | \newcommand*{\sm}[1][k]{\mathop{\textnormal{\textsf{Sm}}/#1}} |
218 | \newcommand*{\Simp}{\mathbf{\Delta}} | 222 | \newcommand*{\Simp}{\mathbf{\Delta}} |
219 | \newcommand*{\sset}{\operatorname{\textnormal{\textsf{sSet}}}} | 223 | \newcommand*{\sset}{\operatorname{\textnormal{\textsf{sSet}}}} |
220 | \newcommand*{\ssetQ}{\operatorname{\textnormal{\textsf{sSet}}_{\textnormal{\textsf{Q}}}}} | 224 | \newcommand*{\ssetQ}{\operatorname{\textnormal{\textsf{sSet}}_{\textnormal{\textsf{Q}}}}} |
@@ -224,6 +228,7 @@ | |||
224 | \newcommand*{\Fin}{\operatorname{\textnormal{\textsf{Fin}}_{*}}} | 228 | \newcommand*{\Fin}{\operatorname{\textnormal{\textsf{Fin}}_{*}}} |
225 | \newcommand*{\tang}[1]{\textnormal{T}\mkern-2mu_{#1}} | 229 | \newcommand*{\tang}[1]{\textnormal{T}\mkern-2mu_{#1}} |
226 | \newcommand*{\dual}[1]{\textnormal{D}#1} | 230 | \newcommand*{\dual}[1]{\textnormal{D}#1} |
231 | \newcommand*{\sch}[1][k]{\mathop{\textnormal{\textsf{Sch}}/#1}} | ||
227 | 232 | ||
228 | \def\<#1>{\left\langle #1 \right\rangle} | 233 | \def\<#1>{\left\langle #1 \right\rangle} |
229 | 234 | ||
diff --git a/build/preview/preview.sty.do b/build/preview/preview.sty.do index 20af68c..cf10bef 100644 --- a/build/preview/preview.sty.do +++ b/build/preview/preview.sty.do | |||
@@ -1,4 +1,4 @@ | |||
1 | redo-ifchange preview.dtx preview.ins | 1 | redo-ifchange preview.dtx preview.ins |
2 | KEEP="preview.dtx preview.ins preview.sty.do" | 2 | KEEP="preview.dtx preview.ins preview.sty.do" |
3 | find * -maxdepth 0 $(for x in $KEEP; do echo "-not -name $x"; done) | xargs rm | 3 | find * -maxdepth 0 $(for x in $KEEP; do echo "-not -name $x"; done) | xargs rm >&2 |
4 | latex -interaction=batchmode preview.ins >&2 | 4 | latex -interaction=batchmode preview.ins >&2 |
diff --git a/build/tex-filter.hs b/build/tex-filter.hs index 67cc88c..13701c3 100755 --- a/build/tex-filter.hs +++ b/build/tex-filter.hs | |||
@@ -7,13 +7,16 @@ import Control.Monad | |||
7 | import Control.Applicative | 7 | import Control.Applicative |
8 | import qualified Data.ByteString.Char8 as BS | 8 | import qualified Data.ByteString.Char8 as BS |
9 | import Crypto.Hash | 9 | import Crypto.Hash |
10 | import System.IO | 10 | import qualified System.IO as SIO |
11 | import System.IO.Strict | ||
11 | import System.Directory | 12 | import System.Directory |
12 | import System.FilePath | 13 | import System.FilePath |
13 | import Text.Printf | 14 | import Text.Printf |
14 | 15 | ||
15 | import qualified Data.Text | 16 | import qualified Data.Text |
16 | 17 | ||
18 | import Prelude hiding (readFile) | ||
19 | |||
17 | type TeX = String | 20 | type TeX = String |
18 | type RawHTML = String | 21 | type RawHTML = String |
19 | 22 | ||
@@ -44,7 +47,7 @@ compileToSVG basepath t s = let tex = Data.Text.unpack $ Data.Text.strip $ Data. | |||
44 | (do writeFile expr_path $ (display t) ++ tex | 47 | (do writeFile expr_path $ (display t) ++ tex |
45 | writeFile align_path "0") | 48 | writeFile align_path "0") |
46 | alignment <- head.lines <$> readFile align_path | 49 | alignment <- head.lines <$> readFile align_path |
47 | hPutStrLn stderr path | 50 | SIO.hPutStrLn SIO.stderr path |
48 | return $ printf "<object data=\"/%s\" type=\"image/svg+xml\" style=\"vertical-align:-%s\">%s</object>" svg_web_path alignment tex | 51 | return $ printf "<object data=\"/%s\" type=\"image/svg+xml\" style=\"vertical-align:-%s\">%s</object>" svg_web_path alignment tex |
49 | 52 | ||
50 | texify :: [String] -> Inline -> IO Inline | 53 | texify :: [String] -> Inline -> IO Inline |