Fix LabelVisualizer crash

#2223 introduced a regression (due to a typo) that was not covered by any unit tests. (which @shunter promptly ran into).  This change adds unit tests and fixed the bug.
Merge pull request #2235 from AnalyticalGraphicsInc/label-visualizer-crash

Fix LabelVisualizer crash