문제

Is there a way to resize the canvas of a QPixmap, similar to how an image editor does it - by padding and clipping the image as necessary, but not scaling it?

If not, I assume I should create a new (compatible) QPixmap, and use QPainter::drawPixmap() to place the original image appropriately.

도움이 되었습니까?

해결책

No, there is no such option. You need to create another pixmap and use drawPixmap as you said.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top