I have placed images in QLabel and want to view it larger when I clicks it ......
Printable View
I have placed images in QLabel and want to view it larger when I clicks it ......
What is the problem you have?
I want to perform click operation on QLabel so that the image I have used should become larger...I have used keyPressEvent(QKeyEvent *event) but Its not showing anything ....
show your code.
And where is the code that should enlarge the image ?
You have reimplemented keyPressEvent, which is responsible for keyboard events.
If you want to perform actions on mouse button click, you need to reimplement QWidget::mousePressEvent.Quote:
I want to perform click operation on QLabel so that the image I have used should become larger...I have used keyPressEvent(QKeyEvent *event) but Its not showing anything ....
Where is code that is supposed to enlarge the image?Quote:
I want to perform click operation on QLabel so that the image I have used should become larger
EDIT: oops, someone was faster :-)
thanks for your reply….Can you please give me a link related to keyPress and mousePressEvent or any example for this….