Results 1 to 5 of 5

Thread: KWin's shadows and frameless window

  1. #1
    Join Date
    Aug 2008
    Posts
    4
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default KWin's shadows and frameless window

    I've done the widget with it's own impl of paintEvent and set Qt::FramelessWindowHint for it. Also I've set attribute Qt::WA_TranslucentBackground to true. At widget I draw argb pixmap.

    So the problem is that KWin draws the shadow everywere under the widget, but it's needed that it wouldn't draw it at all, or only under the certain places. Is it possible?

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,360
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: KWin's shadows and frameless window

    You might try setting a mask on your window using QWidget::setMask(). If this doesn't work then probably not much can be done. And if anything can be done, I think it should be in KWin.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  3. The following user says thank you to wysota for this useful post:

    soulless (22nd July 2010)

  4. #3
    Join Date
    Aug 2008
    Posts
    4
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: KWin's shadows and frameless window

    thanks, this works

  5. #4
    Join Date
    Jul 2009
    Posts
    1
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: KWin's shadows and frameless window

    Quote Originally Posted by wysota View Post
    You might try setting a mask on your window using QWidget::setMask(). If this doesn't work then probably not much can be done. And if anything can be done, I think it should be in KWin.
    setMask() is very low quality. If used "compiz" (KWin effects off), FramelessWindow shadow no draw.
    If used FramelessWindow with KWin (without setMask()) and send "qdbus org.kde.kwin /KWin reconfigure", shadow disappears, but not immediately.
    May be a bug in KWin?

  6. #5
    Join Date
    Aug 2008
    Posts
    4
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: KWin's shadows and frameless window

    Quote Originally Posted by al3000 View Post
    setMask() is very low quality. If used "compiz" (KWin effects off), FramelessWindow shadow no draw.
    If used FramelessWindow with KWin (without setMask()) and send "qdbus org.kde.kwin /KWin reconfigure", shadow disappears, but not immediately.
    May be a bug in KWin?
    Would it save shadows under other windows? I don't think so..

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.