LaTeX/Installation : Différence entre versions

De LaTeX
Aller à : navigation, rechercher
(Calc2LaTeX installation on OpenOffice.org 2.0)
(Calc2LaTeX)
Ligne 64 : Ligne 64 :
 
==Calc2LaTeX==
 
==Calc2LaTeX==
  
Calc2LaTeX lets you selects cells in your spreadsheets and output code for LaTeX tables.
+
Calc2LaTeX lets you select cells in your spreadsheets and output code for LaTeX tables.
  
  
Ligne 80 : Ligne 80 :
 
# You will see a file dialog, so select <tt>script.xlb</tt> which you have extracted from the zip file in advance.
 
# You will see a file dialog, so select <tt>script.xlb</tt> which you have extracted from the zip file in advance.
 
:[[Fichier:calc2latex4.jpg]]
 
:[[Fichier:calc2latex4.jpg]]
 +
 +
You can now use calc2latex to produce LaTeX tables. There is chapter on LaTeX and you will learn how to use calc2latex as well as how to improve the source code output by calc2latex as well as how to simplify it. The following section gives some advices and you can refer to it later.
 +
 +
 +
===Optional steps ===
 +
Default settings of Calc2LaTeX are nice except the encoding which is the old West European Latin 1 or ISO-8859-1 code instead of UNICODE (UTF-8). It doesn't really matter if you store the LaTeX code in your clipboard and paste it in your TeX editor because the transformation to the local encoding of your LaTeX file is done on the fly, but if your output is a file, that file will be ISO-8859-1 encoded. And you will have difficulties to mix words from East European languages as well as Russian, Arabic and Asian languages. Older TeX (1982) and even pdfTeX are not able to mix 'naturally' various languages like this wiki is able to do. Only XeTeX as well LuaTeX are able to do it. You are encouraged to use these engines instead of pdfTeX. Don't worry XeTeX and LuaTeX are outputting PDF formats by default and no more the old DVI format.
 +
 +
Thus in order to make UTF-8 the default encoding of Calc2LaTeX (if not set already by a newer version than the current 0.2.4) you can do it during the installation. It is as easy or as difficult as the installation.
 +
 +
Do the previous steps, and then Edit the <tt>Main</tt> macro. :[[Fichier:calc2latex-edit-macro.png]]
 +
then change ISO-8859-1 to UTF-8 and save.:[[Fichier:calc2latex-change-main-macro.png]]
  
 
== R ==
 
== R ==

Version du 3 juin 2011 à 08:16

TeXLive

TeXLive2010 is a common distribution for Windows, Mac OS/X and Linux. In May 2011, TeXLive2011 is not out but most of packages, if upgraded from CTAN. The Comprehensive TeX Archive Network is the place to get materials related to the TeX typesetting system. You need to read http://www.tug.org/texlive/doc/texlive-en/texlive-en.html

  • On Mac OS/X, you are supposed to get MaCTeX which includes TeXLive and run the dmg file for installation.
  • On Linux, texlive is installed by default. You may need to install some additional packages.

Windows installation

Insert the DVD and install the distribution. It may take half an hour or more. See http://www.tug.org/texlive/doc/texlive-en/texlive-en.html for Post instal actions. In particular open a terminal and enter the command (copy and paste by right click)

> tlmgr option repository http://mirror.ctan.org/systems/texlive/tlnet 

For all 3 OS

Follow the section 3.5 Testing the installation and test the commands: latex, pdflatex, etc. on simple examples.


Once you are finished, you can test the editor TeXworks which works on the 3 operating systems.

Click on the TeXworks icon on your Desktop (Windows installation) and choose File => New from a template. Choose a Beamer template. Run it, look at the pdf, move to another page. Right click somewhere on the pdf text and choose sync to the source code. Your left window will sync with the corresponding tex source line. Move to another section of the source text, right click and choose locate on PDF and the right pane (PDF window) will scroll to the corresponding section.

Test a XeTeX template and run it. If it runs into error because of a missing font, comment the line by adding a % in front of the line and run again. XeTeX is able to run with any font of your OS and not only on "Computer Modern" fonts which are specific to TeX.

Now you have a running mininal running installation.

Gnu-emacs and AucTeX

If you are willing to use Emacs for your TeX editor, you will have to download Aquamacs for OS/X users. On Linux, you need to download gnu-emacs as well as AucTeX which are in two separate packages. On Windows, go to http://www.gnu.org/software/auctex/download-for-windows.html and you will able to download AucTeX as well as Emacs.

Just download the Emacs zip (currently version 23.3) first and then extract it on c:\Program Files\Emacs by creating an Emacs folder. It will created a tree c:\Program Files\Emacs\emacs-23.3 of all the emacs distribution. In the directory c:\Program Files\Emacs\emacs-23.3\bin, you will find a file named runemacs.exe. Right click and create an alias (link) file and then move this link on your desktop or menu bar in order to launch emacs.

