Interface Overlay


  • public interface Overlay
    This domain provides various functionality related to drawing atop the inspected page
    • Method Detail

      • disable

        void disable()
        Disables domain notifications.
      • enable

        void enable()
        Enables domain notifications.
      • hideHighlight

        void hideHighlight()
        Hides any highlight.
      • highlightFrame

        void highlightFrame​(String frameId,
                            RGBA contentColor,
                            RGBA contentOutlineColor)
        Highlights owner element of the frame with given id.
        Parameters:
        frameId - Identifier of the frame to highlight.
        contentColor - The content box highlight fill color (default: transparent).
        contentOutlineColor - The content box highlight outline color (default: transparent).
      • highlightNode

        void highlightNode​(HighlightConfig highlightConfig,
                           Integer nodeId,
                           Integer backendNodeId,
                           String objectId)
        Highlights DOM node with given id or with the given JavaScript object wrapper. Either nodeId or objectId must be specified.
        Parameters:
        highlightConfig - A descriptor for the highlight appearance.
        nodeId - Identifier of the node to highlight.
        backendNodeId - Identifier of the backend node to highlight.
        objectId - JavaScript object id of the node to be highlighted.
      • highlightQuad

        void highlightQuad​(List<Double> quad,
                           RGBA color,
                           RGBA outlineColor)
        Highlights given quad. Coordinates are absolute with respect to the main frame viewport.
        Parameters:
        quad - Quad to highlight
        color - The highlight fill color (default: transparent).
        outlineColor - The highlight outline color (default: transparent).
      • highlightRect

        void highlightRect​(Integer x,
                           Integer y,
                           Integer width,
                           Integer height,
                           RGBA color,
                           RGBA outlineColor)
        Highlights given rectangle. Coordinates are absolute with respect to the main frame viewport.
        Parameters:
        x - X coordinate
        y - Y coordinate
        width - Rectangle width
        height - Rectangle height
        color - The highlight fill color (default: transparent).
        outlineColor - The highlight outline color (default: transparent).
      • setInspectMode

        void setInspectMode​(InspectMode mode,
                            HighlightConfig highlightConfig)
        Enters the 'inspect' mode. In this mode, elements that user is hovering over are highlighted. Backend then generates 'inspectNodeRequested' event upon element selection.
        Parameters:
        mode - Set an inspection mode.
        highlightConfig - A descriptor for the highlight appearance of hovered-over nodes. May be omitted ifenabled == false.
      • setPausedInDebuggerMessage

        void setPausedInDebuggerMessage​(String message)
      • setShowDebugBorders

        void setShowDebugBorders​(Boolean show)
        Requests that backend shows debug borders on layers
        Parameters:
        show - True for showing debug borders
      • setShowFPSCounter

        void setShowFPSCounter​(Boolean show)
        Requests that backend shows the FPS counter
        Parameters:
        show - True for showing the FPS counter
      • setShowPaintRects

        void setShowPaintRects​(Boolean result)
        Requests that backend shows paint rectangles
        Parameters:
        result - True for showing paint rectangles
      • setShowScrollBottleneckRects

        void setShowScrollBottleneckRects​(Boolean show)
        Requests that backend shows scroll bottleneck rects
        Parameters:
        show - True for showing scroll bottleneck rects
      • setShowViewportSizeOnResize

        void setShowViewportSizeOnResize​(Boolean show)
        Paints viewport size upon main frame resize.
        Parameters:
        show - Whether to paint size or not.
      • setSuspended

        void setSuspended​(Boolean suspended)
      • highlightFrame

        void highlightFrame​(String frameId)
        Highlights owner element of the frame with given id.
        Parameters:
        frameId - Identifier of the frame to highlight.
      • highlightNode

        void highlightNode​(HighlightConfig highlightConfig)
        Highlights DOM node with given id or with the given JavaScript object wrapper. Either nodeId or objectId must be specified.
        Parameters:
        highlightConfig - A descriptor for the highlight appearance.
      • highlightQuad

        void highlightQuad​(List<Double> quad)
        Highlights given quad. Coordinates are absolute with respect to the main frame viewport.
        Parameters:
        quad - Quad to highlight
      • highlightRect

        void highlightRect​(Integer x,
                           Integer y,
                           Integer width,
                           Integer height)
        Highlights given rectangle. Coordinates are absolute with respect to the main frame viewport.
        Parameters:
        x - X coordinate
        y - Y coordinate
        width - Rectangle width
        height - Rectangle height
      • setInspectMode

        void setInspectMode​(InspectMode mode)
        Enters the 'inspect' mode. In this mode, elements that user is hovering over are highlighted. Backend then generates 'inspectNodeRequested' event upon element selection.
        Parameters:
        mode - Set an inspection mode.
      • setPausedInDebuggerMessage

        void setPausedInDebuggerMessage()