"""Regenerate all 28 diagrams + verify pixel widths."""
import gen_a, gen_b, gen_c, gen_d

paths = []
for mod in (gen_a, gen_b, gen_c, gen_d):
    for fn in mod.ALL:
        paths.append(fn())

assert len(paths) == 28, len(paths)
from PIL import Image
bad = []
for p in paths:
    im = Image.open(p)
    print(f"{im.size[0]:5d}x{im.size[1]:<5d} {p.split('/')[-1]}")
    if im.size[0] < 1400:
        bad.append(p)
print("WIDTH CHECK:", "ALL >= 1400px" if not bad else f"TOO NARROW: {bad}")
