• Stars
    star
    1,008
  • Rank 45,589 (Top 0.9 %)
  • Language
    JavaScript
  • License
    MIT License
  • Created over 10 years ago
  • Updated about 2 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Drawing in terminal with unicode braille characters

node-drawille Build Status

drawing in terminal with unicode braille characters. The idea is based on drawille by @asciimoo.

cube

install

install the package with npm:

$ npm install --save drawille

usage

See examples.

this module provides a very basic API only, for fancy things, like drawing lines, use another module, like bresenham.

drawille-canvas provides HTML5 Canvas API for drawille.

api

Canvas(w, h)

Create a new canvas with the given dimensions. w must be multiple of 2, h must be multiple of 4. Uses columns & rows from process.stdout as default values for w and h.

canvas.set(x, y)

Draw point on canvas at the given position.

canvas.unset(x, y)

Delete point on canvas at the given position.

canvas.toggle(x, y)

Toggle point on canvas at the given position.

canvas.clear()

Clear the whole canvas (delete every point).

canvas.frame(delimiter)

return the current content of canvas, as a delimiter-delimited string. delimiter defaults to \n.

it uses braille characters to represent points, so every line has length of w/2, and the string contains h/4 lines.

projects

  • vtop uses it to draw CPU and memory usage charts in the terminal
  • datop uses it to draw dat statistics
  • boscillate uses it to draw baudio soundwaves in real-time

license

MIT

More Repositories

1

node-drawille-canvas

JavaScript
378
star
2

node-bresenham

JavaScript
66
star
3

es6-dic

JavaScript
13
star
4

node-fourier-motzkin

Fourier-Motzkin Elimination
JavaScript
11
star
5

funny-accidents

JavaScript
8
star
6

dotfiles

Lua
8
star
7

spacegame

JavaScript
7
star
8

node-tumblr-map

JavaScript
6
star
9

node-round-robin-database

JavaScript
6
star
10

advent-of-code-2019

Clojure
5
star
11

koa-parse-json

Parse JSON request body, with sane stacktrace
JavaScript
5
star
12

opencl-buddhabrot

C
4
star
13

node-drawille-spark

JavaScript
4
star
14

node-tinder-analytics

JavaScript
3
star
15

node-ts-openapi-dsl

TypeScript
3
star
16

aoc-21-clj

Clojure
3
star
17

arukereso-laptop-search

JavaScript
3
star
18

co-lock

JavaScript
3
star
19

cv

HTML
2
star
20

haskell-sudoku

Haskell
2
star
21

aoc-2018-clj

Clojure
2
star
22

spline-playground

JavaScript
2
star
23

danyi.me

JavaScript
1
star
24

clj-euler

Clojure
1
star
25

lena-fft

C++
1
star
26

rmc-demo

Created for toolchain: https://cloud.ibm.com/devops/toolchains/bba09526-84e5-488a-acac-55831f93f3ba?env_id=ibm%3Ayp%3Aus-south
Shell
1
star
27

node-subset-sum

Polynomial approximation of the subset-sum problem
JavaScript
1
star
28

node-ngram

create ngram tokens from a string
JavaScript
1
star
29

nodebp-spacegame

JavaScript
1
star
30

counter_react

first react code
JavaScript
1
star
31

cr-spline-editor

JavaScript
1
star
32

newman-coverage-example

TypeScript
1
star
33

node-gossip

I'm just playing with es6, go away :-)
JavaScript
1
star
34

rtx3080

JavaScript
1
star
35

pyettier

NextGenβ„’ formatter
1
star
36

resmon

Simple parser/wrapper for `sar(1)`
JavaScript
1
star
37

advent-of-code-2015-clj

Clojure
1
star
38

koa-continuation-local-storage

JavaScript
1
star
39

sudoku

C++
1
star
40

advent-of-code-2020

Clojure
1
star
41

random-webgl-art

JavaScript
1
star
42

bsc-thesis

TeX
1
star
43

volman

JavaScript
1
star
44

projective-transformation

JavaScript
1
star
45

gha-test

1
star
46

node-jadeite

Jade-like template library
JavaScript
1
star
47

node-i3-protocol

encode&decode i3 ipc messages
JavaScript
1
star
48

docker-iojs

1
star
49

node-i3-client

Control i3 from `node`!
1
star
50

madbence

1
star
51

node-mail-relay

JavaScript
1
star
52

fearlesscode_szoftlab

Java
1
star
53

react-onlab-preso

JavaScript
1
star