Fix some issues related to cropping