Results 1 to 6 of 6

Thread: Line spacing in QTextEdit/QTextBrowser

  1. #1
    Join Date
    Aug 2006
    Posts
    163
    Thanks
    12
    Thanked 5 Times in 4 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Line spacing in QTextEdit/QTextBrowser

    I'm rendering CP437 encoded text in a QTextBrowser, which is the encoding used for ASCII art in .nfo files. However, the standard line spacing is screwing things up. I need to set the line spacing to 0 to get the pictures to display properly, but I can't find out how to do that in the documentation. Does anyone know how to do this?

    Thanks in advance.

  2. #2
    Join Date
    Jan 2006
    Location
    Munich, Germany
    Posts
    4,714
    Thanks
    21
    Thanked 418 Times in 411 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: Line spacing in QTextEdit/QTextBrowser

    Try and see where QTextLayout leades you.
    Last edited by high_flyer; 11th December 2007 at 14:06.
    ==========================signature=============== ==================
    S.O.L.I.D principles (use them!):
    https://en.wikipedia.org/wiki/SOLID_...iented_design)

    Do you write clean code? - if you are TDD'ing then maybe, if not, your not writing clean code.

  3. #3
    Join Date
    Aug 2006
    Posts
    163
    Thanks
    12
    Thanked 5 Times in 4 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: Line spacing in QTextEdit/QTextBrowser

    Not applicable unfortunately, this is a Qt3 project.

    I worked around it by using a KHTMLPart (since it's a KDE3 application) and then doing the layout in CSS.

  4. #4
    Join Date
    Jan 2006
    Location
    Munich, Germany
    Posts
    4,714
    Thanks
    21
    Thanked 418 Times in 411 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: Line spacing in QTextEdit/QTextBrowser

    this is a Qt3 project.
    oh sorry, didn't see that.
    ==========================signature=============== ==================
    S.O.L.I.D principles (use them!):
    https://en.wikipedia.org/wiki/SOLID_...iented_design)

    Do you write clean code? - if you are TDD'ing then maybe, if not, your not writing clean code.

  5. #5
    Join Date
    May 2009
    Posts
    2
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Line spacing in QTextEdit/QTextBrowser

    so... do you solve you problem? i am interesting how

  6. #6
    Join Date
    Sep 2010
    Posts
    6

    Default Re: Line spacing in QTextEdit/QTextBrowser

    Hi,
    Still no suggestion?

Similar Threads

  1. Qwizard crashed when created in a slot
    By joshlareau in forum Qt Programming
    Replies: 9
    Last Post: 15th January 2008, 09:16
  2. Access Violation on Signal Emit
    By khagzan in forum Qt Programming
    Replies: 2
    Last Post: 25th September 2007, 22:51
  3. QGLWidget bug
    By Wizard in forum Qt Programming
    Replies: 11
    Last Post: 31st August 2007, 11:23
  4. KDE/QWT doubt on debian sarge
    By hildebrand in forum KDE Forum
    Replies: 13
    Last Post: 25th April 2007, 06:13
  5. QTableView paints too much
    By Jimmy2775 in forum Qt Programming
    Replies: 2
    Last Post: 26th July 2006, 18: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.