« get me outta code hell

Add invertOff ansi function - tui-lib - Pure Node.js library for making visual command-line programs (ala vim, ncdu)
about summary refs log tree commit diff
path: root/util
diff options
context:
space:
mode:
authorFlorrie <towerofnix@gmail.com>2017-12-08 10:24:26 -0400
committerFlorrie <towerofnix@gmail.com>2017-12-08 10:24:26 -0400
commit41219968957b3557e654b4e8c91a5ea8c71ef710 (patch)
tree3a8a41161e247adab97b7a35625c531c50b9a7fa /util
parent3f1ff3586fb5db8ab99fdab6e5c5a476cc129cba (diff)
Add invertOff ansi function
Diffstat (limited to 'util')
-rw-r--r--util/ansi.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/util/ansi.js b/util/ansi.js
index 0ee1bc1..564fdf8 100644
--- a/util/ansi.js
+++ b/util/ansi.js
@@ -96,6 +96,12 @@ const ansi = {
     return `${ESC}[7m`
   },
 
+  invertOff() {
+    // Un-inverts the foreground and backgrund colors.
+
+    return `${ESC}[27m`
+  },
+
   requestCursorPosition() {
     // Requests the position of the cursor.
     // Expect a stdin-result '\ESC[l;cR', where l is the line number (1-based),