Results 1 to 2 of 2

Thread: Mac OS QtWebKit CSS3 rendering issues

  1. #1
    Join Date
    Apr 2012
    Posts
    4
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows

    Default Mac OS QtWebKit CSS3 rendering issues

    Hi!

    I'm trying to make an application using QtWebKit on Windows and Mac OS and I've noticed the following rendering issue on Mac when the -webkit-mask-image CSS propery is used:

    qtwebkit_mac_issue.jpg

    Here's the HTML code:
    Qt Code:
    1. <!DOCTYPE HTML>
    2. <html>
    3. <head>
    4. <title>Test</title>
    5.  
    6. <style type="text/css">
    7. body {
    8. margin: 0;
    9. padding: 2em;
    10. background: pink;
    11. }
    12. .button {
    13. width: 140px;
    14. height: 140px;
    15. background: red;
    16. border-radius: 20px;
    17. border: 1px solid #000;
    18. }
    19. .button span {
    20. display: block;
    21. width: 80px;;
    22. height: 80px;
    23. margin: 0 auto;
    24. background: black;
    25. -webkit-mask-image: url(grid.png);
    26. }
    27. </style>
    28.  
    29. </head>
    30. <body>
    31.  
    32. <div class="button"><span></span></div>
    33.  
    34. </body>
    35. </html>
    To copy to clipboard, switch view to plain text mode 

    Is there a way to fix this issue?

  2. #2
    Join Date
    Apr 2012
    Posts
    4
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: Mac OS QtWebKit CSS3 rendering issues

    I've found the solution: I just needed to set the graphics system to raster

    Qt Code:
    1. int main(int argc, char *argv[])
    2. {
    3. QApplication::setGraphicsSystem("raster");
    4. QApplication app(argc, argv);
    5. ...
    6. }
    To copy to clipboard, switch view to plain text mode 

Similar Threads

  1. Arabic text rendering; issues with parentheses
    By TropicalPenguin in forum Qt Programming
    Replies: 4
    Last Post: 10th September 2013, 09:53
  2. Replies: 8
    Last Post: 7th November 2012, 19:20
  3. QtWebkit - Flash rendering problem
    By rsilva in forum Qt Programming
    Replies: 5
    Last Post: 5th May 2011, 08:38
  4. QtWebKit and flash performance issues
    By caelestis in forum Qt Programming
    Replies: 0
    Last Post: 7th February 2010, 05:08
  5. Replies: 0
    Last Post: 30th November 2008, 16:59

Tags for this Thread

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.