# Change textcolor between \cbstart and \cbend of package changebar

%! TEX program = lualatex
\documentclass[]{article}
\usepackage{luatex85}
\usepackage[xcolor,pdftex]{changebar}
\usepackage{lipsum}
\cbcolor{blue}

\begin{document}
\lipsum[2]
\cbstart
{\color{blue} % I want to remove this here and add a configuration to the preamble.
\lipsum[2]
}
\cbend
\lipsum[2]
\end{document}


I would like to automatically change the textcolor when I activate the changebar with \cbstart and switch back with \cbend.

• It won't work, at least not for all variants. \cbstart can start in a different grouping level than \cbend. But you could redefine the changebar environment to add a color. – Ulrike Fischer Mar 28 '17 at 11:57
• Thanks for your comment. I see. I will try out to use a renewed changebar environment. – Hotschke Mar 28 '17 at 11:59

My solution redefining the environment changebar as suggested by Ulrike Fischer:
\let\internchangebar\changebar