Convert raw text to beautiful pixel data.
This script uses PIL to translate text into images.
-
See
texted --help
for all options with default values -
Text can be read from a pipe
printf "some text" | texted - image.png
-
Image data can be written into a pipe
- When using a pipe, the output format is
PNG
- When using a pipe, the output format is
texted text.txt - > image.png
- Fonts can be specified by name or by full path
texted text.txt image.png --font 'Helvetica'
texted text.txt image.png --font /System/Library/Fonts/Helvetica.ttc
- Colors (
-bg
,-fg
) may be passed in various forms (all lines define a yellow background, some with alpha)
texted text.txt image.png -bg '#ff0'
texted text.txt image.png -bg '#ff0f'
texted text.txt image.png -bg '#ffff00'
texted text.txt image.png -bg '#ffff00ff'
texted text.txt image.png -bg 'rgb(255,255,0)'
texted text.txt image.png -bg 'rgb(100%,100%,0%)'
texted text.txt image.png -bg 'rgba(255,255,0,255)'
texted text.txt image.png -bg 'hsl(60,100%,50%)'
texted text.txt image.png -bg 'hsv(60,100%,100%)'
texted text.txt image.png -bg 'yellow'