texlive[47224] Master: handin (2apr18)

commits+karl at tug.org commits+karl at tug.org
Mon Apr 2 00:21:25 CEST 2018


Revision: 47224
          http://tug.org/svn/texlive?view=revision&revision=47224
Author:   karl
Date:     2018-04-02 00:21:24 +0200 (Mon, 02 Apr 2018)
Log Message:
-----------
handin (2apr18)

Modified Paths:
--------------
    trunk/Master/tlpkg/bin/tlpkg-ctan-check
    trunk/Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc

Added Paths:
-----------
    trunk/Master/texmf-dist/doc/latex/handin/
    trunk/Master/texmf-dist/doc/latex/handin/README.txt
    trunk/Master/texmf-dist/doc/latex/handin/example.pdf
    trunk/Master/texmf-dist/doc/latex/handin/example.tex
    trunk/Master/texmf-dist/doc/latex/handin/handin-doc.pdf
    trunk/Master/texmf-dist/doc/latex/handin/handin-doc.tex
    trunk/Master/texmf-dist/doc/latex/handin/layout.pdf
    trunk/Master/texmf-dist/doc/latex/handin/universityTromsoLogo.pdf
    trunk/Master/texmf-dist/tex/latex/handin/
    trunk/Master/texmf-dist/tex/latex/handin/handin.sty
    trunk/Master/tlpkg/tlpsrc/handin.tlpsrc

