Results 1 to 5 of 5

Thread: Strange behaviour with QPen

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Nov 2007
    Location
    Italy
    Posts
    694
    Thanks
    59
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Strange behaviour with QPen

    Quote Originally Posted by boudie View Post
    What does it look like when you don't use QPainter::Antialiasing?

    And what happens when you set pen width to zero: a "cosmetic pen"? That one should always draw 1 pixel wide.
    I removed the Antialiasing flag and seems solved the problem but why???
    Franco Amato

  2. #2
    Join Date
    Sep 2008
    Location
    Bangalore
    Posts
    659
    Thanks
    116
    Thanked 42 Times in 41 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Strange behaviour with QPen

    your painted line will have some strange looking like a small saw tooth wave normally rather than straight .. try to draw a cross line u can see it clearly .. antialiasing is like coating or filling the scramble space ..
    see the link
    http://doc.trolltech.com/4.3/coordsy...iased-painting
    "Behind every great fortune lies a crime" - Balzac

  3. #3
    Join Date
    Nov 2007
    Location
    Italy
    Posts
    694
    Thanks
    59
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Strange behaviour with QPen

    Quote Originally Posted by wagmare View Post
    your painted line will have some strange looking like a small saw tooth wave normally rather than straight .. try to draw a cross line u can see it clearly .. antialiasing is like coating or filling the scramble space ..
    see the link
    http://doc.trolltech.com/4.3/coordsy...iased-painting
    Thank you for your explanation. This is why the width of my line is bigger than 1 pixel
    Franco Amato

Similar Threads

  1. Strange behaviour with QPainter
    By franco.amato in forum Qt Programming
    Replies: 12
    Last Post: 14th January 2010, 05:30
  2. Need help: Strange behaviour
    By navi1084 in forum Qt Programming
    Replies: 3
    Last Post: 14th November 2008, 04:03
  3. Strange behaviour of QPainter...
    By oscar in forum Qt Programming
    Replies: 2
    Last Post: 8th November 2008, 12:07
  4. very strange behaviour
    By regix in forum Qt Programming
    Replies: 23
    Last Post: 20th July 2006, 17:38
  5. [Qt 4.1] Strange behaviour with QTableView
    By fane in forum Qt Programming
    Replies: 1
    Last Post: 23rd January 2006, 06:17

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.