Questions tagged [blessed]

Blessed is a "curses-like library with a high level terminal interface API for Node.js."

Blessed is a JavaScript library, similar to (n)curses in C/C++. It makes it possible to create CLI (Command Line Interface) applications using Node.js.

The library is organized around widgets which provide a convenient way to build text interfaces:

  • Base Nodes: Node, Screen, Element
  • Boxes: Box, Text, Line, BigText
  • Lists: List, FileManager, ListTable, Listbar
  • Forms: Form, Input, Textarea, Textbox, Button, Checkbox, RadioSet, RadioButton
  • Prompts: Prompt, Question, Message, Loading
  • Data Display: ProgressBar, Log, Table
  • Special Elements: Terminal, Image, ANSIImage, OverlayImage, Video, Layout

This project is available on GitHub and npm.

37 questions
9
votes
1 answer

Drawing a line that's always as wide as its parent BoxElement?

I'm using a BoxElement from blessed to display a chat history. Sentences are added using pushLine. For clarity, days are divided by lines (another string added using pushLine). Each line is as wide as the parent BoxElement. If the TUI is resized…
Martin Cowie
  • 2,788
  • 7
  • 38
  • 74
8
votes
1 answer

Blessed server (Node.js) over websocket to Xterm.js client in Browser

What I have: Node.js script running Blessed, and http/websocket server. Browser running Xterm.js and websocket client. What I want to do: Render blessed to the xterm window over websockets. Server Code: "use strict"; process.title =…
6
votes
1 answer

Blessed: Make a log widget scrollable

I'm using the Blessed library to make a dashboard in the terminal. I'm logging things into a log widget, and would like to make the widget scrollable. With the below code, the scrollbar is appearing, but I can't actually scroll using my mouse wheel,…
Rich
  • 5,603
  • 9
  • 39
  • 61
5
votes
2 answers

Blessed "Prompt" is black on black by default - how do I style it?

I am using blessed and I am trying to add a prompt to my application. It works fine, but I can't read its text. I have prepared a minimal example, that illustrates, what I see. I would like to know how I can style the text in the inputs. The…
amenthes
  • 3,117
  • 1
  • 32
  • 38
4
votes
1 answer

How to create a scrollable box with blessed/nodejs

I cannot figure out, how to create a scrollable box with blessed. https://github.com/chjj/blessed According to the docs, it should be like this: "use strict"; const blessed = require('blessed'); const screen = blessed.screen({ smartCSR:…
Tanel Tammik
  • 15,489
  • 3
  • 22
  • 31
3
votes
0 answers

Rendering terminal ansi escape sequence in Blessed lib

I'm in a bad spot. I spent 8 month's working on a portfolio project believing that I could render terminal hyperlinks in the node library called Blessed. My problem is that I thought I was doing it successfully at one point, but now realized it's…
Zach_is_my_name
  • 59
  • 3
  • 14
3
votes
1 answer

Alternative debug output for node/vscode, while building a terminal based visualization

i'm developing a terminal based app with Node, and i'm using the terminal as output of a Blessed.js visualization. So, i can't use the terminal to console.log thing for debug. Does node offer an alternative debug output? I'm using VSCode. Thanks!
piLeoni
  • 131
  • 13
3
votes
1 answer

Blessed objects conversion to JSON

How do I convert a blessed object into JSON in Perl? Following is the array I have: @x = ({ 'notificationtype' => 'TRAP', 'receivedfrom' => 'UDP: [10.127.34.212]:48909->[10.127.34.182]:162', 'version' => 1, }, …
2
votes
1 answer

How to extend a non-exported class in TypeScript?

In my TypeScript program I want to extend a class that is declared in a library. The trick is that the library doesn't "export" it so I can not access it directly. Instead, it provides a builder function, like this: export namespace Library { …
Michael D.
  • 83
  • 7
2
votes
1 answer

Why does my python blessings print statement not print in the same spot?

I am using blessings (or blessed) to try to print in the same spot in a for-loop. However, I find that this only works if I print 3 above the bottom of the terminal, but if I print 1 or two lines above the bottom it prints a new line for each…
2
votes
1 answer

node.js - How to spawn a child process without blocking stdin of parent process?

I'm making an interactive CLI in node (and blessed.js) that spawns child processes every couple of seconds to run some Python scripts. These scripts modify a set of JSON files that the CLI pulls from. The problem is that the CLI must be able to…
1
vote
0 answers

How do I make text blink with blessed?

Im trying to make a blinking cursor for a Fallout 4 Termlink emulator In order to make the menu system work, I need to have a flashing cursor to move around. I saw that with a previous version of blessed (blessed 1.9) that there was an attribute…
Jaxer5636
  • 97
  • 10
1
vote
1 answer

unable to set color in blessed terminal cli

I was trying to set colour for my table for building a node-cli-terminal using blessed function createListTable(alignment, padding, isInteractive = false) { return { parent: screen, keys: true, align: alignment, selectedFg:…
piash
  • 153
  • 1
  • 5
1
vote
1 answer

Why is my .exe[Made with pyinstaller] says that blessed setupterm(kind=vtwin10),the vtwin10 terminal was not found?

hello I made a chess bot with python inside a virtualenv my bot uses blessed to color the boards it displays using pyinstaller I ran the command pyinstaller random_move_chessbot.py --onefile on my cmd, It generated the exe file but when I ran the…
Sasen Perera
  • 473
  • 1
  • 5
  • 12
1
vote
0 answers

Keeping a prompt at the bottom of the screen while avoiding overwritting it

I am trying to create a spigot-like interface in python. Here is what I've come up with so far: from blessed import Terminal import time print("pre-init") term = Terminal() print("post-init") line =…
Gradyn Wursten
  • 118
  • 2
  • 18
1
2 3