All Projects → dhurum → Mattext

dhurum / Mattext

Licence: gpl-3.0
Simple matrix-style pager

Projects that are alternatives of or similar to Mattext

Liquidswipe
Android LiquidSwipe Library
Stars: ✭ 721 (+2020.59%)
Mutual labels:  pager
Element Web
element.io docker image generator
Stars: ✭ 21 (-38.24%)
Mutual labels:  matrix
Kakoune
mawww's experiment for a better code editor
Stars: ✭ 7,593 (+22232.35%)
Mutual labels:  console-application
Element Web
A glossy Matrix collaboration client for the web.
Stars: ✭ 7,547 (+22097.06%)
Mutual labels:  matrix
Nanny
A tidyverse suite for (pre-) machine-learning: cluster, PCA, permute, impute, rotate, redundancy, triangular, smart-subset, abundant and variable features.
Stars: ✭ 17 (-50%)
Mutual labels:  matrix
Neanderthal
Fast Clojure Matrix Library
Stars: ✭ 927 (+2626.47%)
Mutual labels:  matrix
Mtm
Perhaps the smallest useful terminal multiplexer in the world.
Stars: ✭ 677 (+1891.18%)
Mutual labels:  console-application
Matrix
A modern, C++20-native, single-file header-only dense 2D matrix library.
Stars: ✭ 30 (-11.76%)
Mutual labels:  matrix
Supreme
A command line visual file manager for linux
Stars: ✭ 22 (-35.29%)
Mutual labels:  console-application
Notecalc3
NoteCalc is a handy calculator trying to bring the advantages of Soulver to the web.
Stars: ✭ 879 (+2485.29%)
Mutual labels:  matrix
Fmatvec
A fast vector/matrix library
Stars: ✭ 5 (-85.29%)
Mutual labels:  matrix
Cglm
📽 Highly Optimized Graphics Math (glm) for C
Stars: ✭ 887 (+2508.82%)
Mutual labels:  matrix
Gridiron
Feature-Packed React Grid Framework
Stars: ✭ 8 (-76.47%)
Mutual labels:  pager
Cgmath
A linear algebra and mathematics library for computer graphics.
Stars: ✭ 773 (+2173.53%)
Mutual labels:  matrix
Mautrix Hangouts
A Matrix-Hangouts puppeting bridge
Stars: ✭ 29 (-14.71%)
Mutual labels:  matrix
Matrix Js Sdk
Matrix Client-Server SDK for JavaScript
Stars: ✭ 714 (+2000%)
Mutual labels:  matrix
Owl
Owl - OCaml Scientific and Engineering Computing @ http://ocaml.xyz
Stars: ✭ 919 (+2602.94%)
Mutual labels:  matrix
Delta
A syntax-highlighting pager for git, diff, and grep output
Stars: ✭ 11,555 (+33885.29%)
Mutual labels:  pager
Opencv Cheat Sheet
Opencv cheat sheet for C++
Stars: ✭ 30 (-11.76%)
Mutual labels:  matrix
Yadr
Yet another development roadmaps and proficiency matrixes
Stars: ✭ 11 (-67.65%)
Mutual labels:  matrix

Simple matrix-style pager

Mattext shows text with different animations (including matrix-style rain-of-symbols) during page changes (video).
Usage: mattext [options] file1 [file2 ...] or cat file | mattext [options].

Options:

  • -d, --delay <delay> - Delay between screen redraws, in milliseconds, default 60;
  • -l, --rand-len <length> - Maximum length of random symbols columns;
  • -n, --non-interact - Do not wait for user input before showing next page;
  • -i, --infinite - At the end of file start reading it from the beginning;
  • -b, --block-lines <lines> - Block until at least specified number of lines is read, default 1;
  • -B, --block-page - Block until full page is read;
  • -N, --no-color - Do not colorize output;
  • -C, --center-horiz - Center text horizontally;
  • -L, --center-horiz-longest - Center text horizontally by longest string;
  • -v, --center-vert - Center text vertically;
  • -e, --without-japanese - Do not use Japanese symbols;
  • -a, --animation <name> - Animation for switching pages. Available animations are matrix, reverse_matrix, none, fire, beam;
  • --animation-next <name> - Animation for showing next page;
  • --animation-prev <name> - Animation for showing previous page;
  • -t, --tab-width <width> - Tab width, minimum 1, default 4;

Commands:

  • q, ctrl + D - Exit program;
  • f, j, space, PgDown, Down - Show next page;
  • b, k, PgUp, Up - Show previous page;

Building:

You will need a c++ compiler with c++14 (c++1y) support, ncurses built with widechar support and libev.

If you use Archlinux, you can take stable package from aur, or PKGBUILD from archlinux branch.
If you use OSX, you can take homebrew formula from osx branch.

To build mattext from sources open terminal, go to mattext dir, and run mkdir build; cd build; cmake ../ && make
This will build mattext binary. To test it, you can run ./mattext ../src/mattext.cpp
If you would like to install mattext, you can run make install

Examples:

  • mattext file - Show file one page at a time, and exit at the end;
  • mattext -ni file - Show file until exit key is pressed. When end is reached mattext starts reading it from the beginning;
  • tail -f file | mattext -n - Show file, waiting for at least one new line added to it before redrawing screen;
  • echo "" | mattext -ni -b 0 - Show animation until quit command key is pressed, similar to cmatrix;
  • mattext -niLv dir/* - Show all files from directory dir, centrating text horizontally by longest line and vertically, until exit key is pressed. When mattext reaches the end of the last file it starts reading the first file. This mode can be useful for showing off your ascii art collection;

You can redirect program output, in this case it would print text line by line, applying following transformations:

  • Break long lines so they fit in the terminal;
  • Center text horizontally;
  • Center text horizontally by longest string;
  • Replace tabs with spaces;

Troubleshooting:

If you see white squares instead of some symbols, there can be 3 options:

  1. Your terminal does not support unicode - you can use another terminal or --without-japanese option;
  2. You do not have any Japanese font - run fc-list :lang=ja and if this command shows nothing, install some. For example, Droid;
  3. Your terminal can't find this font - add it to the terminal's fonts list. For example, urxvt config should look like URxvt.font: xft:Liberation Mono:size=11, xft:Droid Sans Fallback:size=11;
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].