Results 1 to 20 of 24

Thread: VistaGlassButton widget for Qt 4

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Sep 2007
    Location
    Rome, GA
    Posts
    199
    Thanks
    14
    Thanked 41 Times in 35 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default VistaGlassButton widget for Qt 4

    For a current project I subclassed a QPushButton and re-painted it to look like a Vista Aero glass button. You use it like a normal QPushButton, except there are two public methods - setColor(QColor color) and setShadow(QColor shadow). Color is the red area in the image below, Shadow is the black center. Anyway, I thought it might come in handy for people wanting a look like this or for anyone wondering how to go about redrawing a widget:



    You can download the class here:

    http://www.mediafire.com/?e2v82uujtin

    Enjoy!


    *I haven't tested this class extensively, but it works okay for normal-looking buttons. If you start doing crazy things with it, however, it might go wonky. Feel free to modify/improve to your heart's content...
    Last edited by JimDaniel; 13th February 2008 at 06:00.

  2. The following 3 users say thank you to JimDaniel for this useful post:

    ComaWhite (15th March 2008), giowck (29th May 2010), THRESHE (10th March 2008)

Similar Threads

  1. Tricky problem with ARGB widget / UpdateLayeredWindow
    By nooky59 in forum Qt Programming
    Replies: 3
    Last Post: 21st February 2008, 10:35
  2. Custom widget
    By zorro68 in forum Qt Programming
    Replies: 7
    Last Post: 28th January 2008, 14:06
  3. Replies: 3
    Last Post: 17th October 2007, 12:52
  4. transparent background of the main widget
    By nagpalma in forum Qt Programming
    Replies: 2
    Last Post: 4th May 2007, 17:52
  5. [Qt 4.1.0] Split a widget on demand
    By Townk in forum Qt Programming
    Replies: 3
    Last Post: 17th February 2006, 14:16

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.