Showing posts with label latex. Show all posts
Showing posts with label latex. Show all posts

Monday, March 17, 2014

Latex Tips & Tricks

Setup Page Margins

\newcommand{\CLASSINPUTinnersidemargin}{0.5in} % left side margin
\newcommand{\CLASSINPUToutersidemargin}{0.5in}% right side margin
\newcommand{\CLASSINPUTtoptextmargin}{1.0in} % top text margin
\newcommand{\CLASSINPUTbottomtextmargin}{1.0in}% bottom text margin
\documentclass {your_class}

** Change the number as necessary.

Solving italic-underline Problem

Problem definition: all the italic words are automatically underlined
Solution: Add the following line after \begin{document}

\normalem


Wednesday, August 8, 2012

Latex: Multirow Example


Recently, I found it difficult to create a table with multi-row and multi-column combination. Here is an simple example.

The latex code to create above table.

\begin{tabular}
{|c|c|c|c|}
\hline
\multirow{1}{*}{{1}} & \multirow{2}{*}{{2}} & \multirow{3}{*}{{3}} & \multirow{6}{*}{{6}} \\
\cline{1-1} \multirow{1}{*}{{1}} & & & \\
\cline{1-2} \multirow{1}{*}{{1}} & \multirow{2}{*}{{2}} & & \\
\cline{1-1} \cline{3-3} \multirow{1}{*}{{1}} & & \multirow{3}{*}{{3}}& \\
\cline{1-2} \multirow{1}{*}{{1}} & \multirow{2}{*}{{2}} & & \\
\cline{1-1} \multirow{1}{*}{{1}} & & & \\
\hline
\end{tabular}

Thursday, May 5, 2011

Latex: Italic Underline Problem

Some Latex compiler underlines the the italic text, more precisely the text inside \emph{your text}. If you don't want the text underlined, just add "\normalem" after the line "\begin{document}" !