Added vertical trimming

Fixed up trimming