From f0e06b4d117905be7e10f20f233f790fc1289717 Mon Sep 17 00:00:00 2001 From: "taha@asks2" Date: Fri, 4 Sep 2020 21:19:40 +0200 Subject: [PATCH] Confirmed that physical page size is correct when printed Had to require package luatex85 in the Lua thesis.tex file (see notes in README and cls file). Re-organised the README to make it easier to get started. --- LuaUUThesis.cls | 1 + README.md | 57 +++++++++++++++++++++++++++++++++++++++++++------ 2 files changed, 51 insertions(+), 7 deletions(-) diff --git a/LuaUUThesis.cls b/LuaUUThesis.cls index 34b6803..7af5d0c 100644 --- a/LuaUUThesis.cls +++ b/LuaUUThesis.cls @@ -166,6 +166,7 @@ }% % Define page size and tell dvips to use it by entering the \special command +% these two commands require that your document has \RequirePackage{luatex85} *before* the \documentclass line, otherwise you'll get "undefined control sequence" error \UU@papersize \special{papersize=\the\pdfpagewidth,\the\pdfpageheight} diff --git a/README.md b/README.md index 390cb9c..ff45148 100644 --- a/README.md +++ b/README.md @@ -1,23 +1,65 @@ +## How to use this LaTeX class + Clone this repo into your `TEXMF_LOCAL` directory (I suggest `/usr/local/texlive/texmf-local/tex/latex/local`). -Refresh your `texhash` or similar, and then you should be able to load the following packages: ``` -\usepackage{uuprintcolorscmyk} -\usepackage{uuprintcolorsrgb} +$ cd /usr/local/texlive/texmf-local/tex/latex +$ git clone https://git.solarchemist.se/config/texmf-latex.git local ``` -(note that these sty files depend on `xcolor`, so make sure to add `\usepackage{xcolor}` too) -and the following classes: +You may have to refresh your `texhash` or similar, and then you should be set. + + +## The LuaLaTeX UU thesis class + +This is my own rewrite of [the official (but unsupported) XeLaTeX class for PhD thesis at Uppsala university](https://libguides.ub.uu.se/avhandling/latex). + +To use it, start your main tex file with: + ``` +\RequirePackage{luatex85} \documentclass{LuaUUThesis} +[... the rest of your document ...] +``` + +You will have to compile your document using `lualatex`, like this: +``` +$ lualatex thesis.tex +``` + +But you probably use a nice makefile or something for that :-) + + +## The XeLaTeX UU thesis class + +I have made some slight alterations to this class compared to the original UU class. Use it like this: + +``` \documentclass{UUThesisTemplate} ``` -`LuaUUThesis` is based on the `UUThesisTemplate` but uses LuaLaTeX instead of XeLaTeX. +Compile your document with `xelatex`. + + +## UU colour profiles (CMYK and RGB) The CMYK and RGB colour definitions are entirely based on the [Uppsala university graphical -profile](https://mp.uu.se/web/info/stod/kommunikation-riktlinjer/grafiskariktl) from around 2014. +profile](https://mp.uu.se/web/info/stod/kommunikation-riktlinjer/grafiskariktl) from around 2014. They are probably outdated now. + +They simply use `xcolor` commands to define a bunch of colour names. +If you want to use any of these colour names in your document, load the package in your document preamble (choose CMYK or RGB colourspace depending on how your document will be printed). + +``` +\usepackage{xcolor} +\usepackage{uuprintcolorscmyk} +\usepackage{uuprintcolorsrgb} +``` + +Please note that both `uuprintcolor*` packages depend on the `xcolor` package. + + +## Notes and references > Note to self: your [Ansible luxor playbook](https://git.chepec.se/ansible/luxor) depends on this repo. > This repo lives on luxor at `/usr/local/texlive/texmf-local/tex/latex/local/`. @@ -28,4 +70,5 @@ path](http://matsguru.com/latex-hack-adding-a-custom-cls-to-your-search-path/) + [How to have a local package override default package](https://tex.stackexchange.com/questions/8357/how-to-have-local-package-override-default-package/8359#8359) + [How do I add a .sty file to my MacTeX/TeXShop installation?](https://tex.stackexchange.com/questions/10252/how-do-i-add-a-sty-file-to-my-mactex-texshop-installation) ++ [Undefined control sequence error for LuaLaTeX, TeX.SE](https://tex.stackexchange.com/questions/315025/lualatex-texlive-2016-standalone-undefined-control-sequence) + [Avhandlingsstöd Uppsala universitet, XeLaTeX mall](https://libguides.ub.uu.se/avhandling/latex)