Useful for LaTeX, PDF, PS, and HTML

LaTeX

Upright greek chararacters

I encountered the problem that the greek characters are always slanted due to their origin from the math environment. If they are used in normal text, for example in mm or ms, they always look a little strange.

With MikTeX, upright greek characters are provided within one of the Euler fonts. One way to implement them for my use was the definition of a new font. Then an upright \mu called \umu can be defined for use in the math environment.

Add these four lines to the preamble.

\DeclareFontFamily{U}{euc}{}% I chose euc because the chart is called Euler cursive
\DeclareFontShape{U}{euc}{m}{n}{<-6>eurm5<6-8>eurm7<8->eurm10}{}%
\DeclareSymbolFont{AMSc}{U}{euc}{m}{n} % I chose AMSc because AMSa and AMSb are defined in the amsfonts-package
\DeclareMathSymbol{\umu}{\mathord}{AMSc}{"16}

Fraunhofer and Springer do it in a similar way.

There is also the package textcomp...

\usepackage{textcomp}
\begin{document}
\textmu
\end{document}

A disadvantage of this package is that you cannot have the whole greek alphabet in upright font and in my oponion the Euler \mu looks much nicer.

Adding to the confusion about BiBTeX styles

For publications in journals you will often need something like the unsrt style, that is, sorted by order of citation in the text. If you don't want the titles of the articles included, you may choose the prsty style, used by Physical Review. By default, this reduces lists of more thant four authors to the name of the first one plus et.al., but this feature can be switched off by setting the "useetal" flag in the prsty.bst-file (find the heading customization). Make sure to save it under a different filename!

If you want to switch between long and abbreviated journal names it is probably best to create two extra .bib files and put the @string definitions of journal names in there. The entries may read something like

@string{jap={Journal of Applied Physics}}
@string{prb={Physical Review B}}

in the file long.bib and

@string{jap={J. Appl. Phys.}}
@string{prb={Phys. Rev. B}}

in the file short.bib. You can then create the bibiliography simply by calling two files:

\bibliography{short,my-bib}
\bibliographystyle{my-prsty}

About LaTeX and PDF

There are several ways to achieve this goal. Each one has advantages and drawbacks. Check out for yourself!

pdflatex

The seemingly most straightforward way, instead of creating DVI you create PDF from your .tex file. This will also result in a nice navigation window with the table of contents.

But....

All your imported EPS images must be converted to PDF. In order to do this for EPS images in a given folder you may want to use the following batch file. Just make sure you do not have a file called todolist.txt in yor folder. The script makes use of the epstopdf converter provided by the MikTeX package which in turn expects ghostscript to be in the path. Seems, it does not work under Win9x. Also, you must run it from cmd rather than command (subtle differences...).

dir /b *.eps > todolist.txt
for /F %%y in (todolist.txt) do epstopdf %%y
del todolist.txt

Another thing worthwhile knowing is a problem with font embedding. The Type-1 CM-fonts of older MikTeX versions (before 2.2.5 to my knowledge) will create problems with Acrobat5. They are displayed nicely on screen but they are not printed. Thus, get yourself a new version of MikTeX or avoid Acrobat5. Or get the whole suite and distill your PDF from the PS output (see below).

Creating PDF from DVI

The command dvipdfm will create a PDF from DVI-files. If you used hyperref you will also get links in the document.

Creating PDF from PS

If you do not want to use pdflatex (or if you encounter problems by the combination of pdftex and hyperref) there is another possiblity. Create a DVI with hyperrefs and convert it to Postscript:

dvips -z -P pdf input.dvi -o output.ps

The z-flag takes care of the hyperreferences. The option -P pdf selects a "pdf printer" which embeds scalable Type 1 fonts rather than pixeled pk-fonts. After that you can convert it with ps2pdf or Ghostview or AcrobatDistiller.

Create PDF from scanned page images

Scan your pages black and white whith with a resolution of 200 or 300 dpi and save them in tif or gif format. If you have the complete Acrobat suite you can import the images directly into a new PDF file.

You can also use the free tiff2ps tool in order to create a ps file:

tiff2ps -O out.ps page.tif page2.tif ...

Then, use Ghostview to convert to PDF. Upon opening the PS, Ghostview will complain about the pagenumbers. Press "cancel" and proceed with the conversion.

Manipulate your PostScript

For sorting my A4 thesis into a booklet of A5 pages I rearranged it into signatures with these commands:

psbook infile.ps outfile.ps to rearrange the pages

psnup -2 infile.ps outfile.ps to put two pages on each sheet

pstops 2:0,1u(21cm,29.7cm) infile.ps outfile.ps to turn every other page (this may depend on your particular duplex unit)

HTML frames

Often you will have links on a frame page which refer to things outside of your context. But if you follow the link the page will be displayed right within your frame.

In order to avoid this the link must be called with the target "_top" or "_parent":

<a href="http://www.yourpage.net" target="_top">Click here</a>

See here for more.


Home Back