Skip to content

Commit 1128624

Browse files
libralibradavidcarlisle
authored andcommitted
clean copy of English version for a fresh Chinese translation
1 parent f7c1b15 commit 1128624

46 files changed

Lines changed: 4692 additions & 215 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

zh/contact.md

Lines changed: 24 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,28 @@
11
---
2-
lang: "zh"
2+
layout: "page"
3+
lang: "en"
34
title: Contact
4-
permalink: /zh/contact
5+
permalink: /en/contact
56
---
67

7-
# Contact (Chinese)
8+
# Contact
9+
10+
## Individual Support
11+
12+
Unfortunately we do not have the resources to offer individual help on LaTeX problems and will therefore not reply to emails seeking support. See [The LaTeX Project's help page](https://www.latex-project.org/help/) for ways to get user support.
13+
14+
## Website Team
15+
16+
The [source code of this website](https://github.com/learnlatex/learnlatex.github.io/) is on [GitHub](https://github.com/learnlatex/), please see [CONTRIBUTING](../CONTRIBUTING) and [LICENSE](../LICENSE) for details.
17+
18+
You can also [open an issue on GitHub](https://github.com/learnlatex/learnlatex.github.io/issues) or [email us](mailto:[email protected]) with suggestions.
19+
20+
## Impressum
21+
22+
<p>Joseph Wright<br>
23+
14, Woodlands Chase<br>
24+
Witchford<br>
25+
Ely<br>
26+
CB6 2SB<br>
27+
United Kingdom<br>
28+

zh/extra-01.md

Lines changed: 69 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,73 @@
11
---
22
layout: "lesson"
3-
lang: "zh"
4-
title: "Examples for further study (Chinese)"
5-
description: ""
6-
toc-anchor-text: "Anchor"
7-
toc-description: "Description"
3+
lang: "en"
4+
title: "LaTeX Showcase - Examples for further study"
5+
description: "This lesson shows assorted examples of other popular LaTeX packages that were not covered in the main lessons."
6+
toc-anchor-text: "LaTeX Showcase"
7+
toc-description: "Examples for further study."
88
---
99

10-
Translation to be added _after_ English text completed.
10+
# Showcase
11+
12+
<span
13+
class="summary">This lesson shows assorted examples of other popular LaTeX packages that were not covered in the main lessons.</span>
14+
15+
This course has given an overview of the core features of LaTeX.
16+
LaTeX has vast array of extension packages and is used in many subject
17+
areas. We give here some examples, with no explanation here but links
18+
to the package documentation at [texdoc.org](https://texdoc.org).
19+
The examples are taken from the package documentation unless otherwise noted.
20+
21+
<p
22+
class="hint">Note that inclusion here is not intended as an endorsement of the package over other similar packages, we just aim for a small sample showing a range of areas not otherwise covered in this course.</p>
23+
24+
## Chemistry
25+
26+
Package: [`mhchem`](https://texdoc.org/pkg/mhchem)
27+
28+
{% include extra-01-example-mchem.md %}
29+
30+
## Linguistics
31+
32+
Package: [`forest`](https://texdoc.org/pkg/forest)
33+
34+
{% include extra-01-example-forest.md %}
35+
36+
## Chess
37+
38+
<!-- not 2017 -->
39+
Package: [`xskak`](https://texdoc.org/pkg/xskak)
40+
41+
{% include extra-01-example-xskak.md %}
42+
43+
44+
## Poetry
45+
46+
Class: [`memoir`](https://texdoc.org/pkg/memoir)
47+
48+
{% include extra-01-example-memoir.md %}
49+
50+
51+
## Drawing
52+
<!-- not 2017 -->
53+
Package: [`tikz`](https://texdoc.org/pkg/tikz)
54+
55+
56+
{% include extra-01-example-tikz.md %}
57+
58+
59+
## Function plotting
60+
61+
Package: [`pgfplots`](https://texdoc.org/pkg/pgfplots)
62+
63+
64+
{% include extra-01-example-pgfplots.md %}
65+
66+
67+
## Music
68+
69+
Package: [`musixtex`](https://texdoc.org/pkg/musixtex)
70+
71+
72+
73+
{% include extra-01-example-musixtex.md %}

zh/help.md

Lines changed: 250 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,252 @@
11
---
2-
title: "Using the learnlatex.org site (Chinese)"
3-
permalink: /zh/help
2+
layout: "page"
3+
lang: "en"
4+
title: "Using the learnlatex.org site"
5+
description: "This page explains the learnlatex.org website itself and how to best make use of it."
6+
permalink: /en/help
47
---
5-
Translation to be added _after_ English text completed.
8+
<script>
9+
function acesettings() {
10+
editors['pre0'].execCommand("showSettingsMenu");
11+
}
12+
</script>
13+
14+
# Help
15+
16+
17+
## Navigating the site
18+
19+
The course consists of 16 core lessons that can be reached from the
20+
[table of contents]({{ "/" | absolute_url | append: page.lang | append: "/#toc" }}) on the [start page](./).
21+
22+
Each lesson has a link to one associated lesson on the same subject
23+
that goes into greater depth. It should be possible to work through
24+
all 16 lessons _without_ reading the additional lessons.
25+
26+
At the end of the course there are one or more lessons specific to the
27+
language being used for the lessons, and finally a gallery of examples
28+
of packages demonstrating LaTeX use not covered by this course.
29+
30+
---
31+
32+
## Examples
33+
34+
### Running the examples
35+
36+
Each example consists of a complete small LaTeX document shown within
37+
the page like this:
38+
39+
```latex
40+
\documentclass{article}
41+
\usepackage[T1]{fontenc}
42+
43+
\begin{document}
44+
Example text.
45+
\end{document}
46+
```
47+
48+
Each example is complete. However you may wish to edit it to make small
49+
changes, perhaps as part of an Exercise set at the end of the lesson.
50+
51+
The editor being used is [ACE](https://ace.c9.io/).
52+
53+
You may customise the theme used in the editor (for example using a
54+
dark theme with light text on a dark background) on the [Site Settings](settings) page.
55+
A convenient way to experiment with different themes is to to use <kbd>Ctrl</kbd>+<kbd>,</kbd> (<kbd>⌘</kbd>+<kbd>,</kbd> on Mac)
56+
while on any example in the site. [This displays a panel](javascript:acesettings()) which allows you to change all the ACE settings.
57+
58+
The ACE repository has a [useful page of editor keyboard shortcuts](https://github.com/ajaxorg/ace/wiki/Default-Keyboard-Shortcuts).
59+
60+
61+
62+
#### Three ways to run the example
63+
64+
* Use the Overleaf service
65+
* Use the TeXLive.net service
66+
* Use a locally installed TeX system
67+
68+
##### Use the Overleaf service
69+
70+
Overleaf is one of the most popular online LaTeX editing services. The
71+
<button>Open in Overleaf</button> button, below the example, will submit the
72+
code to [Overleaf](https://www.overleaf.com/about).
73+
74+
If you do not have an account, or the account details are not
75+
already cached in your browser, then you will be redirected to a
76+
login page where you may login or register with Overleaf. This is a
77+
free service but does require you to give some details and agree to
78+
terms and conditions.
79+
80+
If your Overleaf account is already cached in your browser, then
81+
Overleaf will be opened in a new tab, with a new
82+
project with the code. You may then edit it in
83+
Overleaf which will simultaneously run LaTeX on your code showing
84+
the resulting output or error log.
85+
86+
Unlike documents processed at TeXLive.net, you may save your project
87+
in your Overleaf account and return to it later.
88+
89+
##### Use the TeXLive.net service
90+
91+
The <button>Run at TeXLive.net</button> button, below the example, will submit the code to the
92+
[TeXLive.net](https://texlive.net) service[^1].
93+
94+
The TeXLive.net service was developed specifically to support this site, and
95+
in particular makes use of [PDF.js](https://mozilla.github.io/pdf.js/)
96+
to enable display of PDF on mobile and other browsers without built in PDF
97+
readers.
98+
99+
The resulting PDF document (or section of the error log) will be
100+
shown inline immediately below the example. A <button>Delete
101+
Output</button> button will be provided so that you may remove this output
102+
(or you may leave it in place and continue the rest of the lesson
103+
below).
104+
105+
Note that **TeXLive.net** requires no login or signup of any sort
106+
so it is very convenient for small examples, but this site
107+
provides no mechanism to save your document. Any changes that you
108+
make to the example are lost if you move off the page.
109+
110+
##### Locally installed TeX system
111+
112+
If you have a TeX system installed locally, then you may copy the
113+
example code off the page, either explicitly selecting it, or by
114+
using select all keyboard shortcuts in the editor
115+
(<kbd>Ctrl</kbd>+<kbd>A</kbd> <kbd>Ctrl</kbd>+<kbd>C</kbd>
116+
in windows for example). This will place the code in your operating system
117+
clipboard so you can start a blank document using your local
118+
editor, and paste in the text.
119+
120+
### Troubleshooting
121+
122+
Our examples are based around using an up-to-date LaTeX installation. They all
123+
work with both of our online demonstration systems, so if you get errors with
124+
the examples we provide, you might want to check if your LaTeX system is
125+
up-to-date.
126+
127+
---
128+
129+
## Choosing the TeX engine
130+
131+
When submitting example documents, by default the `pdflatex` engine will be used.
132+
133+
You can force the choice of `latex`, `pdflatex`, `xelatex`, `lualatex`,
134+
`platex` or `uplatex` by using a comment of the form:
135+
136+
`% !TEX ` _any text_ `lualatex`
137+
138+
where the white space at the start is optional and case is ignored as
139+
is _any text_ between the first and last word.
140+
141+
This allows the form `% !TEX program=pdflatex` used by some TeX editors
142+
but does not require the `program=` and is currently restricted to
143+
specifying just one of the engines that are supported on
144+
the online systems being used.
145+
146+
You can see an example of a comment being used to specify LuaLaTeX in
147+
[some of the examples on this site](more-14).
148+
149+
If `platex` or `uplatex` is specified; then the `dvipdfmx` program is
150+
also used to produce the PDF result from the DVI file that these variants generate.
151+
Similarly `dvips` and `ps2pdf` are used if `latex` is specified.
152+
153+
If the engine is not specified in a `% !TeX` comment, then `pdflatex` will be used
154+
unless you have specified a default TeX engine on the [Site Settings](settings) page.
155+
156+
---
157+
158+
## Choosing how to display the output
159+
160+
If you use the TeXLive.net system, then the PDF
161+
output from running an example is shown using
162+
[PDF.js](https://mozilla.github.io/pdf.js/) by default. This provides
163+
consistent behavior over the widest range of browsers.
164+
165+
If you would prefer to use your browser's default PDF reader (either
166+
its built in one, or an external application that you have configured)
167+
then add a comment of the form:
168+
169+
`% !TEX ` _any text_ `pdf`
170+
171+
The default behavior can be explicitly specified by using `pdfjs` as
172+
the final token. For debugging you may sometimes want the log file
173+
returned, even if the document produces a PDF with
174+
no errors. This can be specified by using `log` as the final token in
175+
the comment.
176+
177+
As an alternative to using a `% !TeX` comment, you may specify the
178+
site default return parameter on the [Site Settings](settings)
179+
page. The Settings are specific to each browser, so for example you
180+
may choose to use the default `pdfjs` setting on your mobile device,
181+
but use `pdf` on your desktop browser to use its default PDF rendering.
182+
183+
184+
---
185+
186+
## HTML output (make4ht, LaTeXML, lwarp)
187+
188+
If using the TeXLive.net system, then additional return options,
189+
`make4ht`, `LaTeXML` or `lwarp` may be specified. These return one or more HTML pages
190+
in the frame within the page. It may be specified at the same time
191+
as `xelatex` or `lualatex` as well as the default `pdflatex` processing.
192+
193+
To enable this output, add a comment of the form:
194+
195+
196+
```
197+
% !TeX make4ht
198+
```
199+
{: .noedit :}
200+
201+
202+
Replacing `make4ht` by `LaTeXML` or `lwarp` to specify those systems.
203+
204+
205+
206+
Alternatively you may specify `make4ht`, `LaTeXML` or `lwarp` as the default return option
207+
on the [Site Settings](settings) page.
208+
209+
210+
If using a locally installed TeX system, the same output as the `make4ht` option may be obtained
211+
by executing
212+
213+
```
214+
make4ht document.tex "learnlatex4ht,2,mathml,mathjax,svg"
215+
```
216+
{: .noedit :}
217+
218+
with the addional option `-x` or `-l` if XeLaTeX or LuaLaTeX are specified.
219+
220+
When running locally, other configurations would be possible. See the [make4ht
221+
manual](https://texdoc.org/pkg/make4ht).
222+
223+
224+
For `LaTeXML` to run locally, you would need to install LaTeXML (it is not part of TeX Live or MiKTeX)
225+
and use
226+
227+
```
228+
latexml document.tex > document.xml
229+
latexmlpost --format=html5 \
230+
--javascript='https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js' \
231+
--destination=document.html" document.tex
232+
```
233+
{: .noedit :}
234+
235+
Many other LaTeXML configurations are possible,
236+
[as described in the manual](https://dlmf.nist.gov/LaTeXML/manual/).
237+
238+
239+
The `lwarp` configuration is not documented here, it is somewhat experimental and subject to change.
240+
The current version can be seen at the
241+
[source repository](https://github.com/davidcarlisle/latexcgi/blob/main/lwarp/latexcgilwarp).
242+
243+
244+
---
245+
246+
[^1]: Note that during development of the site we have also used
247+
[LaTeX.Online](https://latexonline.cc/) and
248+
[LaTeX-on-HTTP](https://github.com/YtoTech/latex-on-http)
249+
and we thank the developers of those services for making updates to enable
250+
the examples on this site to be available at an early stage.
251+
252+

zh/includes/buttons.js

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
1-
runlatex.texts ={
2-
"Open in Overlaf": "Aberto em Overleaf",
3-
"TeXLive.net": "LaTeX Online",
4-
"Delete Output": "Excluir saída",
5-
"Compiling PDF": "Compiling PDF",
1+
runlatex.texts = {
2+
"Open in Overleaf": "Open in Overleaf",
3+
"TeXLive.net": "Run at TeXLive.net",
4+
"Delete Output": "Delete Output",
5+
"Compiling PDF": "Compiling PDF",
66
// The following not used on learnlatex.org
7-
"edit": "edit",
8-
"copy": "copy",
9-
"Added Code": "Added code",
10-
"End Added Code": "End Added code",
11-
"Top Caption": "Edit and run this example:"
7+
"edit": "edit",
8+
"copy": "copy",
9+
"Added Code": "Added code",
10+
"End Added Code": "End Added code",
11+
"Top Caption": "Edit and run this example:"
1212
}
13+

zh/includes/more.html

Lines changed: 0 additions & 1 deletion
This file was deleted.

zh/includes/next.html

Lines changed: 0 additions & 1 deletion
This file was deleted.

zh/includes/nextmain.html

Lines changed: 0 additions & 1 deletion
This file was deleted.

zh/includes/return.html

Lines changed: 0 additions & 1 deletion
This file was deleted.

0 commit comments

Comments
 (0)