LaTeX template

NOTE: this template is written using Polish language and assumes Polish encoding of input files. this is not a big problem in general, but it might be a bit difficult to use it not knowing Polish (mostly macros). i plan to rewrite it using English language in the future.

writting in LaTeX is great experience. one who have tried it once will never go back to WYSIWYG-kind editors. but there is small problem – some basic elements are always the same and you need to enter them each time. there are also some general-purpose macros you write to make things even simpler.

all of this basics have been collected creating extra-small LaTeX template package.

package content

here i'll describe how to use this package and what is inside of it.

directory structure

the main structure looks this way:

  • <root>/ – root directory of whole template.
  • <root>/pic – directory in which pictures are to be stored.
  • <root>/common – directory containing common code, namely: macros.
  • <root>/chapters – user directory. here sources of all chapters/sections should be kept.

be default there are two files in <root>/chapter: root.tex and root_test.tex. these are the main files that are included from templates root. they are separated to ensure user will need not to change any file inside template itself. purpose of both files will be described later on.

how to latex code

there are two possible modes to building output PDF from template: building full code and only selected part. below both of them are described.

"release" mode

in this case root.tex file is taken as selector for user input. structure of whole document should be placed here. of course it is good idea to split content into separate files that will be included from root.tex. there is no requirement of how exactly this must be done, except of that all files must be kept in <root>/chapters/ directory (for Makefile targets).

to build whole document as PDF type:

make final

in template root.

"test" mode

in test mode root_test.tex is take instead of root.tex . normal course of work is to put only currently processed chapter/section/subsection (whatever one needs) in root_test.tex so that building of “test” will be as fast as possible (this allows fast checking what have been written).

to build “test” PDF type:

make test-final

this forces 3 passes of pdflatex over source + 1 bibtech. you can skip this and process just once by typing:

make test


description of basic macros available in template:

  • \tableka{label}{format}{description}{content} – creates table labeled as 'label' of format 'format' (ex: 'ccc'), with 'description' underneath. content of table is last arg.
  • \tabelkaRef{label} – insert reference to table created with \tabelka macro.
  • \rysunek{label}{description}{input_file_path} – inserts image into text. there is a samilly of \rysunek functions allowing to insert images of predefined scales: \rysunekSmall, \rysunekNormal and \rysunekBig. by default small/normal/big is defined in terms of procentage of page width. there is also possibility to use page height for this: \rysunekSmallH, \rysunekNormalH and \rynsunekBigH. by default \rysunek*W is called.
  • \rysunekRef{label} – inserts reference to inage with a given label.
  • \rysunekTwoInRow{label}{description}{file1}{file2} – inserts two images horizontally.
  • \wstawSI{value}{units} – inserts values with units. ex: \wstawSI{5}{V} will generate formated text similar to '5[V]'.
  • \wstawAng{txt} – inserts given text marking that it is written in English.
  • \rozdzial{label}{title}{file} – inserts given file as a chapter with given label and title.
  • \rozdzialRef{label} – insert reference to chapter of given label.
  • \sekcja{lable}{title} – begins new section of given name.
  • \sekcjaRef{label} – insert reference to given section.
  • \subSekcja{label}{title} – begins new subsection.
  • \subSekcjaRef{label} – inserts reference to given subsection.
  • \wzorMat{label}{eqn} – inserts equation.
  • \wzorMatTab{label}{eqns} – creates equation array.
  • \wzorRef{label} – references given equation.
  • \degree{} – inserts degree symbol
  • \wstawRok{year} – inserts year into text.


here you can download current version of LaTeX template. this is 0.5.1 version.

current version notes

release notes for different versions.


  • updated link to project's page.


  • added new license: revised BSD.
  • default encoding is not UTF-8.
  • removed unnecessary declarations.
  • compatible with texlive (default for Debian etch).
prjs/latex_template/latex_template.txt · Last modified: 2021/06/15 20:09 by
Back to top
Valid CSS Driven by DokuWiki Recent changes RSS feed Valid XHTML 1.0