rcurses 2.2 → 2.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +6 -3
- data/lib/rcurses.rb +1 -1
- metadata +7 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 00434da0ec522a7b5452e13379984e832e5548ac7e070326b74b9e5e19da74a1
|
4
|
+
data.tar.gz: c49c694b53e4521d3959e76d18117dfc6f40c9a151c28d48d00ebf2688a261ac
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3cfd5abe01873f4e5a1b52bbf47e6e9322abe30ecbb366a80ccd97599cec04b02a61c1ed589a4bf60310380e7c0b4f2cde6e64d95cedb1403698e31ae6a63e7a
|
7
|
+
data.tar.gz: 0e0e13e13de006efe4c42c30e793a6aae63e1d6431748fe6f3aa79e9ef96721d5dae00517fe356b85c0d473ccd1c64bb6618c62a3e9e818681c8e39ea59bf755
|
data/README.md
CHANGED
@@ -4,12 +4,13 @@
|
|
4
4
|
|
5
5
|
<img src="img/rcurses-logo.png" width="150" height="150">
|
6
6
|
|
7
|
+
Create curses applications for the terminal easier than ever.
|
7
8
|
|
8
9
|
# Why?
|
9
10
|
Having struggled with the venerable curses library and the ruby interface to it for many years, I finally got around to write an alternative - in pure Ruby.
|
10
11
|
|
11
12
|
# Design principles
|
12
|
-
Simple
|
13
|
+
Simple and with minimum of external dependencies.
|
13
14
|
|
14
15
|
# Installation
|
15
16
|
Simply run `gem install rcurses`.
|
@@ -104,7 +105,7 @@ pure | Strip text of any "dressing" (example: with `text = "TEST".b`,
|
|
104
105
|
PS: Blink does not work in conjunction with setting a background color in urxvt. It does work in gnome-terminal. But the overall performance in urxvt as orders of magnitude better than gnome-terminal.
|
105
106
|
|
106
107
|
# module Cursor
|
107
|
-
Create a new cursor object with `mycursor = Cursor`. Then you can apply the following methods to `mycursor`:
|
108
|
+
To use this module, first do `include Rcurses::Cursor`. Create a new cursor object with `mycursor = Cursor`. Then you can apply the following methods to `mycursor`:
|
108
109
|
|
109
110
|
Method | Description
|
110
111
|
------------------|---------------------------------------------------------------
|
@@ -128,10 +129,12 @@ clear_line_after | Erase from the current position (inclusive) to the end of th
|
|
128
129
|
scroll_up | Scroll display up one line
|
129
130
|
scroll_down | Scroll display down one line
|
130
131
|
clear_screen_down | Clear screen down from current row
|
132
|
+
hide_cursor | Hide the cursor
|
133
|
+
show_cursor | Show cursor
|
131
134
|
|
132
135
|
# The function getchr
|
133
136
|
rcurses provides a vital extension to Ruby in reading characters entered by the user. This is especially needed for curses applications where readline inputs are required.
|
134
|
-
The function getchr is automatically included in your arsenal when you first do `include
|
137
|
+
The function getchr is automatically included in your arsenal when you first do `include Rcurses::Input`.
|
135
138
|
|
136
139
|
Simply use `chr = getchr` in a program to read any character input by the user. The returning code (the content of `chr` in this example) could be any of the following:
|
137
140
|
|
data/lib/rcurses.rb
CHANGED
@@ -5,7 +5,7 @@
|
|
5
5
|
# Web_site: http://isene.com/
|
6
6
|
# Github: https://github.com/isene/rcurses
|
7
7
|
# License: Public domain
|
8
|
-
# Version: 2.
|
8
|
+
# Version: 2.3: Updated docs.
|
9
9
|
|
10
10
|
require 'io/console' # Basic gem for rcurses
|
11
11
|
require 'io/wait' # stdin handling
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rcurses
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: '2.
|
4
|
+
version: '2.3'
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Geir Isene
|
@@ -24,12 +24,12 @@ dependencies:
|
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '2.0'
|
27
|
-
description: 'Create
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
27
|
+
description: 'Create curses applications for the terminal easier than ever. Create
|
28
|
+
panes (with the colors and(or border), manipulate the panes and add content. Dress
|
29
|
+
up text (in panes or anywhere in the terminal) in bold, italic, underline, reverse
|
30
|
+
color, blink and in any 256 terminal colors for foreground and background. Use a
|
31
|
+
simple editor to let users edit text in panes. Left, right or center align text
|
32
|
+
in panes. Cursor movement around the terminal. New in 2.3: Updated docs..'
|
33
33
|
email: g@isene.com
|
34
34
|
executables: []
|
35
35
|
extensions: []
|