1. 13 Dec, 2018 1 commit
    • Martin Flöser's avatar
      Build platform plugins in correct sub directory of build dir · c8ede9a5
      Martin Flöser authored
      This brings KWin a step closer to be run from build dir without having
      to install at all. The integration tests are adjusted so that the
      virtual platform is still found which makes the code be closer to what
      is used in normal kwin_wayland.
      Test Plan: ctest passes, manually verified correct plugin is loaded
      Reviewers: #kwin
      Subscribers: kwin
      Tags: #kwin
      Differential Revision: https://phabricator.kde.org/D17388
  2. 02 Dec, 2018 1 commit
    • Vlad Zahorodnii's avatar
      [scenes/opengl] Cleanup cached decoration shadow textures when suspending compositing · 3ad56045
      Vlad Zahorodnii authored
      When suspending compositing, SceneOpenGLShadow cannot cleanup cached
      decoration shadow textures because the effects handler is already gone.
      This sometimes can result in a crash when running kwin_x11 --replace
      (we're hitting an assert statement).
      To fix that, let's use the scene instead of the effects handler for
      making the OpenGL context current.
      Test Plan:
      No longer hit the assert statement:
          ASSERT: "m_cache.isEmpty()" in file /home/vlad/Workspace/KDE/src/kde/workspace/kwin/plugins/scenes/opengl/scene_opengl.cpp, line 2025
          Application::crashHandler() called with signal 6; recent crashes: 1
          QCoreApplication::applicationFilePath: Please instantiate the QApplication object first
          KCrash: crashing... crashRecursionCounter = 2
          KCrash: Application Name = kwin_x11 path = /home/vlad/Workspace/KDE/usr/bin pid = 5407
          KCrash: Arguments: /home/vlad/Workspace/KDE/usr/bin/kwin_x11 --replace
      Reviewers: #kwin, graesslin
      Reviewed By: #kwin, graesslin
      Subscribers: kwin
      Tags: #kwin
      Differential Revision: https://phabricator.kde.org/D17306
  3. 01 Dec, 2018 1 commit
    • Martin Flöser's avatar
      [opengl] Drop functionality to start kcmshell compositing · 46eceef2
      Martin Flöser authored
      The idea of opening the compositing kcm was to show a warning. But that
      broke quite some time ago without noticing. We had two ways:
       * pass through --args command line argument
       * use dbus call to already open kcm
      Neither of the two ways is working. The kwincompositing doesn't parse
      the arguments and the dbus interface doesn't exist any more.
      Following the advice to remove functionality nobody noticed that it is
      broken, this is removed with this change. This probably broke with
      introducing the new KCM which happened IIRC for Plasma 5.0.
      BUG: 393845
      FIXED-IN: 5.14.0
      Reviewers: #kwin, #plasma
      Subscribers: kwin
      Tags: #kwin
      Differential Revision: https://phabricator.kde.org/D13235
  4. 22 Nov, 2018 1 commit
  5. 14 Nov, 2018 8 commits
  6. 09 Nov, 2018 3 commits
  7. 08 Nov, 2018 3 commits
  8. 04 Nov, 2018 2 commits
  9. 27 Oct, 2018 1 commit
  10. 25 Oct, 2018 1 commit
  11. 24 Oct, 2018 3 commits
  12. 10 Oct, 2018 1 commit
    • David Edmundson's avatar
      [qpa] Always keep a at least one screen · 6724955a
      David Edmundson authored
      Qt does not like having no screens. Both Qt XCB and Wayland QPAs have
      systems pretend there's always at least 1 screen
      Kwin already uses a dummy screen on startup, this patch reinserts the
      dummy screen if the platform states that all real screens are removed.
      BUG: 399564
      Test Plan:
      Logged in, everything still worked
      Did not reproduce the original bug
      Reviewers: #kwin, zzag
      Reviewed By: #kwin, zzag
      Subscribers: kwin
      Tags: #kwin
      Differential Revision: https://phabricator.kde.org/D16096
  13. 05 Oct, 2018 3 commits
  14. 22 Sep, 2018 1 commit
  15. 31 Aug, 2018 7 commits
    • Vlad Zahorodnii's avatar
      [scenes/opengl] Fix overlaps in shadow texture atlas · dadcd511
      Vlad Zahorodnii authored
      If the corner shadow tiles(top-left, top-right, and so on) tiles are missing,
      then the left/top/right/bottom shadow tiles will overlap.
      This diff addresses that problem by changing how the shadow texture
      atlas is rendered:
      * corner tiles will be drawn in the corners of the atlas(buildQuads
        method expects them to be at the corners);
      * top, right, bottom, and left tile will be aligned to the top-left
        corner of the inner shadow rect.
      For majority of desktop themes, the shadow texture atlas looks the same.
      For example, here's for Aether:
      {F6190484, layout=center, size=full}
      {F6190488, layout=center, size=full}
      Depends on D14783
      Reviewers: #kwin, davidedmundson
      Reviewed By: #kwin, davidedmundson
      Subscribers: davidedmundson, abetts, kwin
      Tags: #kwin
      Differential Revision: https://phabricator.kde.org/D14784
    • Vlad Zahorodnii's avatar
      [scenes/opengl] Correctly draw shadows when corner tiles are missing · 5e55664d
      Vlad Zahorodnii authored
      Current implementation of buildQuads assumes that corner shadow tiles
      are always present:
          const QRectF leftRect(
      but that assumption is wrong. For example, if the default panel is on
      the bottom screen edge, then the calendar popup won't have the
      bottom-left shadow tile(at least on Wayland). Which means that the left
      shadow tile won't be visible because
      topLeftRect.left() == bottomLeftRect.right().
      Corner rectangles only have to influence height of the left/right tile
      and width of the top/bottom tile. Width of the left/right tile and
      height of the top/bottom tile should not be controlled by corner tiles.
      Overall, this is how shadow quads are computed:
      * Compute the outer rectangle;
      * Compute target rectangle for each corner tile. If some corner tile is
        missing, move the target rectangle to the corresponding corner of the
        inner shadow rect and set its width and height to 0. We need to do
        that to prevent top/right/bottom/left tiles from spanning over
      {F6190219, layout=center, size=full}
      We would rather prefer something like this if the top-left tile is
      {F6190233, layout=center, size=full}
      * Fix overlaps between corner tiles;
      * Compute target rectangles for top, right, bottom, and left tiles;
      * Fix overlaps between left/right and top/bottom shadow tiles.
      Test Plan:
      * Ran tests;
      * Resized Konsole to its minimimum size(on X11 and Wayland);
      * Opened the calendar popup(on X11 and Wayland):
      {F6190344, layout=center, size=full}
      {F6190346, layout=center, size=full}
      Reviewers: #kwin, davidedmundson
      Reviewed By: #kwin, davidedmundson
      Subscribers: abetts, davidedmundson, kwin
      Tags: #kwin
      Differential Revision: https://phabricator.kde.org/D14783
    • Roman Gilg's avatar
      [platforms/virtual] Set raw physical size of outputs · 95cb47ca
      Roman Gilg authored
      Summary: At least one test requires the physical size to be set.
      Test Plan:
      Lock screen screen edges test is passing again. Without the change the corner
      offset in the ScreenEdges class is not calculated correctly via the
      physicalDpiX() and physicalDpiY() values of an auxilliary QWidget.
      Reviewers: #kwin, davidedmundson
      Reviewed By: #kwin, davidedmundson
      Subscribers: davidedmundson, kwin
      Tags: #kwin
      Differential Revision: https://phabricator.kde.org/D15183
    • Roman Gilg's avatar
      [colorcorrection] Set gamma through Output class · 9cf2730f
      Roman Gilg authored
      With the new Output class we can set the gamma directly here. This is also
      a stepping stone to adjust individual output gamma adjustment later on.
      This means any future backend, which aims to support the color correction
      frontend needs to use the Output class.
      Test Plan: Night Color test still passes.
      Reviewers: #kwin
      Subscribers: kwin
      Tags: #kwin
      Differential Revision: https://phabricator.kde.org/D11803
    • Roman Gilg's avatar
      [platforms/virtual] Let VirtualOutput inherit Output · b22c362b
      Roman Gilg authored
      Let VirtualOutput be a child class of the new generic class Output.
      This allows code sharing and a very similar behavior of the Virtual backend
      in comparision to the Drm backend.
      Test Plan:
      Autotests succesful with two exceptions: The decoration input test fails on
      testDoubleTap, row topLeft. This is to be expected because now the
      ScreenEdgeInputFilter captures the event at position (0,0) before the
      DecorationEventFilter can capture it. The autotest was adapted to take this
      special case into account.
      Also the lockscreen test fails, because the virtual output is currently missing
      the physical size yet.
      Reviewers: #kwin
      Subscribers: kwin
      Tags: #kwin
      Differential Revision: https://phabricator.kde.org/D11789
    • Roman Gilg's avatar
      Introduce OutputScreens class · 34823782
      Roman Gilg authored
      Lift high-level properties into new Screens child class for platform plugins
      using the Output class.
      Directly make DrmScreens a child class of OutputScreens.
      Test Plan: Manually and auto tests with 94%.
      Reviewers: #kwin
      Differential Revision: https://phabricator.kde.org/D11782
    • Roman Gilg's avatar
      Introduce generic Output class · fe63e21f
      Roman Gilg authored
      In order to separate high-level properties of individual outputs from
      hardware-specific ones and access these, introduce a new generic class Output.
      Also make the DrmOutput class directly a child class of this generic class.
      The long-term goal is to get rid of the Screens global object on Wayland and
      instead directly work with Output objects on compositing level.
      This should enable us long-term to do direct scanout to hardware planes, what
      I predict needs this generic output representation at one point.
      Test Plan: Manually.
      Reviewers: #kwin
      Subscribers: kwin
      Tags: #kwin
      Differential Revision: https://phabricator.kde.org/D11781
  16. 29 Aug, 2018 1 commit
  17. 13 Aug, 2018 1 commit
    • Nerdopolis Turfwalker's avatar
      [platforms/fbdev] Attempt to set the framebuffer color layout on the framebuffer device · 304528e8
      Nerdopolis Turfwalker authored
      Weston does something similar
       ...and it seems that the non-primary framebuffer devices start completely off. (the screen is off on my Displayport device, and the window for the second vga card in qemu is much smaller than the primary one, and all black for my qemu vm) .
      In my testing, sending the ioctl FBIOPUT_VSCREENINFO with a *changed* &varinfo allows it to wake up, and turns on the screen.
      doing FBIOGET_VSCREENINFO and then FBIOPUT_VSCREENINFO in my testing does not work.
      I think really the values that end up getting changed are varinfo.transp.offset and varinfo.transp.length. at least on the qemu system, but in this patch I am aligning all of them for completeness, because the drivers might do it differently for qemu
      Test Plan: This causes the window for /dev/fb1 (remote-viewer, and a qemu vm with two "VGA" (bochsdrm) cards) to resize from the smaller size when specifying it as the --fb-device on seat0, and kwin draws on the device.
      Reviewers: #kwin, davidedmundson, graesslin
      Reviewed By: #kwin, graesslin
      Subscribers: zzag, davidedmundson, rkflx, graesslin, kwin
      Tags: #kwin
      Differential Revision: https://phabricator.kde.org/D9572
  18. 06 Aug, 2018 1 commit
    • David Edmundson's avatar
      Fractional scaling in DRM kscreen integration · 7aedacd8
      David Edmundson authored
      The kwin code was written to treat scale as non integers, we just need
      to switch to the relevant float version of methods.
      Test Plan:
      Used kscreen-doctor to change this
      Konsole resized as appropriate
      Plasmashell was all broken, but that's expected until QScreen::size is based on the
      xdg-output virtual size
      Reviewers: #kwin, mart, graesslin, romangg
      Reviewed By: #kwin, mart, graesslin
      Subscribers: romangg, zzag, kwin
      Tags: #kwin
      Differential Revision: https://phabricator.kde.org/D13616