Now, unzip the AucTeX zipped file exactly on this emacs-23.3 folder in order to add the AucTeX tree to the emacs tree. In particular a newer dir file under the emac-23.3\info will supersede the previous file with the same name (accept to overwrite dir file).

Launch runemacs and open a tex file. It should work.

JabReF

JabReF (see http://jabref.sourceforge.net/) is the tool which will be presented for the Bibliography management. Some exercises will be proposed using JabReF. It is very easy to download.

Other softwares

Other softwares will be used during the presentation in relation to LaTeX. They are all free softwares. You can dowload them.

OpenOffice and writer2latex

If you want to export a Word document into a LaTeX document, a nicer way than copy and paste consists in loading the .doc file in Writer from Openoffice and export it using writer2latex as a LaTeX file.

You can download OpenOffice at http://fr.openoffice.org/about-downloads.html and install the default installation with Java.

Then go to http://writer2latex.sourceforge.net/index12.html#download in order to download Writer2LaTeX 1.1.7 (April 2011) as a zip file. Unzip the file in a temporary folder and click on the file writer2latex.oxt which will open by OpenOffice and install as an extension.

Now you can export a .doc into a .tex file. Amongst the various options, you can use Simple LaTeX, utf-8 encoding as well as xetex for the TeX engine instead of pdftex.

For non well structured documents you will find that Writer2LaTeX uses the principle garbage in – garbage out!

But for a well structured Word document, writer2latex (recent version only) simplifies the porting by creating images (png files) for most of the figures.

You need Emacs or any editor to clean the LaTeX file. For tables, simple copy and paste might be preferred. A systematic change of the tabulation character to " & " (two spaces around an ampersand) is helpful.

Calc2LaTeX

Calc2LaTeX lets you select cells in your spreadsheets and output code for LaTeX tables.


Calc2LaTeX installation on OpenOffice.org 2.0

  1. Before you install Calc2LaTeX, download a zip file from http://calc2latex.sourceforge.net and extract it somewhere.
  2. Open OpenOffice Calc or (Libre Office) and click Tools=>Macros=>Organize Macros => OpenOffice.org Basic...
Erreur lors de la création de la miniature : Impossible d'enregistrer la vignette sur la destination
  1. You will see 'OpenOffice.org Basic Macros' dialog box. Select 'My Macros' and push 'Organizer' button
Erreur lors de la création de la miniature : Impossible d'enregistrer la vignette sur la destination
  1. Click 'Libraries' tab, and confirm that 'My Macros & Dialogs' is selected on the list of 'Location.' (If not, select it.)
And then click Append button.
Erreur lors de la création de la miniature : Impossible d'enregistrer la vignette sur la destination
Erreur lors de la création de la miniature : Impossible d'enregistrer la vignette sur la destination
  1. You will see a file dialog, so select script.xlb which you have extracted from the zip file in advance.
Erreur lors de la création de la miniature : Impossible d'enregistrer la vignette sur la destination

You can now use calc2latex to produce LaTeX tables. There is chapter on LaTeX and you will learn how to use calc2latex as well as how to improve the source code output by calc2latex as well as how to simplify it. The following section gives some advices and you can refer to it later.


Optional steps

Default settings of Calc2LaTeX are nice except the encoding which is the old West European Latin 1 or ISO-8859-1 code instead of UNICODE (UTF-8). It doesn't really matter if you store the LaTeX code in your clipboard and paste it in your TeX editor because the transformation to the local encoding of your LaTeX file is done on the fly, but if your output is a file, that file will be ISO-8859-1 encoded. And you will have difficulties to mix words from East European languages as well as Russian, Arabic and Asian languages. Older TeX (1982) and even pdfTeX are not able to mix 'naturally' various languages like this wiki is able to do. Only XeTeX as well LuaTeX are able to do it. You are encouraged to use these engines instead of pdfTeX. Don't worry XeTeX and LuaTeX are outputting PDF formats by default and no more the old DVI format.

Thus in order to make UTF-8 the default encoding of Calc2LaTeX (if not set already by a newer version than the current 0.2.4) you can do it during the installation. It is as easy or as difficult as the installation.

Do the previous steps, and then Edit the Main macro. :
Erreur lors de la création de la miniature : Impossible d'enregistrer la vignette sur la destination
then change ISO-8859-1 to UTF-8 and save.:
Erreur lors de la création de la miniature : Impossible d'enregistrer la vignette sur la destination

R

Gnuplot (***)

Xfig (****)

Linux and OS/X only!!!

Inkscape (***)

IPE 7 (**)

Geogebra (**)

  Index Next: Introduction