1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00
ruby--ruby/lib/reline
st0012 36ca0e58b6 [ruby/reline] Use color name instead of code (integer) in dialog color APIs
As pointed out in the
[comment](https://github.com/ruby/reline/pull/413#issuecomment-1168033973),
the code is actually a control sequence and not only for colors.

To make the dialog color APIs safer to use, we should restrict its
usages and extract away the bg/fg concept from the input.

So in this commit, I made these changes:

1. The dialog_*_bg/fg_color APIs only takes and returns color names (symbol):
  - :black
  - :red
  - :green
  - :yellow
  - :blue
  - :magenta
  - :cyan
  - :white
2. Add additional dialog_*_bg/fg_color_sequence APIs to access the raw code.

https://github.com/ruby/reline/commit/b32a977766
2022-07-16 02:30:23 +09:00
..
key_actor [ruby/reline] Use unix_line_discard when Ctrl-u is entered 2021-12-30 20:23:58 +09:00
unicode [ruby/reline] Improve the performance of get_mbchar_width 2020-12-05 02:58:58 +09:00
ansi.rb [ruby/reline] Support S-Tab to move up completion cursor in vi-mode on Unix 2021-12-24 18:23:28 +09:00
config.rb [ruby/reline] Use color name instead of code (integer) in dialog color APIs 2022-07-16 02:30:23 +09:00
general_io.rb [ruby/reline] Prefer wait_readable for fiber scheduler. 2021-12-11 14:29:20 +09:00
history.rb
key_actor.rb
key_stroke.rb [ruby/reline] Execute compress_meta_key if convert_meta is on 2021-12-10 22:19:14 +09:00
kill_ring.rb [ruby/reline] Add Enumerable to KillRing for debugging 2020-12-19 02:12:11 +09:00
line_editor.rb [ruby/reline] Enable to change the background color of dialogs. (https://github.com/ruby/reline/pull/413) 2022-06-27 22:28:49 +09:00
reline.gemspec [ruby/reline] Require Ruby >= 2.6 2022-05-20 17:49:15 +09:00
terminfo.rb [ruby/reline] Revert "Merge pull request #441 from nevans/workaround-linker-script-so" 2022-06-13 19:33:15 +09:00
unicode.rb [ruby/reline] "Halfwidth char + halfwidth (han)dakuten" is a single grapheme. 2021-12-24 00:51:47 +09:00
version.rb [ruby/reline] Version 0.3.1 2022-01-02 11:24:14 +09:00
windows.rb [ruby/reline] Add a comment for VK_MENU 2022-01-27 20:54:09 +09:00