aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/me/shedaniel/rei/gui/widget/LabelWidget.java
diff options
context:
space:
mode:
authorshedaniel <daniel@shedaniel.me>2020-04-30 01:08:07 +0800
committershedaniel <daniel@shedaniel.me>2020-04-30 02:27:38 +0800
commitbe7b641955a197d55251c3cbd4a314476cf94fb3 (patch)
tree1747230438e2daa7d8debd2f661a69ba11f4ea23 /src/main/java/me/shedaniel/rei/gui/widget/LabelWidget.java
parent43614d50fe2d965246b8ee4522f0ece646031ae9 (diff)
downloadRoughlyEnoughItems-be7b641955a197d55251c3cbd4a314476cf94fb3.tar.gz
RoughlyEnoughItems-be7b641955a197d55251c3cbd4a314476cf94fb3.tar.bz2
RoughlyEnoughItems-be7b641955a197d55251c3cbd4a314476cf94fb3.zip
Update to 20w18a and add recipe exporter
Signed-off-by: shedaniel <daniel@shedaniel.me>
Diffstat (limited to 'src/main/java/me/shedaniel/rei/gui/widget/LabelWidget.java')
-rw-r--r--src/main/java/me/shedaniel/rei/gui/widget/LabelWidget.java12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/main/java/me/shedaniel/rei/gui/widget/LabelWidget.java b/src/main/java/me/shedaniel/rei/gui/widget/LabelWidget.java
index 160604728..6e69a5f69 100644
--- a/src/main/java/me/shedaniel/rei/gui/widget/LabelWidget.java
+++ b/src/main/java/me/shedaniel/rei/gui/widget/LabelWidget.java
@@ -157,7 +157,7 @@ public class LabelWidget extends WidgetWithBounds {
@NotNull
@Override
public Rectangle getBounds() {
- int width = font.method_27525(text);
+ int width = font.getWidth(text);
Point pos = getLocation();
if (isCentered())
return new Rectangle(pos.x - width / 2 - 1, pos.y - 5, width + 2, 14);
@@ -171,18 +171,18 @@ public class LabelWidget extends WidgetWithBounds {
@Override
public void render(MatrixStack matrices, int mouseX, int mouseY, float delta) {
- int width = font.method_27525(text);
+ int width = font.getWidth(text);
Point pos = getLocation();
if (isCentered()) {
if (hasShadows)
- font.method_27517(matrices, text, pos.x - width / 2f, pos.y, defaultColor);
+ font.drawWithShadow(matrices, text, pos.x - width / 2f, pos.y, defaultColor);
else
- font.method_27528(matrices, text, pos.x - width / 2f, pos.y, defaultColor);
+ font.draw(matrices, text, pos.x - width / 2f, pos.y, defaultColor);
} else {
if (hasShadows)
- font.method_27517(matrices, text, pos.x, pos.y, defaultColor);
+ font.drawWithShadow(matrices, text, pos.x, pos.y, defaultColor);
else
- font.method_27528(matrices, text, pos.x, pos.y, defaultColor);
+ font.draw(matrices, text, pos.x, pos.y, defaultColor);
}
}