Results 1 to 3 of 3

Thread: QLABEL how to Set Line Height?

  1. #1
    Join Date
    Oct 2010
    Location
    Iran
    Posts
    27
    Thanks
    1
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11

    Default QLABEL how to Set Line Height?

    QLABEL how to Set Line Height?

  2. #2
    Join Date
    Nov 2010
    Posts
    48
    Thanks
    5
    Thanked 4 Times in 4 Posts
    Qt products
    Qt3 Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Maemo/MeeGo

    Default Re: QLABEL how to Set Line Height?

    you can use this QLabel *label = new QLabel("<h2><i>Hello</i> "
    "<font color=red>Qt!</font></h2>");

  3. #3
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,360
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: QLABEL how to Set Line Height?

    For fine grained control over the text a pure label will not be enough. You can use QTextEdit in read-only mode with adjusted decorations and then you'll be able to use the whole API of QTextDocument.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


Similar Threads

  1. Changing line height in QTextEdit (Qt4)
    By ultr in forum Qt Programming
    Replies: 0
    Last Post: 19th February 2010, 15:59
  2. Replies: 1
    Last Post: 23rd January 2010, 13:16
  3. Replies: 1
    Last Post: 29th September 2009, 19:44
  4. QTextDocument and line height
    By vooft in forum Qt Programming
    Replies: 0
    Last Post: 25th November 2008, 16:47
  5. Replies: 1
    Last Post: 2nd August 2008, 15:46

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.