nider

https://img.shields.io/pypi/v/nider.svg https://img.shields.io/travis/pythad/nider.svg Documentation Status Updates

Python package to add text to images, textures and different backgrounds

nider is an approach to make generation of text based images simple yet flexible. Creating of an image is as simple as describing units you want to be rendered to the image and choosing a method that will be used for drawing.

Installation

$ pip install nider

Example

Creating a simple image is as easy as

from nider.models import Content
from nider.models import Header
from nider.models import Linkback
from nider.models import Paragraph
from nider.models import Image

header = Header('Your super interesting title!')
para = Paragraph('Lorem ipsum dolor sit amet.')
linkback = Linkback('foo.com | @username')
content = Content(para, header, linkback, padding=60)

img = Image(content, fullpath='result.png')

img.draw_on_bg('#212121')

Drawn using nider

On a textture

Draw on texture example

On a solid color

Draw on background example

On an image

Draw on image example

Code used to generate featured images can be found here