Results 1 to 4 of 4

Thread: QPushButton with image - text alignment

  1. #1
    Join Date
    Oct 2006
    Posts
    12
    Thanked 3 Times in 2 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default QPushButton with image - text alignment

    Is it possible (Qt 4.4) to have QPushButton with image, but with text below or above the image using code, css, ... ?

  2. #2
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    6,264
    Thanks
    36
    Thanked 1,519 Times in 1,389 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Maemo/MeeGo

    Default Re: QPushButton with image - text alignment

    At least it's possible with QToolButton.
    J-P Nurmi

  3. #3
    Join Date
    Oct 2006
    Posts
    12
    Thanked 3 Times in 2 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QPushButton with image - text alignment

    Yeah, you are right about that, but toolbutton has 1-2px of (image/text) translation - pushbutton doesn't (which i prefer and need). is it possible to disable this translation using css (so that when i press toolbutton it is rendered without image/text translation)?

  4. #4
    Join Date
    Jun 2009
    Posts
    1
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: QPushButton with image - text alignment

    I sher the same need to have Icon above text - though I did not understood what you meant by - but toolbutton has 1-2px of (image/text) translation. Can you explained or point me where I can read about that.

Similar Threads

  1. Unhandled exception in qatomic
    By NewGuy in forum Qt Programming
    Replies: 14
    Last Post: 23rd July 2013, 09:49
  2. Adding Image to QPushButton
    By Seema Rao in forum Qt Programming
    Replies: 3
    Last Post: 18th November 2011, 09:06
  3. Finding marks on scanned image for alignment
    By caduel in forum Qt Programming
    Replies: 1
    Last Post: 23rd September 2007, 02:10
  4. QPushButton, stylesheets, text alignment
    By SiLiZiUMM in forum Qt Programming
    Replies: 1
    Last Post: 4th July 2007, 19:53
  5. QToolButton text alignment
    By Vladimir in forum Qt Programming
    Replies: 6
    Last Post: 2nd March 2007, 07:42

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.