- Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathtext.py
More file actions
Latest commit
18 lines (13 loc) · 452 Bytes
/
Copy pathtext.py
File metadata and controls
18 lines (13 loc) · 452 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
importpixie
image=pixie.Image(200, 200)
image.fill(pixie.Color(1, 1, 1, 1))
font=pixie.read_font("examples/data/Roboto-Regular_1.ttf")
font.size=20
text="Typesetting is the arrangement and composition of text in graphic design and publishing in both digital and traditional medias."
image.fill_text(
font,
text,
bounds=pixie.Vector2(180, 180),
transform=pixie.translate(10, 10)
)
image.write_file("examples/text.png")