Class TextFeatures

java.lang.Object
valorless.valorlessutils.text.TextFeatures

public class TextFeatures extends Object
  • Constructor Details

    • TextFeatures

      public TextFeatures()
  • Method Details

    • CreateBar

      public static String CreateBar(double progress, double total, int barLength)
      Creates a progress bar with specified parameters.
      Parameters:
      progress - The current progress.
      total - The total progress value.
      barLength - The length of the progress bar.
      Returns:
      The created progress bar as a string.
    • CreateBar

      public static String CreateBar(double progress, double total, int barLength, String barColor, String fillColor, char barStyle, char fillStyle)
      Creates a progress bar with specified parameters and customizable styles and colors.
      Parameters:
      progress - The current progress.
      total - The total progress value.
      barLength - The length of the progress bar.
      barColor - The color of the progress bar. i.e. '§e'
      fillColor - The color of the filled part of the progress bar. i.e. '§e'
      barStyle - The style character for the progress bar. i.e. '#'
      fillStyle - The style character for the filled part of the progress bar. i.e. '='
      Returns:
      The created progress bar as a string with customizable styles and colors.
    • LimitCharacters

      public static String LimitCharacters(String text, int length)
      Limits the characters in a text to a specified length.
      Parameters:
      text - The text to limit.
      length - The maximum length of the text.
      Returns:
      The limited text.
    • LimitDecimal

      public static String LimitDecimal(String text, int length)
      Limits the decimal places in a number to a specified length.
      Parameters:
      text - The number to limit.
      length - The maximum length of the decimal places.
      Returns:
      The number with limited decimal places.