pub fn set_capturing(on: bool) -> bool
Starts or stops redirecting output on this thread, and returns the setting that was in effect, so a caller can put it back.