Results 1 to 3 of 3

Thread: how to set the transparent of a bitmap to a cursor

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #3
    Join Date
    Jun 2010
    Location
    Salatiga, Indonesia
    Posts
    160
    Thanks
    11
    Thanked 32 Times in 29 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Wiki edits
    1

    Default Re: how to set the transparent of a bitmap to a cursor

    This is how i do it
    Qt Code:
    1. QPixmap pix(":/cur.bmp");
    2. pix.setMask(QBitmap(QPixmap(":/mask.bmp")));
    3. setCursor(QCursor(pix));
    To copy to clipboard, switch view to plain text mode 
    Attached Images Attached Images
    Last edited by saa7_go; 29th August 2010 at 06:23.

  2. The following user says thank you to saa7_go for this useful post:

    xiongxiongchuan (29th August 2010)

Similar Threads

  1. Saving Pimap to Bitmap
    By dbrmik in forum Newbie
    Replies: 3
    Last Post: 26th November 2008, 13:34
  2. Port MFC BITMAP Code to Qt?
    By pospiech in forum Qt Programming
    Replies: 3
    Last Post: 28th July 2008, 18:53
  3. Bitmap border
    By SailinShoes in forum Qt Programming
    Replies: 5
    Last Post: 14th May 2008, 18:37
  4. diplay and resize bitmap
    By tommy in forum Qt Programming
    Replies: 8
    Last Post: 14th November 2007, 17:35
  5. Bitmap buttons
    By BloodHo in forum Newbie
    Replies: 1
    Last Post: 4th November 2006, 14:17

Tags for this Thread

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
  •  
Qt is a trademark of The Qt Company.