Skip to content

Instantly share code, notes, and snippets.

@nouredd2
Created September 28, 2023 14:27
Show Gist options
  • Save nouredd2/04b960ce056c3780aade88d246c7e3a4 to your computer and use it in GitHub Desktop.
Save nouredd2/04b960ce056c3780aade88d246c7e3a4 to your computer and use it in GitHub Desktop.
Generic LaTeX macros
\newcommand{\Fix}[1]{\textcolor{red}{[#1]}}
\newcommand{\CodeIn}[1]{{\small \texttt{#1}}}
\newcommand{\CI}[1]{\CodeIn{#1}}
\newcommand{\PP}[1]{\noindent {\bf #1}}
\newcommand{\ie}{i.e.,\xspace}
\newcommand{\eg}{e.g.,\xspace}
\newcommand{\latex}{\LaTeX\xspace}
% stuff needed for the todo list formatting
\RequirePackage{enumitem,amssymb}
\RequirePackage{pifont}
% define the todolist
\newlist{todolist}{itemize}{2}
\setlist[todolist]{label=$\square$}
% tick mark stuff
\newcommand{\cmark}{\ding{51}}%
\newcommand{\xmark}{\ding{55}}%
\newcommand{\done}{\rlap{$\square$}{\raisebox{2pt}{\large\hspace{1pt}\cmark}}%
\hspace{-2.5pt}}
\newcommand{\wontfix}{\rlap{$\square$}{\large\hspace{1pt}\xmark}}
% example of using the todolist
% \begin{todolist}
% \item Normal item that is not done yet.
% \item[\done] Completed item.
% \item[\wontfix] Item that will not be completed.
% \end{todolist}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment