类 EditBox
java.lang.Object
net.minecraft.client.gui.components.AbstractWidget
net.minecraft.client.gui.components.EditBox
- 所有已实现的接口:
GuiEventListener
,Renderable
,TabOrderedElement
,LayoutElement
,NarratableEntry
,NarrationSupplier
,IAbstractWidgetExtension
-
嵌套类概要
从接口继承的嵌套类/接口 net.minecraft.client.gui.narration.NarratableEntry
NarratableEntry.NarrationPriority
-
字段概要
字段修饰符和类型字段说明private static final int
static final int
private static final int
private static final int
private boolean
private boolean
private static final String
private static final int
private static final int
private int
static final int
private int
private final Font
private BiFunction<String,
Integer, FormattedCharSequence> static final int
private int
private int
private Component
private boolean
private int
private boolean
private String
private int
private int
private String
从类继承的字段 net.minecraft.client.gui.components.AbstractWidget
ACCESSIBILITY_TEXTURE, active, alpha, height, isHovered, packedFGColor, UNSET_FG_COLOR, visible, WIDGETS_LOCATION, width
从接口继承的字段 net.minecraft.client.gui.components.events.GuiEventListener
DOUBLE_CLICK_THRESHOLD_MS
-
构造器概要
构造器 -
方法概要
修饰符和类型方法说明boolean
boolean
charTyped
(char pCodePoint, int pModifiers) protected MutableComponent
void
deleteChars
(int pNum) private void
deleteText
(int pCount) void
deleteWords
(int pNum) private int
getCursorPos
(int pDelta) int
int
private int
int
getScreenX
(int pCharNum) getValue()
int
getWordPosition
(int pNumWords) private int
getWordPosition
(int pN, int pPos) private int
getWordPosition
(int pN, int pPos, boolean pSkipWs) void
insertText
(String pTextToWrite) private boolean
private boolean
boolean
isMouseOver
(double pMouseX, double pMouseY) boolean
boolean
keyPressed
(int pKeyCode, int pScanCode, int pModifiers) void
moveCursor
(int pDelta) void
moveCursorTo
(int pPos) void
void
nextFocusPath
(FocusNavigationEvent pEvent) void
onClick
(double pMouseX, double pMouseY) private void
onValueChange
(String pNewText) void
playDownSound
(SoundManager pHandler) private void
renderHighlight
(GuiGraphics pGuiGraphics, int pMinX, int pMinY, int pMaxX, int pMaxY) void
renderWidget
(GuiGraphics pGuiGraphics, int pMouseX, int pMouseY, float pPartialTick) void
setBordered
(boolean pEnableBackgroundDrawing) void
setCanLoseFocus
(boolean pCanLoseFocus) void
setCursorPosition
(int pPos) void
setEditable
(boolean pEnabled) void
void
setFocused
(boolean pFocused) void
setFormatter
(BiFunction<String, Integer, FormattedCharSequence> pTextFormatter) void
setHighlightPos
(int pPosition) void
void
setMaxLength
(int pLength) void
setResponder
(Consumer<String> pResponder) void
setSuggestion
(String pSuggestion) void
setTextColor
(int pColor) void
setTextColorUneditable
(int pColor) void
void
setVisible
(boolean pIsVisible) void
tick()
void
updateWidgetNarration
(NarrationElementOutput pNarrationElementOutput) 从类继承的方法 net.minecraft.client.gui.components.AbstractWidget
clearFGColor, clicked, createTooltipPositioner, defaultButtonNarrationText, getFGColor, getHeight, getMessage, getRectangle, getTabOrderGroup, getTooltip, getWidth, getX, getY, isActive, isFocused, isHovered, isHoveredOrFocused, isValidClickButton, mouseClicked, mouseDragged, mouseReleased, narrationPriority, onDrag, onRelease, render, renderScrollingString, renderScrollingString, renderTexture, setAlpha, setFGColor, setHeight, setMessage, setTabOrderGroup, setTooltip, setTooltipDelay, setWidth, setX, setY, updateNarration, visitWidgets, wrapDefaultNarrationMessage
从类继承的方法 java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
从接口继承的方法 net.minecraft.client.gui.components.events.GuiEventListener
getCurrentFocusPath, keyReleased, mouseMoved, mouseScrolled
从接口继承的方法 net.minecraftforge.client.extensions.IAbstractWidgetExtension
onClick
从接口继承的方法 net.minecraft.client.gui.layouts.LayoutElement
setPosition
从接口继承的方法 net.minecraft.client.gui.components.Renderable
render
-
字段详细资料
-
BACKWARDS
public static final int BACKWARDS- 另请参阅:
-
FORWARDS
public static final int FORWARDS- 另请参阅:
-
CURSOR_INSERT_WIDTH
private static final int CURSOR_INSERT_WIDTH- 另请参阅:
-
CURSOR_INSERT_COLOR
private static final int CURSOR_INSERT_COLOR- 另请参阅:
-
CURSOR_APPEND_CHARACTER
- 另请参阅:
-
DEFAULT_TEXT_COLOR
public static final int DEFAULT_TEXT_COLOR- 另请参阅:
-
BORDER_COLOR_FOCUSED
private static final int BORDER_COLOR_FOCUSED- 另请参阅:
-
BORDER_COLOR
private static final int BORDER_COLOR- 另请参阅:
-
BACKGROUND_COLOR
private static final int BACKGROUND_COLOR- 另请参阅:
-
font
-
value
-
maxLength
private int maxLength -
frame
private int frame -
bordered
private boolean bordered -
canLoseFocus
private boolean canLoseFocus -
isEditable
private boolean isEditable -
shiftPressed
private boolean shiftPressed -
displayPos
private int displayPos -
cursorPos
private int cursorPos -
highlightPos
private int highlightPos -
textColor
private int textColor -
textColorUneditable
private int textColorUneditable -
suggestion
-
responder
-
filter
-
formatter
-
hint
-
-
构造器详细资料
-
EditBox
-
EditBox
-
-
方法详细资料
-
setResponder
-
setFormatter
-
tick
public void tick() -
createNarrationMessage
- 覆盖:
createNarrationMessage
在类中AbstractWidget
-
setValue
-
getValue
-
getHighlighted
-
setFilter
-
insertText
-
onValueChange
-
deleteText
private void deleteText(int pCount) -
deleteWords
public void deleteWords(int pNum) -
deleteChars
public void deleteChars(int pNum) -
getWordPosition
public int getWordPosition(int pNumWords) -
getWordPosition
private int getWordPosition(int pN, int pPos) -
getWordPosition
private int getWordPosition(int pN, int pPos, boolean pSkipWs) -
moveCursor
public void moveCursor(int pDelta) -
getCursorPos
private int getCursorPos(int pDelta) -
moveCursorTo
public void moveCursorTo(int pPos) -
setCursorPosition
public void setCursorPosition(int pPos) -
moveCursorToStart
public void moveCursorToStart() -
moveCursorToEnd
public void moveCursorToEnd() -
keyPressed
public boolean keyPressed(int pKeyCode, int pScanCode, int pModifiers) - 指定者:
keyPressed
在接口中GuiEventListener
-
canConsumeInput
public boolean canConsumeInput() -
charTyped
public boolean charTyped(char pCodePoint, int pModifiers) - 指定者:
charTyped
在接口中GuiEventListener
-
onClick
public void onClick(double pMouseX, double pMouseY) - 覆盖:
onClick
在类中AbstractWidget
-
playDownSound
- 覆盖:
playDownSound
在类中AbstractWidget
-
renderWidget
- 指定者:
renderWidget
在类中AbstractWidget
-
renderHighlight
-
setMaxLength
public void setMaxLength(int pLength) -
getMaxLength
private int getMaxLength() -
getCursorPosition
public int getCursorPosition() -
isBordered
private boolean isBordered() -
setBordered
public void setBordered(boolean pEnableBackgroundDrawing) -
setTextColor
public void setTextColor(int pColor) -
setTextColorUneditable
public void setTextColorUneditable(int pColor) -
isMouseOver
public boolean isMouseOver(double pMouseX, double pMouseY) - 指定者:
isMouseOver
在接口中GuiEventListener
- 覆盖:
isMouseOver
在类中AbstractWidget
-
setFocused
public void setFocused(boolean pFocused) - 指定者:
setFocused
在接口中GuiEventListener
- 覆盖:
setFocused
在类中AbstractWidget
-
isEditable
private boolean isEditable() -
setEditable
public void setEditable(boolean pEnabled) -
getInnerWidth
public int getInnerWidth() -
setHighlightPos
public void setHighlightPos(int pPosition) -
setCanLoseFocus
public void setCanLoseFocus(boolean pCanLoseFocus) -
isVisible
public boolean isVisible() -
setVisible
public void setVisible(boolean pIsVisible) -
setSuggestion
-
getScreenX
public int getScreenX(int pCharNum) -
updateWidgetNarration
- 指定者:
updateWidgetNarration
在类中AbstractWidget
-
setHint
-