Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. What is equivalent of view.viewport()->setAttribute(Qt::WA_NoSystemBackground) in QQmlApplicationEngine??
Forum Updated to NodeBB v4.3 + New Features

What is equivalent of view.viewport()->setAttribute(Qt::WA_NoSystemBackground) in QQmlApplicationEngine??

Scheduled Pinned Locked Moved Unsolved QML and Qt Quick
3 Posts 3 Posters 683 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • P Offline
    P Offline
    PooyaSis
    wrote on last edited by
    #1

    hi.
    I have frameless QML application, when im resizing it, it flickers.
    find this link in google
    https://blog.rburchell.com/2011/11/avoiding-graphics-flicker-in-qt-qml.html

    the problem is thas in my code i have

    QGuiApplication app(argc, argv);
    QQmlApplicationEngine engine;
    

    but in example there is

    QApplication application(argc, argv);
    QDeclarativeView view;
    

    how Can i use
    view.setAttribute(Qt::WA_OpaquePaintEvent);
    view.setAttribute(Qt::WA_NoSystemBackground);
    view.viewport()->setAttribute(Qt::WA_OpaquePaintEvent);
    view.viewport()->setAttribute(Qt::WA_NoSystemBackground);

    these with QQmlApplicationEngine???
    is ther any equivalent for setAttribute in QQmlApplicationEngine?

    1 Reply Last reply
    0
    • G Offline
      G Offline
      Godwin
      wrote on last edited by
      #2

      I code in python, but I'm very sure you don't need to set any of those attributes. Completely do away with them and have something like:

      QGuiApplication app(argc, argv);
      QQmlApplicationEngine engine;
      engine.load(QUrl("qrc:/qml/main.qml"));
      

      I expect it to work, ok.

      1 Reply Last reply
      0
      • M Offline
        M Offline
        maria ivanovna
        wrote on last edited by
        #3

        He needs it, read docs about these two attributes

        1 Reply Last reply
        0

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved