1
$\begingroup$

I am writing a LaTeX document where the custom command \chg{...} highlights changes in some color. Here I am, with a document of about 50 of those. Sure, one could just remove "\chg" everywhere, but after a long history of collaborative editing blocks {...{like this}} keep piling up.

Here is an example:

str = "We extracted \\chg{geometrical statistics \\sout{summary geometric data}} using {Wolfram Mathematica}$^\\text{\\textregistered}$ 11.2."

Could it be automatically adapted so that the output is:

We extracted geometrical statistics \sout{summary geometric data} using {Wolfram Mathematica}$^\text{\textregistered}$ 11.2.

Is there a way to remove \chg{...} but keep its arguments in place? This question shows how to retrieve "\chg{correct!}" from "finally \chg{correct!}", but I couldn't quite work out how to retrieve "finally correct!".

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.