This topic provides a summary of each event type. Consult the API documentation for a complete description of each event member and its purpose.
Events implementing IMouseCaptureEvent
.
MouseCaptureEvent
is sent when an element takes the mouse capture.
target
: The element that takes the capture.
MouseCaptureOutEvent
is sent when an element releases or otherwise loses the mouse capture.
target
: The element that loses the capture.
Events implementing IChangeEvent
.
ChangeEvent<T>
is a generic event sent when the value of an element changes. This is typically sent when a control changes. For the InputEvent
control, this event is not sent for every input event in the control, but only when the value changes. This is usually when either the control loses focus, or the Enter
key is pressed.
<T>
target
previousValue
newValue
Events implementing ICommandEvent
.
target
commandName
This event is sent by IMGUI while it determines whether the command will be handled by an element in the panel.
This event is sent by IMGUI when an element in the panel should execute a command.
Events sent during a drag and drop operation.
The drag and drop operation was cancelled. The drop target did not accept the dragged element.
The dragged element moved over a drop target. If the drop target is willing to accept the dragged element, the callback for this event should set DragAndDrop.visualMode
to ensure a DragPerformEvent
is sent when the user releases the mouse button.
The dragged element was dropped on a target that accepted them. The drag and drop operation is now finished.
The dragged element entered a new VisualElement
. In particular, this event is sent when the drag operation begins.
The dragged element exited the current drop target. In particular, this event is sent when the drag operation ends.
Event sent when either the position or the dimensions of an element changes. Events of this type are only sent to the event target. They are not propagated.
target
oldRect
newRect
Events implementing IFocusEvent
.
These events are sent when an element is given or loses keyboard focus. There are two sets of focus events:
FocusOutEvent
and FocusInEvent
are sent along the propagation path just before the focus change occurs.FocusEvent
and BlurEvent
are sent to the event target only, immediately after the focus change.Event sent when an element is about to lose the focus.
target
relatedTarget
Event sent when an element is about to gain the focus.
target
relatedTarget
Event sent after an element lost the focus.
target
relatedTarget
Event sent after an element gained the focus.
target
relatedTarget
Event sent when data is input to a visual element, typically a control. This event differs from ChangeEvent
in that it is sent for every input event in the control, even if the value of the control did not change.
target
previousData
newData
Events implementing IKeyboardEvent
.
Event sent when the user presses a key on the keyboard.
target
Event sent when the user releases a key on the keyboard.
target
Events implementing IKeyboardEvent
.
While an element is capturing the mouse, mouse events are only be sent to the capturing elements. There is no propagation.
Event sent when the user presses one of the mouse buttons.
target
Event sent when the user releases one of the mouse buttons.
target
Event went when the user moves the mouse.
target
Event sent when the user presses and releases the third mouse button. This event only exists for backward compatibility with IMGUI.
Event sent when the user activates the mouse wheel.
target
Event sent when the mouse enters an window.
target
Event sent when the mouse leaves an window.
target
Event sent when the mouse enters an element or one of its descendant. This event differs from MouseOverEvent
in that this event is sent to each element being entered by the mouse. This event does not propagate.
target
Event sent when the mouse leaves an element or one of its descendant. This event differs from MouseOutEvent
in that this event is sent to each element being exited by the mouse. This event does not propagate.
target
Event sent when the mouse enters an element. This event differs from MouseEnterEvent
in that this event is only sent to the entered element. . This event does not propagate.
target
Event sent when the mouse leaves an element. This event differs from MouseLeaveEvent
in that this event is only sent to the exited element and that it propagates.
target
Event sent by the ContextualMenuManager
when the contextual menu needs to be populated with menu items.
target
Event sent immediately after an element is attached to a IPanel
. Since
setting the panel is recursive, all descendants of the element also
receive the event.
target
Event sent just before an element is detached to a IPanel
. Since
setting the panel is recursive, all descendants of the element also
receive the event.
target
Event sent just before a tooltip is displayed. The handler should set the TooltipEvent.tooltip
string and the TooltipEvent.rect
.
target
Event used to encapsulate IMGUI-specifc events.