Class Overlay

    • Constructor Detail

      • Overlay

        protected Overlay()
      • Overlay

        protected Overlay​(Plugin plugin)
    • Method Detail

      • getName

        public java.lang.String getName()
        Overlay name, used for saving the overlay, needs to be unique
        Returns:
        overlay name
      • drawAfterInterface

        protected void drawAfterInterface​(int interfaceId)
      • drawAfterLayer

        protected void drawAfterLayer​(net.runelite.api.widgets.WidgetInfo layer)
      • onMouseOver

        public void onMouseOver()
      • onDrag

        public boolean onDrag​(Overlay other)
        Called when an overlay is dragged onto this, if dragTargetable is true. Return true to consume the mouse event and prevent the other overlay from being moved
        Parameters:
        other - the overlay being dragged
        Returns:
      • getParentBounds

        @Nullable
        public java.awt.Rectangle getParentBounds()
        Get the parent bounds for overlay dragging. The overlay will not be allowed to be moved outside of the parent bounds.
        Returns:
      • revalidate

        public void revalidate()
      • getPlugin

        @Nullable
        public Plugin getPlugin()
      • getPreferredLocation

        public java.awt.Point getPreferredLocation()
      • getPreferredSize

        public java.awt.Dimension getPreferredSize()
      • getDrawHooks

        public java.util.List<java.lang.Integer> getDrawHooks()
      • isResizable

        public boolean isResizable()
      • getMinimumSize

        public int getMinimumSize()
      • isResettable

        public boolean isResettable()
      • isDragTargetable

        public boolean isDragTargetable()
        Whether this overlay can be dragged onto other overlays & have other overlays dragged onto it.
      • setPreferredPosition

        public void setPreferredPosition​(OverlayPosition preferredPosition)
      • setBounds

        public void setBounds​(java.awt.Rectangle bounds)
      • setResizable

        public void setResizable​(boolean resizable)
      • setMinimumSize

        public void setMinimumSize​(int minimumSize)
      • setResettable

        public void setResettable​(boolean resettable)
      • setDragTargetable

        protected void setDragTargetable​(boolean dragTargetable)
        Whether this overlay can be dragged onto other overlays & have other overlays dragged onto it.