我使用 changes 包来跟踪期刊出版物的更改。一切运行顺利,但我遇到的问题在于,更改可以包含在环境中(图形、表格、摘要框),但无法显示备注,或者这会导致错误消息。
\documentclass{bmcart}
%%% Load packages
\usepackage{amsthm,amsmath}
%\RequirePackage{natbib}
%\RequirePackage[authoryear]{natbib}% uncomment this for author-year bibliography
%\RequirePackage{hyperref}
\usepackage[utf8]{inputenc} %unicode support
\usepackage[pdftex]{graphicx}
\usepackage{multirow}
\usepackage{rotating}
%%% tracking changes + settings
\usepackage[markup=underlined]{changes}
\definechangesauthor[color=green]{Author}
\definechangesauthor[color=blue]{R1}
\definechangesauthor[color=red]{R2}
\reversemarginpar
\setlength{\marginparwidth}{3.5cm}
%% Use "final" option to remove all tracking markups
% \usepackage[final]{changes}
%%% Alternative definition to have the remarks
%%% in the margins instead of footnotes
\usepackage{todonotes}
\setcommentmarkup{\todo[color={authorcolor!20},size=\scriptsize]{#3: #1}}
%%% Begin ...
\begin{document}
%%% Start of article front matter
\begin{frontmatter}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% %%
%% Enter the title of your article here %%
%% %%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\title{Tracking Changes}
\begin{abstractbox}
\begin{abstract} % abstract
\parttitle{Background} %if any
bla bla
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\parttitle{Method} %if any
bla bla
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\parttitle{Results} %if any
\replaced[id=R1,comment={1.1: I want more bla bla}]{new bla bla}{bla bla}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\parttitle{Conclusions} %if any
bla bla
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\end{abstract}
\end{abstractbox}
\end{frontmatter}
%%%%%%%%%%%%%%%%%%%%%%%%% start of article main body
%
% --- Background ---
%
\section*{Background}
bla bla
\end{document}
导致错误信息:
See the LaTeX manual or LaTeX Companion for explanation.
Type H <return> for immediate help.
...
l.551 \clearpage
You've lost some text. Try typing <return> to proceed.
If that doesn't work, type X <return> to quit.
如果我删除[id=R1,comment={1.1: I want more bla bla}]
它,一切都会顺利编译,但相应的位置却没有注释框。图表也是如此。
我已经进行了很多实验,但还没有找到解决方案。
答案1
我现在能够自己解决这个问题了。经过一番研究和反复试验,以下方法有效:
\usepackage{marginnote}\let\marginpar\marginnote
这允许在图形、表格和抽象框环境中使用 changes-package。