packages for template format nicely
This commit is contained in:
21
code.tex
21
code.tex
@@ -16,27 +16,6 @@ go read the documentation and set these up as below. You
|
|||||||
will save yourself a lot of effort, especially if you have to fix
|
will save yourself a lot of effort, especially if you have to fix
|
||||||
anything.
|
anything.
|
||||||
|
|
||||||
%% This default style make long lines wrap nicely
|
|
||||||
\lstdefinestyle{default}{
|
|
||||||
%basicstyle=\footnotesize\ttfamily,%
|
|
||||||
numbers=left,%
|
|
||||||
numberstyle=\tiny,%
|
|
||||||
numberfirstline=true,%
|
|
||||||
stepnumber=2,%
|
|
||||||
numbersep=5pt,%
|
|
||||||
columns=fullflexible,%
|
|
||||||
tabsize=4,%
|
|
||||||
frame=lines,%
|
|
||||||
breaklines=true,% break long lines
|
|
||||||
prebreak=\raisebox{0ex}[0ex][0ex]{\ensuremath{\color{red}\hookleftarrow}}, % red arrow
|
|
||||||
postbreak=\raisebox{0ex}[0ex][0ex]{\ensuremath{\color{red}\hookrightarrow}}, % red arrow
|
|
||||||
% from http://tex.stackexchange.com/questions/116534/lstlisting-line-wrapping
|
|
||||||
}
|
|
||||||
\lstset{%
|
|
||||||
language=,%default similar to verbatim
|
|
||||||
style=default,
|
|
||||||
}
|
|
||||||
|
|
||||||
%% The pre-defined languages we want to use.
|
%% The pre-defined languages we want to use.
|
||||||
\lstloadlanguages{Java, XML}
|
\lstloadlanguages{Java, XML}
|
||||||
|
|
||||||
|
|||||||
28
custom.sty
28
custom.sty
@@ -8,6 +8,28 @@
|
|||||||
%%% Formatting code inclusion and snippets
|
%%% Formatting code inclusion and snippets
|
||||||
%% "final" option to force it to display code
|
%% "final" option to force it to display code
|
||||||
|
|
||||||
|
%% This default listings style make long lines wrap nicely
|
||||||
|
\lstdefinestyle{default}{
|
||||||
|
basicstyle=\ttfamily,%
|
||||||
|
numbers=left,%
|
||||||
|
numberstyle=\tiny,%
|
||||||
|
numberfirstline=true,%
|
||||||
|
stepnumber=2,%
|
||||||
|
numbersep=5pt,%
|
||||||
|
columns=fullflexible,%
|
||||||
|
tabsize=4,%
|
||||||
|
frame=lines,%
|
||||||
|
breaklines=true,% break long lines
|
||||||
|
prebreak=\raisebox{0ex}[0ex][0ex]{\ensuremath{\color{red}\hookleftarrow}}, % red arrow
|
||||||
|
postbreak=\raisebox{0ex}[0ex][0ex]{\ensuremath{\color{red}\hookrightarrow}}, % red arrow
|
||||||
|
% from http://tex.stackexchange.com/questions/116534/lstlisting-line-wrapping
|
||||||
|
}
|
||||||
|
\lstset{%
|
||||||
|
language=,%default similar to verbatim
|
||||||
|
style=default,
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
\usepackage{siunitx}
|
\usepackage{siunitx}
|
||||||
%% \SI{9.82}{\meter\per\second\square}
|
%% \SI{9.82}{\meter\per\second\square}
|
||||||
|
|
||||||
@@ -16,3 +38,9 @@
|
|||||||
%% internal layouts: inline, margin, footnote, index, marginclue
|
%% internal layouts: inline, margin, footnote, index, marginclue
|
||||||
%% % Warning! The pdf external layouts do not play well with hyperref
|
%% % Warning! The pdf external layouts do not play well with hyperref
|
||||||
%% % and must be loaded by doing \fxuselayouts{}
|
%% % and must be loaded by doing \fxuselayouts{}
|
||||||
|
|
||||||
|
%%% Local Variables:
|
||||||
|
%%% mode: latex
|
||||||
|
%%% TeX-master: "main"
|
||||||
|
%%% TeX-engine: luatex
|
||||||
|
%%% End:
|
||||||
|
|||||||
@@ -174,45 +174,37 @@ Some information is at the top of \path{main.tex} file, this file is for a gener
|
|||||||
If you think this is unnecessary, just consider how much time you will lose if your computer crashes.
|
If you think this is unnecessary, just consider how much time you will lose if your computer crashes.
|
||||||
Due to Murphy's law, this is likely to happen just before your thesis is due\footnote{This has happened many times.}.
|
Due to Murphy's law, this is likely to happen just before your thesis is due\footnote{This has happened many times.}.
|
||||||
|
|
||||||
\item Get a LaTeX installation. We recommend TeXlive \url{https://www.tug.org/texlive/}
|
\item Get a LaTeX installation.
|
||||||
|
We recommend TeXlive \url{https://www.tug.org/texlive/}
|
||||||
For this template on windows, MiKTeX will also work, but will run very slowly the first time you render the template.
|
For this template on windows, MiKTeX will also work, but will run very slowly the first time you render the template.
|
||||||
|
{\em As of September 2024, both MikTeX and TexLive did not want to install properly on the author's Windows 11 computer.}
|
||||||
You will need to enable the ``miktex'' option in the template to substitute packages.
|
You will need to enable the ``miktex'' option in the template to substitute packages.
|
||||||
It is very very important that you run the ``MikTeX Update Wizard'' before you start.
|
It is very very important that you run the ``MikTeX Update Wizard'' before you start.
|
||||||
Otherwise you may get errors when you try to build the document.
|
Otherwise you may get errors when you try to build the document.
|
||||||
|
|
||||||
Under linux this is the ``texlive'' package.
|
Under Apple iOS and linux this is the TexLive series of packages.
|
||||||
Under Mac/OSX this is the ``MacTeX'' distribution.
|
Linux distributions name the packages differently.
|
||||||
|
The author's recommendations for RedHat distributions such as Redhat Enterprise Linux, Centos, Fedora are in Listing~\ref{code:texlive-redhat}.
|
||||||
|
Debian-based distributions including Ubuntu and PopOS would use the packages in Listing~\ref{code:texlive-debian}.
|
||||||
|
|
||||||
|
\begin{lstlisting}[caption={RedHat Packages},label={code:texlive-redhat}]
|
||||||
|
sudo yum -y install
|
||||||
|
texlive-collection-fontsrecommended
|
||||||
|
texlive-biblatex-{apa,apa-doc,ieee,ieee-doc}
|
||||||
|
texlive-{lipsum,lastpage,luatex,pseudocode,xurl,listings,pgf,tikz,amsfonts,amsmath,amssymb,siunitx,subcaption,fixme,biblatex,makeglos,nomencl,ltxkeys,
|
||||||
|
framed,boondox,printlen}
|
||||||
|
\end{lstlisting}
|
||||||
|
\begin{lstlisting}[caption={Debian/Ubuntu Packages},label={code:texlive-debian}]
|
||||||
|
sudo apt-get -y install texlive texlive-luatex texlive-latex-extra texlive-science texlive-generic-extra texlive-lang-european texlive-lang-german latex-xcolor texlive-pictures pgf texlive-bibtex-extra texlive-publishers chktex evince fonts-lmodern lmodern biber
|
||||||
|
\end{lstlisting}
|
||||||
|
|
||||||
Alternatively, if nothing you are doing is particularly private or proprietary, you can do development online using Overleaf.
|
Alternatively, if nothing you are doing is particularly private or proprietary, you can do development online using Overleaf.
|
||||||
In this case, you won't need to setup the rest of the tools mentioned below except perhaps the Reference Manager mentioned in step~\ref{list:refmanager}.
|
In this case, you won't need to setup the rest of the tools mentioned below except perhaps the Reference Manager mentioned in step~\ref{list:refmanager}.
|
||||||
\begin{description}
|
|
||||||
\item[RedHat]
|
|
||||||
\begin{lstlisting}
|
|
||||||
sudo yum -y install
|
|
||||||
texlive-collection-fontsrecommended
|
|
||||||
texlive-biblatex-{apa,apa-doc,ieee,ieee-doc}
|
|
||||||
texlive-{xargs,lipsum,lastpage,luatex,pseudocode,url,examplep,
|
|
||||||
listings,xspace,pgf,tikz,amsfonts,amsmath,amssymb,siunitx,svn-multi,
|
|
||||||
subfig,fixme,textpos,biblatex,makeglos,nomencl,xwatermark,ltxkeys,
|
|
||||||
framed,boondox,printlen}
|
|
||||||
\end{lstlisting}
|
|
||||||
\item[Debian/Ubuntu]
|
|
||||||
\end{description}
|
|
||||||
\begin{lstlisting}
|
|
||||||
sudo apt-get -y install texlive texlive-luatex texlive-latex-extra
|
|
||||||
texlive-science texlive-generic-extra texlive-lang-european
|
|
||||||
texlive-lang-german latex-xcolor texlive-pictures pgf
|
|
||||||
texlive-bibtex-extra texlive-publishers chktex evince
|
|
||||||
fonts-lmodern lmodern biber
|
|
||||||
\end{lstlisting}
|
|
||||||
\begin{enumerate}
|
|
||||||
\item Debian/Ubuntu:
|
|
||||||
\end{enumerate}
|
|
||||||
\item Get a LaTeX Integrated Development Environment (recommended, but not required)
|
\item Get a LaTeX Integrated Development Environment (recommended, but not required)
|
||||||
\url{http://texstudio.sourceforge.net/} or
|
Many people like TeXStudio \url{http://texstudio.sourceforge.net/}.
|
||||||
Some editors may include LaTeX support.
|
Some other code editors and IDEs may include LaTeX support.
|
||||||
If you want to learn a very powerful (but old-fashioned) editor \url{http://www.gnu.org/software/emacs/}
|
If you want to learn a very powerful (but old-fashioned) editor, consider GNU Emacs: \url{http://www.gnu.org/software/emacs/}.
|
||||||
Install the auctex package by: M-x list-packages, click on AUCTeX
|
Of note, the author used Emacs to write this template.
|
||||||
|
|
||||||
\item Get a references manager (recommended, but not required)\label{list:refmanager}
|
\item Get a references manager (recommended, but not required)\label{list:refmanager}
|
||||||
\url{http://jabref.sourceforge.net/} (You may have to install a Java JRE first.)
|
\url{http://jabref.sourceforge.net/} (You may have to install a Java JRE first.)
|
||||||
@@ -225,14 +217,13 @@ framed,boondox,printlen}
|
|||||||
\url{http://www.activestate.com/activeperl}
|
\url{http://www.activestate.com/activeperl}
|
||||||
|
|
||||||
\item Get supporting programs for some tools.
|
\item Get supporting programs for some tools.
|
||||||
For glossaries under windows, you will need to install Perl
|
For glossaries under Windows, you will need to install Perl
|
||||||
\url{http://strawberryperl.com/}
|
\url{http://strawberryperl.com/}
|
||||||
(it is already installed on the other platforms.)
|
(it is already installed on the other platforms.)
|
||||||
|
|
||||||
\item Try building the \path{main.tex} file. If you get errors, there
|
\item Try building the \path{main.tex} file with lualatex. If you get errors, there
|
||||||
is something wrong with your LaTeX installation. Fix those first.
|
is something wrong with your LaTeX installation. Fix those first.
|
||||||
|
|
||||||
|
|
||||||
\item Rename the \path{main.tex} file with your information (optional).
|
\item Rename the \path{main.tex} file with your information (optional).
|
||||||
DEGREE-NAME-YEAR is the recommended scheme
|
DEGREE-NAME-YEAR is the recommended scheme
|
||||||
e.g. \path{msc-foley-2025.tex}.
|
e.g. \path{msc-foley-2025.tex}.
|
||||||
@@ -246,19 +237,17 @@ framed,boondox,printlen}
|
|||||||
|
|
||||||
\item Start editing all of the \path{.tex} files with your content.
|
\item Start editing all of the \path{.tex} files with your content.
|
||||||
|
|
||||||
\item Compile the document by running lualatex on the Main file, run the bibliography tool, then view the result.
|
\item Compile the document by running lualatex on the Main file, run \path{biber}, then view the result.
|
||||||
|
|
||||||
\item When you print, make sure that the scale is 100\%.
|
\item When you print, make sure that the scale is 100\%.
|
||||||
If you allow it to resize when printing, the margins won't be right.
|
If you allow it to resize when printing, the margins won't be right.
|
||||||
If the margins aren't right, then the RU logo will not look right on the
|
|
||||||
cover.
|
|
||||||
|
|
||||||
\end{enumerate}
|
\end{enumerate}
|
||||||
|
|
||||||
\subsection{Important Details}
|
\subsection{Important Details}
|
||||||
|
|
||||||
\begin{itemize}
|
\begin{itemize}
|
||||||
\item Make absolutely sure that your \path{references.bib} is in UTF-8. If it is another format (CP1251,etc) you may get weird problems with any accented characters.
|
\item Make absolutely sure that your \path{references.bib} is in UTF-8. If it is another format (CP1251, EBDIC) you may get weird problems with any accented characters.
|
||||||
{\em Students have run into encoding issues in the past and it has taken a surprisingly long time to debug.}
|
{\em Students have run into encoding issues in the past and it has taken a surprisingly long time to debug.}
|
||||||
\item Make sure the rest of the files, particularly the \path{.tex} file are in UTF8 or are at least in the same encoding.
|
\item Make sure the rest of the files, particularly the \path{.tex} file are in UTF8 or are at least in the same encoding.
|
||||||
If the files are in different encoding, you will discover errors with accented characters when you try to include them together.
|
If the files are in different encoding, you will discover errors with accented characters when you try to include them together.
|
||||||
@@ -267,7 +256,7 @@ framed,boondox,printlen}
|
|||||||
Icelandic characters may not work properly in your \path{references.bib} file if you use BibTeX.
|
Icelandic characters may not work properly in your \path{references.bib} file if you use BibTeX.
|
||||||
TexMaker and TeXStudio require a configuration change to do this.
|
TexMaker and TeXStudio require a configuration change to do this.
|
||||||
\item Be consistent about UPPER and lower case in naming files.
|
\item Be consistent about UPPER and lower case in naming files.
|
||||||
Preferably just use the 26 English letters, 10 numbers, and ``-'' to avoid filename issues.
|
Preferably just use the 26 English letters, 10 numbers, dash ``-'', and underscore ``\_'' to avoid filename issues.
|
||||||
Windows doesn't care (but some programs in Windows do).
|
Windows doesn't care (but some programs in Windows do).
|
||||||
OSX sometimes cares.
|
OSX sometimes cares.
|
||||||
Linux always cares.
|
Linux always cares.
|
||||||
|
|||||||
Reference in New Issue
Block a user