def draw(
        self,
        offsetx: int = 0,
        offsety: int = 0,
        width: int | None = None,
        height: int | None = None,
        src_x: int = 0,
        src_y: int = 0,
    ):
        """
        A wrapper for the draw operation.

        This draws our cached operations to the Internal window.

        If Drawer has been disabled then the RecordingSurface will
        be cleared if no mirrors are waiting to copy its contents.

        Parameters
        ==========

        offsetx :
            the X offset to start drawing at.
        offsety :
            the Y offset to start drawing at.
        width :
            the X portion of the canvas to draw at the starting point.
        height :
            the Y portion of the canvas to draw at the starting point.
        src_x  :
            the X position of the origin in the source surface
        src_y  :
            the Y position of the origin in the source surface
        """
        if self._enabled:
            self._draw(
                offsetx=offsetx,
                offsety=offsety,
                width=width,
                height=height,
                src_x=src_x,
                src_y=src_y,
            )
            if self.has_mirrors:
                self._create_last_surface()
                ctx = cairocffi.Context(self.last_surface)
                ctx.set_source_surface(self.surface)
                ctx.paint()

        self._reset_surface()

        A wrapper for the draw operation.

        This draws our cached operations to the Internal window.

        If Drawer has been disabled then the RecordingSurface will
        be cleared if no mirrors are waiting to copy its contents.

        Parameters
        ==========

        offsetx :
            the X offset to start drawing at.
        offsety :
            the Y offset to start drawing at.
        width :
            the X portion of the canvas to draw at the starting point.
        height :
            the Y portion of the canvas to draw at the starting point.
        src_x  :
            the X position of the origin in the source surface
        src_y  :
            the Y position of the origin in the source surface
        
libqtile/backend/base/drawer.py