Class ScreenUtils

java.lang.Object
net.minecraftforge.client.gui.ScreenUtils

@Deprecated(forRemoval=true) public class ScreenUtils extends Object
Deprecated, for removal: This API element is subject to removal in a future version.
Use extension methods in IForgeGuiGraphics instead
This class provides several methods and constants used by the Config GUI classes.
Author:
bspkrs
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final int
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    static final int
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    static final int
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    static final String
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    static final String
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    static int[]
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    static final String
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    static final String
    Deprecated, for removal: This API element is subject to removal in a future version.
     
  • Constructor Summary

    Constructors
    Constructor
    Description
    Deprecated, for removal: This API element is subject to removal in a future version.
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static void
    blitInscribed(GuiGraphics guiGraphics, ResourceLocation texture, int x, int y, int boundsWidth, int boundsHeight, int rectWidth, int rectHeight)
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    static void
    blitInscribed(GuiGraphics guiGraphics, ResourceLocation texture, int x, int y, int boundsWidth, int boundsHeight, int rectWidth, int rectHeight, boolean centerX, boolean centerY)
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    static void
    blitWithBorder(GuiGraphics guiGraphics, int x, int y, int u, int v, int width, int height, int textureWidth, int textureHeight, int borderSize, float zLevel)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Draws a textured box of any size (smallest size is borderSize * 2 square) based on a fixed size textured box with continuous borders and filler.
    static void
    blitWithBorder(GuiGraphics guiGraphics, int x, int y, int u, int v, int width, int height, int textureWidth, int textureHeight, int topBorder, int bottomBorder, int leftBorder, int rightBorder, float zLevel)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Draws a textured box of any size (smallest size is borderSize * 2 square) based on a fixed size textured box with continuous borders and filler.
    static void
    blitWithBorder(GuiGraphics guiGraphics, ResourceLocation res, int x, int y, int u, int v, int width, int height, int textureWidth, int textureHeight, int borderSize, float zLevel)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Draws a textured box of any size (smallest size is borderSize * 2 square) based on a fixed size textured box with continuous borders and filler.
    static void
    blitWithBorder(GuiGraphics guiGraphics, ResourceLocation res, int x, int y, int u, int v, int width, int height, int textureWidth, int textureHeight, int topBorder, int bottomBorder, int leftBorder, int rightBorder, float zLevel)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Draws a textured box of any size (smallest size is borderSize * 2 square) based on a fixed size textured box with continuous borders and filler.
    static void
    drawGradientRect(org.joml.Matrix4f mat, int zLevel, int left, int top, int right, int bottom, int startColor, int endColor)
    Deprecated, for removal: This API element is subject to removal in a future version.
    static void
    drawTexturedModalRect(GuiGraphics guiGraphics, int x, int y, int u, int v, int width, int height, float zLevel)
    Deprecated, for removal: This API element is subject to removal in a future version.
    static int
    getColorFromFormattingCharacter(char c, boolean isLighter)
    Deprecated, for removal: This API element is subject to removal in a future version.
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • DEFAULT_BACKGROUND_COLOR

      public static final int DEFAULT_BACKGROUND_COLOR
      Deprecated, for removal: This API element is subject to removal in a future version.
      See Also:
    • DEFAULT_BORDER_COLOR_START

      public static final int DEFAULT_BORDER_COLOR_START
      Deprecated, for removal: This API element is subject to removal in a future version.
      See Also:
    • DEFAULT_BORDER_COLOR_END

      public static final int DEFAULT_BORDER_COLOR_END
      Deprecated, for removal: This API element is subject to removal in a future version.
      See Also:
    • UNDO_CHAR

      public static final String UNDO_CHAR
      Deprecated, for removal: This API element is subject to removal in a future version.
      See Also:
    • RESET_CHAR

      public static final String RESET_CHAR
      Deprecated, for removal: This API element is subject to removal in a future version.
      See Also:
    • VALID

      public static final String VALID
      Deprecated, for removal: This API element is subject to removal in a future version.
      See Also:
    • INVALID

      public static final String INVALID
      Deprecated, for removal: This API element is subject to removal in a future version.
      See Also:
    • TEXT_COLOR_CODES

      public static int[] TEXT_COLOR_CODES
      Deprecated, for removal: This API element is subject to removal in a future version.
  • Constructor Details

    • ScreenUtils

      public ScreenUtils()
      Deprecated, for removal: This API element is subject to removal in a future version.
  • Method Details

    • getColorFromFormattingCharacter

      public static int getColorFromFormattingCharacter(char c, boolean isLighter)
      Deprecated, for removal: This API element is subject to removal in a future version.
    • blitWithBorder

      public static void blitWithBorder(GuiGraphics guiGraphics, int x, int y, int u, int v, int width, int height, int textureWidth, int textureHeight, int borderSize, float zLevel)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Draws a textured box of any size (smallest size is borderSize * 2 square) based on a fixed size textured box with continuous borders and filler. It is assumed that the desired texture ResourceLocation object has been bound using Minecraft.getMinecraft().getTextureManager().bindTexture(resourceLocation).
      Parameters:
      guiGraphics - the gui graphics
      x - x axis offset
      y - y axis offset
      u - bound resource location image x offset
      v - bound resource location image y offset
      width - the desired box width
      height - the desired box height
      textureWidth - the width of the box texture in the resource location image
      textureHeight - the height of the box texture in the resource location image
      borderSize - the size of the box's borders
      zLevel - the zLevel to draw at
    • blitWithBorder

      public static void blitWithBorder(GuiGraphics guiGraphics, ResourceLocation res, int x, int y, int u, int v, int width, int height, int textureWidth, int textureHeight, int borderSize, float zLevel)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Draws a textured box of any size (smallest size is borderSize * 2 square) based on a fixed size textured box with continuous borders and filler. The provided ResourceLocation object will be bound using Minecraft.getMinecraft().getTextureManager().bindTexture(resourceLocation).
      Parameters:
      guiGraphics - the gui graphics
      res - the ResourceLocation object that contains the desired image
      x - x axis offset
      y - y axis offset
      u - bound resource location image x offset
      v - bound resource location image y offset
      width - the desired box width
      height - the desired box height
      textureWidth - the width of the box texture in the resource location image
      textureHeight - the height of the box texture in the resource location image
      borderSize - the size of the box's borders
      zLevel - the zLevel to draw at
    • blitWithBorder

      public static void blitWithBorder(GuiGraphics guiGraphics, ResourceLocation res, int x, int y, int u, int v, int width, int height, int textureWidth, int textureHeight, int topBorder, int bottomBorder, int leftBorder, int rightBorder, float zLevel)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Draws a textured box of any size (smallest size is borderSize * 2 square) based on a fixed size textured box with continuous borders and filler. The provided ResourceLocation object will be bound using Minecraft.getMinecraft().getTextureManager().bindTexture(resourceLocation).
      Parameters:
      guiGraphics - the gui graphics
      res - the ResourceLocation object that contains the desired image
      x - x axis offset
      y - y axis offset
      u - bound resource location image x offset
      v - bound resource location image y offset
      width - the desired box width
      height - the desired box height
      textureWidth - the width of the box texture in the resource location image
      textureHeight - the height of the box texture in the resource location image
      topBorder - the size of the box's top border
      bottomBorder - the size of the box's bottom border
      leftBorder - the size of the box's left border
      rightBorder - the size of the box's right border
      zLevel - the zLevel to draw at
    • blitWithBorder

      public static void blitWithBorder(GuiGraphics guiGraphics, int x, int y, int u, int v, int width, int height, int textureWidth, int textureHeight, int topBorder, int bottomBorder, int leftBorder, int rightBorder, float zLevel)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Draws a textured box of any size (smallest size is borderSize * 2 square) based on a fixed size textured box with continuous borders and filler. It is assumed that the desired texture ResourceLocation object has been bound using Minecraft.getMinecraft().getTextureManager().bindTexture(resourceLocation).
      Parameters:
      guiGraphics - the gui graphics
      x - x axis offset
      y - y axis offset
      u - bound resource location image x offset
      v - bound resource location image y offset
      width - the desired box width
      height - the desired box height
      textureWidth - the width of the box texture in the resource location image
      textureHeight - the height of the box texture in the resource location image
      topBorder - the size of the box's top border
      bottomBorder - the size of the box's bottom border
      leftBorder - the size of the box's left border
      rightBorder - the size of the box's right border
      zLevel - the zLevel to draw at
    • drawTexturedModalRect

      @Deprecated(forRemoval=true) public static void drawTexturedModalRect(GuiGraphics guiGraphics, int x, int y, int u, int v, int width, int height, float zLevel)
      Deprecated, for removal: This API element is subject to removal in a future version.
    • drawGradientRect

      @Deprecated(forRemoval=true) public static void drawGradientRect(org.joml.Matrix4f mat, int zLevel, int left, int top, int right, int bottom, int startColor, int endColor)
      Deprecated, for removal: This API element is subject to removal in a future version.
    • blitInscribed

      public static void blitInscribed(GuiGraphics guiGraphics, ResourceLocation texture, int x, int y, int boundsWidth, int boundsHeight, int rectWidth, int rectHeight)
      Deprecated, for removal: This API element is subject to removal in a future version.
    • blitInscribed

      public static void blitInscribed(GuiGraphics guiGraphics, ResourceLocation texture, int x, int y, int boundsWidth, int boundsHeight, int rectWidth, int rectHeight, boolean centerX, boolean centerY)
      Deprecated, for removal: This API element is subject to removal in a future version.