File tree 6 files changed +62
-47
lines changed
6 files changed +62
-47
lines changed Original file line number Diff line number Diff line change 1
1
xelatex --shell-escape report.tex
2
- bibtex report.aux
3
2
xelatex --shell-escape report.tex
3
+ bibtex report.aux
4
4
xelatex --shell-escape report.tex
5
5
xelatex --shell-escape report.tex
Original file line number Diff line number Diff line change @@ -16,57 +16,24 @@ \subsection{C-Sharp Code Block}
16
16
}
17
17
}
18
18
\end {minted }
19
- \caption {C-Sharp Code Block}
20
- \label {fig:CSharpCodeBlock }
19
+ \macFC {CSharp Code Block}{cscb}
21
20
\end {figure }
22
21
22
+
23
23
\subsection {Python Code Block }
24
24
25
25
You can print to the python standard output using the \mintinline {python}|print| keyword.
26
26
27
- \begin {figure }[ht]
28
- \centering
29
- \ begin{lstlisting} [language=python]
30
- : print("Hello World!, this is listings instead of minted")
31
- \end {lstlisting }
32
- \caption {Python Code Block}
33
- \label {fig:PythonCodeBlock }
34
- \end {figure }
35
-
36
-
37
- \begin {figure }[ht]
38
- \centering
39
- \begin {Verbatim }
40
- print("this is as-is")
41
- \end {Verbatim }
42
- \caption {Mother Mother}
43
- \label {fig:berbatim }
44
- \end {figure }
45
-
46
27
\newpage
47
28
48
29
49
30
\section {Maths }
50
31
51
- \begin {figure }[ht]
52
- \centering
53
- \begin {math }
54
- E=mc^2
55
- \end {math }
56
- \caption {Einstein Formula}
57
- \label {fig:Emc2 }
58
-
59
- \end {figure }
60
-
61
- \begin {figure }[ht]
62
- \centering
63
- \begin {math }
64
- \frac {1}{2}
65
- \end {math }
66
- \caption {Fraction}
67
- \label {fig:Fraction-1 }
68
-
69
- \end {figure }
32
+ \macMath {
33
+ E = mc^2
34
+ }
35
+ {Einstein Formula}
36
+ {emc2}
70
37
71
38
\subsection {this is a subsection }
72
39
@@ -77,7 +44,7 @@ \subsection{another subection with a table in it}
77
44
78
45
\begin {table }[h!]
79
46
\centering
80
- \begin {tabular }{||c c c c||}
47
+ \begin {tabular }{||c|c|c| c||}
81
48
\hline
82
49
Col1 & Col2 & Col2 & Col3 \\ [0.5ex]
83
50
\hline\hline
@@ -88,8 +55,7 @@ \subsection{another subection with a table in it}
88
55
5 & 88 & 788 & 6344 \\ [1ex]
89
56
\hline
90
57
\end {tabular }
91
- \caption {Table to test captions and labels.}
92
- \label {table:1 }
58
+ \macFC {Table to test captions and labels.}{table:example}
93
59
\end {table }
94
60
95
61
\newpage
Original file line number Diff line number Diff line change 1
- \newcommand {\bib }{\bibliographystyle {config/hull}\bibliography {ref.bib}}
1
+ \newcommand {\bib }{
2
+ \bibliographystyle {config/hull}
3
+ \bibliography {ref.bib}
4
+ }
5
+
6
+ \newcommand {\macFC }[2]{
7
+ \caption {#1}
8
+ \label {#2 }
9
+ }
10
+
11
+ \newcommand {\macMath }[3]{
12
+ \begin {figure }[ht]
13
+ \centering
14
+ \begin {math }
15
+ #1
16
+ \end {math }
17
+ \caption {#2}
18
+ \label {fig: #3 }
19
+ \end {figure }
20
+ }
21
+
22
+ % may be borked
23
+ \newcommand {\macCode }[4]{
24
+ \begin {figure }[ht]
25
+ #2
26
+ \macFC {#3}{#4}
27
+ \end {figure }
28
+ }
29
+
30
+ \newcommand {\macImg }[3]{
31
+ \begin {figure }[ht]
32
+ \centering
33
+ \includegraphics [width=\textwidth ]{#1}
34
+ \macFC {#2}{#3}
35
+ \end {figure }
36
+ }
37
+
38
+ \newcommand {\macVerb }[3]{
39
+ \begin {figure }[ht]
40
+ \centering
41
+ \begin {Verbatim }
42
+ #1
43
+ \end {Verbatim }
44
+ \macfc {#2}{#3}
45
+ \end {figure }
46
+ }
Original file line number Diff line number Diff line change 3
3
\Large\bfseries {\reportModNumber : \reportModName }
4
4
}
5
5
\author {
6
- \reportAuthors
6
+ \reportAuthors \\
7
+ }
8
+ \date {
9
+ Word Count: \reportWordCount \\
10
+ \reportDate
7
11
}
8
- \date {\reportDate }
9
12
10
13
\newcommand {\buildtitle }{\maketitle\normalsize }
11
14
\newcommand {\authorNameNo }[2]{#1 \textit {(#2) } \\ }
Original file line number Diff line number Diff line change 5
5
\newcommand {\reportModNumber }{Module\_ Number}
6
6
\newcommand {\reportModName }{Module Name}
7
7
\newcommand {\reportDate }{Date/Due/In}
8
+ \newcommand {\reportWordCount }{XXXX}
8
9
\newcommand {\reportAuthors } {
9
10
\authorNameNo {1st Author}{author no.}
10
11
\authorName {2nd Author}
You can’t perform that action at this time.
0 commit comments