-
Notifications
You must be signed in to change notification settings - Fork 0
/
reply_letter_head.tex
92 lines (83 loc) · 2.5 KB
/
reply_letter_head.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
% Template for replying to reviewer comments
%
% Author: Gertjan van den Burg (https://gertjan.dev)
% Source: https://github.com/GjjvdBurg/LaTeXReviewReplyTemplate
% License: MIT
%
% Command usage:
%
% - Reply: complete answer to the point raised.
%
% - Partial reply: partial answer to the point raised. More text may be
% needed. Can also imply work on the paper that still has to be done.
%
% - Todo reply: Used for discussion and/or sketching a reply.
%
% - Need reply: Signals that a point needs to get a reply.
%
\documentclass[11pt,a4paper]{article}
\usepackage{geometry}
\usepackage[most]{tcolorbox}
% Colors
\definecolor{lightgray}{rgb}{0.9, 0.9, 0.9}
\definecolor{lightyellow}{rgb}{0.98,0.91,0.71}
\definecolor{lightred}{rgb}{0.8,0.4,0.4}
% Boxes
\newtcolorbox{replybox}{colback=lightgray, grow to right by=-10mm, grow to
left by=-10mm, boxrule=0pt, boxsep=0pt, breakable, before skip=10pt}
\newtcolorbox{partialbox}{colback=lightyellow, grow to right by=-10mm, grow to
left by=-10mm, boxrule=0pt, boxsep=0pt, breakable, before skip=10pt}
\newtcolorbox{todobox}{colback=lightred, grow to right by=-10mm, grow to left
by=-10mm, boxrule=0pt, boxsep=0pt, breakable, before skip=10pt}
% Counters
\newcounter{epntcnt}
\newcounter{rpntcnt}
\newcounter{revcnt}
% Environments
\newenvironment{reviewer}{%
\refstepcounter{revcnt}%
\setcounter{rpntcnt}{0}%
\section*{Reviewer \therevcnt}%
}{}
% Editor environment takes an optional argument
\newenvironment{editor}[1][Editorial Decision]{%
\setcounter{epntcnt}{0}%
\section*{#1}%
}{}
% Reply Commands
\newcommand{\reply}[1]{%
\begin{replybox}%
#1
\end{replybox}%
}
\newcommand{\partialreply}[1]{%
\begin{partialbox}%
Partial reply: \emph{#1}
\end{partialbox}%
}
\newcommand{\todoreply}[1]{%
\begin{todobox}%
Todo reply: \emph{#1}
\end{todobox}%
}
\newcommand{\needsreply}{%
\todoreply{This comment needs a reply.}%
}
% Point command differs depending on the environment
\makeatletter
\newcommand{\point}{%
\medskip\noindent%
\def\@tmp{editor}%
\ifx\@tmp\@currenvir \refstepcounter{epntcnt}\theepntcnt\textbf{.}
\else%
\def\@tmp{reviewer}%
\ifx\@tmp\@currenvir \refstepcounter{rpntcnt}\therpntcnt\textbf{.}
\else\fi\fi%
}
\makeatother
% Renew the commands for the point counters to get the formatting we want in
% both the references and the item labels.
\renewcommand{\therpntcnt}{\textbf{\textup{\therevcnt.\arabic{rpntcnt}}}}
\renewcommand{\theepntcnt}{\textbf{\textup{E.\arabic{epntcnt}}}}
%\setlength\parindent{0pt}
\newcommand{\bft}[1]{\mathbf{#1}}