before initialising my label i made my widget to full screen.
my code:
widget.cpp
Qt Code:
  1. Widget::Widget(QWidget *parent) :
  2. QWidget(parent),
  3. ui(new Ui::Widget)
  4. {
  5.  
  6. showFullScreen();
  7. activateWindow();
  8. label=new QLabel(this);
  9.  
  10. }
To copy to clipboard, switch view to plain text mode 
displaying images in label:
Qt Code:
  1. void displayimages()
  2. {
  3. ImageToLoad.load(dir.absoluteFilePath(remoteimagefilename)); //image name
  4. label->setPixmap(QPixmap::fromImage(ImageToLoad.scaled(1025,1025,Qt::KeepAspectRatio,Qt::FastTransformation))); label->showFullScreen();
  5. }
To copy to clipboard, switch view to plain text mode 
mouseclick event
Qt Code:
  1. void Widget::mousePressEvent(QMouseEvent *event)
  2. {
  3. if (event->button() & (Qt::LeftButton | Qt::RightButton))
  4. {
  5. showMaximized();
  6. activateWindow();
  7. update();
  8.  
  9. }
  10. }
To copy to clipboard, switch view to plain text mode 
Quote Originally Posted by wysota View Post
What have you tried so far to solve your problem?