##// END OF EJS Templates
Reverted change accidently commited.
Jonathan Frederic -
Show More
@@ -1,224 +1,219 b''
1 1 ((*- extends 'display_priority.tplx' -*))
2 2
3 3 ((* block in_prompt *))((* endblock in_prompt *))
4 4
5 5 ((* block output_prompt *))((* endblock output_prompt *))
6 6
7 7 ((* block codecell *))\begin{codecell}((( super() )))
8 8 \end{codecell}
9 9 ((* endblock *))
10 10
11 11 ((* block input *))
12 12 \begin{codeinput}
13 13 \begin{lstlisting}
14 14 ((( cell.input )))
15 15 \end{lstlisting}
16 16 \end{codeinput}
17 17 ((* endblock input *))
18 18
19 19
20 20 ((= Those Two are for error displaying
21 21 even if the first one seem to do nothing,
22 22 it introduces a new line
23 23
24 24 =))
25 25 ((* block pyerr *))((( super() )))
26 26 ((* endblock pyerr *))
27 27
28 28 ((* block traceback_line *))
29 29 ((( line |indent| rm_ansi )))((* endblock traceback_line *))
30 30 ((= .... =))
31 31
32 32
33 33 ((*- block output_group -*))
34 34 \begin{codeoutput}
35 35 ((( super() )))
36 36 \end{codeoutput}((* endblock *))
37 37
38 38 ((*- block data_png -*))
39 39 \begin{center}
40 40 \includegraphics[width=0.7\textwidth, height=0.9\textheight, keepaspectratio]{(((output.key_png)))}
41 41 \par
42 42 \end{center}
43 43 ((*- endblock -*))
44 44
45 45 ((*- block data_svg -*))
46 46 \begin{center}
47 47 \includegraphics[width=0.7\textwidth]{(((output.key_svg)))}
48 48 \par
49 49 \end{center}
50 50 ((*- endblock -*))
51 51
52 52 ((* block pyout *))
53 53 ((( output.text)))
54 54 ((* endblock pyout *))
55 55
56 56 ((* block data_text *))
57 57 \begin{verbatim}
58 58 ((( output.text )))
59 59 \end{verbatim}
60 60 ((* endblock *))
61 61
62 62 ((* block stream *))
63 63 \begin{verbatim}
64 64 ((( output.text)))
65 65 \end{verbatim}
66 66 ((* endblock stream *))
67 67
68
69
70 ((=
71 %Doesn't work on my machine yet. TODO: Fix this.
72 68 ((* block markdowncell scoped *))((( cell.source | markdown2latex )))
73 69 ((* endblock markdowncell *))
74 =))
75 70
76 71 ((* block headingcell scoped *))
77 72 \section{((( cell.source)))}
78 73 ((* endblock headingcell *))
79 74
80 75 ((* block rawcell scoped *))
81 76 ((( cell.source | pycomment )))
82 77 ((* endblock rawcell *))
83 78
84 79 ((* block unknowncell scoped *))
85 80 unknown type (((cell.type)))
86 81 ((* endblock unknowncell *))
87 82
88 83
89 84
90 85 ((* block body *))
91 86
92 87 ((* block bodyBegin *))
93 88 \begin{document}
94 89 ((* endblock bodyBegin *))
95 90
96 91 ((( super() )))
97 92
98 93 ((* block bodyEnd *))
99 94 \end{document}
100 95 ((* endblock bodyEnd *))
101 96 ((* endblock body *))
102 97
103 98 ((* block header *))
104 99 %% This file was auto-generated by IPython.
105 100 %% Conversion from the original notebook file:
106 101 %% tests/ipynbref/Gun_Data.orig.ipynb
107 102 %%
108 103 \documentclass[11pt,english]{article}
109 104
110 105 %% This is the automatic preamble used by IPython. Note that it does *not*
111 106 %% include a documentclass declaration, that is added at runtime to the overall
112 107 %% document.
113 108
114 109 \usepackage{amsmath}
115 110 \usepackage{amssymb}
116 111 \usepackage{graphicx}
117 112 \usepackage{ucs}
118 113 \usepackage[utf8x]{inputenc}
119 114
120 115 % needed for markdown enumerations to work
121 116 \usepackage{enumerate}
122 117
123 118 % Slightly bigger margins than the latex defaults
124 119 \usepackage{geometry}
125 120 \geometry{verbose,tmargin=3cm,bmargin=3cm,lmargin=2.5cm,rmargin=2.5cm}
126 121
127 122 % Define a few colors for use in code, links and cell shading
128 123 \usepackage{color}
129 124 \definecolor{orange}{cmyk}{0,0.4,0.8,0.2}
130 125 \definecolor{darkorange}{rgb}{.71,0.21,0.01}
131 126 \definecolor{darkgreen}{rgb}{.12,.54,.11}
132 127 \definecolor{myteal}{rgb}{.26, .44, .56}
133 128 \definecolor{gray}{gray}{0.45}
134 129 \definecolor{lightgray}{gray}{.95}
135 130 \definecolor{mediumgray}{gray}{.8}
136 131 \definecolor{inputbackground}{rgb}{.95, .95, .85}
137 132 \definecolor{outputbackground}{rgb}{.95, .95, .95}
138 133 \definecolor{traceback}{rgb}{1, .95, .95}
139 134
140 135 % Framed environments for code cells (inputs, outputs, errors, ...). The
141 136 % various uses of \unskip (or not) at the end were fine-tuned by hand, so don't
142 137 % randomly change them unless you're sure of the effect it will have.
143 138 \usepackage{framed}
144 139
145 140 % remove extraneous vertical space in boxes
146 141 \setlength\fboxsep{0pt}
147 142
148 143 % codecell is the whole input+output set of blocks that a Code cell can
149 144 % generate.
150 145
151 146 % TODO: unfortunately, it seems that using a framed codecell environment breaks
152 147 % the ability of the frames inside of it to be broken across pages. This
153 148 % causes at least the problem of having lots of empty space at the bottom of
154 149 % pages as new frames are moved to the next page, and if a single frame is too
155 150 % long to fit on a page, will completely stop latex from compiling the
156 151 % document. So unless we figure out a solution to this, we'll have to instead
157 152 % leave the codecell env. as empty. I'm keeping the original codecell
158 153 % definition here (a thin vertical bar) for reference, in case we find a
159 154 % solution to the page break issue.
160 155
161 156 %% \newenvironment{codecell}{%
162 157 %% \def\FrameCommand{\color{mediumgray} \vrule width 1pt \hspace{5pt}}%
163 158 %% \MakeFramed{\vspace{-0.5em}}}
164 159 %% {\unskip\endMakeFramed}
165 160
166 161 % For now, make this a no-op...
167 162 \newenvironment{codecell}{}
168 163
169 164 \newenvironment{codeinput}{%
170 165 \def\FrameCommand{\colorbox{inputbackground}}%
171 166 \MakeFramed{\advance\hsize-\width \FrameRestore}}
172 167 {\unskip\endMakeFramed}
173 168
174 169 \newenvironment{codeoutput}{%
175 170 \def\FrameCommand{\colorbox{outputbackground}}%
176 171 \vspace{-1.4em}
177 172 \MakeFramed{\advance\hsize-\width \FrameRestore}}
178 173 {\unskip\medskip\endMakeFramed}
179 174
180 175 \newenvironment{traceback}{%
181 176 \def\FrameCommand{\colorbox{traceback}}%
182 177 \MakeFramed{\advance\hsize-\width \FrameRestore}}
183 178 {\endMakeFramed}
184 179
185 180 % Use and configure listings package for nicely formatted code
186 181 \usepackage{listingsutf8}
187 182 \lstset{
188 183 language=python,
189 184 inputencoding=utf8x,
190 185 extendedchars=\true,
191 186 aboveskip=\smallskipamount,
192 187 belowskip=\smallskipamount,
193 188 xleftmargin=2mm,
194 189 breaklines=true,
195 190 basicstyle=\small \ttfamily,
196 191 showstringspaces=false,
197 192 keywordstyle=\color{blue}\bfseries,
198 193 commentstyle=\color{myteal},
199 194 stringstyle=\color{darkgreen},
200 195 identifierstyle=\color{darkorange},
201 196 columns=fullflexible, % tighter character kerning, like verb
202 197 }
203 198
204 199 % The hyperref package gives us a pdf with properly built
205 200 % internal navigation ('pdf bookmarks' for the table of contents,
206 201 % internal cross-reference links, web links for URLs, etc.)
207 202 \usepackage{hyperref}
208 203 \hypersetup{
209 204 breaklinks=true, % so long urls are correctly broken across lines
210 205 colorlinks=true,
211 206 urlcolor=blue,
212 207 linkcolor=darkorange,
213 208 citecolor=darkgreen,
214 209 }
215 210
216 211 % hardcode size of all verbatim environments to be a bit smaller
217 212 \makeatletter
218 213 \g@addto@macro\@verbatim\small\topsep=0.5em\partopsep=0pt
219 214 \makeatother
220 215
221 216 % Prevent overflowing lines due to urls and other hard-to-break entities.
222 217 \sloppy
223 218
224 219 ((* endblock *))
General Comments 0
You need to be logged in to leave comments. Login now