diff options
author | tomoya ishida <tomoyapenguin@gmail.com> | 2023-11-13 21:42:25 +0900 |
---|---|---|
committer | git <svn-admin@ruby-lang.org> | 2023-11-13 12:42:31 +0000 |
commit | 90b49024c0d5fe8fe60942b96dcbd1f610042f1b (patch) | |
tree | 71d11125058e206f912f1a17d3027cfb1e969a8e /doc | |
parent | 8e64c87f64508bf7192d44581632aff6dce15bf6 (diff) |
[ruby/reline] Fallback to 256color if COLORTERM != truecolor
(https://github.com/ruby/reline/pull/604)
* Fallback to 256color if COLORTERM != truecolor
* Add Reline::Face.force_truecolor to force truecolor without COLORTERM env
https://github.com/ruby/reline/commit/090e1e4df0
Diffstat (limited to 'doc')
-rw-r--r-- | doc/reline/face.md | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/doc/reline/face.md b/doc/reline/face.md index cf3bb69440..1fa916123b 100644 --- a/doc/reline/face.md +++ b/doc/reline/face.md @@ -102,7 +102,10 @@ irb(main):001:0> Reline::Face.configs :scrollbar=>{:foreground=>:white, :background=>:cyan, :escape_sequence=>"\e[0m\e[37;46m"}}} ``` -## Backlog - -- Support for 256-color terminal emulator. Fallback hex color code such as "#FF1020" to 256 colors +## 256-Color and TrueColor +Reline will automatically detect if your terminal emulator supports truecolor with `ENV['COLORTERM] in 'truecolor' | '24bit'`. When this env is not set, Reline will fallback to 256-color. +If your terminal emulator supports truecolor but does not set COLORTERM env, add this line to `.irbrc`. +```ruby +Reline::Face.force_truecolor +``` |