Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/samuallb/ncurses
Ncurses bindings for Crystal
https://github.com/samuallb/ncurses
crystal crystal-language curses library ncurses ncurses-library
Last synced: 8 days ago
JSON representation
Ncurses bindings for Crystal
- Host: GitHub
- URL: https://github.com/samuallb/ncurses
- Owner: SamualLB
- License: mit
- Created: 2018-07-14T19:09:00.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2024-06-15T05:16:37.000Z (5 months ago)
- Last Synced: 2024-10-04T21:33:18.189Z (about 1 month ago)
- Topics: crystal, crystal-language, curses, library, ncurses, ncurses-library
- Language: Crystal
- Homepage: https://samuallb.github.io/ncurses/
- Size: 187 KB
- Stars: 25
- Watchers: 3
- Forks: 7
- Open Issues: 6
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
[![Build Status](https://travis-ci.com/SamualLB/ncurses.svg?branch=master)](https://travis-ci.com/SamualLB/ncurses)
# ncursesNcurses Bindings for Crystal
## Installation
1. Add this to your application's `shard.yml`:
```yaml
dependencies:
ncurses:
github: SamualLB/ncurses
```2. Run `shards install`
**NOTE**: You may need to install the wide ncurses development library `libncursesw5-dev` (Debian)
## Usage
```crystal
require "ncurses"
```#### Basic Printing
```crystal
NCurses.startNCurses.print "Hello world!"
NCurses.end
```#### Run Examples
Prints input
```text
$ crystal run examples/input.cr
```Displays text with attributes
```text
$ crystal run examples/attributes.cr
```Displays text with colors
```text
$ crystal run examples/colors.cr
```Shows separate windows
```text
$ crystal run examples/windows.cr
```Mouse interaction with individual windows
```text
$ crystal run examples/window_enclose.cr
```Scroll when overflowing window
```text
$ crystal run examples/scroll.cr
```## Contributing
1. Fork it ( https://github.com/SamualLB/ncurses.git )
2. Create your feature branch (git checkout -b my-new-feature)
3. Commit your changes (git commit -am 'Add some feature')
4. Push to the branch (git push origin my-new-feature)
5. Create a new Pull Request## Contributors
- (https://github.com/jreinert) Joakim Reinert - creator, maintainer
- (https://github.com/SamualLB) Samual Black - maintainer