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 :: jenkins decrypt password script console 
Java :: maven spring boot devtools install 
Java :: change java version command line debian 
Java :: Console color text java 
Java :: How do you nuke japan 
Java :: regex java email validation 
Java :: string to double java 
Java :: bootstrap center text vertically 
Java :: fullscreen activity android 
Java :: loop through dictionary java 
Java :: java int to roman 
Java :: Card view implement 
Java :: java random boolean 
Java :: ranfom number between 1 to 100 java 
Java :: love2d set screen size 
Java :: java create a set with values 
Java :: array to map java 
Java :: java android play sound file with variable 
Java :: set color of text for jlabel 
Java :: read int from keyboard java 
Java :: set text size programmatically android 
Java :: testing if editText is empty java 
Java :: java calculate delta time 
Java :: java robot left click 
Java :: create color object java 
Java :: java getdeclaredfield private field 
Java :: Selection Structure and Conditions 
Java :: appcompatdelegate.setdefaultnightmode(appcompatdelegate.mode_night_yes) not working 
Java :: foreach not applicable to type - binary tree sort 
Java :: Could not identify launch activity: Default Activity not found 
ADD CONTENT
Topic
Content
Source link
Name
6+2 =