how to zoom in/zoomout of a picture using mouse scroll
Hi,
I have a picture displayed on a label.There are zoomin/zoomout buttons (which are functioning properly).I want to implement this feature--scroll the mouse button up(anticlockwise) and you zoomin on the pic and zoomout when you scroll down(clockwise).
I was advised to try out QWheelEvent class but,haven't got much idea of how to implement this feature.
Please advice on how to proceed.
Thanks.
Re: how to zoom in/zoomout of a picture using mouse scroll
Create a subclass of QWidget or QLabel and re-implement the wheelEvent function
From this function you can call the same functions/slots that your buttons call to zoom in and zoom out.
Re: how to zoom in/zoomout of a picture using mouse scroll
Hi,thanks for the prompt reply.I will give it a shot .