Code example for ForegroundColorSpan

0
     * @param text 
     * @param color 
     * @return this text 
     */ 
    public StyledText foreground(final CharSequence text, final int color) {
        return append(text, new ForegroundColorSpan(color));
    } 
 
    /** 
     * Append text in with custom foreground color 
     * 
     * @param text 
     * @param color 
     * @return this text 
     */ 
    public StyledText foreground(final char text, final int color) {
        return append(text, new ForegroundColorSpan(color));
    } 
 
    /** 
Connect your IDE to all the code out there  Get Codota for Java