Jump to content
From ArchWiki
< TeX Live

This article or section needs language, wiki syntax or style improvements. See Help:Style for reference.

Reason: Bad style. (Discuss in Talk:TeX Live/FAQ)

This article or section is a candidate for merging with TeX Live.

Notes: Bad style, useful information needs to be rewritten and extracted. (Discuss in Talk:TeX Live/FAQ)

## Tips and tricks

### Bibliography / references

Biblatex which is in texlive-bibtexextra is then the thing you are looking for. Some templates for specialized publishers (e.g. the IEEE, some universities, etc.) are included in the texlive-publishers package.

### ConTeXt

(English) ConTeXt should be enabled automatically. Remember that the ruby wrapper to be used with ConTeXt is

    texexec

If ConTeXt is not enabled (or you want to use localized version), use

    texconfig

to edit the configuration file with formats, and uncomment the appropriate lines. To set up the new MarkIV implementation of ConTeXt, see https://wiki.contextgarden.net/Running_Mark_IV

## Troubleshooting

### texlive stopped working after update

- The most common reason is that your have configuation in TEXMFCONFIG or formats in TEXMFVAR that conflict with the new version.

- After upgrade, TeX "stops working" with the following error message:

      Fatal format file error; I'm stymied.

  What one should understand is that the TeX system "precompiles" formats (that is, takes the macros which constitute for instance the LaTeX format, and creates a binary file (`latex.fmt`), which is then used when you call "latex <somefile>"). Now when the tex binary itself is updated, all the precompiled formats need to be recompiled as well. While pacman does that for you for system-wide formats, the info above implies that if a user (or some program like LyX) ever compiled the formats by himself, that user needs to recompile the formats manually. The command for that is `fmtutil --all`. (By the way, the location of `*.fmt` files is `<texmfroot>/texmf-var/web2c`.) The other option is to delete the `*.fmt` files from the local tree (`~/.texlive/texmf-var/web2c/*.fmt`) and use the system-wide generated formats, which can be regenerated with

      # fmtutil-sys --all

- After upgrade, some fonts stop being used properly; or there is an error that TeX cannot find some font. This is related to the question below - you most probably have a local `updmap.cfg` file (check by `kpsewhich updmap.cfg`) which does not reflect changes in `*.map` files and fonts which came with the upgrade. In this case, apply the methods from #pdftex and/or dvips uses bitmap fonts instead of type1 postscript fonts.

### pdftex and/or dvips uses bitmap fonts instead of type1 postscript fonts

Symptoms:

- zooming on PDF/ps file, fonts are really pixelated
- when running tex, it takes a long time because it generates fonts with metafont
- at the end of the log file generated by pdftex it includes *.pk fonts instead of *.pfb"

Files which tell pdftex/dvips which fonts are to be included as type1 fonts (instead of traditional bitmap fonts) have suffix .map and reside somewhere in `<texmfroot>/fonts/map/{pdftex,dvips}/updmap/{pdftex.map,psfonts.map}` . First of all, you need to find out the name of the map file you want. The log for my TeX compilation gave me the error "Font rtxr at 540 not found", so I typed `locate rtxr` and got, among others, `/usr/share/texmf-dist/fonts/afm/public/txfonts/rtxr.afm`. This tells me the font package is `txfonts`.

You do not want to edit these mapfiles manually; they are good for checking if your favorite type1 font which causes trouble is sitting there properly.

- These files are automatically generated, when you run

    $ updmap

as user, or

    # updmap-sys

as root for system-wide changes

What you need to do to have your favorite fonts (for instance kpfonts or txfonts) properly used as type1 fonts in pdf and ps files is to locate the .map file that goes with the package (e.g. kpfonts.map; you do not need to actually *do* anything with the file, just know that it is there somewhere), edit `updmap.cfg` by running

    $ updmap --edit

as user (or

    # updmap-sys --edit

as root) and add the line

    Map kpfonts.map

or the line

    MixedMap kpfonts.map

(MixedMap indicates that fonts are also available as bitmap fonts.), and exit the editor. At this point, you should see the messages which indicate that updmap is regenerating {pdftex,psfonts}.map files.

Alternatively, just run

    $ updmap --enable Map=kpfonts

or (as root)

    # updmap-sys --enable Map=kpfonts

if you just want to add one map without going into an editor.

This should be sufficient, and your next run of pdftex/dvips should be already including the type1 versions of fonts.

## Creating graphics with TeX commands

### Pictures with LaTeX labels

Apart from some latex in-source macros (which are a bit of a PITA to write), there are excellent "picture programming languages" metapost and its (more-less) successor asymptote. They are pretty powerful, but have similar approach as tex itself - you write down what you want to have and how are the things related, and compiler then produces the picture. The target format is postscript for metapost; and EPS/PDF/PNG for asymptote.

Even closer incorporated to TeX itself - i.e. to Plain TeX, LaTeX or ConTeXt, there are layers for each of this formats - is the relatively new PGF package with its language named TIKZ[dead link 2022-09-23 ⓘ].

The Python library PyX (python-pyx) gives the possibility to use Python to program pictures, and it uses TeX for the typesetting.

Last but not least: PSTricks, which gives an interface for direct inclusion of Postscript-code into TeX (ps2pdf). There are some hurdles to climb if you want to have pdf-output, because PSTricks is not compatible to pdftex.

### Pictures with LaTeX labels - GUI

The "grandfather" of vector editors - xfigAUR is able to produce some output relevant to TeX. I had relatively good experience with ipe recently (saves EPS/PDF). Inkscape is a good choice too.

Category:

- TeX

Hidden categories:

- Pages or sections flagged with Template:Style
- Pages or sections flagged with Template:Merge
- Pages with dead links