<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.kde.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugs.kde.org/"
          
          maintainer="sysadmin@kde.org"
>

    <bug>
          <bug_id>478383</bug_id>
          
          <creation_ts>2023-12-11 03:15:27 +0000</creation_ts>
          <short_desc>Lowering a window with transient or a transient window is broken on wayland</short_desc>
          <delta_ts>2025-03-07 19:01:37 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>4</classification_id>
          <classification>Plasma</classification>
          <product>kwin</product>
          <component>core</component>
          <version>git master</version>
          <rep_platform>Neon</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>wayland-only</keywords>
          <priority>NOR</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>0</everconfirmed>
          <reporter name="Jarek Janik">ann.of.the.green.gables</reporter>
          <assigned_to name="KWin default assignee">kwin-bugs-null</assigned_to>
          <cc>nate</cc>
          
          <cf_commitlink>https://invent.kde.org/plasma/kwin/-/commit/dc3e489472431789ded4ad5b9ab36c466118d5df</cf_commitlink>
          <cf_versionfixedin>6.3.3</cf_versionfixedin>
          <cf_sentryurl></cf_sentryurl>
          <votes>0</votes>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>2272832</commentid>
    <comment_count>0</comment_count>
    <who name="Jarek Janik">ann.of.the.green.gables</who>
    <bug_when>2023-12-11 03:15:27 +0000</bug_when>
    <thetext>SUMMARY
Workspace::lowerWindow() method uses X11 specific code path for selecting members of window hierarchy, that code path returns empty list - so only the lowered window actually gets lowered:
- when this window is a parent of hierarchy then it leave this hierarchy dangling
- when this window is a transient - it only gets lowered as low as possible - so it ends right above the parent window of the hierarchy

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: 
KDE Plasma Version: 5.81.80
KDE Frameworks Version: 5.245.0
Qt Version: 6.6.0</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2272841</commentid>
    <comment_count>1</comment_count>
    <who name="Jarek Janik">ann.of.the.green.gables</who>
    <bug_when>2023-12-11 03:50:45 +0000</bug_when>
    <thetext>MR with fix is here:
https://invent.kde.org/plasma/kwin/-/merge_requests/4779</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2380027</commentid>
    <comment_count>2</comment_count>
    <who name="Jarek Janik">ann.of.the.green.gables</who>
    <bug_when>2024-12-10 02:06:22 +0000</bug_when>
    <thetext>New MR:
https://invent.kde.org/plasma/kwin/-/merge_requests/6882</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2405795</commentid>
    <comment_count>3</comment_count>
    <who name="Zamundaaa">xaver.hugl</who>
    <bug_when>2025-03-07 17:29:59 +0000</bug_when>
    <thetext>Git commit 1df917fae4bc744e1508b4e95e8d9a7b521a00da by Xaver Hugl, on behalf of Jarek Janik.
Committed on 07/03/2025 at 15:08.
Pushed by zamundaaa into branch &apos;master&apos;.

layers: fix stacking issues in Workspace::lowerWindow

Workspace::lowerWindow() method had issues when handling window
hierarchies (different on X11 and on wayland, see BUGS below).

This patch unifies code paths for both X11 and wayland in lowerWindow()
method, fixing the aforementioned bugs.
Related: bug 478382

M  +19   -14   src/layers.cpp

https://invent.kde.org/plasma/kwin/-/commit/1df917fae4bc744e1508b4e95e8d9a7b521a00da</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2405823</commentid>
    <comment_count>4</comment_count>
    <who name="Zamundaaa">xaver.hugl</who>
    <bug_when>2025-03-07 18:53:27 +0000</bug_when>
    <thetext>Git commit dc3e489472431789ded4ad5b9ab36c466118d5df by Xaver Hugl, on behalf of Jarek Janik.
Committed on 07/03/2025 at 18:15.
Pushed by zamundaaa into branch &apos;Plasma/6.3&apos;.

layers: fix stacking issues in Workspace::lowerWindow

Workspace::lowerWindow() method had issues when handling window
hierarchies (different on X11 and on wayland, see BUGS below).

This patch unifies code paths for both X11 and wayland in lowerWindow()
method, fixing the aforementioned bugs.
Related: bug 478382
(cherry picked from commit 1df917fae4bc744e1508b4e95e8d9a7b521a00da)

M  +19   -14   src/layers.cpp

https://invent.kde.org/plasma/kwin/-/commit/dc3e489472431789ded4ad5b9ab36c466118d5df</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>