Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Latex paragraph spacing and page Margins

Tags:

latex

My latex file is:

    \title{\large\textbf{Optimizarea rela\c tiei dintre structur\u a \c si comportament \^in modelarea UML}}

    \author{
            Sorin Oltean \\
                    \textit{Universitatea Transilvania din Bra\c sov} \\
                    \small\textit{[email protected], [email protected]} \\
                    \small Tel.: 0752/314288
    }

    \documentclass[12pt]{article}

    \begin{document}
    \maketitle
    \renewcommand\abstractname{\textit{\textbf{Abstract}}}

    \begin{abstract}
    Something..... text.........
    \end{abstract}\\\

    \textbf{Cuvinte cheie:}  \textit{sistem, structur\u a, comportament, UML}

    \section{Introducere}

    \paragraph{  } 
    Para11.............
    \paragraph{ } 
   Para2......
    \bibliographystyle{abbrv}
    \bibliography{main}

    \end{document}

After para1, i wanna start a new paragraph, but between the paragraphs there is a blank line, how can i start the 2nd paragraph below the 1st one, without that blank space? Also, how can i define the margins (top, down, left, right) of the document? There is too much space from the left, right, top and down, i wanna just 2cm space from the left and right, and 3cm from the top and down. Sorry for my bad english.. Also how can i specify the font name and size of the document?

Thanks!

like image 811
qwerty Avatar asked Dec 23 '22 01:12

qwerty


2 Answers

I see you make several mistakes that are typical for beginners:

  • Don't use the standard classes for generic documents (article, report, book), they are too inflexible. Use the KOMA-Script classes (scrartcl, scrreprt, scrbook) or the memoir class instead.
  • Don't change the default settings until you have read books or articles about typography.
  • In particular, the default page margins are OK, there is no need to change them. Margins of 2 cm would be way too narrow.
  • When it comes to fonts, the answer depends on which engine you use: pdfTeX-based documents require specially-crafted packages, whereas modern engines (XeTeX and LuaTeX) can access system fonts. Like before, don't switch fonts light-heartedly. Only very few fonts of high quality are available to normal users. In particular, never use Arial or Times New Roman. On Mac OS X, you could use Hoefler Text, on Windows Cambria, for example.
  • Don't include formatting commands in token lists that are intended for plain strings like \title or \abstractname; use the formatting commands that your document class provides.
  • \paragraph is a sectioning commands that creates a heading; use blank lines to separate simple text paragraphs.
  • Load the inputenc package (only necessary in the case of pdfTeX) so that you can enter non-ASCII characters directly.
  • The \documentclass command must come first.
  • Don't use the geometry package unless you have very specific and unavoidable requirements.
  • Avoid the parskip package; modern document classes already include its functionality; and normally, paragraphs should be marked by indents, not by vertical space, so no changes to the default are required.
  • Never use the fullpage package, it's completely outdated.
  • Like the others said, start by reading some introductory material about LaTeX like the Short Introduction.
  • Read the document Obsolete packages and commands.
like image 117
Philipp Avatar answered Dec 31 '22 14:12

Philipp


Use the geometry package. It allows full control over margins etc.

\usepackage{geometry}
\geometry{margin=2cm}

The space between paragraphs can be set via parskip:

\setlength{\parskip}{0cm}

However, parskip does not work for paragarphs introduced by \paragraph. But if your paragraphs do not need a caption (as I assume since you wrote \paragraph{}, it may be better to begin paragraphs just with a blank line:

\setlength{\parskip}{0cm}
Here goes the first paragraph.

Here the second. With no space. Note that this paragraph was introduced with a blank line.

\paragraph{The third paragraph} This paragraph will have a small offset, since it is introduced explicitly with paragraph command.
like image 36
phimuemue Avatar answered Dec 31 '22 14:12

phimuemue