resized legend and partitions