def get_layering_information(self) -> tuple[bool, bool, bool, bool, bool, bool]:
        """
        Get layer-related EMWH-flags
        https://specifications.freedesktop.org/wm-spec/1.3/ar01s07.html#STACKINGORDER

        Copied here:

         To obtain good interoperability between different Desktop Environments,
         the following layered stacking order is recommended, from the bottom:

            - windows of type _NET_WM_TYPE_DESKTOP
            - windows having state _NET_WM_STATE_BELOW
            - windows not belonging in any other layer
            - windows of type _NET_WM_TYPE_DOCK (unless they have state
              _NET_WM_TYPE_BELOW) and windows having state _NET_WM_STATE_ABOVE
            - focused windows having state _NET_WM_STATE_FULLSCREEN

        Windows that are transient for another window should be kept above this window.

        The window manager may choose to put some windows in different stacking positions,
        for example to allow the user to bring currently a active window to the top and return
        it back when the window loses focus. To this end, qtile adds an additional layer so that
        scratchpad windows are placed above all others, always.
        """
        state = self.window.get_net_wm_state()
        _type = self.window.get_wm_type() or ""

        # Check if this window is focused
        active_window = self.qtile.core._root.get_property(
            "_NET_ACTIVE_WINDOW", "WINDOW", unpack=int
        )
        if active_window and active_window[0] == self.window.wid:
            focus = True
        else:
            focus = False

        desktop = _type == "desktop"
        below = "_NET_WM_STATE_BELOW" in state
        dock = _type == "dock"
        above = "_NET_WM_STATE_ABOVE" in state
        full = (
            "fullscreen" in state
        )  # get_net_wm_state translates this state so we don't use _NET_WM name
        is_scratchpad = isinstance(self.qtile.groups_map.get(self.group), ScratchPad)

        # sort the flags from bottom to top, True meaning further below than False at each step
        states = [desktop, below, above or (dock and not below), full and focus, is_scratchpad]
        other = not any(states)
        states.insert(2, other)

        # If we're a desktop, this should always be the lowest layer...
        if desktop:
            # mypy can't work out that this gives us tuple[bool, bool, bool, bool, bool, bool]...
            # (True, False, False, False, False, False)
            return tuple(not i for i in range(6))  # type: ignore

        # ...otherwise, we set to the highest matching layer.
        # Look for the highest matching level and then set all other levels to False
        highest = max(i for i, state in enumerate(states) if state)

        # mypy can't work out that this gives us tuple[bool, bool, bool, bool, bool, bool]...
        return tuple(i == highest for i in range(6))  # type: ignore

        Get layer-related EMWH-flags
        https://specifications.freedesktop.org/wm-spec/1.3/ar01s07.html#STACKINGORDER

        Copied here:

         To obtain good interoperability between different Desktop Environments,
         the following layered stacking order is recommended, from the bottom:

            - windows of type _NET_WM_TYPE_DESKTOP
            - windows having state _NET_WM_STATE_BELOW
            - windows not belonging in any other layer
            - windows of type _NET_WM_TYPE_DOCK (unless they have state
              _NET_WM_TYPE_BELOW) and windows having state _NET_WM_STATE_ABOVE
            - focused windows having state _NET_WM_STATE_FULLSCREEN

        Windows that are transient for another window should be kept above this window.

        The window manager may choose to put some windows in different stacking positions,
        for example to allow the user to bring currently a active window to the top and return
        it back when the window loses focus. To this end, qtile adds an additional layer so that
        scratchpad windows are placed above all others, always.
        
libqtile/backend/x11/window.py