Results 1 to 3 of 3

Thread: viewing jpeg-pictures on widgets

  1. #1
    Join Date
    Jan 2006
    Posts
    12
    Qt products
    Qt/Embedded
    Platforms
    Unix/X11

    Default viewing jpeg-pictures on widgets

    Can I view small jpeg-pictures straight to QWidget, or do I have to use something like QCanvas or any other method? I would like to have my program showing pictures pointing to key functionalities, like setting software configuration etc. So for example if I press a button besides a picture of pen on my widget, I'll have access to memo.

  2. #2
    Join Date
    Jan 2006
    Location
    travelling
    Posts
    1,116
    Thanks
    8
    Thanked 127 Times in 121 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: viewing jpeg-pictures on widgets

    use QPixmap or QImage, QLabel may work as well.
    Current Qt projects : QCodeEdit, RotiDeCode

  3. #3
    Join Date
    Jan 2006
    Posts
    12
    Qt products
    Qt/Embedded
    Platforms
    Unix/X11

    Default Re: viewing jpeg-pictures on widgets

    Quote Originally Posted by fullmetalcoder
    use QPixmap or QImage, QLabel may work as well.
    Thanks, I succesfully set a picture on label:

    setPixmap(QPixmap("jpg/picture.jpg"));

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.