Newer
Older
LaTeX / lectures / lectureassignment.cls
Nigel Stanger on 12 Sep 2016 1 KB Merge commit '01b673a' as 'lectures'
  1. \def\filedate{28 January 2014}
  2. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  3. %
  4. % Document class for lecture/lab worksheets (particularly for fourth year).
  5. %
  6. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  7. %
  8. % Version History
  9. % v1.0 Initial version.
  10. %
  11. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  12.  
  13. \NeedsTeXFormat{LaTeX2e}[2001/06/01]
  14. \ProvidesClass{lectureassignment}%
  15. [2016/03/08 INFO assignment style, v.1.0]
  16.  
  17.  
  18. \LoadClassWithOptions{article}
  19.  
  20.  
  21. % Load required packages.
  22. \RequirePackage{geometry}
  23. \RequirePackage{pifont}
  24. \RequirePackage{parskip} % Space-separated rather than indented paragraphs.
  25. % DO NOT REMOVE THE NEXT LINE! The lecturecommon package loads a bunch
  26. % of other packages and sets up various counters, etc., several of which
  27. % are used below.
  28. \RequirePackage{lecturecommon}
  29.  
  30.  
  31. % Some additional variables.
  32. \newcommand{\AssignmentNumber}{UNDEFINED}
  33. \newcommand{\SetAssignmentNumber}[1]{\renewcommand{\AssignmentNumber}{#1}}
  34.  
  35.  
  36. % Package initialisation.
  37.  
  38. % geometry setup.
  39. \geometry{a4paper,margin={1in,1in}}
  40.  
  41. % hyperref setup. We can't execute this immediately, because the
  42. % macros referenced here haven't been set yet. All paper and chapter
  43. % variables (where applicable) must therefore be initialised in the
  44. % document preamble.
  45. \AtBeginDocument{%
  46. \hypersetup{%
  47. pdftitle={\PaperCode\ Assignment \AssignmentNumber},%
  48. pdfsubject={\PaperTitle},%
  49. pdfauthor={Information Science, University of Otago},%
  50. }%
  51. }
  52.  
  53.  
  54. \endinput