You are here

24 December 2014

How to display an image in Python. Using PyQt5 application window.

Source code viewer
  1. #import os
  2. #from PyQt5.QtGui import QPixmap
  3. #from PyQt5.QtWidgets import QLabel
  4.  
  5. label = QLabel(window)
  6. pixmap = QPixmap(os.getcwd() + '/test.jpg')
  7. label.setPixmap(pixmap)
Programming Language: Python