Created
March 17, 2019 09:53
-
-
Save mhuebert/80f29769558ecf252c9dec144019f94d to your computer and use it in GitHub Desktop.
tabular formatting wish
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; `table` configured with indent-1 and "align-tabular" | |
(table {:size [3 3]} | |
'_ "| " "|[ ]" "[|]" | |
[:cursor/move :x 1] " |" "[| ]" "[]|" | |
[:cursor/move :x -1] "| " "|[ ]" "[]") | |
;; just for context - one might compile ^that to | |
;; something like the following | |
(fn [x y] | |
(case [x y] | |
[[:cursor/move :x 1] "| "] " |" | |
[[:cursor/move :x 1] "|[ ]"] "[| ]" | |
[[:cursor/move :x 1] "[|]"] "[]|" | |
[[:cursor/move :x -1] "| "] "| " | |
[[:cursor/move :x -1] "|[ ]"] "|[ ]" | |
[[:cursor/move :x -1] "[|]"] "|[]")) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment