Class AbstractSignEditScreen
java.lang.Object
net.minecraft.client.gui.components.events.AbstractContainerEventHandler
net.minecraft.client.gui.screens.Screen
net.minecraft.client.gui.screens.inventory.AbstractSignEditScreen
- All Implemented Interfaces:
ContainerEventHandler,GuiEventListener,Renderable,TabOrderedElement
- Direct Known Subclasses:
HangingSignEditScreen,SignEditScreen
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.client.gui.screens.Screen
Screen.NarratableSearchResult -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate intCounts the number of screen updates.private final booleanprivate intThe index of the line that is being edited.private final String[]protected final SignBlockEntityReference to the sign object.private @Nullable TextFieldHelperprivate SignTextprotected final WoodTypeFields inherited from class net.minecraft.client.gui.screens.Screen
FADE_IN_TIME, font, FOOTER_SEPARATOR, HEADER_SEPARATOR, height, INWORLD_FOOTER_SEPARATOR, INWORLD_HEADER_SEPARATOR, MENU_BACKGROUND, minecraft, narratorButton, renderables, screenExecutor, title, width -
Constructor Summary
ConstructorsConstructorDescriptionAbstractSignEditScreen(SignBlockEntity pSign, boolean pIsFrontText, boolean pIsFiltered) AbstractSignEditScreen(SignBlockEntity pSign, boolean pIsFrontText, boolean pIsFiltered, Component pTitle) -
Method Summary
Modifier and TypeMethodDescriptionbooleancharTyped(CharacterEvent p_445902_) protected abstract Vector3fprotected abstract floatprotected voidinit()booleanbooleanprivate booleanisValid()booleankeyPressed(KeyEvent p_446082_) voidonClose()private voidonDone()voidremoved()voidrender(GuiGraphics p_282418_, int p_281700_, int p_283040_, float p_282799_) Renders the graphical user interface (GUI) element.private voidrenderSign(GuiGraphics pGuiGraphics) protected abstract voidrenderSignBackground(GuiGraphics pGuiGraphics) private voidrenderSignText(GuiGraphics pGuiGraphics) private voidsetMessage(String pMessage) voidtick()Methods inherited from class net.minecraft.client.gui.screens.Screen
added, addRenderableOnly, addRenderableWidget, addWidget, afterKeyboardAction, afterMouseAction, afterMouseMove, canInterruptWithAnotherScreen, changeFocus, children, clearFocus, clearWidgets, clickCommandAction, clickUrlAction, defaultHandleClickEvent, defaultHandleGameClickEvent, fadeWidgets, fillCrashDetails, findNarratableWidget, getBackgroundMusic, getFont, getMinecraft, getNarrationMessage, getRectangle, getTitle, getTooltipFromItem, getUsageNarration, handleDelayedNarration, init, insertText, isAllowedInPortal, isMouseOver, isValidCharacterForName, onFilesDrop, panoramaShouldSpin, rebuildWidgets, removeWidget, renderBackground, renderBlurredBackground, renderMenuBackground, renderMenuBackground, renderMenuBackgroundTexture, renderPanorama, renderTransparentBackground, renderWithTooltipAndSubtitles, repositionElements, resize, setInitialFocus, setInitialFocus, shouldCloseOnEsc, shouldNarrateNavigation, showsActiveEffects, triggerImmediateNarration, updateNarratedWidget, updateNarrationState, updateNarratorStatusMethods inherited from class net.minecraft.client.gui.components.events.AbstractContainerEventHandler
getFocused, isDragging, setDragging, setFocusedMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.minecraft.client.gui.components.events.ContainerEventHandler
getChildAt, getCurrentFocusPath, isFocused, keyReleased, mouseClicked, mouseDragged, mouseReleased, mouseScrolled, nextFocusPath, setFocusedMethods inherited from interface net.minecraft.client.gui.components.events.GuiEventListener
getBorderForArrowNavigation, mouseMoved, shouldTakeFocusAfterInteractionMethods inherited from interface net.minecraft.client.gui.components.TabOrderedElement
getTabOrderGroup
-
Field Details
-
sign
Reference to the sign object. -
text
-
messages
-
isFrontText
private final boolean isFrontText -
woodType
-
frame
private int frameCounts the number of screen updates. -
line
private int lineThe index of the line that is being edited. -
signField
-
-
Constructor Details
-
AbstractSignEditScreen
-
AbstractSignEditScreen
public AbstractSignEditScreen(SignBlockEntity pSign, boolean pIsFrontText, boolean pIsFiltered, Component pTitle)
-
-
Method Details
-
init
protected void init() -
tick
public void tick() -
isValid
private boolean isValid() -
keyPressed
- Specified by:
keyPressedin interfaceContainerEventHandler- Specified by:
keyPressedin interfaceGuiEventListener- Overrides:
keyPressedin classScreen
-
charTyped
-
render
Description copied from interface:RenderableRenders the graphical user interface (GUI) element.- Specified by:
renderin interfaceRenderable- Overrides:
renderin classScreen- Parameters:
p_282418_- the GuiGraphics object used for rendering.p_281700_- the x-coordinate of the mouse cursor.p_283040_- the y-coordinate of the mouse cursor.p_282799_- the partial tick time.
-
onClose
public void onClose() -
removed
public void removed() -
isPauseScreen
public boolean isPauseScreen()- Overrides:
isPauseScreenin classScreen
-
isInGameUi
public boolean isInGameUi()- Overrides:
isInGameUiin classScreen
-
renderSignBackground
-
getSignTextScale
-
getSignYOffset
protected abstract float getSignYOffset() -
renderSign
-
renderSignText
-
setMessage
-
onDone
private void onDone()
-