winprint
libapps
winprint | libapps | |
---|---|---|
1 | 1 | |
69 | 37 | |
- | - | |
0.0 | 0.0 | |
10 months ago | almost 2 years ago | |
C# | JavaScript | |
MIT License | BSD 3-clause "New" or "Revised" License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
winprint
-
Everything you ever wanted to know about terminals(but were afraid to ask)
I built a cross platform app to print 'pretty formatted' source code [1]. I didn't want to re-invent the wheel on formatting source code, so looked at all the existing libraries. Originally I figured formatting to HTML, and then building a print-friendly HTML render would work. But this proved super challenging. I tried a dozen HTML engines (including Chromium) but none gave me enough control to render just a single page of the original source file.
Then I noticed Pygments, a Python-based library for pretty formatting source code, has an option to output an ANSI formatted file. I quickly found a bunch of libraries that could render ANSI formatted text to a print canvas.
In the end, I put the original source code file through 'pygmentize -16m -o tempfile.an` (`16m` is the 16M color terminal ANSI formatter) and pipe the `tempfile.an` through a print-optimized renderer to actually print the source code.
ANSI escapes FTW!
[1] WinPrint - https://github.com/tig/winprint
libapps
-
Everything you ever wanted to know about terminals(but were afraid to ask)
Upstream: https://chromium.googlesource.com/apps/libapps/+/HEAD/hterm
Fork used by iSH: https://github.com/ish-app/libapps/tree/master/hterm
I looked at the docs (https://github.com/ish-app/libapps/blob/master/hterm/doc/Con...) and it appears to use the same protocol as iTerm.
Here's an implementation: https://github.com/ish-app/libapps/blob/master/hterm/etc/hte...
What are some alternatives?
CsharpToColouredHTML - C# to HTML Converter with syntax highlighting
termfo - A terminfo library for Go
blessed - Blessed is an easy, practical library for making python terminal apps