Added: trunk/Master/texmf-dist/doc/latex/handin/README.txt
===================================================================
--- trunk/Master/texmf-dist/doc/latex/handin/README.txt	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/handin/README.txt	2018-04-01 22:21:24 UTC (rev 47224)
@@ -0,0 +1,33 @@
+Handin:
+Light weight template for creating school submissions using LaTeX. Especially suitable for math, physics, statistics and the like.
+
+Files:
+- handin.sty : The handin package
+- handin-doc.pdf : Description of how the package works
+- handin-doc.tex : Source of handin-doc.tex
+- layout.pdf : Contains an overview on which macro goes where in the new \maketitle
+- example.pdf : Output of example.tex
+- example.tex : Contains example code
+- universityTromsoLogo.pdf : An image to be used in the example
+
+Author: Storvik Strauman, Andreas
+
+For bug report, inquires, contributed or anything else:
+https://github.com/Strauman/Handin-LaTeX-template/
+
+Licence:
+
+The LaTeX package handin - version v0.0.2 (2018/04/01) build 30
+handin.sty
+-------------------------------------------------------------------------------------------
+Copyright (c) 2018 by Andreas Storvik Strauman
+-------------------------------------------------------------------------------------------
+This work may be distributed and/or modified under the
+conditions of the LaTeX Project Public License, either version 1.3c
+of this license or (at your option) any later version.
+The latest version of this license is in
+  http://www.latex-project.org/lppl.txt
+and version 1.3c or later is part of all distributions of LaTeX
+version 2008/05/04 or later.
+This work has the LPPL maintenance status `author-maintained'.
+This work consists of all files listed in README


Property changes on: trunk/Master/texmf-dist/doc/latex/handin/README.txt
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/handin/example.pdf
===================================================================
(Binary files differ)

Index: trunk/Master/texmf-dist/doc/latex/handin/example.pdf
===================================================================
--- trunk/Master/texmf-dist/doc/latex/handin/example.pdf	2018-04-01 22:20:15 UTC (rev 47223)
+++ trunk/Master/texmf-dist/doc/latex/handin/example.pdf	2018-04-01 22:21:24 UTC (rev 47224)

Property changes on: trunk/Master/texmf-dist/doc/latex/handin/example.pdf
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/pdf
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/handin/example.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/handin/example.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/handin/example.tex	2018-04-01 22:21:24 UTC (rev 47224)
@@ -0,0 +1,22 @@
+\documentclass{article}
+\usepackage[english]{babel}
+% ^ Supports [english] and [norsk] (norwegian)
+\usepackage{handin}
+
+\title{Assignment 1}
+\author{The name}
+\coursename{TST-101}
+\coursetitle{Test course}
+\institute{Institute of Physics and Technology}
+\logo{universityTromsoLogo}
+%Values below are optional and defaults as given:
+\pagetext{Page \thepage~of \pageref{LastPage}}
+\containspages{Contains \pageref{LastPage} pages, front page included}
+
+\begin{document}
+  \maketitle
+  \problem{1}
+  \pproblem{a}
+  Gauss law tells us that
+  \[ \oiint\limits_{S}\vec E\cdot \mathrm{d}\vec{S}=\frac{Q_{\text{enc}}}{\varepsilon_0} \]
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/handin/example.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/handin/handin-doc.pdf
===================================================================
(Binary files differ)

Index: trunk/Master/texmf-dist/doc/latex/handin/handin-doc.pdf
===================================================================
--- trunk/Master/texmf-dist/doc/latex/handin/handin-doc.pdf	2018-04-01 22:20:15 UTC (rev 47223)
+++ trunk/Master/texmf-dist/doc/latex/handin/handin-doc.pdf	2018-04-01 22:21:24 UTC (rev 47224)

Property changes on: trunk/Master/texmf-dist/doc/latex/handin/handin-doc.pdf
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/pdf
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/handin/handin-doc.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/handin/handin-doc.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/handin/handin-doc.tex	2018-04-01 22:21:24 UTC (rev 47224)
@@ -0,0 +1,150 @@
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% This is a generated file %
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+\documentclass{article}
+\usepackage[all]{tcolorbox}
+\makeatletter
+\lstdefinestyle{mydocumentation}{style=tcbdocumentation,
+  classoffset=0,
+  texcsstyle=*\color{blue},
+  moretexcs={arrayrulecolor,draw,includegraphics,ifthenelse,isodd,lipsum,path,pgfkeysalso},
+  classoffset=1,
+  moretexcs={% core
+    problem,pproblem,title,author,logo,coursename,coursetitle,institute,containspages,pagetext,settable
+  },
+  texcsstyle=*\color{Definition}\bfseries,
+  classoffset=0,% restore default
+  }
+\newtcolorbox{marker}[1][]{enhanced,
+    before skip=2mm,after skip=3mm,
+    boxrule=0.4pt,left=5mm,right=2mm,top=1mm,bottom=1mm,
+    colback=yellow!50,
+    colframe=yellow!20!black,
+    sharp corners,rounded corners=southeast,arc is angular,arc=3mm,
+    underlay={%
+      \path[fill=tcbcol at back!80!black] ([yshift=3mm]interior.south east)--++(-0.4,-0.1)--++(0.1,-0.2);
+      \path[draw=tcbcol at frame,shorten <=-0.05mm,shorten >=-0.05mm] ([yshift=3mm]interior.south east)--++(-0.4,-0.1)--++(0.1,-0.2);
+      \path[fill=yellow!50!black,draw=none] (interior.south west) rectangle node[white]{\Huge\bfseries !} ([xshift=4mm]interior.north west);
+      },
+    drop fuzzy shadow,#1}
+  \makeatother
+\let\dac\docAuxCommand
+\tcbset{documentation listing style=mydocumentation}
+
+\setlength{\parindent}{0pt}
+\title{{Handin - manual\\ v0.0.2{\\[-0.5em]\footnotesize(build 30)}}}
+\author{Andreas Strauman}
+\begin{document}
+\maketitle
+\section*{2 Problem}
+I remember when I first started out with LaTeX, as a student, it was very new and challenging just to make a simple nicely typeset document. We've all seen documents that has problem numbering using sections, like I did here. (The header says \textbf{2 Problem}.)\\
+
+This is a package that makes it easy for student to hand in a formatted document in LaTeX. It just creates a couple of commands that typesets the document with nice headers (problem numbers and part problem numbers e.g. \textbf{(1a)} ).\\
+
+If you are a teacher, this package works just as well for creating exercises!\\
+ 
+If you found any bugs or want new functionality, to contribute, view the commented source, get latest version of this package or get in touch with me, you can do all of that at \url{https://github.com/Strauman/Handin-LaTeX-template/}
+\tableofcontents
+\clearpage
+ \section{Reference}
+\subsection{Making exercises}
+ Here are commands related to creating exercises
+
+
+\begin{docCommand}[]{problem}{\marg{text}}
+ This command will print out a problem header. For example \dac{problem}\{1\}
+ prints a nice big header \textbf{Problem 1} You can do a star (*) after \dac{problem} to
+ prevent it from showing in the table of contents
+
+\end{docCommand}
+
+\begin{docCommand}[]{problem*}{\marg{text}}
+ Does the same as \dac{problem}, but does not add the problem to the table of contents
+
+\end{docCommand}
+
+\begin{docCommand}[]{pproblem}{\marg{text}}
+ This command will print out a part problem header based on what problem you are on.
+ For example if you already have done \dac{problem}\{1\}, then \dac{pproblem}\{a\}
+ prints a nice big header \textbf{(1a)}. You can do a star (*) after \dac{pproblem} to
+ prevent it from showing in the table of contents
+
+\end{docCommand}
+
+\begin{docCommand}[]{pproblem*}{\marg{text}}
+ Does the same as \dac{pproblem}, but does not add the part problem to the table of contents
+
+\end{docCommand}
+
+\subsection{Page formatting commands}
+\begin{docCommand}[]{title}{\marg{title}}
+
+\end{docCommand}
+
+\begin{docCommand}[]{author}{\marg{your name}}
+
+\end{docCommand}
+
+\begin{docCommand}[]{logo}{\marg{path/to/image}}
+ If you want an image below the title, you provide the path to the image here
+
+\end{docCommand}
+
+\begin{docCommand}[]{coursename}{\marg{text}}
+
+\end{docCommand}
+
+\begin{docCommand}[]{coursetitle}{\marg{text}}
+ The front page will show coursename - coursetitle on a "subtitle" format
+
+\end{docCommand}
+
+\begin{docCommand}[]{institute}{\marg{text}}
+ Shows as text on bottom
+
+\end{docCommand}
+
+\begin{docCommand}[]{containspages}{\marg{text}}
+   Here you can set a string that shows on bottom. Default is\\
+   \dac{containspages}\{Contains \dac{pageref}\brackets{LastPage\} pages, front page included}
+
+\end{docCommand}
+
+\begin{docCommand}[]{pagetext}{\marg{string}}
+ This is the text that is on the bottom right corner reading "Page x of y". Default is
+ \dac{pagetext}\{Page \dac{thepage}~of \dac{pageref}{LastPage\}}
+
+\end{docCommand}
+
+\subsection{Languages}
+This package supports norwegian and english. Translations are welcome at \dac{url}\{https://github.com/Strauman/Handin-LaTeX-template/tree/master/src/languages\}. that are set by the \!\dac{texttt}\{iflang\} package.
+
+
+
+\subsection{General reference}
+\begin{docCommand}[]{settable}{\marg{text}}
+ The text you enter would be a macro. See example:
+
+\end{docCommand}
+
+\begin{dispListing}
+ \settable{hello}
+ %if now \@hello is called,
+ % a warning is displayed with
+ % the text "\hello not set"
+ \hello{world}
+ % if now \@hello is called, it prints "world"
+ \@hello at noerror gives the returning
+ content and empty without error if no content set.
+ \ifset at hello{true}{false}
+
+\end{dispListing}
+
+
+\section{Changelog}
+% Use , 2018/04/01
+\begin{tabular}{lll}
+  Version&Date&Changes\\
+  v0.0.2&2018/04/01&Problems are now added to the table of contents by default
+\end{tabular}
+ \end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/handin/handin-doc.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/handin/layout.pdf
===================================================================
(Binary files differ)

Index: trunk/Master/texmf-dist/doc/latex/handin/layout.pdf
===================================================================
--- trunk/Master/texmf-dist/doc/latex/handin/layout.pdf	2018-04-01 22:20:15 UTC (rev 47223)
+++ trunk/Master/texmf-dist/doc/latex/handin/layout.pdf	2018-04-01 22:21:24 UTC (rev 47224)

Property changes on: trunk/Master/texmf-dist/doc/latex/handin/layout.pdf
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/pdf
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/handin/universityTromsoLogo.pdf
===================================================================
(Binary files differ)

Index: trunk/Master/texmf-dist/doc/latex/handin/universityTromsoLogo.pdf
===================================================================
--- trunk/Master/texmf-dist/doc/latex/handin/universityTromsoLogo.pdf	2018-04-01 22:20:15 UTC (rev 47223)
+++ trunk/Master/texmf-dist/doc/latex/handin/universityTromsoLogo.pdf	2018-04-01 22:21:24 UTC (rev 47224)

Property changes on: trunk/Master/texmf-dist/doc/latex/handin/universityTromsoLogo.pdf
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/pdf
\ No newline at end of property
Added: trunk/Master/texmf-dist/tex/latex/handin/handin.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/handin/handin.sty	                        (rev 0)
+++ trunk/Master/texmf-dist/tex/latex/handin/handin.sty	2018-04-01 22:21:24 UTC (rev 47224)
@@ -0,0 +1,132 @@
+% handin v0.0.2b30 - 2018/04/01
+\ProvidesPackage{handin}[2018/04/01 v0.0.2 Creates a setup that is ideal for handing in hard-science school papers that are divided in exercises.]
+\usepackage[utf8]{inputenc}
+\usepackage{graphicx}
+\usepackage{lastpage}
+\usepackage{scrextend}
+\def\exerciseNr{0}
+\gdef\problem{\@ifnextchar*{\expandafter\@problem\@secondoftwo}{\@problemTOC}}
+\gdef\@problemTOC#1{  \addcontentsline{toc}{section}{\@tr{Problem} #1}
+  \@problem{#1}
+}
+\newcommand{\@problem}[1]{  \def\exerciseNr{#1}
+  \begin{addmargin}{-1.5em}
+    {\normalfont\Large\bfseries \@tr{Problem} #1}
+  \end{addmargin}
+}
+\gdef\pproblem{\@ifnextchar*{\expandafter\@pproblem\@secondoftwo}{\@pproblemTOC}}
+\gdef\@pproblemTOC#1{  \addcontentsline{toc}{subsection}{\exerciseNr #1}
+  \@pproblem{#1}
+}
+\newcommand{\@pproblem}[1]{  \vspace*{1em}
+  \hspace*{-0.5em}{\normalfont\Large\bfseries\exerciseNr #1)}
+}
+ \usepackage{fancyhdr}
+\usepackage{geometry}
+\usepackage{amsmath}
+\usepackage{mathtools}
+\usepackage{bm}
+\usepackage{esint}
+\usepackage{iflang}
+\def\@tr#1{  \ifcsname tr@#1\endcsname%
+    \csname tr@#1\endcsname%
+  \else%
+    #1%
+  \fi%
+}
+\newcommand{\set at tr}[2]{  \expandafter\def\csname tr@#1\endcsname{#2}
+}
+\set at tr{Problem}{Problem}
+\set at tr{problem}{problem}
+\set at tr{containspages}{Contains \pageref{LastPage} pages, front page included}
+\set at tr{pagetext}{Page \thepage~of \pageref{LastPage}}
+ \IfLanguageName{norsk}{%
+\set at tr{Problem}{Oppgave}
+\set at tr{problem}{oppgave}
+\set at tr{pagetext}{Side \thepage~av \pageref{LastPage}}
+\set at tr{containspages}{Inneholder \pageref{LastPage} sider, inkludert forside.}
+}{}
+ \newif\ifshowoff
+\showofffalse
+\let\ea = \expandafter
+\newcommand{\settable}[2][\@nil]{  \ea\def\csname #2\ea\endcsname##1{    \ea\def\csname @#2\endcsname{##1}
+    \ea\def\csname @#2 at noerror\endcsname{##1}
+    \ea\def\csname isset@#2\endcsname{1}
+}
+  \ea\def\csname ifset@#2\endcsname##1##2{    \ifcsname isset@#2\endcsname%
+    ##1
+    \else
+    ##2
+    \fi
+}
+  \ea\def\csname default@#2\endcsname{#1}%
+  \ea\def\csname @#2 at noerror\endcsname{#1}%
+  \ea\ifx\csname default@#2\endcsname\@nnil
+    \ea\def\csname default@#2\endcsname{      \textbackslash #2%
+      {\ea\@latex at warning{\ #2 not given}}
+}
+  \fi
+  \ea\def\csname @#2\endcsname{    \csname default@#2\endcsname
+}
+}
+\ifshowoff
+\@latex at warning{Settable: showing off, no settable is actually set!}
+\renewcommand{\settable}[2][\@nil]{  \ea\def\csname #2\endcsname##1{\relax}%
+  \ea\def\csname @#2\endcsname{}%
+  \ea\def\csname @#2 at noerror\endcsname{}%
+  \ea\def\csname ifset@#2\endcsname##1##2{##2}
+  \ea\def\csname default@#2\endcsname{#1}%
+  \ea\def\csname @#2 at noerror\endcsname{#1}%
+  \ea\def\csname @#2\endcsname{\textbackslash #2}
+}
+\fi
+\settable{title}
+\settable{author}
+\settable{logo}
+\settable{coursename}
+\settable{coursetitle}
+\settable{institute}
+\settable{containspages}
+\settable{pagetext}
+\setlength\parindent{0pt}
+\geometry{paper=a4paper, bottom=3cm, top=3cm, footnotesep=3cm}
+\fancyhf{}
+\addtolength\headwidth{4em}
+\fancyheadoffset{2em}
+\pagestyle{fancy}
+\let\old at maketitle = \maketitle
+\def\maketitle{	\old at maketitle
+	\thispagestyle{empty}
+	\clearpage
+}
+\def\@maketitle{%
+\begin{center}
+  \ifshowoff
+    \Huge{\textbackslash logo}\\
+    \Large{\@title} \\[1.5cm]
+  \else
+  \ifset at logo{    \includegraphics[scale=1]{\@logo}\\[0.5cm]
+    \Large{\@title} \\[1.5cm]
+}{    \ea\@latex at warning{Use \noexpand\logo{path/to/image} to set a logo on the front page}
+    \Huge{\@title} \\[1.0cm]
+}
+  \fi
+\end{center}
+\begin{center}
+  \textbf{\@coursename - \@coursetitle}\\[1cm]
+  \textbf{\@author} \\[1cm]
+  \textbf{\today} \\[3cm]
+\end{center}
+\begin{center}
+  \vfill
+  \ifset at containspages{    \@containspages
+}{    \@tr{containspages}
+}\\[0.5cm]
+  \textsc{\@institute}
+\end{center}
+ 	\rhead{\@author}
+	\lhead{\@coursename - \@coursetitle}
+	\ifset at pagetext{		\rfoot{\@pagetext}
+}{		\rfoot{\@tr{pagetext}}
+}
+}


Property changes on: trunk/Master/texmf-dist/tex/latex/handin/handin.sty
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Modified: trunk/Master/tlpkg/bin/tlpkg-ctan-check
===================================================================
--- trunk/Master/tlpkg/bin/tlpkg-ctan-check	2018-04-01 22:20:15 UTC (rev 47223)
+++ trunk/Master/tlpkg/bin/tlpkg-ctan-check	2018-04-01 22:21:24 UTC (rev 47224)
@@ -319,7 +319,7 @@
     gsemthesis gtl gtrlib-largetrees gtrcrd
     gu guitar guitarchordschemes guitlogo gzt
   h2020proposal hackthefootline hacm hagenberg-thesis halloweenmath
-    handout hands hang hanging hanoi
+    handin handout hands hang hanging hanoi
     happy4th har2nat hardwrap harmony harnon-cv harpoon
     harvard harveyballs harvmac hatching hausarbeit-jura havannah
     hc he-she hecthese hep hepnames

Modified: trunk/Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc
===================================================================
--- trunk/Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc	2018-04-01 22:20:15 UTC (rev 47223)
+++ trunk/Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc	2018-04-01 22:21:24 UTC (rev 47224)
@@ -511,6 +511,7 @@
 depend guitlogo
 depend halloweenmath
 depend hackthefootline
+depend handin
 depend handout
 depend hang
 depend hanging

Added: trunk/Master/tlpkg/tlpsrc/handin.tlpsrc
===================================================================


More information about the tex-live-commits mailing list