Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Blur behind Window (on Linux)

Blur behind Window (on Linux)

Scheduled Pinned Locked Moved Unsolved General and Desktop
3 Posts 3 Posters 980 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.
  • M Offline
    M Offline
    m83k
    wrote on last edited by
    #1

    Hi!

    Is it possible to create a frameless, transparent and blurred window under Linux? I know, there are some engines for KDE providing that kind of feature, but I want to keep my app as independent as possible. The frameless and transparent things are not really my problem, but the "blur" is. It should not blend with the window background, instead it should appear as transparent and blurred, with the wallpaper, background itself. Any ideas where to start?

    1 Reply Last reply
    0
    • mrjjM Offline
      mrjjM Offline
      mrjj
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi
      You mean like a true window that has a semi transparent look with blur?

      we can get blur with
      QGraphicsBlurEffect *effect = new QGraphicsBlurEffect;
      item->setGraphicsEffect(effect);

      however, my linux MINT with XFCE did not like trans+blur.

      You could cheat and simply grab the desktop underneath but that is still somewhat static if user sneaks a window under yours
      it would not show. etc.

      1 Reply Last reply
      1
      • E Offline
        E Offline
        eumeeu
        wrote on last edited by
        #3

        Hello!
        I have the same problem, I'm not able to make the window blur the desktop. I've already seen the deepin implementation and I couldn't find where they apply this effect. Do I have to call a function from KWin(In my case), XCB, X11 or the QPainter is enough?
        I saw some implementations using the following code alongside a way to grab a screenshot of what is behind, but ,at the moment I make it, I can't reapply because the blurred image stays on top (keep blurring the same screenshot).

        QT_BEGIN_NAMESPACE
        Q_WIDGETS_EXPORT void qt_blurImage(QPainter *p, QImage &blurImage, qreal radius, bool quality, bool alphaOnly, int transposed = 0);
        QT_END_NAMESPACE
        
        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