texlive[72758] Master: rebuttal (3nov24)

commits+karl at tug.org commits+karl at tug.org
Sun Nov 3 22:06:10 CET 2024


Revision: 72758
          https://tug.org/svn/texlive?view=revision&revision=72758
Author:   karl
Date:     2024-11-03 22:06:10 +0100 (Sun, 03 Nov 2024)
Log Message:
-----------
rebuttal (3nov24)

Modified Paths:
--------------
    trunk/Master/tlpkg/bin/tlpkg-ctan-check
    trunk/Master/tlpkg/tlpsrc/collection-publishers.tlpsrc

Added Paths:
-----------
    trunk/Master/texmf-dist/doc/latex/rebuttal/
    trunk/Master/texmf-dist/doc/latex/rebuttal/01-example.tex
    trunk/Master/texmf-dist/doc/latex/rebuttal/README.md
    trunk/Master/texmf-dist/doc/latex/rebuttal/rebuttal.pdf
    trunk/Master/texmf-dist/source/latex/rebuttal/
    trunk/Master/texmf-dist/source/latex/rebuttal/rebuttal.dtx
    trunk/Master/texmf-dist/source/latex/rebuttal/rebuttal.ins
    trunk/Master/texmf-dist/tex/latex/rebuttal/
    trunk/Master/texmf-dist/tex/latex/rebuttal/rebuttal.sty
    trunk/Master/tlpkg/tlpsrc/rebuttal.tlpsrc

Added: trunk/Master/texmf-dist/doc/latex/rebuttal/01-example.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/rebuttal/01-example.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/rebuttal/01-example.tex	2024-11-03 21:06:10 UTC (rev 72758)
@@ -0,0 +1,172 @@
+%%
+%% This is file `01-example.tex',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% rebuttal.dtx  (with options: `example1')
+%% 
+%% Copyright (C) 2018-2021, 2024 Sergiu Deitsch
+%% 
+%% This work may be distributed and/or modified under the
+%% conditions of the LaTeX Project Public License, either version 1.3
+%% of this license or (at your option) any later version.
+%% The latest version of this license is in
+%%   http://www.latex-project.org/lppl.txt
+%% and version 1.3 or later is part of all distributions of LaTeX
+%% version 2005/12/01 or later.
+%% 
+%% This work has the LPPL maintenance status `maintained'.
+%% 
+%% The Current Maintainer of this work is Sergiu Deitsch.
+%% 
+%% This work consists of the files rebuttal.dtx and rebuttal.ins.
+%% 
+\documentclass[american,version=last,fromphone,fromemail,svgnames,dvipsnames,x11names]{scrlttr2}
+\usepackage[T1]{fontenc}
+\usepackage[utf8]{inputenc}
+\usepackage[babel]{csquotes}
+\usepackage{babel}
+\usepackage{graphicx}
+\usepackage{microtype}
+\usepackage{lipsum}
+\usepackage{rebuttal}
+\usepackage{varioref}
+\usepackage{hyperref}
+\usepackage{cleveref}
+
+\hypersetup{colorlinks=true}
+
+\setkomavar{fromname}{Jane Smith}
+\setkomavar{fromaddress}{%
+  Pattern Recognition Lab\\
+  University of Erlangen-Nürnberg
+}
+\setkomavar{backaddress}{}
+\setkomavar{fromphone}{$+49$\,(0)\,12345678}
+\setkomavar{fromemail}{firstname.lastname at fau.de}
+\setkomavar{place}{Erlangen}
+
+\begin{document}
+
+\setkomavar{subject}{Manuscript: Extended Field of View in C-Arm Computed
+  Tomography for Weight-Bearing Imaging}
+
+\begin{letter}{Medical Physics}
+
+\opening{Dear Prof. Jones, Dear Prof. Taylor,}
+
+We thank you for considering our submission as a research article for Medical
+Physics. We also thank the reviewers for the thoughtful comments. We have
+carefully revised the document and prepared a point-by-point response to the
+reviewer’s comments.
+
+The major changes to the paper are:
+\begin{itemize}
+  \item Clarification of the medical impact
+  \item An extension of the evaluation and discussion to 3D Cone Beam CT and
+    off-center positioning of the object
+  \item Inclusion of more substantive figure captions
+\end{itemize}
+
+Below, you will find the reviewers’ comments in blue, our response in normal
+face and additions to the manuscript in quotes and \enquote{italic face.} Note
+that we omitted footnotes and references in the quotations.
+
+We are looking forward to hearing from you.
+
+\closing{With kind regards,}
+
+\end{letter}
+
+\clearpage\noindent The following pages contain a list of editor's and
+reviewers' comments followed by our replies. The comments are sequentially
+numbered and associated either with the editor or the corresponding reviewer.
+The replies may contain references to changes in the original manuscript which
+are identified by a label consisting of a running number and followed by the
+label of the original comment in parentheses. The label back references the
+original reviewer comment within the manuscript. For instance, the reference
+\textbf{C2~(1.3)}, which is typeset in the manuscript margin, refers to the
+second change stemming from the third comment of the first reviewer.
+
+\begin{rebuttal}[Editor's Comments]
+  \begin{comment}
+  The topic of this manuscript is of interest. We concur with the summary review
+  of the associate editor and the reviews of the referees. The authors should
+  thoroughly address all of the comments, below, in a revised manuscript.
+  \end{comment}
+
+\end{rebuttal}
+
+\begin{rebuttal}[Specific Comments]
+  \begin{comment}
+  \label{c:specific}
+  You need to include figure captions that make your figures intelligible.
+  See~\cref{a:foo} and \cref{c:foo2}.
+  \end{comment}
+
+  \begin{answer}
+    The reviewer is right. We have reworked the figure captions to make the
+    figures more independent of the text. Furthermore, check if lists are
+    typeset correctly:
+    \begin{itemize}
+      \item One
+      \item Two
+        \begin{enumerate}
+          \item Three
+          \item Four
+        \end{enumerate}
+    \end{itemize}
+  \end{answer}
+
+  \begin{comment}
+    \label{c:c2}
+    Are you going to pay for color in the print article? If not, the lines are
+    not intelligible in Figures 2, 5, 11. In addition to color coding for the
+    digital version, you could make lines with distinct patterns (dots, dashes,
+    etc.) so they are distinct in monochrome presentations.
+  \end{comment}
+
+  \begin{answer}
+    We agree with this point and we are sorry that we missed this in the first
+    version of the article. The article will appear as an online only version
+    and is part of the special issue associated with this year’s CT Meeting
+    conference. Thus there will be no additional cost associated with color
+    figures. Nonetheless, we agree that all figures need to be correct in
+    grey-scale as some readers might print the article. According to the
+    reviewer’s comment, we have adjusted the figures by using different patterns
+    and gray levels.
+
+    (Refer also to \cref{c:specific} for more information.)
+  \end{answer}
+\end{rebuttal}
+
+\lipsum[1] \addition[label=a:foo,ref=c:specific]{\lipsum[2]} \lipsum[3]
+
+\lipsum[4] \deletion[label=a:foo1,ref=c:c2]{An unintended addition.}
+and a \change[label=c:foo2,ref=c:c2]{from}{to} change. And another addition
+\addition[label=a:foo3,ref=c:c2]{here}.
+Also \addition[label=a:foo4,ref=c:c2]{here}.
+Maybe \addition[label=a:foo5,ref=c:c2]{here}.
+Additionally \addition[label=a:foo6,ref=c:c2]{here}.
+Additionally \addition[label=a:foo7,ref=c:c2]{here}.
+
+\begin{additionenv}[label=d:par,ref=c:c2]
+  \begin{itemize}
+    \item \lipsum[1]
+  \end{itemize}
+  \lipsum[2]
+\end{additionenv}
+
+Additional notes:
+\begin{itemize}
+  \item Multiple source references can be
+    \addition[label=a:foo8,ref={c:specific,c:c2}]{specified}.
+  \item If the references do not fit into a single line in the margin, you may
+    force a \addition[label=a:break,ref={c:specific,c:c2},break]{break}.
+\end{itemize}
+
+\end{document}
+\endinput
+%%
+%% End of file `01-example.tex'.


Property changes on: trunk/Master/texmf-dist/doc/latex/rebuttal/01-example.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/rebuttal/README.md
===================================================================
--- trunk/Master/texmf-dist/doc/latex/rebuttal/README.md	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/rebuttal/README.md	2024-11-03 21:06:10 UTC (rev 72758)
@@ -0,0 +1,109 @@
+# Structured Rebuttals in LaTeX
+
+[![TeXLive](https://github.com/sergiud/rebuttal/actions/workflows/texlive.yml/badge.svg)](https://github.com/sergiud/rebuttal/actions/workflows/texlive.yml)
+
+The rebuttal LaTeX package provides means for writing structured journal and
+conference paper rebuttals.
+
+## Features
+
+* Creation of a master list of referee comments and the corresponding replies
+* Support for cross-referencing the changes (i.e., additions, deletions, and
+  changes) within the original manuscript and the rebuttal letter
+
+## Getting Started
+
+To use the package, simply load `rebuttal` in the document preamble as follows:
+
+```latex
+\usepackage{rebuttal}
+```
+
+Also make sure the `xcolor` package has been loaded using the following options:
+
+* `dvipsnames`
+* `svgnames`
+* `x11names`
+
+Please refer to the
+[letter](https://github.com/sergiud/rebuttal/blob/2e8839440c55e23de8dd05a7c0a0cef6f15ce23e/examples/letter.tex#L1)
+example for necessary preamble setup.
+
+Afterwards, you can structure the rebuttal using (multiple) `rebuttal`
+environment(s).
+
+## Usage
+
+A well-structured rebuttal typically consists of the following parts:
+
+1. a master list of referee comments and author's replies, and
+2. clearly highlighted changes to the manuscript that stem from reviewers'
+   comments.
+
+The following sections provide an overview of the package's functionality that
+supports authors in producing the above content in a consistent manner.
+
+### Structuring the Rebuttal
+
+The `rebuttal` environment can contain several blocks that refer to editor's or
+specific reviewers' comments and your replies to referees' comments.
+Specifically, the environment is expected to contain a `comment` and an `answer`
+environment. The general layout looks as follows:
+
+```latex
+\begin{rebuttal}[Editor's Comments]
+  \begin{comment}
+    % Reviewer's comment
+  \end{comment}
+  \begin{answer}
+    % The reply
+  \end{answer}
+\end{rebuttal}
+```
+
+### Annotating Changes to the Manuscript
+
+Within the manuscript, three main commands can be used to denote additions,
+deletions, or changes. The corresponding commands are `\addition`, `\deletion`,
+and `\change`.
+
+All three commands require specifying their labels for referencing the
+modifications using the `label` option. Additionally, the `ref` option back
+references the original reviewer comment. While `\addition` and `\deletion`
+require a single argument. `\change` expects two arguments, where the first one
+denotes the changed text, and the second one the new text.
+
+### Annotating Multiple Paragraphs
+
+Additionally to the provided markup commands, the package also defines
+equivalent environments for annotating multiple paragraphs:
+
+```latex
+\begin{additionenv}[label=a:par,ref=c:missing-motivations]
+  \section{New Experiment}
+  % new text
+\end{additionenv}
+
+\begin{changeenv}[label=ch:par,ref=c:missing-motivations]{old text}
+  \section{Improved Experiment}
+  % new text
+\end{changeenv}
+
+\begin{deletionenv}[label=d:par,ref=c:missing-motivations]
+  \section{Useless Discussion}
+  % old text
+\end{deletionenv}
+```
+
+### Referencing Multiple Changes
+
+The `ref` option provided by markup commands may specify multiple labels:
+
+```latex
+\addition[label=a:new,ref={c:c1,c:c2}]{new text}.
+```
+
+## Limitations
+
+* Rebuttal markup cannot be used within floating environments such as `figure`
+  and `table`, and the `\caption` command.


Property changes on: trunk/Master/texmf-dist/doc/latex/rebuttal/README.md
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/rebuttal/rebuttal.pdf
===================================================================
(Binary files differ)

Index: trunk/Master/texmf-dist/doc/latex/rebuttal/rebuttal.pdf
===================================================================
--- trunk/Master/texmf-dist/doc/latex/rebuttal/rebuttal.pdf	2024-11-03 21:05:30 UTC (rev 72757)
+++ trunk/Master/texmf-dist/doc/latex/rebuttal/rebuttal.pdf	2024-11-03 21:06:10 UTC (rev 72758)

Property changes on: trunk/Master/texmf-dist/doc/latex/rebuttal/rebuttal.pdf
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/pdf
\ No newline at end of property
Added: trunk/Master/texmf-dist/source/latex/rebuttal/rebuttal.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/rebuttal/rebuttal.dtx	                        (rev 0)
+++ trunk/Master/texmf-dist/source/latex/rebuttal/rebuttal.dtx	2024-11-03 21:06:10 UTC (rev 72758)
@@ -0,0 +1,790 @@
+% \iffalse meta-comment
+%
+% Copyright 2018-2021, 2024 Sergiu Deitsch
+%
+% This work may be distributed and/or modified under the
+% conditions of the LaTeX Project Public License, either version 1.3
+% of this license or (at your option) any later version.
+% The latest version of this license is in
+%   http://www.latex-project.org/lppl.txt
+% and version 1.3 or later is part of all distributions of LaTeX
+% version 2005/12/01 or later.
+%
+% \fi
+%
+% \iffalse
+%<package>\NeedsTeXFormat{LaTeX2e}
+%<package>\ProvidesPackage{rebuttal}
+%<package>   [2024-11-01 v0.1.0 Markup for rebuttal letters]
+%
+%<*driver>
+\ProvidesFile{rebuttal.dtx}
+
+\documentclass[american,reportchangedates]{ltxdoc}
+\usepackage[abbreviations]{foreign}
+\usepackage[utf8]{inputenc}
+\usepackage[T1]{fontenc}
+\usepackage{babel}
+\usepackage{microtype}
+\usepackage[all]{nowidow}
+\usepackage{rebuttal}
+\usepackage{hyperref}
+
+\EnableCrossrefs
+\OnlyDescription
+\CodelineIndex
+\RecordChanges
+
+\hypersetup{%
+  pdfauthor = {Sergiu Deitsch},
+  pdftitle  = {The rebuttal package},
+}
+
+\begin{document}
+  \DocInput{rebuttal.dtx}
+\end{document}
+%</driver>
+% \fi
+%
+% \CheckSum{0}
+%
+% \CharacterTable
+%  {Upper-case    \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
+%   Lower-case    \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
+%   Digits        \0\1\2\3\4\5\6\7\8\9
+%   Exclamation   \!     Double quote  \"     Hash (number) \#
+%   Dollar        \$     Percent       \%     Ampersand     \&
+%   Acute accent  \'     Left paren    \(     Right paren   \)
+%   Asterisk      \*     Plus          \+     Comma         \,
+%   Minus         \-     Point         \.     Solidus       \/
+%   Colon         \:     Semicolon     \;     Less than     \<
+%   Equals        \=     Greater than  \>     Question mark \?
+%   Commercial at \@     Left bracket  \[     Backslash     \\
+%   Right bracket \]     Circumflex    \^     Underscore    \_
+%   Grave accent  \`     Left brace    \{     Vertical bar  \|
+%   Right brace   \}     Tilde         \~}
+%
+%
+% \changes{v0.1.0}{2024-11-01}{Initial release}
+%
+% \GetFileInfo{rebuttal.sty}
+%
+% \DoNotIndex{\newcommand,\newenvironment,\def,\the,\let,\if,\fi,\else}
+% \DoNotIndex{\newif,\ifx,\ifcase,\or}
+% \DoNotIndex{\begingroup,\endgroup}
+%
+% \title{The \textsf{rebuttal} package\thanks{This document
+%   corresponds to \textsf{rebuttal}~\fileversion, dated \filedate.}}
+% \author{Sergiu Deitsch\\\texttt{sergiu.deitsch at gmail.com}}
+% \date{November 1, 2024}
+%
+% \maketitle
+%
+% \begin{abstract}
+% The rebuttal LaTeX package provides means for writing structured journal and
+% conference paper rebuttals.
+% \end{abstract}
+%
+% \section{Introduction}
+%
+% A well-structured rebuttal typically consists of the following parts:
+%
+% \begin{enumerate}
+%   \item a master list of referee comments and author's replies, and
+%   \item clearly highlighted changes to the manuscript that stem from
+%   reviewers' comments.
+% \end{enumerate}
+%
+% The \textsf{rebuttal} provides markup to support authors in producing the
+% above content in a consistent manner.
+%
+% \section{Usage}
+%
+% The following sections provide an overview of the package's functionality for
+% structuring rebuttals and annotating manuscripts.
+%
+% \subsection{Structuring the Rebuttal}
+%
+% \DescribeEnv{rebuttal}
+% \DescribeEnv{comment}
+% \DescribeEnv{answer}
+% The packages defines the |rebuttal| environment that can contain several
+% blocks that refer to editor's or specific reviewers' comments and your replies
+% to referees' comments. Specifically, the environment is expected to contain a
+% |comment| and an |answer| environment. The general layout looks as follows:
+%
+% \begin{verbatim}
+%   \begin{rebuttal}[Editor's Comments]
+%     \begin{comment}
+%       % Reviewer's comment
+%     \end{comment}
+%     \begin{answer}
+%       % The reply
+%     \end{answer}
+%   \end{rebuttal}
+% \end{verbatim}
+%
+% \subsection{Annotating Changes to the Manuscript}
+%
+% \DescribeMacro{\addition}
+% \DescribeMacro{\deletion}
+% \DescribeMacro{\change}
+% Within the manuscript, three main commands can be used to denote additions,
+% deletions, or changes. The corresponding commands are
+% |\addition|\oarg{options}\marg{text}, |\deletion|\oarg{options}\marg{text},
+% and |\change|\oarg{options}\marg{old text}\marg{new text}.
+%
+% All three commands require specifying their labels for referencing the
+% modifications using the \meta{label} option. Additionally, the \meta{ref}
+% option back references the original reviewer comment and may specify multiple
+% labels, \eg
+%
+% \begin{verbatim}
+%   \addition[label=a:new,ref={c:c1,c:c2}]{new text}.
+% \end{verbatim}
+%
+% While |\addition| and
+% |\deletion| require a single argument. |\change| expects two arguments, where
+% the first one denotes the changed text, and the second one the new text.
+%
+%
+% \subsection{Annotating Multiple Paragraphs}
+%
+% \DescribeEnv{additionenv}
+% \DescribeEnv{changeenv}
+% \DescribeEnv{deletionenv}
+% Additionally to the provided markup commands, the package also defines
+% equivalent environments for annotating multiple paragraphs:
+%
+% \begin{verbatim}
+%   \begin{additionenv}[label=a:par,ref=c:missing-motivations]
+%     \section{New Experiment}
+%     % new text
+%   \end{additionenv}
+%
+%   \begin{changeenv}[label=ch:par,ref=c:missing-motivations]{old text}
+%     \section{Improved Experiment}
+%     % new text
+%   \end{changeenv}
+%
+%   \begin{deletionenv}[label=d:par,ref=c:missing-motivations]
+%     \section{Useless Discussion}
+%     % old text
+%   \end{deletionenv}
+% \end{verbatim}
+%
+% \section{Known Limitations}
+%
+% Rebuttal markup cannot be used within floating environments such as |figure|
+% and |table|, and the |\caption| command.
+%
+% \MaybeStop{\PrintChanges}
+%
+% \section{Implementation}
+%
+% \subsection{Package}
+%
+%    \begin{macrocode}
+%<*package>
+%    \end{macrocode}
+%    \begin{macrocode}
+
+\PassOptionsToPackage{dvipsnames,svgnames,x11names}{xcolor}
+
+\RequirePackage{calc}
+\RequirePackage{environ}
+\RequirePackage{etoolbox}
+\RequirePackage{marginnote}
+\RequirePackage{pgfkeys}
+\RequirePackage{soul}
+\RequirePackage{tikz}
+\RequirePackage{todonotes}
+\RequirePackage{ulem}
+\RequirePackage{xcolor}
+\RequirePackage{xstring}
+
+\AtEndPreamble{
+  \RequirePackage{pdfcomment}
+}
+
+\ifx\counterwithin\@undefined
+\RequirePackage{chngcntr}
+\fi
+
+\newcommand\rebuttal at triangle{%
+  \begingroup
+  \ifx\tikzexternaldisable\@undefined\else
+    \tikzexternaldisable
+  \fi
+  \begin{tikzpicture}[x=.5em,y=.5em]
+    \fill[/rebuttal/answer/label] (0,0) -- (0,1) -- (.75,.5) -- cycle;
+  \end{tikzpicture}%
+  \endgroup
+}
+
+\newcommand\rebuttal at decbookmarklevel{%
+  \ifx\Hy at currentbookmarklevel\@undefined\else
+    \@tempcnta\Hy at currentbookmarklevel
+    \advance\@tempcnta by -1 %
+    \xdef\Hy at currentbookmarklevel{\the\@tempcnta}%
+  \fi
+}
+
+\newcommand\rebuttal at incbookmarklevel{%
+  \ifx\Hy at currentbookmarklevel\@undefined\else
+    \@tempcnta\Hy at currentbookmarklevel
+    \advance\@tempcnta by 1 %
+    \xdef\Hy at currentbookmarklevel{\the\@tempcnta}%
+  \fi
+}
+
+\newif\ifrebuttal at marked
+\newif\ifrebuttal at nohyperlinks
+\newif\ifrebuttal at refbreak
+\newif\ifrebuttal at twocolumn
+
+\pgfkeys{
+  /rebuttal/.is family,
+  /rebuttal/execute on begin/.initial=,
+  /rebuttal/execute on end/.initial=,
+  /rebuttal/no hyperlinks/.is if=rebuttal at nohyperlinks,
+  /rebuttal/no hyperlinks=false,
+  /rebuttal/marked/.is if=rebuttal at marked,
+  /rebuttal/marked=true,
+  /rebuttal/title/font/.store in=\rebuttal at titlefont,
+  /rebuttal/title/font=\normalfont\bfseries,
+  /rebuttal/title/format/.code=#1:,
+  /rebuttal/change/from command/.store in=\rebuttal at changefrom,
+  /rebuttal/change/from command=\sout,
+  /rebuttal/change/from color/.code={\colorlet{rebuttal at change@from}{#1}},
+  /rebuttal/change/from color=DodgerBlue3!50,
+  /rebuttal/deletion/command/.store in=\rebuttal at delete,
+  /rebuttal/deletion/command=\xout,
+  /rebuttal/comment/font/.store in=\rebuttal at commentfont,
+  /rebuttal/comment/font=\normalfont\itshape,
+  /rebuttal/comment/label/font/.store in=\rebuttal at commentlabelfont,
+  /rebuttal/comment/label/font=\normalfont\rmfamily\bfseries,
+  /rebuttal/answer/font/.store in=\rebuttal at answerfont,
+  /rebuttal/answer/font=\normalfont,
+  /rebuttal/answer/label/.store in=\rebuttal at answerlabel,
+  /rebuttal/answer/label={\rebuttal at triangle},
+  /rebuttal/answer/label/font/.store in=\rebuttal at answerlabelfont,
+  /rebuttal/answer/label/font=\normalfont,
+  /rebuttal/answer/label/.style={black!65},
+  /rebuttal/reference/font/.store in=\rebuttal at referencefont,
+  /rebuttal/reference/font={%
+    \tiny\bfseries%
+  },
+  % TODO does not work within \todo
+  %/rebuttal/reference/.code={%
+  %},
+}
+
+\let\rebuttalanswerlabel\rebuttal at answerlabel
+
+\newrobustcmd\rebuttal at reference[1]{%
+  \begingroup
+  \rebuttal at referencefont
+  \begin{tabular}{@{}c@{}}
+    \begingroup
+      \color{rebuttal@#1}%
+      \MakeUppercase{\rebuttal at id}%
+      \csname therebuttal#1\endcsname
+    \endgroup
+    \ifrebuttal at refbreak
+      \\%
+    \else
+      \enspace
+    \fi
+    \normalfont
+    % Reset color (TODO Maybe allow to modify the color)
+    \color{black}%
+    (\pgfkeys{/rebuttal/#1/ref/all})%
+  \end{tabular}%
+  \endgroup
+}
+
+\newcommand\rebuttal at define@keys[2]{
+  \pgfkeys{
+    /rebuttal/#1/label/.initial=,
+    /rebuttal/#1/label/.value required,
+    /rebuttal/#1/break/.is if=rebuttal at refbreak,
+    /rebuttal/#1/ref/.initial=,
+    /rebuttal/#1/ref/.value required,
+    /rebuttal/#1/ref/create/.code={
+      \ifrebuttal at nohyperlinks
+        \ref*{##1}%
+      \else
+        \ref{##1}%
+      \fi
+    },
+    /rebuttal/#1/ref/all/.code={%
+      \pgfkeysgetvalue{/rebuttal/#1/ref}\rebuttal at currefs
+      \edef\rebuttal at tmp{\rebuttal at currefs}%
+      \foreach
+      [
+        %expand list,
+        count=\ri from 0,
+      ]
+      \r in \rebuttal at tmp {%
+        \ifnum\ri > 0\relax
+          ,\,%
+        \fi
+        \pgfkeys{/rebuttal/#1/ref/create=\r}%
+      }%
+    },
+    /rebuttal/#1/color/.code={\colorlet{rebuttal@#1}{##1}},
+    /rebuttal/#1/color=#2,
+    /rebuttal/#1/font/.value required,
+    /rebuttal/#1/font/.code={
+      \expandafter\def\csname rebuttal@#1 at font\endcsname{##1}%
+    },
+    /rebuttal/#1/font=\normalfont\mdseries,
+  }
+}
+
+\rebuttal at define@keys{addition}{RedViolet}
+\rebuttal at define@keys{deletion}{Firebrick3}
+\rebuttal at define@keys{change}{DodgerBlue3}
+
+\newlength\rebuttal at textwidth
+\newlength\rebuttal at hskip
+
+\newcommand\rebuttal at command[3]{%
+  \newcounter{rebuttal#1}%
+  \AtEndPreamble{%
+    \@ifpackageloaded{cleveref}{%
+      \crefname{rebuttal#1}{#1}{#1s}%
+    }{}%
+  }%
+  % Marked version with full output
+  \expandafter\newcommand\csname #1\endcsname[#3][]{%
+    \ifrebuttal at marked
+      \stepcounter{rebuttalchanges}%
+      \refstepcounter{rebuttal#1}%
+      \begingroup
+        \tikzset{notestyleraw/.append style={
+          inner sep=\z@,
+          rounded corners=\z@,
+        }}%
+        \pgfqkeys{/rebuttal/#1}{##1}%
+        \label{\pgfkeysvalueof{/rebuttal/#1/label}}%
+        \colorlet{Changes at Color}{rebuttal@#1}%
+        \begingroup
+          % Main content
+          #2%
+        \endgroup
+        \StrLeft{#1}{1}[\rebuttal at id]%
+        \ifx\tikzexternaldisable\@undefined\else
+          \tikzexternaldisable
+        \fi
+        % Shrink to text
+        \settowidth\rebuttal at textwidth{\rebuttal at reference{#1}}%
+        \tikzset{notestyleraw/.append style={text width=\rebuttal at textwidth}}%
+        % Place labels in left margin at the same distance as on the right
+        \setlength\rebuttal at hskip{\marginparwidth}%
+        \addtolength\rebuttal at hskip{-\rebuttal at textwidth}%
+        \let\old at xmpar\@xmpar
+        % Hook into LaTeX kernel command since \if at firstcolumn is not unreliable
+        % because margin notes are floats.
+        \renewcommand\@xmpar[2][]{%
+          \old at xmpar[\hspace*{\rebuttal at hskip}####1]{####2}%
+        }%
+        \todo
+        [
+          backgroundcolor=none,
+          bordercolor=none,
+          linecolor=rebuttal@#1,
+          %size=\tiny,
+        ]{%
+          \rebuttal at reference{#1}%
+          %\pgfkeys{/rebuttal/reference=#1}
+        }%
+      \endgroup
+    \else
+      #2%
+    \fi
+  }%
+}
+
+% Provide an equivalent environment for rebuttal commands
+\NewEnviron{additionenv}[1][]{%
+  \addition[#1]{\BODY}%
+}%
+
+\NewEnviron{changeenv}[2][]{%
+  \change[#1]{#2}{\BODY}%
+}%
+
+\NewEnviron{deletionenv}[1][]{%
+  \deletion[#1]{\BODY}%
+}%
+
+\newcommand\rebuttal at added[1]{%
+  \ifrebuttal at marked
+    \rebuttal at addition@font%
+    \textcolor{rebuttal at addition}{#1}%
+  \else
+    #1%
+  \fi
+}
+
+\newcommand\rebuttal at deleted[1]{%
+  \ifrebuttal at marked
+    \rebuttal at deletion@font%
+    \textcolor{rebuttal at deletion}{\rebuttal at delete{#1}}%
+  \fi
+}
+
+\newcommand\rebuttal at replaced[2]{%
+  \ifrebuttal at marked
+    \rebuttal at change@font%
+    \textcolor{rebuttal at change@from}{\rebuttal at changefrom{#1}}%
+    \allowbreak
+    \textcolor{rebuttal at change}{#2}%
+  \else
+    #2%
+  \fi
+}
+
+\rebuttal at command{addition}{\rebuttal at added{#2}}{2}
+\rebuttal at command{deletion}{\rebuttal at deleted{#2}}{2}
+\rebuttal at command{change}{\rebuttal at replaced{#2}{#3}}{3}
+
+\newcounter{rebuttalcomments}
+\newcounter{rebuttalchanges}
+
+\newcounter{rebuttal}
+\newcounter{rebuttalcomment}
+\newcounter{rebuttalanswer}
+
+\renewcommand\therebuttalcomment{%
+  \arabic{rebuttal}.\arabic{rebuttalcomment}%
+}
+
+\let\theHrebuttalcomment\therebuttalcomment
+
+\renewcommand\therebuttalanswer{%
+  \therebuttalcomment%
+}
+
+\counterwithin*{rebuttalcomment}{rebuttal}%
+\counterwithin*{rebuttalanswer}{rebuttalcomment}%
+
+\newdimen\rebuttal at labelsep
+
+% Disable hyperlinks if NoHyper environment is available
+\newcommand\rebuttal at startlinkguard{%
+  \ifx\NoHyper\@undefined\else
+    \ifrebuttal at nohyperlinks
+      \begin{NoHyper}%
+    \fi
+  \fi
+}
+
+% End of disable hyperlinks if NoHyper environment is available
+\newcommand\rebuttal at endlinkguard{
+  \ifx\endNoHyper\@undefined\else
+    \ifrebuttal at nohyperlinks
+      \end{NoHyper}%
+    \fi
+  \fi
+}
+
+% TODO Comment labels tooltips
+\newenvironment{rebuttal}[1][]{%
+  \rebuttal at startlinkguard
+  % Execute user code
+  \pgfkeysvalueof{/rebuttal/execute on begin}%
+  \begingroup
+  \refstepcounter{rebuttal}%
+  \if at twocolumn
+    \onecolumn
+    % Remember the layout
+    \rebuttal at twocolumntrue
+  \else
+    \rebuttal at twocolumnfalse
+  \fi
+  \begingroup
+  \par
+  \addvspace{\bigskipamount}%
+  \ifstrempty{#1}{}{%
+    \ifx\subpdfbookmark\@undefined\else
+      \subpdfbookmark{#1}{rebuttalcomment.\therebuttalcomment}%
+    \fi
+    \noindent\bgroup\rebuttal at titlefont\strut
+    \pgfkeys{/rebuttal/title/format=#1}\egroup%
+  }%
+  \par%
+  \@afterheading
+  \vspace*{\medskipamount}%
+  \begin{trivlist}%
+  \let\rebuttal at oldmakelabel\makelabel%
+  \renewcommand\makelabel[1]{\llap{\rebuttal at commentlabelfont ##1}}%
+  \labelwidth\z@
+  %\setlength{\parsep}{\smallskipamount}%
+  %\setlength{\labelsep}{1pt}%
+  %\setlength{\topsep}{\z@}%
+  %\setlength{\partopsep}{\bigskipamount}
+  \let\comment\@undefined
+  \let\endcomment\@undefined
+  \newenvironment{comment}{%
+    \rebuttal at incbookmarklevel
+    \apptocmd\@item{%
+      \ifx\currentpdfbookmark\@undefined\else
+        \currentpdfbookmark{Comment~\therebuttalcomment}{rebuttalcomment.\therebuttalcomment}%
+      \fi
+    }{%
+      \PackageInfo{rebuttal}{The \string\@item\space command was patched to
+        provide comment bookmarks.}%
+    }{%
+      \PackageWarning{rebuttal}{Failed to patch the \string\@item\space command.
+        Bookmarks may not be displayed correctly.}%
+    }%
+    % Do not allow to place answers within a comment by undefining the answer
+    % environment
+    \let\answer\@undefined
+    \let\endanswer\@undefined
+    \stepcounter{rebuttalcomments}%
+    \refstepcounter{rebuttalcomment}
+    %\settowidth{\labelwidth}{\rebuttal at commentlabelfont #1}
+    %\addtolength{\labelwidth}{1em}
+    \item
+    [%
+      \therebuttalcomment%
+    ]%
+    \begingroup
+    \rebuttal at commentfont
+    \let\makelabel\rebuttal at oldmakelabel
+  }{%
+    \endgroup
+    \rebuttal at decbookmarklevel
+  }
+  \newenvironment{answer}{%
+    \par\medskip
+    \@afterheading
+    \rebuttal at incbookmarklevel
+    \begin{trivlist}
+      \ifx\belowpdfbookmark\@undefined\else
+        \belowpdfbookmark{Anwser to~\therebuttalcomment}{rebuttalanswer.\therebuttalanswer}%
+      \fi
+      \normalfont\rebuttal at answerfont%
+      \rebuttal at labelsep\labelsep%
+      \newcommand\rebuttal at makelabel[1]{\rebuttal at answerlabelfont ####1\enspace}
+      \renewcommand\makelabel[1]{\rebuttal at makelabel{####1}}%
+      \labelsep\z@
+      \labelwidth\z@
+      \let\makelabel\empty
+      %\settowidth\labelwidth{\rebuttal at makelabel{\rebuttal at answerlabel}}%
+      \item
+        [%
+          \ifx\pdftooltip\@undefined
+            \llap{\rebuttal at answerlabel\enspace}%
+          \else
+            \llap{\pdftooltip{\rebuttal at answerlabel}{Reply}\enspace}%
+          \fi
+        ]%
+        \begingroup
+        \labelsep\rebuttal at labelsep
+        \refstepcounter{rebuttalanswer}%
+  }{%
+    \endgroup
+    \end{trivlist}%
+    \rebuttal at decbookmarklevel
+  }
+}{%
+  \end{trivlist}%
+  \rebuttal at decbookmarklevel
+  \endgroup
+  \par\addvspace{\bigskipamount}%
+  \ifrebuttal at twocolumn
+    % Restore the layout
+    \twocolumn
+  \fi
+  \endgroup
+  % Execute user code
+  \pgfkeysvalueof{/rebuttal/execute on end}%
+  \rebuttal at endlinkguard
+}
+
+% Support cleveref
+\AtEndPreamble{%
+  \@ifpackageloaded{cleveref}{%
+    \crefname{rebuttalcomment}{comment}{comments}
+    \crefname{rebuttalanswer}{answer}{answers}
+    \Crefname{rebuttalcomment}{Comment}{Comments}
+    \Crefname{rebuttalanswer}{Answer}{Answers}
+  }{}
+}
+
+\newcommand\rebuttaltotalcomments{%
+  \textbf{??}%
+  \@latex at warning{Reference \string\rebuttaltotalcomments\space on page \thepage\space undefined}%
+}
+
+\newcommand\rebuttaltotalchanges{%
+  \textbf{??}%
+  \@latex at warning{Reference \string\rebuttaltotalchanges\space on page \thepage\space undefined}%
+}
+
+\AtEndDocument{%
+  \immediate\write\@auxout{%
+    \gdef\string\rebuttaltotalcomments{\arabic{rebuttalcomments}}%
+    \gdef\string\rebuttaltotalchanges{\arabic{rebuttalchanges}}%
+  }
+}
+
+\newcommand\rebuttalset[1]{%
+  \pgfqkeys{/rebuttal}{#1}%
+}
+%</package>
+%<*example1>
+\documentclass[american,version=last,fromphone,fromemail,svgnames,dvipsnames,x11names]{scrlttr2}
+\usepackage[T1]{fontenc}
+\usepackage[utf8]{inputenc}
+\usepackage[babel]{csquotes}
+\usepackage{babel}
+\usepackage{graphicx}
+\usepackage{microtype}
+\usepackage{lipsum}
+\usepackage{rebuttal}
+\usepackage{varioref}
+\usepackage{hyperref}
+\usepackage{cleveref}
+
+\hypersetup{colorlinks=true}
+
+\setkomavar{fromname}{Jane Smith}
+\setkomavar{fromaddress}{%
+  Pattern Recognition Lab\\
+  University of Erlangen-Nürnberg
+}
+\setkomavar{backaddress}{}
+\setkomavar{fromphone}{$+49$\,(0)\,12345678}
+\setkomavar{fromemail}{firstname.lastname at fau.de}
+\setkomavar{place}{Erlangen}
+
+\begin{document}
+
+\setkomavar{subject}{Manuscript: Extended Field of View in C-Arm Computed
+  Tomography for Weight-Bearing Imaging}
+
+\begin{letter}{Medical Physics}
+
+\opening{Dear Prof. Jones, Dear Prof. Taylor,}
+
+We thank you for considering our submission as a research article for Medical
+Physics. We also thank the reviewers for the thoughtful comments. We have
+carefully revised the document and prepared a point-by-point response to the
+reviewer’s comments.
+
+The major changes to the paper are:
+\begin{itemize}
+  \item Clarification of the medical impact
+  \item An extension of the evaluation and discussion to 3D Cone Beam CT and
+    off-center positioning of the object
+  \item Inclusion of more substantive figure captions
+\end{itemize}
+
+Below, you will find the reviewers’ comments in blue, our response in normal
+face and additions to the manuscript in quotes and \enquote{italic face.} Note
+that we omitted footnotes and references in the quotations.
+
+We are looking forward to hearing from you.
+
+\closing{With kind regards,}
+
+\end{letter}
+
+\clearpage\noindent The following pages contain a list of editor's and
+reviewers' comments followed by our replies. The comments are sequentially
+numbered and associated either with the editor or the corresponding reviewer.
+The replies may contain references to changes in the original manuscript which
+are identified by a label consisting of a running number and followed by the
+label of the original comment in parentheses. The label back references the
+original reviewer comment within the manuscript. For instance, the reference
+\textbf{C2~(1.3)}, which is typeset in the manuscript margin, refers to the
+second change stemming from the third comment of the first reviewer.
+
+\begin{rebuttal}[Editor's Comments]
+  \begin{comment}
+  The topic of this manuscript is of interest. We concur with the summary review
+  of the associate editor and the reviews of the referees. The authors should
+  thoroughly address all of the comments, below, in a revised manuscript.
+  \end{comment}
+
+\end{rebuttal}
+
+\begin{rebuttal}[Specific Comments]
+  \begin{comment}
+  \label{c:specific}
+  You need to include figure captions that make your figures intelligible.
+  See~\cref{a:foo} and \cref{c:foo2}.
+  \end{comment}
+
+  \begin{answer}
+    The reviewer is right. We have reworked the figure captions to make the
+    figures more independent of the text. Furthermore, check if lists are
+    typeset correctly:
+    \begin{itemize}
+      \item One
+      \item Two
+        \begin{enumerate}
+          \item Three
+          \item Four
+        \end{enumerate}
+    \end{itemize}
+  \end{answer}
+
+  \begin{comment}
+    \label{c:c2}
+    Are you going to pay for color in the print article? If not, the lines are
+    not intelligible in Figures 2, 5, 11. In addition to color coding for the
+    digital version, you could make lines with distinct patterns (dots, dashes,
+    etc.) so they are distinct in monochrome presentations.
+  \end{comment}
+
+  \begin{answer}
+    We agree with this point and we are sorry that we missed this in the first
+    version of the article. The article will appear as an online only version
+    and is part of the special issue associated with this year’s CT Meeting
+    conference. Thus there will be no additional cost associated with color
+    figures. Nonetheless, we agree that all figures need to be correct in
+    grey-scale as some readers might print the article. According to the
+    reviewer’s comment, we have adjusted the figures by using different patterns
+    and gray levels.
+
+    (Refer also to \cref{c:specific} for more information.)
+  \end{answer}
+\end{rebuttal}
+
+\lipsum[1] \addition[label=a:foo,ref=c:specific]{\lipsum[2]} \lipsum[3]
+
+\lipsum[4] \deletion[label=a:foo1,ref=c:c2]{An unintended addition.}
+and a \change[label=c:foo2,ref=c:c2]{from}{to} change. And another addition
+\addition[label=a:foo3,ref=c:c2]{here}.
+Also \addition[label=a:foo4,ref=c:c2]{here}.
+Maybe \addition[label=a:foo5,ref=c:c2]{here}.
+Additionally \addition[label=a:foo6,ref=c:c2]{here}.
+Additionally \addition[label=a:foo7,ref=c:c2]{here}.
+
+\begin{additionenv}[label=d:par,ref=c:c2]
+  \begin{itemize}
+    \item \lipsum[1]
+  \end{itemize}
+  \lipsum[2]
+\end{additionenv}
+
+Additional notes:
+\begin{itemize}
+  \item Multiple source references can be
+    \addition[label=a:foo8,ref={c:specific,c:c2}]{specified}.
+  \item If the references do not fit into a single line in the margin, you may
+    force a \addition[label=a:break,ref={c:specific,c:c2},break]{break}.
+\end{itemize}
+
+\end{document}
+%</example1>
+%    \end{macrocode}
+%
+% vim: ft=tex


Property changes on: trunk/Master/texmf-dist/source/latex/rebuttal/rebuttal.dtx
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/source/latex/rebuttal/rebuttal.ins
===================================================================
--- trunk/Master/texmf-dist/source/latex/rebuttal/rebuttal.ins	                        (rev 0)
+++ trunk/Master/texmf-dist/source/latex/rebuttal/rebuttal.ins	2024-11-03 21:06:10 UTC (rev 72758)
@@ -0,0 +1,60 @@
+%%
+%% Copyright (C) 2024 by Sergiu Deitsch
+%%
+%% This work may be distributed and/or modified under the
+%% conditions of the LaTeX Project Public License, either version 1.3
+%% of this license or (at your option) any later version.
+%% The latest version of this license is in
+%%   http://www.latex-project.org/lppl.txt
+%% and version 1.3 or later is part of all distributions of LaTeX
+%% version 2005/12/01 or later.
+%%
+
+\input docstrip.tex
+
+\keepsilent
+\askforoverwritefalse
+
+\usedir{tex/latex/rebuttal}
+
+\preamble
+
+Copyright (C) 2018-2021, 2024 Sergiu Deitsch
+
+This work may be distributed and/or modified under the
+conditions of the LaTeX Project Public License, either version 1.3
+of this license or (at your option) any later version.
+The latest version of this license is in
+  http://www.latex-project.org/lppl.txt
+and version 1.3 or later is part of all distributions of LaTeX
+version 2005/12/01 or later.
+
+This work has the LPPL maintenance status `maintained'.
+
+The Current Maintainer of this work is Sergiu Deitsch.
+
+This work consists of the files rebuttal.dtx and rebuttal.ins.
+
+\endpreamble
+
+\generate{
+  \file{rebuttal.sty}{\from{rebuttal.dtx}{package}}
+  \file{01-example.tex}{\from{rebuttal.dtx}{example1}}
+}
+
+\obeyspaces
+\Msg{*************************************************************}
+\Msg{*                                                           *}
+\Msg{* To finish the installation you have to move the following *}
+\Msg{* file into a directory searched by TeX:                    *}
+\Msg{*                                                           *}
+\Msg{*     rebuttal.sty                                          *}
+\Msg{*                                                           *}
+\Msg{* To produce the documentation run the file rebuttal.dtx    *}
+\Msg{* through LaTeX.                                            *}
+\Msg{*                                                           *}
+\Msg{* Happy TeXing!                                             *}
+\Msg{*                                                           *}
+\Msg{*************************************************************}
+
+\endbatchfile

Added: trunk/Master/texmf-dist/tex/latex/rebuttal/rebuttal.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/rebuttal/rebuttal.sty	                        (rev 0)
+++ trunk/Master/texmf-dist/tex/latex/rebuttal/rebuttal.sty	2024-11-03 21:06:10 UTC (rev 72758)
@@ -0,0 +1,474 @@
+%%
+%% This is file `rebuttal.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% rebuttal.dtx  (with options: `package')
+%% 
+%% Copyright (C) 2018-2021, 2024 Sergiu Deitsch
+%% 
+%% This work may be distributed and/or modified under the
+%% conditions of the LaTeX Project Public License, either version 1.3
+%% of this license or (at your option) any later version.
+%% The latest version of this license is in
+%%   http://www.latex-project.org/lppl.txt
+%% and version 1.3 or later is part of all distributions of LaTeX
+%% version 2005/12/01 or later.
+%% 
+%% This work has the LPPL maintenance status `maintained'.
+%% 
+%% The Current Maintainer of this work is Sergiu Deitsch.
+%% 
+%% This work consists of the files rebuttal.dtx and rebuttal.ins.
+%% 
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesPackage{rebuttal}
+   [2024-11-01 v0.1.0 Markup for rebuttal letters]
+
+\PassOptionsToPackage{dvipsnames,svgnames,x11names}{xcolor}
+
+\RequirePackage{calc}
+\RequirePackage{environ}
+\RequirePackage{etoolbox}
+\RequirePackage{marginnote}
+\RequirePackage{pgfkeys}
+\RequirePackage{soul}
+\RequirePackage{tikz}
+\RequirePackage{todonotes}
+\RequirePackage{ulem}
+\RequirePackage{xcolor}
+\RequirePackage{xstring}
+
+\AtEndPreamble{
+  \RequirePackage{pdfcomment}
+}
+
+\ifx\counterwithin\@undefined
+\RequirePackage{chngcntr}
+\fi
+
+\newcommand\rebuttal at triangle{%
+  \begingroup
+  \ifx\tikzexternaldisable\@undefined\else
+    \tikzexternaldisable
+  \fi
+  \begin{tikzpicture}[x=.5em,y=.5em]
+    \fill[/rebuttal/answer/label] (0,0) -- (0,1) -- (.75,.5) -- cycle;
+  \end{tikzpicture}%
+  \endgroup
+}
+
+\newcommand\rebuttal at decbookmarklevel{%
+  \ifx\Hy at currentbookmarklevel\@undefined\else
+    \@tempcnta\Hy at currentbookmarklevel
+    \advance\@tempcnta by -1 %
+    \xdef\Hy at currentbookmarklevel{\the\@tempcnta}%
+  \fi
+}
+
+\newcommand\rebuttal at incbookmarklevel{%
+  \ifx\Hy at currentbookmarklevel\@undefined\else
+    \@tempcnta\Hy at currentbookmarklevel
+    \advance\@tempcnta by 1 %
+    \xdef\Hy at currentbookmarklevel{\the\@tempcnta}%
+  \fi
+}
+
+\newif\ifrebuttal at marked
+\newif\ifrebuttal at nohyperlinks
+\newif\ifrebuttal at refbreak
+\newif\ifrebuttal at twocolumn
+
+\pgfkeys{
+  /rebuttal/.is family,
+  /rebuttal/execute on begin/.initial=,
+  /rebuttal/execute on end/.initial=,
+  /rebuttal/no hyperlinks/.is if=rebuttal at nohyperlinks,
+  /rebuttal/no hyperlinks=false,
+  /rebuttal/marked/.is if=rebuttal at marked,
+  /rebuttal/marked=true,
+  /rebuttal/title/font/.store in=\rebuttal at titlefont,
+  /rebuttal/title/font=\normalfont\bfseries,
+  /rebuttal/title/format/.code=#1:,
+  /rebuttal/change/from command/.store in=\rebuttal at changefrom,
+  /rebuttal/change/from command=\sout,
+  /rebuttal/change/from color/.code={\colorlet{rebuttal at change@from}{#1}},
+  /rebuttal/change/from color=DodgerBlue3!50,
+  /rebuttal/deletion/command/.store in=\rebuttal at delete,
+  /rebuttal/deletion/command=\xout,
+  /rebuttal/comment/font/.store in=\rebuttal at commentfont,
+  /rebuttal/comment/font=\normalfont\itshape,
+  /rebuttal/comment/label/font/.store in=\rebuttal at commentlabelfont,
+  /rebuttal/comment/label/font=\normalfont\rmfamily\bfseries,
+  /rebuttal/answer/font/.store in=\rebuttal at answerfont,
+  /rebuttal/answer/font=\normalfont,
+  /rebuttal/answer/label/.store in=\rebuttal at answerlabel,
+  /rebuttal/answer/label={\rebuttal at triangle},
+  /rebuttal/answer/label/font/.store in=\rebuttal at answerlabelfont,
+  /rebuttal/answer/label/font=\normalfont,
+  /rebuttal/answer/label/.style={black!65},
+  /rebuttal/reference/font/.store in=\rebuttal at referencefont,
+  /rebuttal/reference/font={%
+    \tiny\bfseries%
+  },
+  % TODO does not work within \todo
+  %/rebuttal/reference/.code={%
+  %},
+}
+
+\let\rebuttalanswerlabel\rebuttal at answerlabel
+
+\newrobustcmd\rebuttal at reference[1]{%
+  \begingroup
+  \rebuttal at referencefont
+  \begin{tabular}{@{}c@{}}
+    \begingroup
+      \color{rebuttal@#1}%
+      \MakeUppercase{\rebuttal at id}%
+      \csname therebuttal#1\endcsname
+    \endgroup
+    \ifrebuttal at refbreak
+      \\%
+    \else
+      \enspace
+    \fi
+    \normalfont
+    % Reset color (TODO Maybe allow to modify the color)
+    \color{black}%
+    (\pgfkeys{/rebuttal/#1/ref/all})%
+  \end{tabular}%
+  \endgroup
+}
+
+\newcommand\rebuttal at define@keys[2]{
+  \pgfkeys{
+    /rebuttal/#1/label/.initial=,
+    /rebuttal/#1/label/.value required,
+    /rebuttal/#1/break/.is if=rebuttal at refbreak,
+    /rebuttal/#1/ref/.initial=,
+    /rebuttal/#1/ref/.value required,
+    /rebuttal/#1/ref/create/.code={
+      \ifrebuttal at nohyperlinks
+        \ref*{##1}%
+      \else
+        \ref{##1}%
+      \fi
+    },
+    /rebuttal/#1/ref/all/.code={%
+      \pgfkeysgetvalue{/rebuttal/#1/ref}\rebuttal at currefs
+      \edef\rebuttal at tmp{\rebuttal at currefs}%
+      \foreach
+      [
+        %expand list,
+        count=\ri from 0,
+      ]
+      \r in \rebuttal at tmp {%
+        \ifnum\ri > 0\relax
+          ,\,%
+        \fi
+        \pgfkeys{/rebuttal/#1/ref/create=\r}%
+      }%
+    },
+    /rebuttal/#1/color/.code={\colorlet{rebuttal@#1}{##1}},
+    /rebuttal/#1/color=#2,
+    /rebuttal/#1/font/.value required,
+    /rebuttal/#1/font/.code={
+      \expandafter\def\csname rebuttal@#1 at font\endcsname{##1}%
+    },
+    /rebuttal/#1/font=\normalfont\mdseries,
+  }
+}
+
+\rebuttal at define@keys{addition}{RedViolet}
+\rebuttal at define@keys{deletion}{Firebrick3}
+\rebuttal at define@keys{change}{DodgerBlue3}
+
+\newlength\rebuttal at textwidth
+\newlength\rebuttal at hskip
+
+\newcommand\rebuttal at command[3]{%
+  \newcounter{rebuttal#1}%
+  \AtEndPreamble{%
+    \@ifpackageloaded{cleveref}{%
+      \crefname{rebuttal#1}{#1}{#1s}%
+    }{}%
+  }%
+  % Marked version with full output
+  \expandafter\newcommand\csname #1\endcsname[#3][]{%
+    \ifrebuttal at marked
+      \stepcounter{rebuttalchanges}%
+      \refstepcounter{rebuttal#1}%
+      \begingroup
+        \tikzset{notestyleraw/.append style={
+          inner sep=\z@,
+          rounded corners=\z@,
+        }}%
+        \pgfqkeys{/rebuttal/#1}{##1}%
+        \label{\pgfkeysvalueof{/rebuttal/#1/label}}%
+        \colorlet{Changes at Color}{rebuttal@#1}%
+        \begingroup
+          % Main content
+          #2%
+        \endgroup
+        \StrLeft{#1}{1}[\rebuttal at id]%
+        \ifx\tikzexternaldisable\@undefined\else
+          \tikzexternaldisable
+        \fi
+        % Shrink to text
+        \settowidth\rebuttal at textwidth{\rebuttal at reference{#1}}%
+        \tikzset{notestyleraw/.append style={text width=\rebuttal at textwidth}}%
+        % Place labels in left margin at the same distance as on the right
+        \setlength\rebuttal at hskip{\marginparwidth}%
+        \addtolength\rebuttal at hskip{-\rebuttal at textwidth}%
+        \let\old at xmpar\@xmpar
+        % Hook into LaTeX kernel command since \if at firstcolumn is not unreliable
+        % because margin notes are floats.
+        \renewcommand\@xmpar[2][]{%
+          \old at xmpar[\hspace*{\rebuttal at hskip}####1]{####2}%
+        }%
+        \todo
+        [
+          backgroundcolor=none,
+          bordercolor=none,
+          linecolor=rebuttal@#1,
+          %size=\tiny,
+        ]{%
+          \rebuttal at reference{#1}%
+          %\pgfkeys{/rebuttal/reference=#1}
+        }%
+      \endgroup
+    \else
+      #2%
+    \fi
+  }%
+}
+
+\NewEnviron{additionenv}[1][]{%
+  \addition[#1]{\BODY}%
+}%
+
+\NewEnviron{changeenv}[2][]{%
+  \change[#1]{#2}{\BODY}%
+}%
+
+\NewEnviron{deletionenv}[1][]{%
+  \deletion[#1]{\BODY}%
+}%
+
+\newcommand\rebuttal at added[1]{%
+  \ifrebuttal at marked
+    \rebuttal at addition@font%
+    \textcolor{rebuttal at addition}{#1}%
+  \else
+    #1%
+  \fi
+}
+
+\newcommand\rebuttal at deleted[1]{%
+  \ifrebuttal at marked
+    \rebuttal at deletion@font%
+    \textcolor{rebuttal at deletion}{\rebuttal at delete{#1}}%
+  \fi
+}
+
+\newcommand\rebuttal at replaced[2]{%
+  \ifrebuttal at marked
+    \rebuttal at change@font%
+    \textcolor{rebuttal at change@from}{\rebuttal at changefrom{#1}}%
+    \allowbreak
+    \textcolor{rebuttal at change}{#2}%
+  \else
+    #2%
+  \fi
+}
+
+\rebuttal at command{addition}{\rebuttal at added{#2}}{2}
+\rebuttal at command{deletion}{\rebuttal at deleted{#2}}{2}
+\rebuttal at command{change}{\rebuttal at replaced{#2}{#3}}{3}
+
+\newcounter{rebuttalcomments}
+\newcounter{rebuttalchanges}
+
+\newcounter{rebuttal}
+\newcounter{rebuttalcomment}
+\newcounter{rebuttalanswer}
+
+\renewcommand\therebuttalcomment{%
+  \arabic{rebuttal}.\arabic{rebuttalcomment}%
+}
+
+\let\theHrebuttalcomment\therebuttalcomment
+
+\renewcommand\therebuttalanswer{%
+  \therebuttalcomment%
+}
+
+\counterwithin*{rebuttalcomment}{rebuttal}%
+\counterwithin*{rebuttalanswer}{rebuttalcomment}%
+
+\newdimen\rebuttal at labelsep
+
+\newcommand\rebuttal at startlinkguard{%
+  \ifx\NoHyper\@undefined\else
+    \ifrebuttal at nohyperlinks
+      \begin{NoHyper}%
+    \fi
+  \fi
+}
+
+\newcommand\rebuttal at endlinkguard{
+  \ifx\endNoHyper\@undefined\else
+    \ifrebuttal at nohyperlinks
+      \end{NoHyper}%
+    \fi
+  \fi
+}
+
+\newenvironment{rebuttal}[1][]{%
+  \rebuttal at startlinkguard
+  % Execute user code
+  \pgfkeysvalueof{/rebuttal/execute on begin}%
+  \begingroup
+  \refstepcounter{rebuttal}%
+  \if at twocolumn
+    \onecolumn
+    % Remember the layout
+    \rebuttal at twocolumntrue
+  \else
+    \rebuttal at twocolumnfalse
+  \fi
+  \begingroup
+  \par
+  \addvspace{\bigskipamount}%
+  \ifstrempty{#1}{}{%
+    \ifx\subpdfbookmark\@undefined\else
+      \subpdfbookmark{#1}{rebuttalcomment.\therebuttalcomment}%
+    \fi
+    \noindent\bgroup\rebuttal at titlefont\strut
+    \pgfkeys{/rebuttal/title/format=#1}\egroup%
+  }%
+  \par%
+  \@afterheading
+  \vspace*{\medskipamount}%
+  \begin{trivlist}%
+  \let\rebuttal at oldmakelabel\makelabel%
+  \renewcommand\makelabel[1]{\llap{\rebuttal at commentlabelfont ##1}}%
+  \labelwidth\z@
+  %\setlength{\parsep}{\smallskipamount}%
+  %\setlength{\labelsep}{1pt}%
+  %\setlength{\topsep}{\z@}%
+  %\setlength{\partopsep}{\bigskipamount}
+  \let\comment\@undefined
+  \let\endcomment\@undefined
+  \newenvironment{comment}{%
+    \rebuttal at incbookmarklevel
+    \apptocmd\@item{%
+      \ifx\currentpdfbookmark\@undefined\else
+        \currentpdfbookmark{Comment~\therebuttalcomment}{rebuttalcomment.\therebuttalcomment}%
+      \fi
+    }{%
+      \PackageInfo{rebuttal}{The \string\@item\space command was patched to
+        provide comment bookmarks.}%
+    }{%
+      \PackageWarning{rebuttal}{Failed to patch the \string\@item\space command.
+        Bookmarks may not be displayed correctly.}%
+    }%
+    % Do not allow to place answers within a comment by undefining the answer
+    % environment
+    \let\answer\@undefined
+    \let\endanswer\@undefined
+    \stepcounter{rebuttalcomments}%
+    \refstepcounter{rebuttalcomment}
+    %\settowidth{\labelwidth}{\rebuttal at commentlabelfont #1}
+    %\addtolength{\labelwidth}{1em}
+    \item
+    [%
+      \therebuttalcomment%
+    ]%
+    \begingroup
+    \rebuttal at commentfont
+    \let\makelabel\rebuttal at oldmakelabel
+  }{%
+    \endgroup
+    \rebuttal at decbookmarklevel
+  }
+  \newenvironment{answer}{%
+    \par\medskip
+    \@afterheading
+    \rebuttal at incbookmarklevel
+    \begin{trivlist}
+      \ifx\belowpdfbookmark\@undefined\else
+        \belowpdfbookmark{Anwser to~\therebuttalcomment}{rebuttalanswer.\therebuttalanswer}%
+      \fi
+      \normalfont\rebuttal at answerfont%
+      \rebuttal at labelsep\labelsep%
+      \newcommand\rebuttal at makelabel[1]{\rebuttal at answerlabelfont ####1\enspace}
+      \renewcommand\makelabel[1]{\rebuttal at makelabel{####1}}%
+      \labelsep\z@
+      \labelwidth\z@
+      \let\makelabel\empty
+      %\settowidth\labelwidth{\rebuttal at makelabel{\rebuttal at answerlabel}}%
+      \item
+        [%
+          \ifx\pdftooltip\@undefined
+            \llap{\rebuttal at answerlabel\enspace}%
+          \else
+            \llap{\pdftooltip{\rebuttal at answerlabel}{Reply}\enspace}%
+          \fi
+        ]%
+        \begingroup
+        \labelsep\rebuttal at labelsep
+        \refstepcounter{rebuttalanswer}%
+  }{%
+    \endgroup
+    \end{trivlist}%
+    \rebuttal at decbookmarklevel
+  }
+}{%
+  \end{trivlist}%
+  \rebuttal at decbookmarklevel
+  \endgroup
+  \par\addvspace{\bigskipamount}%
+  \ifrebuttal at twocolumn
+    % Restore the layout
+    \twocolumn
+  \fi
+  \endgroup
+  % Execute user code
+  \pgfkeysvalueof{/rebuttal/execute on end}%
+  \rebuttal at endlinkguard
+}
+
+\AtEndPreamble{%
+  \@ifpackageloaded{cleveref}{%
+    \crefname{rebuttalcomment}{comment}{comments}
+    \crefname{rebuttalanswer}{answer}{answers}
+    \Crefname{rebuttalcomment}{Comment}{Comments}
+    \Crefname{rebuttalanswer}{Answer}{Answers}
+  }{}
+}
+
+\newcommand\rebuttaltotalcomments{%
+  \textbf{??}%
+  \@latex at warning{Reference \string\rebuttaltotalcomments\space on page \thepage\space undefined}%
+}
+
+\newcommand\rebuttaltotalchanges{%
+  \textbf{??}%
+  \@latex at warning{Reference \string\rebuttaltotalchanges\space on page \thepage\space undefined}%
+}
+
+\AtEndDocument{%
+  \immediate\write\@auxout{%
+    \gdef\string\rebuttaltotalcomments{\arabic{rebuttalcomments}}%
+    \gdef\string\rebuttaltotalchanges{\arabic{rebuttalchanges}}%
+  }
+}
+
+\newcommand\rebuttalset[1]{%
+  \pgfqkeys{/rebuttal}{#1}%
+}
+\endinput
+%%
+%% End of file `rebuttal.sty'.


Property changes on: trunk/Master/texmf-dist/tex/latex/rebuttal/rebuttal.sty
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Modified: trunk/Master/tlpkg/bin/tlpkg-ctan-check
===================================================================
--- trunk/Master/tlpkg/bin/tlpkg-ctan-check	2024-11-03 21:05:30 UTC (rev 72757)
+++ trunk/Master/tlpkg/bin/tlpkg-ctan-check	2024-11-03 21:06:10 UTC (rev 72758)
@@ -736,7 +736,8 @@
   r_und_s ragged2e raleway ran_toks randbild randexam randintlist
     random randomlist randomwalk randtext
     rank-2-roots rbt-mathnotes rccol rcs rcs-multi rcsinfo
-    readablecv readarray realboxes realhats realscripts realtranspose rec-thy
+    readablecv readarray realboxes realhats realscripts realtranspose
+    rebuttal rec-thy
     recipe recipebook recipecard recorder-fingering recycle rectopma
     refcheck refcount refenums reflectgraphics refman refstyle
     regcount regexpatch register regstats regulatory

Modified: trunk/Master/tlpkg/tlpsrc/collection-publishers.tlpsrc
===================================================================
--- trunk/Master/tlpkg/tlpsrc/collection-publishers.tlpsrc	2024-11-03 21:05:30 UTC (rev 72757)
+++ trunk/Master/tlpkg/tlpsrc/collection-publishers.tlpsrc	2024-11-03 21:06:10 UTC (rev 72758)
@@ -189,6 +189,7 @@
 depend ptptex
 depend qrbill
 depend quantumarticle
+depend rebuttal
 depend regulatory
 depend resphilosophica
 depend resumecls

Added: trunk/Master/tlpkg/tlpsrc/rebuttal.tlpsrc
===================================================================


More information about the tex-live-commits mailing list.