Created
March 26, 2021 02:10
-
-
Save arrowtype/9e71ca44edde92a6b3bd02320a022e00 to your computer and use it in GitHub Desktop.
Make a cool reflected alphabet pattern in Drawbot.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Make a cool reflected alphabet pattern. | |
Inspired by Klaus Burkhardt and Reinhard Döhl, Rot 40: | |
Poem Structures In the Looking Glass, Edition Rot, Stuttgart, 1969. | |
https://twitter.com/Lett_Arc/status/1375252819620466688 | |
""" | |
s = "ABCDEFGHIJKLMNOPQRSTUVWXYZ" | |
w, h = 2160, 2700 | |
padding = 112 | |
fontSize = w* 0.027 | |
newPage(w, h) | |
rect(0,0,w,h) | |
fill(1) | |
lineHeight(fontSize*0.845) | |
tracking(fontSize*0.027) | |
font("HelveticaNeue",fontSize) | |
# font("NameSansDisplay-Bold",fontSize) # actually made to look best with Name Sans | |
def drawABC(): | |
draw = "" | |
for i, c in enumerate(s): | |
draw += s[i:] + s[:i] + "\n" | |
textBox(draw,(0, 0, w/2-w*0.0005, h/2), align="right") | |
drawABC() | |
with savedState(): | |
transform((-1, 0, 0, 1, w, 0)) | |
drawABC() | |
with savedState(): | |
transform((1, 0, 0, -1, 0, h)) | |
drawABC() | |
with savedState(): | |
transform((-1, 0, 0, -1, w, h)) | |
drawABC() | |
import os | |
currentDir = os.path.dirname(os.path.abspath(__file__)) | |
saveImage(currentDir + "/grid.png") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment