curses 1.4.4.beta.1 → 1.4.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/dependabot.yml +6 -0
- data/.github/workflows/macos.yml +1 -1
- data/.github/workflows/ubuntu.yml +2 -2
- data/.github/workflows/windows.yml +2 -2
- data/History.md +29 -0
- data/README.md +7 -0
- data/curses.gemspec +1 -1
- data/ext/curses/curses.c +9 -9
- data/sample/colors.rb +6 -1
- data/sample/form.rb +1 -1
- data/sample/menu.rb +2 -0
- metadata +6 -9
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4d3c4ee3a32a22bdc006790932cc8165fad60d26647406b36f5b13b313440a9e
|
4
|
+
data.tar.gz: 4f4ef970743073eea63a4747b395d98d9076e392e84f194cd5ab9e9245bad5a6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 006a0008c75d4384e8279b6208b3ad86bdb2291f5096002cda43fe2f833db46a46be38b382d6eb39fa48ad5759a2ce8070c68dd8afe648fd46aa4fb1165a5d5c
|
7
|
+
data.tar.gz: 6140a1f5a6474321de418cb189e542d1b6e13e79333637fb53fa082768fb9c97c23a865b7c14373a8e49f5384a2c3150e9ffb49157aeba340a0a1e26f7b2f775
|
data/.github/workflows/macos.yml
CHANGED
@@ -6,10 +6,10 @@ jobs:
|
|
6
6
|
test:
|
7
7
|
strategy:
|
8
8
|
matrix:
|
9
|
-
ruby: [ head, 3.
|
9
|
+
ruby: [ head, 3.3, 3.2, 3.1, 3.0 ]
|
10
10
|
runs-on: ubuntu-latest
|
11
11
|
steps:
|
12
|
-
- uses: actions/checkout@
|
12
|
+
- uses: actions/checkout@v4
|
13
13
|
- uses: ruby/setup-ruby@v1
|
14
14
|
with:
|
15
15
|
ruby-version: ${{ matrix.ruby }}
|
@@ -7,9 +7,9 @@ jobs:
|
|
7
7
|
runs-on: windows-latest
|
8
8
|
strategy:
|
9
9
|
matrix:
|
10
|
-
ruby: [ 'mingw', 'mswin', '
|
10
|
+
ruby: [ 'mingw', 'mswin', '3.3' ]
|
11
11
|
steps:
|
12
|
-
- uses: actions/checkout@
|
12
|
+
- uses: actions/checkout@v4
|
13
13
|
with:
|
14
14
|
submodules: true
|
15
15
|
- name: Set up Ruby
|
data/History.md
CHANGED
@@ -1,3 +1,32 @@
|
|
1
|
+
### 1.4.5 / 2024-04-24
|
2
|
+
|
3
|
+
New features:
|
4
|
+
|
5
|
+
* Add documentation of TERM.
|
6
|
+
Issue #80 by rubyFeedback.
|
7
|
+
* Add MacOS directives to install curses with menu support
|
8
|
+
Pull request #84 by AlexB52.
|
9
|
+
|
10
|
+
Bug fixes:
|
11
|
+
|
12
|
+
* Add x permissoin to samples.
|
13
|
+
Pull request #71 by dvarrui.
|
14
|
+
* Supress gem installation warning.
|
15
|
+
Issue #77 by rubyFeedback.
|
16
|
+
* Ignore Curses::UnknownCommandError.
|
17
|
+
Issue #79 by rubyFeedback.
|
18
|
+
* Fix installation problem on macOS (Apple Silicon).
|
19
|
+
Issue #85 by pusewicz.
|
20
|
+
|
21
|
+
### 1.4.4 / 2022-02-03
|
22
|
+
|
23
|
+
Bug fixes:
|
24
|
+
|
25
|
+
* Define Curses.colors even if COLORS is a macro.
|
26
|
+
Issue #69 by dvarrui.
|
27
|
+
* Use require instead of require_relative.
|
28
|
+
Pull request #68 by dvarrui.
|
29
|
+
|
1
30
|
### 1.4.3 / 2022-01-06
|
2
31
|
|
3
32
|
New features:
|
data/README.md
CHANGED
@@ -37,6 +37,13 @@ However, if you prefer ncurses to PDCurses, specify the following option:
|
|
37
37
|
|
38
38
|
On mingw, you need DevKit to compile the extension library.
|
39
39
|
|
40
|
+
On MacOS, `ncurses` menu isn't natively supported. You can install the gem with menu support using homebrew:
|
41
|
+
|
42
|
+
brew install ncurses
|
43
|
+
gem install curses -- --use-system-libraries --with-ncurses-dir=/usr/local/opt/ncurses
|
44
|
+
|
45
|
+
_with `/usr/local/opt/ncurses` the path where homebrew installed ncurses on your machine_
|
46
|
+
|
40
47
|
## Documentation
|
41
48
|
|
42
49
|
See [https://www.rubydoc.info/gems/curses](https://www.rubydoc.info/gems/curses).
|
data/curses.gemspec
CHANGED
data/ext/curses/curses.c
CHANGED
@@ -1368,7 +1368,7 @@ curses_can_change_color(VALUE obj)
|
|
1368
1368
|
|
1369
1369
|
#if defined(HAVE_COLORS) || defined(COLORS)
|
1370
1370
|
/*
|
1371
|
-
* Document-method: Curses.
|
1371
|
+
* Document-method: Curses.colors
|
1372
1372
|
*
|
1373
1373
|
* returns COLORS
|
1374
1374
|
*/
|
@@ -1398,7 +1398,7 @@ curses_color_content(VALUE obj, VALUE color)
|
|
1398
1398
|
}
|
1399
1399
|
|
1400
1400
|
|
1401
|
-
#if defined(HAVE_COLOR_PAIRS)
|
1401
|
+
#if defined(HAVE_COLOR_PAIRS) || defined(COLOR_PAIRS)
|
1402
1402
|
/*
|
1403
1403
|
* Document-method: Curses.color_pairs
|
1404
1404
|
*
|
@@ -3252,7 +3252,7 @@ item_opts_off_m(VALUE obj, VALUE opts)
|
|
3252
3252
|
* Get the current option bits of the item.
|
3253
3253
|
*/
|
3254
3254
|
static VALUE
|
3255
|
-
item_opts_m(VALUE obj
|
3255
|
+
item_opts_m(VALUE obj)
|
3256
3256
|
{
|
3257
3257
|
struct itemdata *itemp;
|
3258
3258
|
|
@@ -3701,7 +3701,7 @@ menu_set_fore(VALUE obj, VALUE attr)
|
|
3701
3701
|
* This is the highlight used for selected menu items.
|
3702
3702
|
*/
|
3703
3703
|
static VALUE
|
3704
|
-
menu_get_fore(VALUE obj
|
3704
|
+
menu_get_fore(VALUE obj)
|
3705
3705
|
{
|
3706
3706
|
struct menudata *menup;
|
3707
3707
|
|
@@ -3738,7 +3738,7 @@ menu_set_back(VALUE obj, VALUE attr)
|
|
3738
3738
|
* Get the background attribute of menu.
|
3739
3739
|
*/
|
3740
3740
|
static VALUE
|
3741
|
-
menu_get_back(VALUE obj
|
3741
|
+
menu_get_back(VALUE obj)
|
3742
3742
|
{
|
3743
3743
|
struct menudata *menup;
|
3744
3744
|
|
@@ -3835,7 +3835,7 @@ menu_opts_off_m(VALUE obj, VALUE opts)
|
|
3835
3835
|
* Get the current option bits of the menu.
|
3836
3836
|
*/
|
3837
3837
|
static VALUE
|
3838
|
-
menu_opts_m(VALUE obj
|
3838
|
+
menu_opts_m(VALUE obj)
|
3839
3839
|
{
|
3840
3840
|
struct menudata *menup;
|
3841
3841
|
|
@@ -4800,11 +4800,11 @@ curses_save_key_modifiers(VALUE obj, VALUE flag)
|
|
4800
4800
|
* == Examples
|
4801
4801
|
*
|
4802
4802
|
* * hello.rb
|
4803
|
-
* :include: sample/hello.rb
|
4803
|
+
* :include: ../../sample/hello.rb
|
4804
4804
|
*
|
4805
4805
|
*
|
4806
4806
|
* * rain.rb
|
4807
|
-
* :include: sample/rain.rb
|
4807
|
+
* :include: ../../sample/rain.rb
|
4808
4808
|
*
|
4809
4809
|
*
|
4810
4810
|
*/
|
@@ -4844,7 +4844,7 @@ Init_curses(void)
|
|
4844
4844
|
* == Example
|
4845
4845
|
*
|
4846
4846
|
* * mouse.rb
|
4847
|
-
* :include: sample/mouse.rb
|
4847
|
+
* :include: ../../sample/mouse.rb
|
4848
4848
|
*
|
4849
4849
|
*/
|
4850
4850
|
cMouseEvent = rb_define_class_under(mCurses,"MouseEvent",rb_cObject);
|
data/sample/colors.rb
CHANGED
@@ -1,6 +1,11 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
|
1
3
|
require "curses"
|
2
4
|
include Curses
|
3
5
|
|
6
|
+
# The TERM environment variable should be set to xterm-256color etc. to
|
7
|
+
# use 256 colors. Curses.colors returns the color numbers of the terminal.
|
8
|
+
|
4
9
|
begin
|
5
10
|
init_screen
|
6
11
|
|
@@ -23,4 +28,4 @@ begin
|
|
23
28
|
|
24
29
|
ensure
|
25
30
|
close_screen
|
26
|
-
end
|
31
|
+
end
|
data/sample/form.rb
CHANGED
data/sample/menu.rb
CHANGED
metadata
CHANGED
@@ -1,15 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: curses
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.4.
|
4
|
+
version: 1.4.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Shugo Maeda
|
8
8
|
- Eric Hodel
|
9
|
-
autorequire:
|
10
9
|
bindir: bin
|
11
10
|
cert_chain: []
|
12
|
-
date:
|
11
|
+
date: 2024-04-24 00:00:00.000000000 Z
|
13
12
|
dependencies:
|
14
13
|
- !ruby/object:Gem::Dependency
|
15
14
|
name: bundler
|
@@ -39,7 +38,6 @@ dependencies:
|
|
39
38
|
- - ">="
|
40
39
|
- !ruby/object:Gem::Version
|
41
40
|
version: '0'
|
42
|
-
description:
|
43
41
|
email:
|
44
42
|
- shugo@ruby-lang.org
|
45
43
|
- drbrain@segment7.net
|
@@ -48,6 +46,7 @@ extensions:
|
|
48
46
|
- ext/curses/extconf.rb
|
49
47
|
extra_rdoc_files: []
|
50
48
|
files:
|
49
|
+
- ".github/dependabot.yml"
|
51
50
|
- ".github/workflows/macos.yml"
|
52
51
|
- ".github/workflows/ubuntu.yml"
|
53
52
|
- ".github/workflows/windows.yml"
|
@@ -324,7 +323,6 @@ licenses:
|
|
324
323
|
- Ruby
|
325
324
|
- BSD-2-Clause
|
326
325
|
metadata: {}
|
327
|
-
post_install_message:
|
328
326
|
rdoc_options: []
|
329
327
|
require_paths:
|
330
328
|
- lib
|
@@ -335,12 +333,11 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
335
333
|
version: 2.6.0
|
336
334
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
337
335
|
requirements:
|
338
|
-
- - "
|
336
|
+
- - ">="
|
339
337
|
- !ruby/object:Gem::Version
|
340
|
-
version:
|
338
|
+
version: '0'
|
341
339
|
requirements: []
|
342
|
-
rubygems_version: 3.
|
343
|
-
signing_key:
|
340
|
+
rubygems_version: 3.6.0.dev
|
344
341
|
specification_version: 4
|
345
342
|
summary: A Ruby binding for curses, ncurses, and PDCurses. curses is an extension
|
346
343
|
library for text UI applications. Formerly part of the Ruby standard library, [curses
|