public class BoxWidget extends ElementWidget
| Modifier and Type | Field and Description |
|---|---|
protected boolean |
animateColors |
protected BoxElement |
box |
protected LerpedFloat |
colorAnimation |
protected Color |
customBackground |
protected Color |
customBorderBot |
protected Color |
customBorderTop |
protected Color |
gradientColor1 |
protected Color |
gradientColor2 |
static java.util.function.Function<BoxWidget,DelegatedStencilElement.ElementRenderer> |
gradientFactory |
element, fade, fadeModX, fadeModY, paddingX, paddingY, rescaleElement, rescaleSizeX, rescaleSizeY, usesFadeonClick, toolTip, wasHovered, z| Constructor and Description |
|---|
BoxWidget() |
BoxWidget(int x,
int y) |
BoxWidget(int x,
int y,
int width,
int height) |
| Modifier and Type | Method and Description |
|---|---|
<T extends BoxWidget> |
animateColors(boolean b) |
void |
animateGradientFromState() |
protected void |
beforeRender(com.mojang.blaze3d.matrix.MatrixStack ms,
int mouseX,
int mouseY,
float partialTicks) |
BoxElement |
getBox() |
Theme.Key |
getClickTheme() |
Theme.Key |
getDisabledTheme() |
Theme.Key |
getHoverTheme() |
Theme.Key |
getIdleTheme() |
boolean |
isMouseOver(double mX,
double mY) |
void |
onClick(double x,
double y) |
void |
renderButton(com.mojang.blaze3d.matrix.MatrixStack ms,
int mouseX,
int mouseY,
float partialTicks) |
void |
tick() |
void |
updateColorsFromState() |
<T extends BoxWidget> |
withBorderColors(Color top,
Color bot) |
<T extends BoxWidget> |
withBorderColors(Couple<Color> colors) |
<T extends BoxWidget> |
withBounds(int width,
int height) |
<T extends BoxWidget> |
withCustomBackground(Color color) |
disableFade, disableRescale, enableFade, fade, fade, getRenderElement, mapElement, modifyElement, rescaleElement, showing, showingElement, withPaddingafterRender, atZLevel, clicked, getToolTip, render, runCallback, withCallback, withCallbackchangeFocus, clearFGColor, createNarrationMessage, getFGColor, getHeight, getMessage, getWidth, getYImage, isFocused, isHovered, isValidClickButton, mouseClicked, mouseDragged, mouseReleased, narrate, onDrag, onFocusedChanged, onRelease, playDownSound, queueNarration, renderBg, renderToolTip, setAlpha, setFGColor, setFocused, setHeight, setMessage, setWidthblit, blit, blit, blit, blit, blitOutlineBlack, drawCenteredString, drawCenteredString, drawString, drawString, fill, fillGradient, fillGradient, getBlitOffset, hLine, setBlitOffset, vLinepublic static final java.util.function.Function<BoxWidget,DelegatedStencilElement.ElementRenderer> gradientFactory
protected BoxElement box
protected Color customBorderTop
protected Color customBorderBot
protected Color customBackground
protected boolean animateColors
protected LerpedFloat colorAnimation
protected Color gradientColor1
protected Color gradientColor2
public BoxWidget()
public BoxWidget(int x,
int y)
public BoxWidget(int x,
int y,
int width,
int height)
public <T extends BoxWidget> T withBounds(int width, int height)
public <T extends BoxWidget> T animateColors(boolean b)
public void tick()
tick in class ElementWidgetpublic void onClick(double x,
double y)
onClick in class AbstractSimiWidgetprotected void beforeRender(@Nonnull
com.mojang.blaze3d.matrix.MatrixStack ms,
int mouseX,
int mouseY,
float partialTicks)
beforeRender in class ElementWidgetpublic void renderButton(@Nonnull
com.mojang.blaze3d.matrix.MatrixStack ms,
int mouseX,
int mouseY,
float partialTicks)
renderButton in class ElementWidgetpublic boolean isMouseOver(double mX,
double mY)
isMouseOver in interface net.minecraft.client.gui.IGuiEventListenerisMouseOver in class net.minecraft.client.gui.widget.Widgetpublic BoxElement getBox()
public void updateColorsFromState()
public void animateGradientFromState()
public Theme.Key getDisabledTheme()
public Theme.Key getIdleTheme()
public Theme.Key getHoverTheme()
public Theme.Key getClickTheme()