improve legends