This module contains procedures and generic interfaces for styling strings according for display on DEC VT100 or compatible terminals.
More...
|
character(*, SK), parameter | MODULE_NAME = "@pm_strANSI" |
|
character(4, SK) | bold = ESC//"[1m" |
| The ANSI escape code that makes subsequent texts appear bold/bright. More...
|
|
character(4, SK) | bright = ESC//"[1m" |
| The ANSI escape code that makes subsequent texts appear bold/bright. More...
|
|
character(4, SK) | dim = ESC//"[2m" |
| The ANSI escape code that makes subsequent texts appear dim. More...
|
|
character(4, SK) | italic = ESC//"[3m" |
| The ANSI escape code that makes subsequent texts appear italic. More...
|
|
character(4, SK) | underlined = ESC//"[4m" |
| The ANSI escape code that makes subsequent texts appear underlined. More...
|
|
character(4, SK) | blinking = ESC//"[5m" |
| The ANSI escape code that makes subsequent texts appear blinking (not universally supported). More...
|
|
character(4, SK) | reverse = ESC//"[7m" |
| The ANSI escape code that makes subsequent texts appear in reverse. More...
|
|
character(4, SK) | hidden = ESC//"[8m" |
| The ANSI escape code that makes subsequent texts disappear (hidden but not removed!). More...
|
|
character(4, SK) | strike = ESC//"[9m" |
| The ANSI escape code that makes subsequent texts to have strike-through (not universally supported). More...
|
|
character(4, SK) | endbold = ESC//"[1m" |
| The ANSI escape code that ends the ANSI style bold/bright. More...
|
|
character(4, SK) | endbright = ESC//"[1m" |
| The ANSI escape code that ends the ANSI style bold/bright. More...
|
|
character(4, SK) | enddim = ESC//"[2m" |
| The ANSI escape code that ends the ANSI style dim. More...
|
|
character(4, SK) | enditalic = ESC//"[3m" |
| The ANSI escape code that ends the ANSI style italic. More...
|
|
character(4, SK) | endunderlined = ESC//"[4m" |
| The ANSI escape code that ends the ANSI style underlined. More...
|
|
character(4, SK) | endblinking = ESC//"[5m" |
| The ANSI escape code that ends the ANSI style blinking. More...
|
|
character(4, SK) | endreverse = ESC//"[7m" |
| The ANSI escape code that ends the ANSI style reverse. More...
|
|
character(4, SK) | endhidden = ESC//"[8m" |
| The ANSI escape code that ends the ANSI style hidden. More...
|
|
character(4, SK) | endstrike = ESC//"[9m" |
| The ANSI escape code that ends the ANSI style strike-through. More...
|
|
character(4, SK) | endall = ESC//"[0m" |
| The ANSI escape code that resets all previously specified ANSI text styles (same as [](pm_strANSI::reset)). More...
|
|
character(4, SK) | reset = ESC//"[0m" |
| The ANSI escape code that resets all previously specified ANSI text styles (same as [](pm_strANSI::endall)). More...
|
|
character(5, SK) | fblack = ESC//"[30m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for foreground black color. More...
|
|
character(5, SK) | fred = ESC//"[31m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for foreground red color. More...
|
|
character(5, SK) | fgreen = ESC//"[32m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for foreground green color. More...
|
|
character(5, SK) | fyellow = ESC//"[33m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for foreground yellow color. More...
|
|
character(5, SK) | fblue = ESC//"[34m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for foreground blue color. More...
|
|
character(5, SK) | fmagenta = ESC//"[35m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for foreground magenta color. More...
|
|
character(5, SK) | fcyan = ESC//"[36m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for foreground cyan color. More...
|
|
character(5, SK) | fwhite = ESC//"[37m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for foreground white (light gray) color. More...
|
|
character(5, SK) | fdefault = ESC//"[39m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for foreground default color. More...
|
|
character(6, SK) | flblack = ESC//"[90m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for foreground light black (dark gray) color. More...
|
|
character(6, SK) | flred = ESC//"[91m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for foreground light red color. More...
|
|
character(6, SK) | flgreen = ESC//"[92m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for foreground light green color. More...
|
|
character(6, SK) | flyellow = ESC//"[93m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for foreground light yellow color. More...
|
|
character(6, SK) | flblue = ESC//"[94m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for foreground light blue color. More...
|
|
character(6, SK) | flmagenta = ESC//"[95m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for foreground light magenta color. More...
|
|
character(6, SK) | flcyan = ESC//"[96m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for foreground light cyan color. More...
|
|
character(6, SK) | flwhite = ESC//"[97m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for foreground light gray color. More...
|
|
character(5, SK) | bblack = ESC//"[40m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for background black color. More...
|
|
character(5, SK) | bred = ESC//"[41m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for background red color. More...
|
|
character(5, SK) | bgreen = ESC//"[42m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for background green color. More...
|
|
character(5, SK) | byellow = ESC//"[43m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for background yellow color. More...
|
|
character(5, SK) | bblue = ESC//"[44m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for background blue color. More...
|
|
character(5, SK) | bmagenta = ESC//"[45m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for background magenta color. More...
|
|
character(5, SK) | bcyan = ESC//"[46m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for background cyan color. More...
|
|
character(5, SK) | bwhite = ESC//"[47m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for background white (light gray) color. More...
|
|
character(5, SK) | bdefault = ESC//"[49m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for background default color. More...
|
|
character(6, SK) | blblack = ESC//"[100m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for background light black (dark gray) color. More...
|
|
character(6, SK) | blred = ESC//"[101m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for background light red color. More...
|
|
character(6, SK) | blgreen = ESC//"[102m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for background light green color. More...
|
|
character(6, SK) | blyellow = ESC//"[103m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for background light yellow color. More...
|
|
character(6, SK) | blblue = ESC//"[104m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for background light blue color. More...
|
|
character(6, SK) | blmagenta = ESC//"[105m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for background light magenta color. More...
|
|
character(6, SK) | blcyan = ESC//"[106m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for background light cyan color. More...
|
|
character(6, SK) | blwhite = ESC//"[107m" |
| The scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) containing the ANSI code sequence for background light white color. More...
|
|
This module contains procedures and generic interfaces for styling strings according for display on DEC VT100 or compatible terminals.
- Bug:
- ESC should be ideally and portably defined as
achar(27, kind)
, once the gfortran 11 bug is resolved.
The current implementation includes only a subset of the ANSI standard text attributes and colors that are recognized by virtually all terminals and terminal emulators. These styles are particularly recognized by the Bash and Windows CMD (>2016) terminals.
Notational conventions used in this module
- Any object name that begins with an f is related to foreground effects.
- Any object name that begins with an b is related to background effects.
- Any object name that begins with an end contains the string that ends the corresponding ANSI style.
- Test:
- test_pm_strANSI
- Bug:
Status: Unresolved
Source: GNU Fortran Compiler gfortran
version 10-12
Description: The character ESC
should be ideally and portably defined as achar(27, kind)
.
However, GNU Fortran Compiler gfortran
as of version 11 cannot handle this in component initializations.
Remedy (as of ParaMonte Library version 2.0.0): The character ESC
is defined a direct copy of the actual character via a preprocessor macro.
- Todo:
- Critical Priority: The gfortran bug must be resolved as soon as possible.
Final Remarks ⛓
If you believe this algorithm or its documentation can be improved, we appreciate your contribution and help to edit this page's documentation and source file on GitHub.
For details on the naming abbreviations, see this page.
For details on the naming conventions, see this page.
This software is distributed under the MIT license with additional terms outlined below.
-
If you use any parts or concepts from this library to any extent, please acknowledge the usage by citing the relevant publications of the ParaMonte library.
-
If you regenerate any parts/ideas from this library in a programming environment other than those currently supported by this ParaMonte library (i.e., other than C, C++, Fortran, MATLAB, Python, R), please also ask the end users to cite this original ParaMonte library.
This software is available to the public under a highly permissive license.
Help us justify its continued development and maintenance by acknowledging its benefit to society, distributing it, and contributing to it.
- Copyright
- Computational Data Science Lab
- Author:
- Amir Shahmoradi, September 1, 2017, 12:00 AM, Institute for Computational Engineering and Sciences (ICES), The University of Texas Austin