Package dev.twilite.client.ui.overlay
Class AnnotatedOverlay
java.lang.Object
dev.twilite.client.ui.overlay.AnnotatedOverlay
- All Implemented Interfaces:
Overlay,StackedOverlay,OverlayBinding
Reflection-backed overlay for classes annotated with
OverlayPanel.-
Constructor Summary
ConstructorsConstructorDescriptionAnnotatedOverlay(Object target) Creates an overlay wrapper for an annotated object.AnnotatedOverlay(Object target, PluginDescriptor descriptor) Creates an overlay wrapper for an annotated object owned by a plugin.AnnotatedOverlay(Object target, PluginDescriptor descriptor, dev.twilite.client.ui.OverlayRenderSettings renderSettings) Creates an overlay wrapper for an annotated object owned by a plugin. -
Method Summary
Modifier and TypeMethodDescriptionvoidbuildImGuiOverlay(ImGuiOverlay overlay) voidbuildImGuiOverlay(ImGuiOverlay overlay, int stackOffset) booleanimgui()Returns whether annotation-backed panel rows should render through native ImGui.booleanmouseMoved(int x, int y) booleanmousePressed(int x, int y) booleanmouseReleased(int x, int y) booleanmouseWheel(int x, int y, int wheelDelta) voidpaint(Graphics2D graphics, int width, int height) Paints this overlay.voidpaint(Graphics2D graphics, int width, int height, int stackOffset) panelSize(Graphics2D graphics) position()size(Graphics2D graphics, int canvasWidth, int canvasHeight) static booleanReturns whether a type can be rendered by this overlay wrapper.
-
Constructor Details
-
AnnotatedOverlay
Creates an overlay wrapper for an annotated object. -
AnnotatedOverlay
Creates an overlay wrapper for an annotated object owned by a plugin. -
AnnotatedOverlay
public AnnotatedOverlay(Object target, PluginDescriptor descriptor, dev.twilite.client.ui.OverlayRenderSettings renderSettings) Creates an overlay wrapper for an annotated object owned by a plugin.
-
-
Method Details
-
supports
Returns whether a type can be rendered by this overlay wrapper. -
imgui
public boolean imgui()Description copied from interface:OverlayBindingReturns whether annotation-backed panel rows should render through native ImGui.World geometry overlays still render through Java2D. Override this when an overlay needs to force a renderer. If left inherited, the Overlay plugin config controls the effective default.
- Specified by:
imguiin interfaceOverlayBinding
-
paint
Description copied from interface:OverlayPaints this overlay. -
position
- Specified by:
positionin interfaceStackedOverlay
-
size
- Specified by:
sizein interfaceStackedOverlay
-
panelSize
-
paint
- Specified by:
paintin interfaceStackedOverlay
-
mousePressed
public boolean mousePressed(int x, int y) - Specified by:
mousePressedin interfaceStackedOverlay
-
mouseReleased
public boolean mouseReleased(int x, int y) - Specified by:
mouseReleasedin interfaceStackedOverlay
-
mouseMoved
public boolean mouseMoved(int x, int y) - Specified by:
mouseMovedin interfaceStackedOverlay
-
mouseWheel
public boolean mouseWheel(int x, int y, int wheelDelta) - Specified by:
mouseWheelin interfaceStackedOverlay
-
buildImGuiOverlay
-
buildImGuiOverlay
-