This file contains hidden or 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
// For Adobe InDesign! | |
// this script will make a new file | |
// with the same dimensions as the currently active document | |
// and place the pages as linked files. | |
// The active source document needs a number of pages that is a multiple of 4 (4, 8, 12, 16, ...) | |
// Depending on the submitted pageamount per section | |
// the pages will be placed for saddle stitch binding. | |
// johannes lang january 2025 | |
// not heavily tested, use at own risk! |
This file contains hidden or 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
from collections import Counter | |
# Change the path to whatever file you want to be read | |
pth = 'MOBY-DICK.txt' | |
with open(pth) as f: | |
words = f.read().lower().split() | |
ct = Counter(words) | |
print (ct.most_common(100)) |
This file contains hidden or 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
# a simple script to generate pdfs of (german) text converted to braille. | |
# this script need the drawbot app! | |
# This follows the DIN 32976 | |
# a list of words | |
words = [ | |
'This should output braille', | |
] | |
dot_s = 16 # the dot size 1.6mm |
This file contains hidden or 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
''' | |
An interpretation of a work by Timm Ulrichs | |
see this blog post: https://letterformarchive.org/news/shaped-text | |
See other solutions in this twitter-thread: | |
https://twitter.com/MauriceMeilleur/status/1329218247594561538 | |
''' | |
# --------------- | |
# S E T T I N G S |
This file contains hidden or 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
# -*- coding: utf-8 -*- | |
import re | |
from random import shuffle | |
look_for = 'áàãâéêçíóôõúü' | |
omit = '[,:;.()!"?]' | |
max_amount = 2000000 | |
pattern = r'[^\s]*'+ '[' + re.escape(look_for) + ']' + r'[^\s]*' | |
found_words = [] |