public static class RenderTooltipEvent.Pre extends RenderTooltipEvent
This event is Cancelable
.
RenderTooltipEvent.Post, RenderTooltipEvent.PostBackground, RenderTooltipEvent.PostText, RenderTooltipEvent.Pre
Event.HasResult, Event.Result
Constructor and Description |
---|
Pre(ItemStack stack,
java.util.List<java.lang.String> lines,
int x,
int y,
int screenWidth,
int screenHeight,
int maxWidth,
FontRenderer fr) |
Modifier and Type | Method and Description |
---|---|
int |
getMaxWidth() |
int |
getScreenHeight() |
int |
getScreenWidth() |
void |
setFontRenderer(FontRenderer fr)
Sets the
FontRenderer to be used to render text. |
void |
setMaxWidth(int maxWidth)
Sets the max width of the tooltip.
|
void |
setScreenHeight(int screenHeight) |
void |
setScreenWidth(int screenWidth) |
void |
setX(int x)
Set the X origin of the tooltip.
|
void |
setY(int y)
Set the Y origin of the tooltip.
|
getFontRenderer, getLines, getStack, getX, getY
getListenerList, getPhase, getResult, hasResult, isCancelable, isCanceled, setCanceled, setPhase, setResult, setup
public Pre(@Nonnull ItemStack stack, @Nonnull java.util.List<java.lang.String> lines, int x, int y, int screenWidth, int screenHeight, int maxWidth, @Nonnull FontRenderer fr)
public int getScreenWidth()
public void setScreenWidth(int screenWidth)
public int getScreenHeight()
public void setScreenHeight(int screenHeight)
public int getMaxWidth()
public void setMaxWidth(int maxWidth)
public void setFontRenderer(@Nonnull FontRenderer fr)
FontRenderer
to be used to render text.public void setX(int x)
public void setY(int y)