Commit 9b250c7c authored by Sergey Goncharov's avatar Sergey Goncharov
Browse files

redefined defbbname; added test.tex

parent ae54b807
Pipeline #65853 passed with stage
in 27 seconds
......@@ -2,7 +2,7 @@ The idea of this directory is to provide shared resources for preparing publicat
Most importantly it contains the makefile with common command packages to compile latex files.
In order to use it create a makefile in your directory with the same name with the only content
In order to use it, create a makefile in your directory with the same name with the only content
'include <path-to-this-dir>/Makefile'. If your directory contains more than one root latex file
add 'SRCNAME=<name-of-root-file>' before the include command.
......
......@@ -9,8 +9,10 @@
% Same applies to other commands.
%
\usepackage{bm} % Needed for defbbname
\providecommand{\catname}{\mathbf}
\providecommand{\mndname}{\mathbbb}
%\providecommand{\mndname}{\mathbbb}
\providecommand{\clsname}{\mathcal}
\providecommand{\oname}[1]{\operatorname{\mathsf{#1}}}
......@@ -25,7 +27,7 @@
\defclsnames ABCDEFGHIJKLMNOPQRSTUVWXYZ\defclsnames
%% Defining \BBA, \BBB, etc
\def\defbbname#1{\expandafter\def\csname BB#1\endcsname{\mndname{#1}}}
\def\defbbname#1{\expandafter\def\csname BB#1\endcsname{{\bm{\mathsf{#1}}}}}
\def\defbbnames#1{\ifx#1\defbbnames\else\defbbname#1\expandafter\defbbnames\fi}
\defbbnames ABCDEFGHIJKLMNOPQRSTUVWXYZ\defbbnames
......
\documentclass[draft]{article}
\sloppy
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{lipsum}
\usepackage{todos}
\include{catprog}
\makeatletter
\def\show@monad@names#1{\ifx#1\show@monad@names\else\csname BB#1\endcsname\expandafter\show@monad@names@\fi}
\def\show@monad@names@#1{\ifx#1\show@monad@names\else\comma\csname BB#1\endcsname\expandafter\show@monad@names@\fi}
%
\def\show@cat@names#1{\ifx#1\show@cat@names\else\csname BB#1\endcsname\expandafter\show@cat@names@\fi}
\def\show@cat@names@#1{\ifx#1\show@cat@names\else\comma\csname B#1\endcsname\expandafter\show@cat@names@\fi}
\begin{document}
Categories: $\show@cat@names ABCDEFGHIJKLMNOPQRSTUVWXYZ\show@cat@names$
Monads: $\show@monad@names ABCDEFGHIJKLMNOPQRSTUVWXYZ\show@monad@names$
\todo{This is a use of the todo-command}
$-\dfrac{\hslash^2}{2m} \, \dfrac{\mathrm{d}^2 \psi}{\mathrm{d} x^2} \todo{It can be used like this}$
%
\begin{flalign*}
E = mc^2 &&\by{\todo{or like this}}
\end{flalign*}
\todo*{This is a use of the todo-command with a star
- starts a new line
- no indentation (initially)
- suitable for large chunks of text
\bigskip
\lipsum[1]
}
\end{document}
......@@ -18,9 +18,15 @@
\def\ensuretext#1{\ifmmode\text{#1}\else{#1}\fi}
\def\todo{\@ifstar\@@todo\@todo}
\ifpdf
% non-starred version for brief todos
\long\def\@todo#1{\ensuretext{\ttfamily\color[RGB]{255,64,64}TODO: #1}}
% starred version for extensive todos
\long\def\@@todo#1{{\hfill\\\noindent\ttfamily\color[RGB]{255,64,64}TODO: #1\hfill\par}}
\else
\fi
}
{}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment