-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathresponseletter.cls
186 lines (151 loc) · 3.73 KB
/
responseletter.cls
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
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
% Author: Hunter Hwang
\NeedsTeXFormat{LaTeX2e}
\ProvidesClass{responseletter}[2024/5/26 A Latex Response Letter class]
\LoadClass[]{article}
%%%%%%%%%%%%%%%%%%%%%%%% Core Package %%%%%%%%%%%%%%%%%%%%%%%%%%%
\RequirePackage[utf8]{inputenc}
% page size setting
\RequirePackage{geometry}
\geometry{
a4paper,
left=15mm,
right=15mm,
top=15mm,
bottom=15mm,
marginparwidth=15mm
}
% To add author blocks to the front-matter
\RequirePackage{authblk}
% Reference
\RequirePackage[style=ieee,refsection=subsection]{biblatex}
%% cite style
\DeclareFieldFormat{labelnumber}{R.#1}
% Color
\RequirePackage{xcolor}
% reference style for builtin
\renewcommand{\theequation}{R.\arabic{equation}}
\renewcommand{\thefigure}{R.\arabic{figure}}
\renewcommand{\thetable}{R.\arabic{table}}
%%%%%%%%%%%%%%%%%%%%%%%% Additonal Package %%%%%%%%%%%%%%%%%%%%%%%%%%%
% Indent first line automatically
\RequirePackage{indentfirst}
% Using [H] to ban the float of algorithm, figure and so on.
\RequirePackage{float}
% Figure
\RequirePackage{graphicx}
\RequirePackage[]{subfig}
% Math
\RequirePackage{amsmath}
\RequirePackage{amssymb}
% Algorithm
%% Float of algorithm
\RequirePackage{algorithm}
%% Body of algorithm
\RequirePackage{algorithmic}
%% Custom setting for algorithmic
\renewcommand{\algorithmicrequire}{\textbf{Input:}}
\renewcommand{\algorithmicensure}{\textbf{Output:}}
%% cite style
\renewcommand{\thealgorithm}{R.\arabic{algorithm}}
% Code highlight
\RequirePackage{minted}
% Autoref
\RequirePackage[
colorlinks,
linkcolor=red,
anchorcolor=blue,
citecolor=green % black
]{hyperref}
%% Custom refname for algorithm
\newcommand{\algorithmautorefname}{Algorithm}
%% Custom refname for subfigure
\newcommand{\subfigureautorefname}{Figure}
%% Custom refname for section
\renewcommand{\sectionautorefname}{Section}
%% Custom refname for subsection
\renewcommand{\subsectionautorefname}{Subsection}
%% Custom refname for subsection
\renewcommand{\subsubsectionautorefname}{SubSubsection}
%% Custom refname for step of algorithm
\makeatletter
\newcommand{\ALC@uniqueautorefname}{Line}
\makeatother
% border box
\RequirePackage{framed}
%%%%%%%%%%%%%%%%%%%%%%%% Common Part of Comment %%%%%%%%%%%%%%%%%%%%%%%%%%%
\newenvironment{Draft}{
\ifx \IfDraft True {
}{
}
\fi
}
%%%%%%%%%%%%%%%%%%%%%%%% Labels %%%%%%%%%%%%%%%%%%%%%%%%%%%
\newcommand{\Label}[2]{
\colorbox{#1}{\color{white} \textbf{#2}}
}
\newcommand{\Hard}{
\Label{red}{Hard}
}
\newcommand{\Medium}{
\Label{yellow}{Medium}
}
\newcommand{\Easy}{
\Label{green}{Easy}
}
\newcommand{\Done}{
\Label{blue}{Done}
}
\newcommand{\InProcess}{
\Label{cyan}{Done}
}
\newcommand{\Tip}{
\Label{violet}{Tip}
}
%%%%%%%%%%%%%%%%%%%%%%%% Common Part of Comment %%%%%%%%%%%%%%%%%%%%%%%%%%%
\makeatletter
\renewcommand{\@seccntformat}[1]{}
\makeatother
\newenvironment{CommentSummary}{
\subsection*{Comments to the Authors:}
%\begin{quotation}
\begin{em}
}{
\end{em}
%\end{quotation}
}
\newenvironment{Response}{
\subsection*{Response}
}{
\vspace{2cm}
}
%%%%%%%%%%%%%%%%%%%%%%%%%%% Editors %%%%%%%%%%%%%%%%%%%%%%%%%%%
\newenvironment{Editor}[1][Editor]{
\section{#1}
}{
\pagebreak
}
%%%%%%%%%%%%%%%%%%%%%%%%%%% Reviewer %%%%%%%%%%%%%%%%%%%%%%%%%%%
\newcounter{ReviewerCounter}
\setcounter{ReviewerCounter}{1}
\newcounter{ReviewerCommentCounter}[section]
\newenvironment{Reviewer}[1][\arabic{ReviewerCounter}]{
\ifx #1 \empty {
\section{Reviewer #1}
} \else {
\setcounter{ReviewerCounter}{#1}
\section{Reviewer \arabic{ReviewerCounter}}
}
\fi
\stepcounter{ReviewerCounter}
}{
\pagebreak
}
\newenvironment{ReviewerComment}{
\stepcounter{ReviewerCommentCounter}
\subsection{Comment \Roman{ReviewerCommentCounter}}
%\begin{quotation}
\begin{em}
}{
\end{em}
%\end{quotation}
}