improved legend.titles todo legend.config