查看“特殊:Badtitle/NS100:LaTeX/zh”的源代码
来自Ubuntu中文
←
特殊:Badtitle/NS100:LaTeX/zh
跳到导航
跳到搜索
因为以下原因,您没有权限编辑该页面:
您请求的操作仅限属于该用户组的用户执行:
用户
您可以查看和复制此页面的源代码。
{{Translation}} {{From|https://help.ubuntu.com/community/LaTeX}} {{Translator|zhan}} {{Languages|UbuntuHelp:LaTeX}} Latex is a language for describing a document. If you have used HTML, or edited a wiki then you will be familiar with the idea of using symbols or commands within a text file to describe the layout of text. Latex is commonly used in scientific publishing. It helps you to make well formated papers, with good looking formulae. It also helps keep track of figure and equation numbers. Latex files can be converted into a huge number of formats such as PDF, PostScript, DVI, and HTML. LaTex 是一种文档描述语言。如果你曾使用过 HTML, 或曾经编辑过 wiki 那么你对文本中使用符号或命令来描述文档结构的方法很熟悉。 LaTeX 普遍使用在科学出版界。它帮助你制作非常漂亮的论文,还有非常好看的数学公式。它也能帮助你跟踪记录图片和公式的编号。LaTeX 源文件能够被转换成非常多的格式比如 PDF, PostScript, DVI, 和 HTML。 A Latex file is an ASCII file containing the text and markup commands. It can be written in a text editor such as Gedit or vim. It is converted into an output format using a Latex compiler. Some people like to write Latex files in a more integrated environment, with menus and buttons for formatting commands. There are also many add on packages that add features to Latex. 一个 LaTeX 源文件是一个包含文本和标记命令的 ASCII 文件。它能够在文本编辑器如 Gedit 和 Vim 中编辑。他被 LaTeX 编译器转换成特定的输出格式。有人喜欢在一个更加集成的环境中书写 LaTeX 文件,使用菜单和按钮来生成格式控制命令。也有非常多的插件包为 LaTeX 增加新的功能。 === Installing === = 安装 = Like Linux, Latex is a collection of many tools and files. Rather than find and install them all you use a Latex distribution. Latex distributions in the Ubuntu repositories are 就像 Linux, LaTeX 也包含了非常多的相互依赖的工具和文件。一般来说,您会使用一个 LaTeX 的发行版,而不是寻找和安装所有的这些文件,在 Ubuntu 的软件仓库中,他们是下面的两种: * Tetex * Texlive Tetex is a common Latex distribution for Linux. This is in the main Ubuntu repository and can be installed with synaptic or apt-get. At a minimum you will need to install the packages <pre><nowiki> tetex-base tetex-bin </nowiki></pre> you may also want some add on packages <pre><nowiki> tetex-extra </nowiki></pre> Another Latex distribution you can install is texlive. Texlive has a more comprehensive selection of Latex tools than tetex but takes up more space. It is also a newer addition to Ubuntu so you may run into some teething problems. It is available for Ubuntu from version 6.10 and is in the universe repository. To install texlive install the package <pre><nowiki> texlive </nowiki></pre> === Add on packages === Latex can be extended using add on packages. ==== Repositories ==== In addition to <code><nowiki>tetex-extra</nowiki></code> there are numerous packages in the repositories containing add-ons. To see what packages are available you can browse [http://packages.ubuntu.com/breezy/tex/ Software Packages in "breezy", tex section]. ==== Other add-ons ==== There are also lots of add-ons which are not in the repositories. A comprehensive list is availiable at the [http://www.tug.org/tex-archive/help/Catalogue/index.html TeX Catalogue Online] or the [http://www.ctan.org/ Comprehensive TeX Archive Network]. They are usually downloaded as tar.gz or zip files. To install them they need to be uncompressed and copied to /usr/local/share/texmf/tex/latex/. Then you need to run texhash, to update the database. If you downloaded the package mhchem.zip to your home directory, then this should work: <pre><nowiki> cd /usr/local/share/texmf/tex/latex sudo unzip ~/mhchem.zip sudo texhash </nowiki></pre> ==== Local Installation ==== You can also install style or class files in your home directory. This is especially useful if you don't have access to root privileges. The variable <code><nowiki> TEXINPUTS </nowiki></code> controls where latex looks for local files. Suppose you want to put them in a subdirectory of your home directory called <code><nowiki>mylatex</nowiki></code>. Just set <code><nowiki> TEXINPUTS </nowiki></code> as follows: <pre><nowiki> export TEXINPUTS= ~/mylatex/: </nowiki></pre> Now you can put files in <code><nowiki> ~/mylatex </nowiki></code> and latex will know where to find them. To set this as the default value of <code><nowiki>TEXINPUTS</nowiki></code> add the line above to <code><nowiki>.bashrc</nowiki></code> or type <pre><nowiki> cd echo "export TEXINPUTS= ~/mylatex:" >> .bashrc </nowiki></pre> ==== Useful addons include: ==== * [http://www.tug.org/tex-archive/help/Catalogue/entries/mhchem.html mhchem] chemical names, chemical reactions etc. * [http://www.tug.org/tex-archive/help/Catalogue/entries/isotope.html isotope] === Resources === * [http://www.tug.org/interest.html TeX Users Group] Lots of links * [http://www.latex-project.org/guides/ Latex Documentation] * [http://tug.org/TeXnik/mainFAQ.cgi?file=index A-Z list of TeX FAQs] === Inverse Search === Inverse search means that **** A mouse click in the dvi-viewer window can open an editor with the corresponding place in the (La)TeX source (also called `reverse search') * Ctrl-Left Click is the default for xdvi * Middle Click is the default for kdvi **** the dvi-viewer can jump to (and visually highlight) a position in the DVI file that corresponds to a certain line number in the (La)TeX source file (`forward search'). **** for information see [http://xdvi.sourceforge.net/inverse-search.html] ==== Emacs and xdvi ==== ==== Reverse search ==== ===== Instructions to set up reverse search with emacs and xdvi ===== ** Add the following line to the file <code><nowiki>.emacs</nowiki></code> in your home directory <pre><nowiki> (server-start) </nowiki></pre> ** Add the following line to <code><nowiki>.Xresources</nowiki></code> <pre><nowiki> xdvi.editor: emacsclient --no-wait +%l %f </nowiki></pre> ** and run <pre><nowiki> xrdb .Xresources </nowiki></pre> ** Download and install the latex package [http://www.ctan.org/tex-archive/help/Catalogue/entries/srcltx.html srcltx] ** You need to compile your latex file with the srcltx package. Put the line <pre><nowiki> \usepackage[active]{srcltx} </nowiki></pre>in your latex files for this to work ==== Kile and kdvi ==== ** You need to compile your latex file with the srcltx package. Put the line <pre><nowiki> \usepackage[active]{srcltx} </nowiki></pre>in your latex files and forward and reverse search should work. ---- [[category:CategoryDocumentation]] [[category:CategoryArchive]] [[category:CategoryScience]] [[category:UbuntuHelp]]
该页面使用的模板:
模板:From
(
查看源代码
)
模板:Languages
(
查看源代码
)(受保护)
模板:Languages/Lang
(
查看源代码
)(受保护)
模板:Translator
(
查看源代码
)
模板:Verifier
(
查看源代码
)
返回
特殊:Badtitle/NS100:LaTeX/zh
。
导航菜单
页面操作
页面
讨论
阅读
查看源代码
历史
页面操作
页面
讨论
更多
工具
个人工具
登录
导航
首页
最近更改
随机页面
页面分类
帮助
搜索
编辑
编辑指南
沙盒
新闻动态
字词处理
工具
链入页面
相关更改
特殊页面
页面信息