Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jnyjny/pyliter
Generate PNG images of syntax highlighted Python.
https://github.com/jnyjny/pyliter
opengl png presentation python syntax-highlighter syntax-highlighting syntax-highlited
Last synced: 17 days ago
JSON representation
Generate PNG images of syntax highlighted Python.
- Host: GitHub
- URL: https://github.com/jnyjny/pyliter
- Owner: JnyJny
- License: apache-2.0
- Created: 2019-12-12T02:10:34.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2021-07-07T16:25:29.000Z (over 3 years ago)
- Last Synced: 2024-10-10T20:53:43.495Z (about 1 month ago)
- Topics: opengl, png, presentation, python, syntax-highlighter, syntax-highlighting, syntax-highlited
- Language: Python
- Homepage:
- Size: 1.79 MB
- Stars: 10
- Watchers: 3
- Forks: 0
- Open Issues: 5
-
Metadata Files:
- Readme: README.rst
- License: LICENSE
Awesome Lists containing this project
README
pyliter - Python syntax highlighting
====================================``pyliter`` is a Python 3 command-line tool that generates PNG files
from python source.Features
--------- syntax highlighting
- PNG files
- preview mode
- OpenGL rendering using pygletInstall
-------::
$ pip install pyliter
::
$ pip install git+https://github.com/JnyJny/pyliter
Usage
-----::
$ pyliter --help
Usage: pyliter [OPTIONS] COMMAND [ARGS]...
Python syntax highlighting
Options:
--install-completion Install completion for the current shell.
--show-completion Show completion for the current shell, to copy it or
customize the installation.
--help Show this message and exit.
Commands:
list List builtin text styles.
render Renders syntax-highlighted text to PNG file or displayed in a...::
$ pyliter render --help
Usage: pyliter render [OPTIONS] INPUT_FILE
Renders syntax-highlighted text to PNG file or displayed in a window.
If the optional output path is omitted, preview is enabled automatically.
Arguments:
INPUT_FILE [required]
Options:
-o, --output PATH
-s, --start-line INTEGER [default: 0]
-L, --line-count INTEGER [default: 10]
-N, --no-line-numbers [default: False]
-p, --preview [default: False]
-t, --transparent [default: False]
--style-name TEXT [default: default]
--font-name TEXT [default: courier]
--font-size INTEGER [default: 24]
--help Show this message and exit.Example
-------.. image:: https://github.com/JnyJny/pyliter/blob/master/examples/screenshot.png
:width: 400
:alt: Super Awesome PNG Screenshot