All Projects → jbyuki → venn.nvim

jbyuki / venn.nvim

Licence: MIT license
Draw ASCII diagrams in Neovim

Programming Languages

lua
6591 projects

Projects that are alternatives of or similar to venn.nvim

TextGraphic
TextGraphic is a framework for creating Textual Graphics. It provides layers, styling, rich color, text justification, layouts, tables, view-ports, transparency, etc.
Stars: ✭ 83 (-84.6%)
Mutual labels:  ascii-art, ascii-graphics
durdraw
Animated Unicode, ANSI and ASCII Art Editor for Linux/Unix/macOS
Stars: ✭ 55 (-89.8%)
Mutual labels:  ascii-art, ascii-graphics
aart
Convert images and video to ascii art!
Stars: ✭ 18 (-96.66%)
Mutual labels:  ascii-art, ascii-graphics
Asciitosvg
Create beautiful SVG renderings of ASCII diagrams.
Stars: ✭ 82 (-84.79%)
Mutual labels:  ascii-art, diagrams
outfancy
Python3 library to print tables in Terminal.
Stars: ✭ 47 (-91.28%)
Mutual labels:  ascii-art, ascii-graphics
asciiarena
Terminal multiplayer deathmatch game
Stars: ✭ 34 (-93.69%)
Mutual labels:  ascii-art, ascii-graphics
xibalba
A Mayan roguelike
Stars: ✭ 50 (-90.72%)
Mutual labels:  ascii-art, ascii-graphics
nabla.nvim
take your scientific notes ✏️ in Neovim
Stars: ✭ 391 (-27.46%)
Mutual labels:  nvim, ascii-art
asciju
Conversion of Image, video, text into ASCII format
Stars: ✭ 11 (-97.96%)
Mutual labels:  ascii-art, ascii-graphics
telescope-zoxide
An extension for telescope.nvim that allows you operate zoxide within Neovim.
Stars: ✭ 126 (-76.62%)
Mutual labels:  nvim
neocode
Completely theme responsive, lean, streamlined lua configuration for neovim (dotfiles). NeoCode aims to provide a fluent experience in nvim and vscode.
Stars: ✭ 38 (-92.95%)
Mutual labels:  nvim
jpgtxt
Generating jpg files that can be viewed both in image viewer and text editor (as ASCII art)
Stars: ✭ 24 (-95.55%)
Mutual labels:  ascii-art
wechit
WeChat in Terminal (微信终端版)
Stars: ✭ 74 (-86.27%)
Mutual labels:  ascii-art
txtpic
Generate Unicode art from images
Stars: ✭ 22 (-95.92%)
Mutual labels:  ascii-art
asm16 projects
My small projects writen in 16 bit asm (NOTE: those are my practice projects that I wrote when I was 15, I give no warranty for this code!)
Stars: ✭ 20 (-96.29%)
Mutual labels:  ascii-art
asciiartview
Drawing for AsciiArt
Stars: ✭ 29 (-94.62%)
Mutual labels:  ascii-art
bpmn-visualization-js
A TypeScript library for visualizing process execution data on BPMN diagrams
Stars: ✭ 113 (-79.04%)
Mutual labels:  diagrams
ncm2-otherbuf
ncm2 plugin for completing words in other buffers
Stars: ✭ 19 (-96.47%)
Mutual labels:  nvim
zk-nvim
Neovim extension for zk
Stars: ✭ 207 (-61.6%)
Mutual labels:  nvim
dotfiles
Opinionated garbage for your terminal. Gotta get that yolo swag.
Stars: ✭ 37 (-93.14%)
Mutual labels:  nvim

venn.nvim

Draw ASCII diagrams in Neovim.

Installation

Install using your prefered method:

Plug 'jbyuki/venn.nvim'
use "jbyuki/venn.nvim"

Usage

  • set virtualedit=all or set ve=all. This will allow you to freely move the cursor in the buffer. (see help virtualedit).

  • Enter in Visual Block mode using <C-v>. Select the region where the box should be.

  • Invoke :VBox. This will draw a rectangle. In case, it has a width or a height of 1, it will draw a line.

Key Mapping

Using hydra.nvim

Draw diagrams

Using toggle command

You can map :VBox commands to allow different ways of drawing lines.

Use the following function in your neovim config to toggle drawing lines on HJKL directional keys to allow for faster creation of diagrams:

-- venn.nvim: enable or disable keymappings
function _G.Toggle_venn()
    local venn_enabled = vim.inspect(vim.b.venn_enabled)
    if venn_enabled == "nil" then
        vim.b.venn_enabled = true
        vim.cmd[[setlocal ve=all]]
        -- draw a line on HJKL keystokes
        vim.api.nvim_buf_set_keymap(0, "n", "J", "<C-v>j:VBox<CR>", {noremap = true})
        vim.api.nvim_buf_set_keymap(0, "n", "K", "<C-v>k:VBox<CR>", {noremap = true})
        vim.api.nvim_buf_set_keymap(0, "n", "L", "<C-v>l:VBox<CR>", {noremap = true})
        vim.api.nvim_buf_set_keymap(0, "n", "H", "<C-v>h:VBox<CR>", {noremap = true})
        -- draw a box by pressing "f" with visual selection
        vim.api.nvim_buf_set_keymap(0, "v", "f", ":VBox<CR>", {noremap = true})
    else
        vim.cmd[[setlocal ve=]]
        vim.cmd[[mapclear <buffer>]]
        vim.b.venn_enabled = nil
    end
end
-- toggle keymappings for venn using <leader>v
vim.api.nvim_set_keymap('n', '<leader>v', ":lua Toggle_venn()<CR>", { noremap = true})

veenDemo

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].