Search
 
SCRIPT & CODE EXAMPLE
 

JAVA

java console text color

// Define color constants
public static final String TEXT_RESET = "u001B[0m";
public static final String TEXT_BLACK = "u001B[30m";
public static final String TEXT_RED = "u001B[31m";
public static final String TEXT_GREEN = "u001B[32m";
public static final String TEXT_YELLOW = "u001B[33m";
public static final String TEXT_BLUE = "u001B[34m";
public static final String TEXT_PURPLE = "u001B[35m";
public static final String TEXT_CYAN = "u001B[36m";
public static final String TEXT_WHITE = "u001B[37m";

// Implementation
System.out.println(TEXT_RED + "This text is red!" + TEXT_RESET);
Comment

java console colors


public static final String ANSI_RESET = "u001B[0m";
public static final String ANSI_BLACK = "u001B[30m";
public static final String ANSI_RED = "u001B[31m";
public static final String ANSI_GREEN = "u001B[32m";
public static final String ANSI_YELLOW = "u001B[33m";
public static final String ANSI_BLUE = "u001B[34m";
public static final String ANSI_PURPLE = "u001B[35m";
public static final String ANSI_CYAN = "u001B[36m";
public static final String ANSI_WHITE = "u001B[37m";

Comment

PREVIOUS NEXT
Code Example
Java :: make javafx open full screen 
Java :: jbutton set background transparent 
Java :: java main 
Java :: java read file to string 
Java :: gson java maven dependency script google json repository 
Java :: javafx get screen size 
Java :: how to create new frame with java swing 
Java :: generate random password in java 
Java :: java program to calculate age from date of birth 
Java :: convert string to float java 
Java :: Card view implement 
Java :: java for loop high to low 
Java :: java how to get current date 
Java :: android java remove imageview source 
Java :: gravatar default 
Java :: java get files in directory 
Java :: how to hide status bar in android studio kotlin 
Java :: sololearn java shapes coding project 
Java :: guess the number java 
Java :: how to convert object to list in java 
Java :: read jar manifest 
Java :: javax notblank not working 
Java :: fullscreen in java 
Java :: from string to double andoird studio 
Java :: java method to capitalize first letter 
Java :: android hide textview 
Java :: spigot run code asynhronously 
Java :: inject in jsp 
Java :: rwegex java 
Java :: java create set with values 
ADD CONTENT
Topic
Content
Source link
Name
6+7 =