ChalkString extension
Extensions on the String class that allow you to use the Chalk methods directly on Strings, ie. 'This will be red italic'.red.italic 'This will be red on yellow background'.red.onYellow
- on
Properties
- bgBlack → String
-
Available on String, provided by the ChalkString extension
no setter - bgBlackBright → String
-
Available on String, provided by the ChalkString extension
no setter - bgBlue → String
-
Available on String, provided by the ChalkString extension
no setter - bgBlueBright → String
-
Available on String, provided by the ChalkString extension
no setter - bgBrightBlack → String
-
Available on String, provided by the ChalkString extension
no setter - bgBrightBlue → String
-
Available on String, provided by the ChalkString extension
no setter - bgBrightCyan → String
-
Available on String, provided by the ChalkString extension
no setter - bgBrightGreen → String
-
Available on String, provided by the ChalkString extension
no setter - bgBrightMagenta → String
-
Available on String, provided by the ChalkString extension
no setter - bgBrightRed → String
-
Available on String, provided by the ChalkString extension
no setter - bgBrightWhite → String
-
Available on String, provided by the ChalkString extension
no setter - bgBrightYellow → String
-
Available on String, provided by the ChalkString extension
no setter - bgCyan → String
-
Available on String, provided by the ChalkString extension
no setter - bgCyanBright → String
-
Available on String, provided by the ChalkString extension
no setter - bgGray → String
-
Available on String, provided by the ChalkString extension
no setter - bgGreen → String
-
Available on String, provided by the ChalkString extension
no setter - bgGreenBright → String
-
Available on String, provided by the ChalkString extension
no setter - bgGrey → String
-
Available on String, provided by the ChalkString extension
no setter - bgMagenta → String
-
Available on String, provided by the ChalkString extension
no setter - bgMagentaBright → String
-
Available on String, provided by the ChalkString extension
no setter - bgRed → String
-
Available on String, provided by the ChalkString extension
no setter - bgRedBright → String
-
Available on String, provided by the ChalkString extension
no setter - bgWhite → String
-
Available on String, provided by the ChalkString extension
no setter - bgWhiteBright → String
-
Available on String, provided by the ChalkString extension
no setter - bgYellow → String
-
Available on String, provided by the ChalkString extension
no setter - bgYellowBright → String
-
Available on String, provided by the ChalkString extension
no setter - black → String
-
Available on String, provided by the ChalkString extension
no setter - blackBright → String
-
Available on String, provided by the ChalkString extension
no setter - blackletter → String
-
Available on String, provided by the ChalkString extension
no setter - blink → String
-
Available on String, provided by the ChalkString extension
no setter - blue → String
-
Available on String, provided by the ChalkString extension
no setter - blueBright → String
-
Available on String, provided by the ChalkString extension
no setter - bold → String
-
Available on String, provided by the ChalkString extension
no setter - brightBlack → String
-
Available on String, provided by the ChalkString extension
no setter - brightBlue → String
-
Available on String, provided by the ChalkString extension
no setter - brightCyan → String
-
Available on String, provided by the ChalkString extension
no setter - brightGreen → String
-
Available on String, provided by the ChalkString extension
no setter - brightMagenta → String
-
Available on String, provided by the ChalkString extension
no setter - brightRed → String
-
Available on String, provided by the ChalkString extension
no setter - brightWhite → String
-
Available on String, provided by the ChalkString extension
no setter - brightYellow → String
-
Available on String, provided by the ChalkString extension
no setter - cyan → String
-
Available on String, provided by the ChalkString extension
no setter - cyanBright → String
-
Available on String, provided by the ChalkString extension
no setter - dim → String
-
Available on String, provided by the ChalkString extension
no setter - doubleUnderline → String
-
Available on String, provided by the ChalkString extension
no setter - doubleunderline → String
-
Available on String, provided by the ChalkString extension
no setter - doubleunderlined → String
-
Available on String, provided by the ChalkString extension
no setter - font1 → String
-
Available on String, provided by the ChalkString extension
no setter - font2 → String
-
Available on String, provided by the ChalkString extension
no setter - font3 → String
-
Available on String, provided by the ChalkString extension
no setter - font4 → String
-
Available on String, provided by the ChalkString extension
no setter - font5 → String
-
Available on String, provided by the ChalkString extension
no setter - font6 → String
-
Available on String, provided by the ChalkString extension
no setter - font7 → String
-
Available on String, provided by the ChalkString extension
no setter - font8 → String
-
Available on String, provided by the ChalkString extension
no setter - font9 → String
-
Available on String, provided by the ChalkString extension
no setter - font10 → String
-
Available on String, provided by the ChalkString extension
no setter - gray → String
-
Available on String, provided by the ChalkString extension
no setter - green → String
-
Available on String, provided by the ChalkString extension
no setter - greenBright → String
-
Available on String, provided by the ChalkString extension
no setter - grey → String
-
Available on String, provided by the ChalkString extension
no setter -
Available on String, provided by the ChalkString extension
no setter - inverse → String
-
Available on String, provided by the ChalkString extension
no setter - invert → String
-
Available on String, provided by the ChalkString extension
no setter - italic → String
-
Available on String, provided by the ChalkString extension
no setter - magenta → String
-
Available on String, provided by the ChalkString extension
no setter - magentaBright → String
-
Available on String, provided by the ChalkString extension
no setter - normal → String
-
Available on String, provided by the ChalkString extension
no setter - onBlack → String
-
Available on String, provided by the ChalkString extension
no setter - onBlue → String
-
Available on String, provided by the ChalkString extension
no setter - onBrightBlack → String
-
Available on String, provided by the ChalkString extension
no setter - onBrightBlue → String
-
Available on String, provided by the ChalkString extension
no setter - onBrightCyan → String
-
Available on String, provided by the ChalkString extension
no setter - onBrightGreen → String
-
Available on String, provided by the ChalkString extension
no setter - onBrightMagenta → String
-
Available on String, provided by the ChalkString extension
no setter - onBrightRed → String
-
Available on String, provided by the ChalkString extension
no setter - onBrightWhite → String
-
Available on String, provided by the ChalkString extension
no setter - onBrightYellow → String
-
Available on String, provided by the ChalkString extension
no setter - onCyan → String
-
Available on String, provided by the ChalkString extension
no setter - onGray → String
-
Available on String, provided by the ChalkString extension
no setter - onGreen → String
-
Available on String, provided by the ChalkString extension
no setter - onGrey → String
-
Available on String, provided by the ChalkString extension
no setter - onMagenta → String
-
Available on String, provided by the ChalkString extension
no setter - onRed → String
-
Available on String, provided by the ChalkString extension
no setter - onWhite → String
-
Available on String, provided by the ChalkString extension
no setter - onYellow → String
-
Available on String, provided by the ChalkString extension
no setter - overline → String
-
Available on String, provided by the ChalkString extension
no setter - overlined → String
-
Available on String, provided by the ChalkString extension
no setter - rapidblink → String
-
Available on String, provided by the ChalkString extension
no setter - red → String
-
Available on String, provided by the ChalkString extension
no setter - redBright → String
-
Available on String, provided by the ChalkString extension
no setter - reset → String
-
Available on String, provided by the ChalkString extension
no setter - strikethrough → String
-
Available on String, provided by the ChalkString extension
no setter - strip → String
-
Available on String, provided by the ChalkString extension
no setter - subscript → String
-
Available on String, provided by the ChalkString extension
no setter - superscript → String
-
Available on String, provided by the ChalkString extension
no setter - underline → String
-
Available on String, provided by the ChalkString extension
no setter - underlined → String
-
Available on String, provided by the ChalkString extension
no setter - visible → String
-
Available on String, provided by the ChalkString extension
no setter - white → String
-
Available on String, provided by the ChalkString extension
no setter - whiteBright → String
-
Available on String, provided by the ChalkString extension
no setter - yellow → String
-
Available on String, provided by the ChalkString extension
no setter - yellowBright → String
-
Available on String, provided by the ChalkString extension
no setter
Methods
-
ansi(
int ansicode) → String -
Available on String, provided by the ChalkString extension
Creates String with the foreground color specified by the ansi color escape code. https://en.wikipedia.org/wiki/ANSI_escape_code -
ansi256(
int ansicode256) → String -
Available on String, provided by the ChalkString extension
https://en.wikipedia.org/wiki/ANSI_escape_code -
ansiSgr(
dynamic openCode, dynamic closeCode) → String -
Available on String, provided by the ChalkString extension
https://en.wikipedia.org/wiki/ANSI_escape_code -
bgAnsi(
int ansicode) → String -
Available on String, provided by the ChalkString extension
Alternate name for onAnsi() (provided for legacy compatibility with JS Chalk) -
bgAnsi256(
int ansicode256) → String -
Available on String, provided by the ChalkString extension
Alternate name for onAnsi256() (provided for legacy compatibility with JS Chalk) -
bgGreyscale(
num greyscale) → String -
Available on String, provided by the ChalkString extension
Alternate name for onGreyscale() (provided for legacy compatibility with JS Chalk) -
bgHex(
dynamic hex) → String -
Available on String, provided by the ChalkString extension
Alternate name for onHex() (provided for legacy compatibility with JS Chalk). -
bgHsl(
num hue, num saturation, num lightness) → String -
Available on String, provided by the ChalkString extension
Alternate name for onHsl() (provided for legacy compatibility with JS Chalk) -
bgHsv(
num hue, num saturation, num value) → String -
Available on String, provided by the ChalkString extension
Alternate name for onHsv() (provided for legacy compatibility with JS Chalk) -
bgHwb(
num hue, num whiteness, num blackness) → String -
Available on String, provided by the ChalkString extension
Alternate name for onHwb() (provided for legacy compatibility with JS Chalk) -
bgKeyword(
String colorKeyword) → String -
Available on String, provided by the ChalkString extension
Alternate name for onKeyword() (provided for legacy compatibility with JS Chalk). -
bgLab(
num l, num a, num b) → String -
Available on String, provided by the ChalkString extension
Alternate name for onLab() (provided for legacy compatibility with JS Chalk) -
bgRgb(
num red, num green, num blue) → String -
Available on String, provided by the ChalkString extension
Alternate name for onRgb() (provided for legacy compatibility with JS Chalk). -
bgRgb16m(
num red, num green, num blue) → String -
Available on String, provided by the ChalkString extension
Alternate name for onRgb16m() (provided for legacy compatibility with JS Chalk). -
bgXyz(
num x, num y, num z) → String -
Available on String, provided by the ChalkString extension
Alternate name for onXyz() (provided for legacy compatibility with JS Chalk) -
greyscale(
num greyscale) → String -
Available on String, provided by the ChalkString extension
-
hex(
dynamic hex) → String -
Available on String, provided by the ChalkString extension
Returns a String with the foreground color set to the passed in RGB Hex code. This dynamically accepts color hex codes as integer codes (0xAABBCC) or (0xABC) or as strings ('#AABBCC') or ('#ABC') -
hsl(
num hue, num saturation, num lightness) → String -
Available on String, provided by the ChalkString extension
Creates String with foreground color defined from HSL (Hue, Saturation and Lightness) color space parameters. https://en.wikipedia.org/wiki/HSL_and_HSV -
hsv(
num hue, num saturation, num value) → String -
Available on String, provided by the ChalkString extension
Creates String with foreground color defined from HSV (Hue, Saturation and Value) color space parameters. https://en.wikipedia.org/wiki/HSL_and_HSV -
hwb(
num hue, num whiteness, num blackness) → String -
Available on String, provided by the ChalkString extension
Creates String with foreground color defined from HWB (Hue, Whiteness and Blackness) color space parameters. https://en.wikipedia.org/wiki/HWB_color_model -
keyword(
String colorKeyword) → String -
Available on String, provided by the ChalkString extension
Returns a String with the foreground color set to the color represented by the passed in color keyword. This accepts all of the standard X11/CSS/SVG color names, and the user can extend the list of accepted color keywords using the addColorKeywordRgb() and addColorKeywordHex() methods -
lab(
num l, num a, num b) → String -
Available on String, provided by the ChalkString extension
Creates String with foreground color defined from lab color space parameters. https://en.wikipedia.org/wiki/CIELAB_color_space#CIELAB -
onAnsi(
int ansicode) → String -
Available on String, provided by the ChalkString extension
Creates String with the background color specified by the ansi color escape code. https://en.wikipedia.org/wiki/ANSI_escape_code -
onAnsi256(
int ansicode256) → String -
Available on String, provided by the ChalkString extension
https://en.wikipedia.org/wiki/ANSI_escape_code -
onGreyscale(
num greyscale) → String -
Available on String, provided by the ChalkString extension
-
onHex(
dynamic hex) → String -
Available on String, provided by the ChalkString extension
Returns a String with the background color set to the passed in RGB Hex code. This dynamically accepts color hex codes as integer codes (0xAABBCC) or (0xABC) or as strings ('#AABBCC') or ('#ABC') -
onHsl(
num hue, num saturation, num lightness) → String -
Available on String, provided by the ChalkString extension
Creates String with background color defined from HSL (Hue, Saturation and Lightness) color space parameters. https://en.wikipedia.org/wiki/HSL_and_HSV -
onHsv(
num hue, num saturation, num value) → String -
Available on String, provided by the ChalkString extension
Creates chalk with background color defined from HSV (Hue, Saturation and Value) color space parameters. https://en.wikipedia.org/wiki/HSL_and_HSV -
onHwb(
num hue, num whiteness, num blackness) → String -
Available on String, provided by the ChalkString extension
Creates String with background color defined from HWB (Hue, Whiteness and Blackness) color space parameters. https://en.wikipedia.org/wiki/HWB_color_model -
onKeyword(
String colorKeyword) → String -
Available on String, provided by the ChalkString extension
Returns a String with the background color set to the color represented by the passed in color keyword. This accepts all of the standard X11/CSS/SVG color names, and the user can extend the list of accepted color keywords using the addColorKeywordRgb() and addColorKeywordHex() methods -
onLab(
num l, num a, num b) → String -
Available on String, provided by the ChalkString extension
Creates String with background color defined from lab color space parameters. https://en.wikipedia.org/wiki/CIELAB_color_space#CIELAB -
onRgb(
num red, num green, num blue) → String -
Available on String, provided by the ChalkString extension
Create String with a background color with the specified RGB values. -
onRgb16m(
num red, num green, num blue) → String -
Available on String, provided by the ChalkString extension
Create String with a background color with the specified RGB values (forces using ANSI 16m SGR codes, even iflevel
is not 3). -
onXyz(
num x, num y, num z) → String -
Available on String, provided by the ChalkString extension
Creates String with background color defined from XYZ color space parameters. https://en.wikipedia.org/wiki/CIE_1931_color_space -
rgb(
num red, num green, num blue) → String -
Available on String, provided by the ChalkString extension
Create String with a foreground color with the specified RGB values. -
rgb16m(
num red, num green, num blue) → String -
Available on String, provided by the ChalkString extension
Create String with a foreground color with the specified RGB values (forces using ANSI 16m SGR codes, even iflevel
is not 3). -
underlineRgb(
num red, num green, num blue) → String -
Available on String, provided by the ChalkString extension
Create String with an underline of the the specified RGB color WARNING: on some consoles without support for this, such as Android Studio, using this will prevent ALL styles of the Chalk from appearing -
underlineRgb16m(
num red, num green, num blue) → String -
Available on String, provided by the ChalkString extension
Create String with an underline of the the specified RGB color (forces using ANSI 16m SGR codes, even iflevel
is not 3) WARNING: on some consoles without support for this, such as Android Studio, using this will prevent ALL styles of the Chalk from appearing -
wrap(
String prefix, String suffix) → String -
Available on String, provided by the ChalkString extension
Wrap this chalk with specified prefix and suffix strings. -
xyz(
num x, num y, num z) → String -
Available on String, provided by the ChalkString extension
Creates String with foreground color defined from XYZ color space parameters. https://en.wikipedia.org/wiki/CIE_1931_color_space