Interface KeybindComponent
- All Superinterfaces:
Component, ComponentBuilderApplicable, ComponentLike, HoverEventSource<Component>, ScopedComponent<KeybindComponent>, StyleGetter, StyleSetter<Component>
A
Component that displays the client's current keybind for the supplied action.
This component takes:
- keybind
- a keybind identifier for a action. (e.g key.inventory, key.jump etc..)
- Since:
- 4.0.0
- Since Minecraft:
- 1.12
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic interfaceA keybind component builder.static interfaceSomething that can provide a keybind identifier. -
Field Summary
Fields inherited from interface Component
EQUALS, EQUALS_IDENTITY, IS_NOT_EMPTY -
Method Summary
Modifier and TypeMethodDescriptionkeybind()Gets the keybind.Sets the keybind.default KeybindComponentkeybind(KeybindComponent.KeybindLike keybind) Sets the keybind.Returns a builder for this component.Methods inherited from interface Component
asHoverEvent, children, clickEvent, color, compact, compact, componentBuilderApply, contains, contains, decoration, decorations, font, hasDecoration, hasStyling, hoverEvent, insertion, iterable, iterable, iterator, iterator, replaceText, replaceText, shadowColor, spliterator, spliterator, styleMethods inherited from interface HoverEventSource
asHoverEventMethods inherited from interface ScopedComponent
append, append, append, append, append, appendNewline, appendSpace, applyFallbackStyle, applyFallbackStyle, asComponent, children, clickEvent, color, colorIfAbsent, decorate, decoration, decoration, decorationIfAbsent, decorations, font, hoverEvent, insertion, mergeStyle, mergeStyle, mergeStyle, shadowColor, shadowColorIfAbsent, style, style, style, styleMethods inherited from interface StyleSetter
decorate, decorations
-
Method Details
-
keybind
-
keybind
Sets the keybind.- Parameters:
keybind- the keybind- Returns:
- a copy of this component
- Since:
- 4.0.0
-
keybind
Sets the keybind.- Parameters:
keybind- the keybind- Returns:
- a copy of this component
- Since:
- 4.9.0
-
toBuilder
KeybindComponent.Builder toBuilder()Description copied from interface:ComponentReturns a builder for this component.- Specified by:
toBuilderin interfaceComponent- Specified by:
toBuilderin interfaceScopedComponent<KeybindComponent>- Returns:
- the builder
-