Fix #17912: display of "\n" in summary submenu

Regression introduced by 0552366c6e2aff04efd4d3ada7c794b6300bb8f5.