Class TextFeatures

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

public class TextFeatures extends Object
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static String
    createBar(double progress, double total, int barLength)
    Creates a progress bar with specified parameters.
    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.
    static String
    CreateBar(double progress, double total, int barLength)
    Deprecated, for removal: This API element is subject to removal in a future version.
    static String
    CreateBar(double progress, double total, int barLength, String barColor, String fillColor, char barStyle, char fillStyle)
    Deprecated, for removal: This API element is subject to removal in a future version.
    static String
    limitCharacters(String text, int length)
    Limits the characters in a text to a specified length.
    static String
    LimitCharacters(String text, int length)
    Deprecated, for removal: This API element is subject to removal in a future version.
    static String
    limitDecimal(String text, int length)
    Limits the decimal places in a number to a specified length.
    static String
    LimitDecimal(String text, int length)
    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
  • 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

      @Deprecated(since="Replaced by createBar()", forRemoval=true) public static String CreateBar(double progress, double total, int barLength)
      Deprecated, for removal: This API element is subject to removal in a future version.
    • 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.
    • CreateBar

      @Deprecated(since="Replaced by createBar()", forRemoval=true) public static String CreateBar(double progress, double total, int barLength, String barColor, String fillColor, char barStyle, char fillStyle)
      Deprecated, for removal: This API element is subject to removal in a future version.
    • 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.
    • LimitCharacters

      @Deprecated(since="Replaced by limitCharacters()", forRemoval=true) public static String LimitCharacters(String text, int length)
      Deprecated, for removal: This API element is subject to removal in a future version.
    • 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.
    • LimitDecimal

      @Deprecated(since="Replaced by limitDecimal()", forRemoval=true) public static String LimitDecimal(String text, int length)
      Deprecated, for removal: This API element is subject to removal in a future version.