Layout problem
-
How can I best make this layout ? Using grid. And make all images with the same size and aspect ratio. If they have a different aspect ratio, then maybe a little crop, but also the same size, and when you increase or decrease the window, they automatically become larger or smaller for adaptive layout.
And there is another problem because of the pictures, my window is larger than the computer window, what could be the problem? Looks like that
-
Hi,
How are you doing it currently ?
One way is to paint the image on the widget yourself so you can manage the aspect ratio and paint them the way you want.
-
Hi,
How are you doing it currently ?
One way is to paint the image on the widget yourself so you can manage the aspect ratio and paint them the way you want.
-
I haven't said anything about layouts.
I am suggesting to subclass QWidget and reimplement the paint event. You might also want to consider reimplementing the resize event so you can ensure you have the image of the correct size to paint. Keep the original image as member variable so you can use a resized version of it for the painting.
Since you have at least three times the same widget, you should create a custom class that implements it and reuse it.
-
I haven't said anything about layouts.
I am suggesting to subclass QWidget and reimplement the paint event. You might also want to consider reimplementing the resize event so you can ensure you have the image of the correct size to paint. Keep the original image as member variable so you can use a resized version of it for the painting.
Since you have at least three times the same widget, you should create a custom class that implements it and reuse it.