fix #24672: Bar lines disappearing when hiding empty staves