Updated document classes to support 'leden' and 'onderdelen' enumerate types.
This commit is contained in:
parent
a38204b625
commit
4c3ac741fc
|
@ -1,4 +1,4 @@
|
|||
\documentclass{proposal}
|
||||
\documentclass{craftconstitution}
|
||||
\usepackage{enumitem}
|
||||
\usepackage{hyperref}
|
||||
|
||||
|
|
|
@ -1,141 +1,214 @@
|
|||
\NeedsTeXFormat{LaTeX2e}
|
||||
\ProvidesClass{craftconstitution}[CraftLaw Constitution Class for an extra fancy print]
|
||||
\ProvidesClass{proposal}[CraftLaw for the CraftFuze Legal Project, Council Proposal]
|
||||
|
||||
\LoadClass[a4paper,8pt,oneside]{article}
|
||||
\RequirePackage[left=2cm, right=5cm, top=2cm]{geometry}
|
||||
\RequirePackage[left=2cm, right=2cm, top=2cm]{geometry}
|
||||
\RequirePackage[utf8]{inputenc}
|
||||
\RequirePackage[english]{babel}
|
||||
\RequirePackage{blindtext}
|
||||
\RequirePackage{fancyhdr}
|
||||
\RequirePackage{titling}
|
||||
\RequirePackage{fancyhdr}
|
||||
\RequirePackage{tikz}
|
||||
\RequirePackage[shortlabels]{enumitem}
|
||||
\RequirePackage{needspace}
|
||||
\RequirePackage[document]{ragged2e}
|
||||
\RequirePackage{scrextend}
|
||||
|
||||
% Margins
|
||||
%\RequirePackage[inner=5cm,outer=1.5cm,bottom=3cm,marginparsep=6mm]{geometry}
|
||||
%\setlength{\marginparwidth}{2.8cm}
|
||||
%\reversemarginpar
|
||||
|
||||
\let\oldmarginpar\marginpar
|
||||
\renewcommand{\marginpar}[2][rectangle,fill=white,text=black,text width=3cm]{
|
||||
\oldmarginpar{
|
||||
\hspace{50pt}\scriptsize \tikz \node at (0,0) [#1]{\textbf{#2}};}
|
||||
}
|
||||
% AlphAlph
|
||||
\usepackage{enumitem,alphalph}
|
||||
\makeatletter
|
||||
\newcommand{\AlphAlphFmt}[1]{\@alphfmt{#1}} % Define the \alphalph wrapper for enumitem
|
||||
\newcommand{\@alphfmt}[1]{\alphalph{\value{#1}}} % Internal representation
|
||||
\AddEnumerateCounter{\alphalphFmt}{\@alphfmt}{aaa} % Register this new format
|
||||
|
||||
% Indent
|
||||
\setlength{\parindent}{0pt}
|
||||
\setlength{\parskip}{0pt}
|
||||
\newcommand{\articleindent}{\leavevmode{\parindent=3em\indent}}
|
||||
\setlist[enumerate,1]{leftmargin=1.5em,topsep=-1ex,itemsep=-1ex,partopsep=1ex,parsep=1ex,style=sameline}
|
||||
\setlist[enumerate,2]{leftmargin=1.5em,topsep=-1ex,itemsep=-1ex,partopsep=1ex,parsep=1ex,style=sameline}
|
||||
\setenumerate[0]{label=-\arabic*.}
|
||||
\setenumerate[0]{label=\textbf{\arabic*.}}
|
||||
|
||||
% General Data
|
||||
\date{\today}
|
||||
|
||||
\newcommand{\setheader}[1]{}
|
||||
% Header and footer
|
||||
\pagestyle{fancy}
|
||||
\fancyhf{}
|
||||
\fancyfoot[LE,RO]{\thepage}
|
||||
|
||||
% New title layout
|
||||
\newcommand{\settitle}[1]{%
|
||||
\newcommand{\settitle}[1]{\def\@lawtitle{#1}}
|
||||
\newcommand{\setdate}[1]{\def\@date{#1}}
|
||||
|
||||
\newcommand{\generateHeader}{
|
||||
% Header
|
||||
\fancyhead[LE,LO]{\@date}
|
||||
\fancyhead[CE,CO]{Official Journal of the Crafty Table}
|
||||
\fancyhead[RE,RO]{\@lawtitle}
|
||||
|
||||
% Title
|
||||
\noindent%
|
||||
\begin{figure}
|
||||
\centering
|
||||
\includegraphics[width=30mm]{councilseal}
|
||||
\end{figure}
|
||||
\centering%
|
||||
\textbf{\large\fontfamily{phv}\fontseries{b}%
|
||||
\selectfont #1}%
|
||||
\medskip%
|
||||
\fancyhead[RE,LO]{#1}%
|
||||
\selectfont \@lawtitle}%
|
||||
\medskip%
|
||||
}
|
||||
|
||||
|
||||
% Introduction
|
||||
\newcommand{\introduction}[1]{%
|
||||
\bigskip%
|
||||
\vbox{%
|
||||
Preamble:\medskip%
|
||||
|
||||
\noindent{#1}%
|
||||
PREAMBLE\medskip%
|
||||
\begin{flushleft}
|
||||
\noindent{#1}%
|
||||
\end{flushleft}
|
||||
}%
|
||||
}
|
||||
|
||||
% About Articles
|
||||
\newcounter{BookCounter}
|
||||
\newcounter{TitleCounter}[BookCounter]
|
||||
% About legal content
|
||||
\newcounter{TitleCounter}
|
||||
\newcounter{TitleSubCounter}[TitleCounter]
|
||||
\newcounter{ChapterCounter}[TitleCounter]
|
||||
\newcounter{ParagraphCounter}[ChapterCounter]
|
||||
\newcounter{ChapterSubCounter}[ChapterCounter]
|
||||
\newcounter{SectionCounter}[ChapterCounter]
|
||||
\newcounter{SectionSubCounter}[SectionCounter]
|
||||
\newcounter{ParagraphCounter}[SectionCounter]
|
||||
\newcounter{SubParagraphCounter}[ParagraphCounter]
|
||||
\newcounter{ArticleCounter}[BookCounter]
|
||||
\newcounter{ArticleCounter}
|
||||
\newcounter{ArticleSubCounter}[ArticleCounter]
|
||||
\newcommand{\book}[1]{%
|
||||
\newpage%
|
||||
\stepcounter{BookCounter}%
|
||||
\vbox{%
|
||||
\noindent{BOOK \Roman{BookCounter}\newline\textbf{#1}}%
|
||||
}%
|
||||
}
|
||||
\renewcommand{\title}[1]{
|
||||
\renewcommand{\title}[1]{%
|
||||
\begin{addmargin}[0em]{0em}
|
||||
\stepcounter{TitleCounter}%
|
||||
\needspace{25\baselineskip}%
|
||||
|
||||
\begin{flushleft}
|
||||
\textbf{Title \Roman{TitleCounter}}%
|
||||
: \textbf{#1}
|
||||
\end{flushleft}
|
||||
\end{addmargin}
|
||||
\bigskip%
|
||||
\stepcounter{TitleCounter}%
|
||||
\needspace{15\baselineskip}%
|
||||
\vbox{%
|
||||
\noindent{TITLE \Roman{TitleCounter}\newline\textbf{#1}}%
|
||||
}%
|
||||
}
|
||||
\newcommand{\chapter}[1]{%
|
||||
\newcommand{\subtitle}[1]{%
|
||||
\begin{addmargin}[0em]{0em}
|
||||
\stepcounter{TitleSubCounter}%
|
||||
\needspace{25\baselineskip}%
|
||||
|
||||
\begin{flushleft}
|
||||
\textbf{Title \Roman{TitleCounter} \AlphAlph{\value{TitleSubCounter}}}%
|
||||
: \textbf{#1}
|
||||
\end{flushleft}
|
||||
\end{addmargin}
|
||||
\bigskip%
|
||||
}
|
||||
\newcommand{\chapter}[1]{
|
||||
\begin{addmargin}[0em]{0em}
|
||||
\stepcounter{ChapterCounter}%
|
||||
\needspace{20\baselineskip}%
|
||||
|
||||
\begin{flushleft}
|
||||
\textbf{Chapter \Roman{ChapterCounter}}%
|
||||
: \textbf{#1}%
|
||||
\end{flushleft}
|
||||
\end{addmargin}
|
||||
\bigskip%
|
||||
}
|
||||
\newcommand{\subchapter}[1]{
|
||||
\begin{addmargin}[0em]{0em}
|
||||
\stepcounter{ChapterSubCounter}%
|
||||
\needspace{20\baselineskip}%
|
||||
|
||||
\begin{flushleft}
|
||||
\textbf{Chapter \Roman{ChapterCounter} \AlphAlph{\value{ChapterSubCounter}}}%
|
||||
: \textbf{#1}%
|
||||
\end{flushleft}
|
||||
\end{addmargin}
|
||||
\bigskip%
|
||||
}
|
||||
\renewcommand{\section}[1]{%
|
||||
\begin{addmargin}[0em]{0em}
|
||||
\stepcounter{SectionCounter}%
|
||||
\needspace{15\baselineskip}%
|
||||
|
||||
\begin{flushleft}
|
||||
\textbf{Section \Roman{SectionCounter}}%
|
||||
: \textbf{#1}%
|
||||
\end{flushleft}
|
||||
\end{addmargin}
|
||||
\bigskip%
|
||||
}
|
||||
\renewcommand{\subsection}[1]{%
|
||||
\begin{addmargin}[0em]{0em}
|
||||
\stepcounter{SectionSubCounter}%
|
||||
\needspace{15\baselineskip}%
|
||||
|
||||
\begin{flushleft}
|
||||
\textbf{Section \Roman{SectionCounter} \AlphAlph{\value{SectionSubCounter}}}%
|
||||
: \textbf{#1}%
|
||||
\end{flushleft}
|
||||
\end{addmargin}
|
||||
\bigskip%
|
||||
\stepcounter{ChapterCounter}%
|
||||
\needspace{10\baselineskip}%
|
||||
\vbox{%
|
||||
\noindent{CHAPTER \Roman{ChapterCounter}\newline\textbf{#1}}%
|
||||
}%
|
||||
}
|
||||
\renewcommand{\paragraph}[1]{%
|
||||
\begin{addmargin}[0em]{0em}
|
||||
\stepcounter{ParagraphCounter}%
|
||||
\needspace{10\baselineskip}%
|
||||
|
||||
\begin{flushleft}
|
||||
\textbf{Paragraph §\arabic{ParagraphCounter}.\arabic{SubParagraphCounter}}%
|
||||
: \textbf{#1}%
|
||||
\end{flushleft}
|
||||
\end{addmargin}
|
||||
\bigskip%
|
||||
\stepcounter{ParagraphCounter}%
|
||||
\needspace{10\baselineskip}%
|
||||
\vbox{%
|
||||
\noindent{\textbf{§ \arabic{ParagraphCounter}.\arabic{SubParagraphCounter}. #1}}\newline%
|
||||
}%
|
||||
}
|
||||
\renewcommand{\subparagraph}[1]{%
|
||||
\begin{addmargin}[0em]{0em}
|
||||
\stepcounter{SubParagraphCounter}%
|
||||
\needspace{10\baselineskip}%
|
||||
|
||||
\begin{flushleft}
|
||||
\textbf{Paragraph §\arabic{ParagraphCounter}.\arabic{SubParagraphCounter}}%
|
||||
: \textbf{#1}%
|
||||
\end{flushleft}
|
||||
\end{addmargin}
|
||||
\bigskip%
|
||||
\stepcounter{SubParagraphCounter}%
|
||||
\needspace{10\baselineskip}%
|
||||
\vbox{%
|
||||
\noindent{\textbf{§ \arabic{ParagraphCounter}.\arabic{SubParagraphCounter}. #1}}\newline%
|
||||
}%
|
||||
}
|
||||
\newcommand{\article}[2]{%
|
||||
\stepcounter{ArticleCounter}%
|
||||
\needspace{5\baselineskip}%
|
||||
\ifnum\value{BookCounter}>0
|
||||
\hbox{%
|
||||
\articleindent\textbf{Art. \arabic{BookCounter}:\arabic{ArticleCounter}}\newline%
|
||||
}
|
||||
\marginpar{#1}
|
||||
\else
|
||||
\hbox{%
|
||||
\articleindent\textbf{Art. \arabic{ArticleCounter}}\newline%
|
||||
}
|
||||
\marginpar{#1}
|
||||
\fi
|
||||
\par{#2}%
|
||||
\begin{addmargin}[0em]{0em}
|
||||
\stepcounter{ArticleCounter}%
|
||||
\needspace{5\baselineskip}%
|
||||
|
||||
\begin{flushleft}
|
||||
\textbf{Article \arabic{ArticleCounter}}%
|
||||
\def\param{#1}%
|
||||
\ifx\param\empty
|
||||
%
|
||||
\else
|
||||
: \textbf{#1}%
|
||||
\fi
|
||||
|
||||
\par{#2}
|
||||
\end{flushleft}
|
||||
\end{addmargin}
|
||||
\bigskip%
|
||||
}
|
||||
\newcommand{\subarticle}[2]{%
|
||||
\stepcounter{ArticleSubCounter}%
|
||||
\needspace{5\baselineskip}%
|
||||
\ifnum\value{BookCounter}>0
|
||||
\hbox{
|
||||
\articleindent\textbf{Art. \arabic{BookCounter}:\arabic{ArticleCounter}\alph{ArticleSubCounter}}\newline%
|
||||
}
|
||||
\marginpar{#1}
|
||||
\else
|
||||
\hbox{
|
||||
\articleindent\textbf{Art. \arabic{ArticleCounter}\alph{ArticleSubCounter}}\newline%
|
||||
}
|
||||
\marginpar{#1}
|
||||
\fi
|
||||
\par{#2}%
|
||||
}
|
||||
|
||||
% Header and footer
|
||||
\pagestyle{fancy}
|
||||
\fancyhf{}
|
||||
\fancyfoot[LE,RO]{\thepage}
|
||||
\begin{addmargin}[0em]{0em}
|
||||
\stepcounter{ArticleSubCounter}%
|
||||
\needspace{5\baselineskip}%
|
||||
|
||||
\begin{flushleft}
|
||||
\textbf{Article \arabic{ArticleCounter}\alphalph{\value{ArticleSubCounter}}}%
|
||||
\def\param{#1}%
|
||||
\ifx\param\empty
|
||||
%
|
||||
\else
|
||||
: \textbf{#1}%
|
||||
\fi
|
||||
|
||||
\par{#2}
|
||||
\end{flushleft}
|
||||
\end{addmargin}
|
||||
\bigskip%
|
||||
}
|
|
@ -29,6 +29,12 @@
|
|||
\setlist[enumerate,2]{leftmargin=1.5em,topsep=-1ex,itemsep=-1ex,partopsep=1ex,parsep=1ex,style=sameline}
|
||||
\setenumerate[0]{label=\textbf{\arabic*.}}
|
||||
|
||||
% Enumerates
|
||||
\newlist{leden}{enumerate}{1}
|
||||
\newlist{onderdelen}{enumerate}{2}
|
||||
\setlist[leden]{label=\textbf{\arabic*.},leftmargin=1.5em,topsep=-1ex,itemsep=-1ex,partopsep=1ex,parsep=1ex,style=sameline}
|
||||
\setlist[onderdelen]{label=\textit{\alph*}.,leftmargin=1.5em,topsep=-1ex,itemsep=-1ex,partopsep=1ex,parsep=1ex,style=sameline}
|
||||
|
||||
% Header and footer
|
||||
\pagestyle{fancy}
|
||||
\fancyhf{}
|
||||
|
|
37
proposal.cls
37
proposal.cls
|
@ -28,6 +28,12 @@
|
|||
\setlist[enumerate,2]{leftmargin=1.5em,topsep=-1ex,itemsep=-1ex,partopsep=1ex,parsep=1ex,style=sameline}
|
||||
\setenumerate[0]{label=\textbf{\arabic*.}}
|
||||
|
||||
% Enumerates
|
||||
\newlist{leden}{enumerate}{1}
|
||||
\newlist{onderdelen}{enumerate}{2}
|
||||
\setlist[leden]{label=\textbf{\arabic*.},leftmargin=1.5em,topsep=-1ex,itemsep=-1ex,partopsep=1ex,parsep=1ex,style=sameline}
|
||||
\setlist[onderdelen]{label=\textit{\alph*}.,leftmargin=1.5em,topsep=-1ex,itemsep=-1ex,partopsep=1ex,parsep=1ex,style=sameline}
|
||||
|
||||
% Header and footer
|
||||
\pagestyle{fancy}
|
||||
\fancyhf{}
|
||||
|
@ -68,17 +74,41 @@
|
|||
}
|
||||
|
||||
% About proposal content
|
||||
\newcounter{TopArticle}
|
||||
\newcounter{TopArticleCounter}
|
||||
\newcounter{SubTopArticleCounter}[TopArticleCounter]
|
||||
\newcommand{\toparticle}[2]{%
|
||||
% Count 1 up
|
||||
\stepcounter{TopArticle}%
|
||||
\stepcounter{TopArticleCounter}%
|
||||
|
||||
% Demand space and take space
|
||||
\needspace{5\baselineskip}%
|
||||
|
||||
% Center the title and print it
|
||||
\begin{flushleft}
|
||||
\textbf{ARTICLE \Roman{TopArticle}}%
|
||||
\textbf{ARTICLE \Roman{TopArticleCounter}}%
|
||||
\def\param{#1}%
|
||||
\ifx\param\empty
|
||||
%
|
||||
\else
|
||||
: \uppercase{\textbf{#1}}
|
||||
\fi
|
||||
\newline%
|
||||
|
||||
\medskip%
|
||||
\par{#2}
|
||||
\end{flushleft}
|
||||
}
|
||||
|
||||
\newcommand{\subtoparticle}[2]{%
|
||||
% Count 1 up
|
||||
\stepcounter{SubTopArticleCounter}
|
||||
|
||||
% Demand space and take space
|
||||
\needspace{5\baselineskip}%
|
||||
|
||||
% Center the title and print it
|
||||
\begin{flushleft}
|
||||
\textbf{ARTICLE \Roman{TopArticleCounter} \Alph{SubTopArticleCounter}}
|
||||
\def\param{#1}%
|
||||
\ifx\param\empty
|
||||
%
|
||||
|
@ -93,7 +123,6 @@
|
|||
}
|
||||
|
||||
\newcommand*\wildcard[2][5cm]{\vspace*{1cm}\parbox{#1}{\textit{Signed}: \hrulefill\par#2}}
|
||||
|
||||
\newcommand{\signature}[3]{
|
||||
\bigskip%
|
||||
\begin{flushleft}
|
||||
|
|
Loading…
Reference in New Issue