\documentclass[full]{l3doc}

\title{The \pkg{mkessler-categories} package}
\author{Maximilian Keßler}

\usepackage{mkessler-categories}

\begin{document}


\maketitle

\begin{abstract}
  This is a ready-to-use package providing symbols of mathematical
  categories with automatic indexing.

  It is certainly plausible that you prefer to name your categories slightly
  differently that the author.
\end{abstract}

\begin{documentation}

\section{General notice}

This package is based on the \pkg{mkessler-symbindex} package.
We thus use \pkg{imakeindex} to generate the index file.

\section{Functionality}

\begin{function}{\category}
  \begin{syntax}
    \cs{category}\marg{category}
  \end{syntax}

  Makes the given argument \meta{category} behave like a math operator
  and prints its name in bold.

  This is just to ensure a unified style for printing categories,
  if you don't like it, redefine this macro.
\end{function}

\begin{function}{\DeclareCategory}
  \begin{syntax}
    \cs{DeclareCategory}\oarg{key=value list}\marg{category}
  \end{syntax}

  Has the same syntax as \cs{DeclareSymbol} from the \pkg{mkessler-symbindex} package,
  but adds the key \texttt{group = categories}.
\end{function}

\begin{function}{\DeclareSimpleCategory}
  \begin{syntax}
    \cs{DeclareSimpleCategory}\oarg{key=value list}\marg{category}\oarg{description}
  \end{syntax}

  Declares a \enquote{simple} category, i.e.~the category \cs{\meta{category}}
  is declared and will expand to \enquote{\cs{category}\marg{category}}
  when expanded.

  The optional \meta{description} is shown in the index when present.
\end{function}

\begin{function}{\MakeCategoryIndex}
  Prints the index of categories.
\end{function}

\section{Default categories}

The package also provides default categories, these are (by now):

\begin{gather*}
  \Top, \hTop, \Set, \CHaus, \Grp, \Ab, \CRing, \Ring, \Vect, \\
  \Cat, \Mod, \Alg, \Field, \AffVar_k, \Sch, \GrAb, \OrdCat
\end{gather*}
  
\end{documentation}

\MakeCategoryIndex

\PrintIndex
  
\end{document}
