Dendrogram threshold color

This is a continuation of #3765, addressing comments and adding a unit test. I also rebased, squashed, and added the git commit message prefixes.