Discussion Board

Results 1 to 3 of 3
  1. #1
    Registered User kamaljaiswal's Avatar
    Join Date
    Mar 2006
    Location
    India
    Posts
    503
    using QPixmap to load image not able to specify the path properly
    QPixmap image;

    image.load(":/icon.png");
    or
    image.load("icon.png")
    Regards
    Kamal :)
    ------------------
    You never expect what expects you.

  2. #2
    Registered User kamaljaiswal's Avatar
    Join Date
    Mar 2006
    Location
    India
    Posts
    503
    How to display an image as i am unable to display an image on widget ..
    Regards
    Kamal :)
    ------------------
    You never expect what expects you.

  3. #3
    Registered User Sorcery-ltd's Avatar
    Join Date
    Dec 2006
    Posts
    2,280
    Hi,

    Read that documentation about the Qt Resource Compiler and .qrc files. That compiles the images into the binary for you, then you should be able to access them using your original syntax.

    As an alternative, simple be sure to specify an absolute path and make sure you've put the image file in the appropriate place on the emulator or real device.

    Mark

Similar Threads

  1. Can i use c++ functions in Open C
    By yvsandeep in forum Open C/C++
    Replies: 16
    Last Post: 2008-11-03, 02:08
  2. Replies: 1
    Last Post: 2008-07-11, 02:32
  3. Using Icon as Image
    By korakotc in forum Python
    Replies: 6
    Last Post: 2006-02-13, 19:34
  4. image failed to load
    By killarkai in forum Mobile Java Media (Graphics & Sounds)
    Replies: 4
    Last Post: 2003-07-25, 13:07
  5. Image Uploader / Image Downloader / Image Server
    By kehong in forum Symbian C++
    Replies: 0
    Last Post: 2003-05-12, 17:38

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Nokia Developer aims to help you create apps and publish them so you can connect with users around the world.

京ICP备05048969号  © Copyright Nokia 2013 All rights reserved