Record Class ConfigIcons.Icon
java.lang.Object
java.lang.Record
net.ixdarklord.coolcatcanvas.internal.client.gui.style.ConfigIcons.Icon
- Enclosing class:
ConfigIcons
-
Constructor Summary
ConstructorsConstructorDescriptionIcon(net.minecraft.resources.Identifier texture) Creates an instance of aIconrecord class. -
Method Summary
Modifier and TypeMethodDescriptionvoiddraw(net.minecraft.client.gui.GuiGraphicsExtractor graphics, int x, int y, int color) voiddraw(net.minecraft.client.gui.GuiGraphicsExtractor graphics, int x, int y, int size, int color) voiddrawCentered(net.minecraft.client.gui.GuiGraphicsExtractor graphics, int x, int y, int width, int height, int color) Draws the icon centered in a box.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.intheight()net.minecraft.resources.Identifiertexture()Returns the value of thetexturerecord component.final StringtoString()Returns a string representation of this record class.intwidth()
-
Constructor Details
-
Icon
public Icon(net.minecraft.resources.Identifier texture) Creates an instance of aIconrecord class.- Parameters:
texture- the value for thetexturerecord component
-
-
Method Details
-
width
public int width() -
height
public int height() -
draw
public void draw(net.minecraft.client.gui.GuiGraphicsExtractor graphics, int x, int y, int color) -
draw
public void draw(net.minecraft.client.gui.GuiGraphicsExtractor graphics, int x, int y, int size, int color) -
drawCentered
public void drawCentered(net.minecraft.client.gui.GuiGraphicsExtractor graphics, int x, int y, int width, int height, int color) Draws the icon centered in a box. -
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
texture
public net.minecraft.resources.Identifier texture()Returns the value of thetexturerecord component.- Returns:
- the value of the
texturerecord component
-